Skip to Content.
Sympa Menu

cgal-discuss - [cgal-discuss] performance of finite_adjacent_vertices

Subject: CGAL users discussion list

List archive

[cgal-discuss] performance of finite_adjacent_vertices


Chronological Thread 
  • From: Frankie Li <>
  • To:
  • Subject: [cgal-discuss] performance of finite_adjacent_vertices
  • Date: Tue, 25 May 2010 21:23:02 -0400

Hi all,

I'm trying to traverse all neighbors of each vertex in a regular triangulation, and naively, I've done something like this:

// pseudo-code

for( Finite_vertex_iterator it = tr.finite_vertices_begin();
it != tr.finite_vertices_end(); ++ it )
{

vector<Vertex_handle> Ngb_vertices;
tr.finite_adjacent_vertices( it, std::back_inserter( Ngb_vertices ));
}

However, I found it to be surprisingly slow. I have approximately 15000 vertices, and I'm using Exact_predicates_inexact_constructions_kernel. (It takes about 3000 seconds to go through the loop above for 15000 vertices. I'm running on a Core 2 Quad machine.)


Any advice is welcomed! Thanks!

Frankie



Archive powered by MHonArc 2.6.16.

Top of Page