[MOAB-dev] canonical face connectivity from 10-nodded tet mesh
Julien Vignollet
vignollet at civil.gla.ac.uk
Mon May 31 11:02:33 CDT 2010
Dear Moab developers,
I am a new (and very modest!) moab user experiencing difficulties when trying to retrieve the canonical face connectivities in a mesh of 10 nodded tetrahedrons (order based on Tautges system from the paper "Canonical numbering systems for finite-element codes") . I am trying to use moab in a 3D finite element code to model multi-phasic hyperelastic elements. I am using Gmsh and Paraview for pre- and post-processing. Attached is the basic mesh I am using to get started.
Apart from a small problem when importing the gmsh file (it seems nodes 7 and 8 are swapped), my main difficulty arises when I try to access the faces connectivity (see extract of code at the end of this message). This technique worked successfully to obtain the element connectivities (i.e. the 10 nodes of the tets in a canonical order) when I loop over the elements, but it fails when I loop over the faces. The handle conn gets populated with the correct 6 face nodes but not in a canonical order. The vertex nodes are in the right order, but the mid-nodes are not and I don't see any consistent pattern.
Is there anything I am doing wrong here? Could you advise any tip to get around this?
MBRange elems, faces;
const MBEntityHandle* conn;
int num_nodes;
double coord_node_face[6*3];
result = gMB->load_mesh("test_mesh_modified.msh"); EE(gMB);
result = gMB->get_entities_by_dimension(0, 3, elems);
gMB->get_adjacencies(elems,2,true,faces,MBInterface::UNION);
for (MBRange::iterator fit = faces.begin(); fit != faces.end(); fit++) {
gMB->get_connectivity(*fit,conn,num_nodes);
gMB->get_coords(conn,num_nodes,coord_node_face);
if (coord_node_face[1]==0.5) [... call a function using face canonical connectivities...]
}
result = gMB->write_file("Vtk_file.vtk")
Hope that this was clear enough and not too lengthy!
Regards,
---
Julien Vignollet
PhD Student
Department of Civil Engineering
The University of Glasgow, Glasgow G12 8LT
Tel: +44 (0)141 330 6027
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/moab-dev/attachments/20100531/b9fca83a/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_mesh_modified.msh
Type: application/octet-stream
Size: 2372 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/moab-dev/attachments/20100531/b9fca83a/attachment.obj>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/moab-dev/attachments/20100531/b9fca83a/attachment-0001.htm>
More information about the moab-dev
mailing list