Hi FreeFem community,
I have a 3d mesh and I need to get the data about the number of tetrahedrons and to obtain the adjacent elements of each one. According to the documentation, in 2d i can compute the number of triangles according to the command Th.nt and the adjacencies by Th.adj
However, it is not specified how to obtain the number of tetrahedrons in 3d. Also, I need to specify each element by its number to compute its adjacencies by using the above command.
You can use the following code to test and visualize:
mesh3 Th = cube(2, 1, 1);
cout << "Volume: " << Th.measure << endl;
cout << "Number of tetrahedron: " << Th.nt << endl;
cout << "Number of vertex: " << Th.nv << endl;
cout << "Number of boundary triangle: " << Th.nbe << endl;
This section explains a little bit.
Thank you very much for your reply. Yes, finally worked by using the commands you mentioned in the previous post.