Chaste
Release::2017.1
|
#include <QuadraticMeshHelper.hpp>
Static Public Member Functions | |
static void | AddInternalNodesToElements (AbstractTetrahedralMesh< DIM, DIM > *pMesh, AbstractMeshReader< DIM, DIM > *pMeshReader) |
static void | AddInternalNodesToBoundaryElements (AbstractTetrahedralMesh< DIM, DIM > *pMesh, AbstractMeshReader< DIM, DIM > *pMeshReader) |
static void | AddNodesToBoundaryElements (AbstractTetrahedralMesh< DIM, DIM > *pMesh, AbstractMeshReader< DIM, DIM > *pMeshReader) |
static void | CheckBoundaryElements (AbstractTetrahedralMesh< DIM, DIM > *pMesh) |
static void | AddNodeToBoundaryElement (AbstractTetrahedralMesh< DIM, DIM > *pMesh, BoundaryElement< DIM-1, DIM > *pBoundaryElement, Element< DIM, DIM > *pElement, unsigned internalNode) |
static void | AddNodeToBoundaryElement (AbstractTetrahedralMesh< DIM, DIM > *pMesh, BoundaryElement< DIM-1, DIM > *pBoundaryElement, Node< DIM > *pNode) |
static void | AddExtraBoundaryNodes (AbstractTetrahedralMesh< DIM, DIM > *pMesh, BoundaryElement< DIM-1, DIM > *pBoundaryElement, Element< DIM, DIM > *pElement, unsigned nodeIndexOppositeToFace) |
static void | HelperMethod1 (unsigned boundaryElemNode0, unsigned boundaryElemNode1, Element< DIM, DIM > *pElement, unsigned node0, unsigned node1, unsigned node2, unsigned &rOffset, bool &rReverse) |
static void | HelperMethod2 (AbstractTetrahedralMesh< DIM, DIM > *pMesh, BoundaryElement< DIM-1, DIM > *pBoundaryElement, Element< DIM, DIM > *pElement, unsigned internalNode0, unsigned internalNode1, unsigned internalNode2, unsigned offset, bool reverse) |
A helper class for QuadraticMesh and DistributedQuadratic mesh, containing utility methods that are common to both classes (and only require public access).
Definition at line 47 of file QuadraticMeshHelper.hpp.
|
static |
Given a face in an element (defined by giving an element and the opposite node number to the face) that corresponds to a given boundary element, this method adds in the face's internal nodes to the boundary element (in the correct order).
pMesh | the (quadratic) mesh to modify |
pBoundaryElement | pointer to a boundary element in the mesh |
pElement | pointer to an element in the mesh |
nodeIndexOppositeToFace | index of a node in the mesh |
Definition at line 291 of file QuadraticMeshHelper.cpp.
References AbstractElement< ELEMENT_DIM, SPACE_DIM >::GetNodeGlobalIndex().
Referenced by QuadraticMeshHelper< DIM >::AddNodesToBoundaryElements().
|
static |
Top level method for adding internal nodes to the mesh's boundary elements.
Note that the internal nodes must already exist in the mesh; this method just associates them with the relevant boundary elements. If the mesh on disk has internal node indices in the boundary elements file, then we just look them up. Otherwise we figure out which normal element has each boundary element as a face, and extract the internal nodes from that.
pMesh | the mesh to modify |
pMeshReader | pointer to the reader for accessing the on-disk mesh data |
Definition at line 104 of file QuadraticMeshHelper.cpp.
References AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetBoundaryElementIteratorBegin(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetNumLocalBoundaryElements(), and AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetOrderOfBoundaryElements().
Referenced by DistributedQuadraticMesh< DIM >::ConstructFromMeshReader(), and QuadraticMesh< DIM >::ConstructFromMeshReader().
|
static |
Top level method for adding internal nodes to the mesh's elements.
Note that the internal nodes must already exist in the mesh; this method just associates them with the relevant elements.
pMesh | the mesh to modify |
pMeshReader | pointer to the reader for accessing the on-disk mesh data |
Definition at line 55 of file QuadraticMeshHelper.cpp.
References Node< SPACE_DIM >::AddElement(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetElement(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetElementIteratorBegin(), AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetElementIteratorBegin(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetElementIteratorEnd(), AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetElementIteratorEnd(), AbstractMesh< ELEMENT_DIM, SPACE_DIM >::GetNodeOrHaloNode(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetNumLocalElements(), Node< SPACE_DIM >::MarkAsInternal(), AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::Reset(), and AbstractMesh< ELEMENT_DIM, SPACE_DIM >::rGetNodePermutation().
Referenced by DistributedQuadraticMesh< DIM >::ConstructFromMeshReader(), and QuadraticMesh< DIM >::ConstructFromMeshReader().
|
static |
Used by AddInternalNodesToBoundaryElements in the case where the on-disk mesh doesn't have the associations already, and by the linear -> quadratic mesh conversion routines.
If there is an on-mesh disk that has containing element information in its edge/face file, then this can be supplied to speed up finding the full element containing each boundary element.
pMesh | the mesh to modify |
pMeshReader | pointer to the reader for accessing the on-disk mesh data, if any; NULL otherwise |
Definition at line 128 of file QuadraticMeshHelper.cpp.
References QuadraticMeshHelper< DIM >::AddExtraBoundaryNodes(), ElementData::ContainingElement, Node< SPACE_DIM >::ContainingElementsBegin(), Node< SPACE_DIM >::ContainingElementsEnd(), EXCEPTION, AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetBoundaryElementIteratorBegin(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetBoundaryElementIteratorEnd(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetElement(), Node< SPACE_DIM >::GetIndex(), AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNextFaceData(), AbstractElement< ELEMENT_DIM, SPACE_DIM >::GetNodeGlobalIndex(), AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetReadContainingElementOfBoundaryElement(), and AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::Reset().
Referenced by QuadraticMesh< DIM >::ConstructFromLinearMeshReader().
|
static |
This method adds the given node (defined by an element and a node index) to the given boundary element, and also sets the node as a boundary node and adds it to the mesh's boundary nodes.
pMesh | the (quadratic) mesh to modify |
pBoundaryElement | pointer to a boundary element in the mesh |
pElement | pointer to an element in the mesh |
internalNode | index of a node in the mesh |
Definition at line 278 of file QuadraticMeshHelper.cpp.
References AbstractElement< ELEMENT_DIM, SPACE_DIM >::GetNode().
|
static |
This method adds the given node to the given boundary element, and also sets the node as a boundary node and adds it to the mesh's boundary nodes.
pMesh | the (quadratic) mesh to modify |
pBoundaryElement | pointer to a boundary element in the mesh |
pNode | pointer to a node in the mesh |
Definition at line 261 of file QuadraticMeshHelper.cpp.
References AbstractElement< ELEMENT_DIM, SPACE_DIM >::AddNode(), Node< SPACE_DIM >::IsBoundaryNode(), AbstractMesh< ELEMENT_DIM, SPACE_DIM >::mBoundaryNodes, and Node< SPACE_DIM >::SetAsBoundaryNode().
|
static |
Check whether all the boundary elements in the given mesh have the expected number of nodes.
pMesh | the mesh to check |
Definition at line 246 of file QuadraticMeshHelper.cpp.
References AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetBoundaryElementIteratorBegin(), and AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::GetBoundaryElementIteratorEnd().
Referenced by DistributedQuadraticMesh< DIM >::ConstructFromMeshReader(), and QuadraticMesh< DIM >::ConstructFromMeshReader().
|
static |
Nasty helper method for AddNodeToBoundaryElement() in 3D.
This method takes in the three vertices of a face which match the given boundary element, and figure out if the order of the nodes in the face is reversed in the boundary element (returned in the bool 'rReverse'). Also, the offset between the first node in the face (as given to this method) and the first node in the boundary element is computed (returned in the variable 'rOffset'). Offset should then be applied before reverse to match the face nodes to the boundary element nodes.
boundaryElemNode0 | |
boundaryElemNode1 | |
pElement | |
node0 | |
node1 | |
node2 | |
rOffset | |
rReverse |
Definition at line 347 of file QuadraticMeshHelper.cpp.
References AbstractElement< ELEMENT_DIM, SPACE_DIM >::GetNodeGlobalIndex().
|
static |
Nasty helper method for AddNodeToBoundaryElement() in 3D.
This method takes the three internal nodes for some face in some element, applies the given offset and reverse (see HelperMethod1) to them, to get the ordered internal nodes which should given to the boundary element. It then calls AddNodeToBoundaryElement with each of the three internal nodes.
pMesh | |
pBoundaryElement | |
pElement | |
internalNode0 | |
internalNode1 | |
internalNode2 | |
offset | |
reverse |
Definition at line 399 of file QuadraticMeshHelper.cpp.