Hi David,
> I'm not very familiar with the VISAD library, and at the moment am only
> using it for delaunay triangulations. I'm trying to create a
> triangulation for a set of points (ie, a list of coordinates) in two
> dimensions. I'm probably using the Watson algorithm, though these
> questions are of a more general nature.
>
> Firstly, the constructor calls for an array of type
> float[dimension][number_of_points] . I assume for two dimensions, this
> would be an array of x and corresponding y values?
Yes, given samples[2][number_of_points], samples[0] is an
array of x values and samples[1] is an array of y values.
> Secondly, once you have the triangulation, I'm at a loss as to how to
> get any information out of it. The class has these fields:
>
> Tri
>
> public int[][] Tri
>
> triangles/tetrahedra --> vertices
>
> Tri = new int[ntris][dim + 1]
This is the key output, a list of triangles (in two
dimensions, tetrahedra in three dimensions, etc). ntris
is the number of triangles. In 2-D, Tri[i] is an array
of [3] integers, which are three indices into the
samples[0] and samples[1] arrays to get the x and y values
of the three verticees of the triangle.
> ________________________________
>
>
> Vertices
>
> public int[][] Vertices
>
> vertices --> triangles/tetrahedra
>
> Vertices = new int[nrs][nverts[i]]
nrs is the length of the samples[0] and samples[1] arrays.
For sample i, Vertices[i] is a (variable length) list of
indices into the Tri array above, giving the indices of
the triangles that include vertex i.
You can use Tri and Vertices together to traverse the
triangulation. If you don't need to traverse, then you
can probably ignore all arrays except Tri.
> ________________________________
>
>
> Walk
>
> public int[][] Walk
>
> triangles/tetrahedra --> triangles/tetrahedra
>
> Walk = new int[ntris][dim + 1]
Also useful for traversing the triangulation, in this case
giving the indices of triangles that share edges with the
current triangle.
> ________________________________
>
>
> Edges
>
> public int[][] Edges
>
> tri/tetra edges --> global edge number
>
> Edges = new int[ntris][3 * (dim - 1)];
'global edge number' is the number of an edge that
is unique among the whole triangulation.
> ________________________________
>
>
> NumEdges
>
> public int NumEdges
>
> number of unique global edge numbers
>
> nverts would be the number of vertices(but why is it an array?),
nverts is an array as the second index of the Vertices array
since different vertices may be part of different numbers of
triangles.
> ntris would be the number of triangles, dim would be the dimension, but
> what is nrs?
The total number of vertices, i.e., the length of the
second index of samples[][].
If you do not need to traverse the triangulation, please
ignore all but the Tri array.
Good luck,
Bill