initial commit for version 1.6.x patch release
[OpenFOAM-1.6.x.git] / applications / test / triTet / triTet.C
blob5c850a4377ed9fc299af4fa4042f6fdf109f2e07
1 #include "point.H"
2 #include "triangle.H"
3 #include "tetrahedron.H"
4 #include "IOstreams.H"
6 using namespace Foam;
8 int main()
10     triangle<point, point> tri
11     (
12         vector(0, 0, 0),
13         vector(1, 0, 0),
14         vector(1, 1, 0)
15     );
17     Info<< "tri circumCentre = " << tri.circumCentre() << endl;
18     Info<< "tri circumRadius = " << tri.circumRadius() << endl;
20     tetrahedron<point, point> tet
21     (
22         vector(1, 0, 0),
23         vector(0, 1, 0),
24         vector(0, 0, 1),
25         vector(0.5773502, 0.5773502, 0.5773502)
26     );
28     Info<< "tet circumCentre = " << tet.circumCentre() << endl;
29     Info<< "tet circumRadius = " << tet.circumRadius() << endl;
31     vector a(Sin);
32     vector b(Sin);
33     vector c(Sin);
34     vector d(Sin);
36     Info<< "tet circumRadius = "
37         << tetrahedron<point, point>(a, b, c, d).circumRadius() << endl;
39     return 0;