Files Used by the TRIANGLE Program (original) (raw)
TRIANGLE_FILES
Files Used by the TRIANGLE Program
TRIANGLE_FILES is a data directory which contains some examples of the groups of files used by the TRIANGLE and SHOWME programs to produce triangulations and Voronoi decompositions of a region.
Licensing:
The computer code and data files described and made available on this web page are distributed underthe GNU LGPL license.
Related Data and Programs:
POLY, a data directory which contains examples of POLY files, a 2D format used by triangle and showme for Planar Straight Line Graphs.
SHOWME, a C program which uses the X Window library to display triangulatons, by Jonathan Shewchuk.
TRIANGLE, a C program which computes a triangulation of a geometric region, by Jonathan Shewchuk.
TRIANGLE_DISPLAY, a MATLAB program which displays the nodes and elements of a triangulation on the MATLAB graphics screen, assuming the data has been stored in NODE and ELE files by the TRIANGLE program.
Reference:
- Jonathan Shewchuk,
Triangle: Engineering a 2D Quality Mesh Generator and Delaunay Triangulator,
in Applied Computational Geometry: Towards Geometric Engineering,
edited by Ming Lin, Dinesh Manocha,
Lecture Notes in Computer Science, Volume 1148,
Springer, 1996,
ISBN: 354061785X,
LC: QA448.D38.A635. - Jonathan Shewchuk,
Delaunay Refinement Algorithms for Triangular Mesh Generation,
Computational Geometry, Theory and Applications,
Volume 23, pages 21-74, May 2002. - http://www-2.cs.cmu.edu/~quake/triangle.html, the TRIANGLE web site;
Example Files:
A is a planar straight line graph of the capital letter A. We use it as input to get a constrained Delaunay triangulation.
- <A.poly>, the POLY file;
- <A.1.poly>, the output polygon file;
- <A.1.node>, the output node file;
- <A.1.ele>; the output element file;
AIRFOIL_EXTERIOR defines the boundary of an airfoil, and a box. We want to mesh the region inside the box and exterior to the airfoil. We use the command
triangle -a0.05 airfoil_exterior.poly
- <airfoil%5Fexterior.poly>, the POLY file;
- <airfoil%5Fexterior%5Felements.png>, a PNG image of the level 1 mesh.
- <airfoil%5Fexterior.node>, the level 0 node file;
- <airfoil%5Fexterior.1.ele>, the level 1 element file.
- <airfoil%5Fexterior.1.node>, the level 1 node file;
- <airfoil%5Fexterior.1.poly>; the level 1 poly file;
AIRFOIL_INTERIOR defines the boundary of an airfoil, whose interior we want to mesh. We use the command
triangle -a0.05 airfoil_interior.poly
- <airfoil%5Finterior.poly>, the POLY file;
- <airfoil%5Finterior%5Felements.png>, a PNG image of the level 1 mesh.
- <airfoil%5Finterior.node>, the level 0 node file;
- <airfoil%5Finterior.1.ele>, the level 1 element file.
- <airfoil%5Finterior.1.node>, the level 1 node file;
- <airfoil%5Finterior.1.poly>; the level 1 poly file;
BOX is a planar straight line graph of a double box. We use it as input to get a constrained Delaunay triangulation.
- <box.poly>, the initial POLY file; The command "triangle -pc box" creates the first mesh. (We need the -pc because we didn't surround our initial area with segments.)
- <box.1.poly>, the POLY file;
- <box.1.node>, the node file;
- <box.1.ele>; the element file;
- <box.1.ele.png>; a PNG image of the elements. The command "triangle -rpa0.2 box.1" refines the box.1 mesh with an area constraint of 0.2:
- <box.2.poly>, the POLY file;
- <box.2.node>, the node file;
- <box.2.ele>; the element file;
- <box.2.ele.png>; a PNG image of the elements. The command "triangle -rpa0.05 box.2" refines the box.2 mesh with an area constraint of 0.05, 1/4 of the previous maximum area:
- <box.3.poly>, the POLY file;
- <box.3.node>, the node file;
- <box.3.ele>; the element file;
- <box.3.ele.png>; a PNG image of the elements. The command "triangle -rpa0.0125 box.3" refines the box.3 mesh with an area constraint of 0.0125, 1/4 of the previous maximum area:
- <box.4.poly>, the POLY file;
- <box.4.node>, the node file;
- <box.4.ele>; the element file;
- <box.4.ele.png>; a PNG image of the elements.
DIAMOND_02_00009 is another set of test data, for which we want the Voronoi diagram.
- <diamond%5F02%5F00009.node>, a sample input file of 9 nodes;
- <diamond%5F02%5F00009.1.node>, the output Delaunay nodes;
- <diamond%5F02%5F00009.1.ele>, the output Delaunay triangles;
- <diamond%5F02%5F00009.1.v.node>, the output Voronoi vertices;
- <diamond%5F02%5F00009.1.v.edge>, the output lines and rays that make up the Voronoi diagram;
DOUBLE_HEX describes a unit square with two hexagonal holes. 72 points are listed on the outer boundary, and 12 on each of the holes. It is desired to create a nice looking mesh of about 500 nodes, and no additional nodes on the boundary segments.
- <double%5Fhex.poly>, is the original POLY file;
- <double%5Fhex.poly.png>, a PNG image of the segments; Our first command
triangle -p double_hex.poly
requests that we triangulate the current points:
- <double%5Fhex.1.node>, the NODE file after step 1;
- <double%5Fhex.1.node.png>, a PNG image of the nodes.
- <double%5Fhex.1.poly>, the POLY file after step 1;
- <double%5Fhex.1.ele>, the ELE file after step 1;
- <double%5Fhex.1.ele.png>, a PNG image of the ELE file, created by SHOWME; Our second command
triangle -pqY -a0.0015 double_hex.1.poly
requests that we triangulate the current points, adding new nodes as necessary to make a nice mesh, with no triangle being larger than 0.0015 in area, and with no points added on boundary segments. We end up with 525 nodes and 956 elements:
- <double%5Fhex.2.node>, the NODE file after step 2;
- <double%5Fhex.2.node.png>, a PNG image of the nodes.
- <double%5Fhex.2.poly>, the POLY file after step 2;
- <double%5Fhex.2.ele>, the ELE file after step 2;
- <double%5Fhex.2.ele.png>, a PNG image of the elements;
DOUBLE_HEX2 describes a unit square with two hexagonal holes. 36 points are listed on the outer boundary, and 6 on each of the holes. It is desired to create a nice looking mesh of about 235 elements, and no additional nodes on the boundary segments.
- <double%5Fhex2.poly>, is the original POLY file;
- <double%5Fhex2.poly.png>, a PNG image of the segments; Our first command
triangle -p double_hex2.poly
requests that we triangulate the current points:
- <double%5Fhex2.1.node>, the NODE file after step 1;
- <double%5Fhex2.1.poly>, the POLY file after step 1;
- <double%5Fhex2.1.ele>, the ELE file after step 1;
- <double%5Fhex2.1.ele.png>, a PNG image of the ELE file, created by SHOWME; Our second command
triangle -pqY -a0.0060 double_hex2.1.poly
requests that we triangulate the current points, adding new nodes as necessary to make a nice mesh, with no triangle being larger than 0.0060 in area, and with no points added on boundary segments. We end up with 141 nodes and 236 elements:
- <double%5Fhex2.2.node>, the NODE file after step 2;
- <double%5Fhex2.2.poly>, the POLY file after step 2;
- <double%5Fhex2.2.ele>, the ELE file after step 2;
- <double%5Fhex2.2.ele.png>, a PNG image of the ELE file, created by SHOWME;
DOUBLE_HEX3 describes a unit square with two hexagonal holes. 4 points are listed on the outer boundary, and 6 on each of the holes. We want triangle to triangulate this region.
- <double%5Fhex3.poly>, is the POLY file;
- <double%5Fhex3.node>, is the NODE file;
- double_hex2.node.png, a PNG image of the nodes; Our command
triangle -pq -a0.0015 double_hex3.poly
requests that we triangulate the region, adding points as necessary so that no triangle has an area greater than 0.0015.
- <double%5Fhex3.1.node>, the NODE file after step 1;
- <double%5Fhex3.1.node.png>, a PNG image of the nodes.
- <double%5Fhex3.1.poly>, the POLY file after step 1;
- <double%5Fhex3.1.ele>, the ELE file after step 1;
- <double%5Fhex3.1.ele.png>, a PNG image of the elements;
ELL is a triangulation of an L-shaped region, using a mesh of 21 nodes and 24 elements.
- ell.node, the nodes;
- ell.ele, the elements;
- ell.png, a PNG image of the ELE file, created by SHOWME;
GREENLAND is a triangulation of Greenland, using a graded (varying-size) mesh of 33,343 nodes and 64,125 elements. The resulting image is essentially a red blob the shape of Greenland. However, using the ZOOM tool, it is possible to see interesting details of the mesh.
- greenland.node, the nodes;
- greenland.ele, the elements;
- greenland_zoom.png, a zoomed image of the upper right margin of the triangulation.
LA is a POLY file containing information representing soil layers. The data includes points that are bounded by line segments defining the different layers. The intent is that certain layers will be triangulated with smaller area requirements.
- la.poly, the POLY file;
SPIRAL is a node file containing points that form a spiral.
- <spiral.node>, the nodes;
- <spiral.node.png>, a PNG image of the nodes; The command "triangle spiral" produces a Delaunay triangulation of the points, in the following node and element files:
- <spiral.1.ele>, the elements;
- <spiral.1.ele.png>, a PNG image of the elements;
- <spiral.1.node>, the nodes;
- <spiral.1.node.png>, a PNG image of the nodes;
The command "triangle -q spiral" produces a Delaunay triangulation with no angle smaller than 20 degrees (the default). This is done by adding points as necessary: in the following node and element files:
- <spiral.q.1.ele>, the elements;
- <spiral.q.1.ele.png>, a PNG image of the elements;
- <spiral.q.1.node>, the nodes;
- <spiral.q.1.node.png>, a PNG image of the nodes;
The command "triangle -q32.5 spiral" produces a Delaunay triangulation with no angle smaller than 32.5 degrees. This is done by adding points as necessary: in the following node and element files:
- <spiral.r.1.ele>, the elements;
- <spiral.r.1.ele.png>, a PNG image of the elements;
- <spiral.r.1.node>, the nodes;
- <spiral.r.1.node.png>, a PNG image of the nodes;
SQUARE_CIRCLE_HOLE is a planar straight line graph of a square region with an off center circular hole, and 826 points computed by a CVT calculation, prepared by Hua Fei.
* <square%5Fcircle%5Fhole.poly>, the POLY file;
* [ square\_circle\_hole.1.node](square%5Fcircle%5Fhole.1.node), the nodes;
* [ square\_circle\_hole.1.ele](square%5Fcircle%5Fhole.1.ele), the elements;
* [ square\_circle\_hole.1.png](square%5Fcircle%5Fhole.1.png), an image of the triangulation.
* [ square\_circle\_hole.1.output.txt](square%5Fcircle%5Fhole.1.output.txt), the output file.
You can go up one level tothe DATA page.
Last revised on 09 October 2014.