A simplicial mesh data structure. More...
#include <SimpMeshRed.h>
Classes | |
struct | CellIteratorCompare |
Functor for comparing cell iterators by their identifiers. More... | |
struct | FaceCompare |
Functor for comparing faces. More... | |
struct | FaceIteratorCompare |
Functor for comparing face iterators. More... | |
class | IndSimpIter |
An indexed simplex iterator for a SimpMeshRed. More... | |
struct | NodeIteratorCompare |
Functor for comparing node iterators by their identifiers. More... | |
class | SimpIter |
A simplex iterator for a SimpMeshRed. More... | |
Public Types | |
enum | { N = _N, M = _M } |
The space dimension and simplex dimension. | |
typedef NodeContainer::value_type | Node |
A node. | |
typedef NodeContainer::iterator | NodeIterator |
Node iterator. | |
typedef NodeContainer::const_iterator | NodeConstIterator |
Vertex const iterator. | |
typedef CellContainer::value_type | Cell |
A cell (simplex). | |
typedef CellContainer::iterator | CellIterator |
Cell iterator. | |
typedef CellContainer::const_iterator | CellConstIterator |
Cell const iterator. | |
typedef std::pair < CellConstIterator, int > | ConstFace |
A const face of a cell is determined by a cell and a node index. | |
typedef FaceIterator< M, ConstFace, CellConstIterator > | FaceConstIterator |
A bidirectional, constant iterator on the faces. | |
typedef std::pair < CellIterator, int > | Face |
A face of a cell is determined by a cell and a node index. | |
typedef FaceIterator< M, Face, CellIterator > | FaceIterator |
A bidirectional, iterator on the faces. | |
typedef ads::Triplet < CellConstIterator, int, int > | ConstEdge |
A const edge of a cell is determined by a cell and two node indices. | |
typedef EdgeIterator < SimpMeshRed, true > | EdgeConstIterator |
A bidirectional, constant iterator on the edges. | |
typedef ads::Triplet < CellIterator, int, int > | Edge |
An edge of a cell is determined by a cell and two node indices. | |
typedef EdgeIterator < SimpMeshRed, false > | EdgeIterator |
A bidirectional, iterator on the edges. | |
typedef T | Number |
The number type. | |
typedef Node::Vertex | Vertex |
A node (a Cartesian point). | |
typedef BBox< N, Number > | BBox |
A bounding box. | |
typedef int | SizeType |
The size type. | |
typedef NodeContainer::difference_type | DifferenceType |
The pointer difference type. | |
typedef Simplex< M, int > | IndexedSimplex |
A simplex of indices. | |
typedef Simplex< M, Vertex > | Simplex |
A simplex of vertices. | |
typedef ads::MemFunIterator < NodeConstIterator, Node, const Vertex &, true > | VertexIterator |
Vertex point iterator. | |
typedef ads::MemFunIterator < NodeConstIterator, Node, int, true > | NodeIdentifierIterator |
Node identifier iterator. | |
typedef ads::MemFunIterator < CellConstIterator, Cell, int, true > | CellIdentifierIterator |
Cell identifier iterator. | |
typedef IndSimpIter | IndexedSimplexIterator |
A const iterator over indexed simplices. | |
typedef SimpIter | SimplexIterator |
A const iterator over simplices. | |
typedef std::set< NodeIterator, NodeIteratorCompare > | NodeIteratorSet |
A set of node iterators. | |
typedef std::set< CellIterator, CellIteratorCompare > | CellIteratorSet |
A set of cell iterators. | |
typedef std::set< Face, FaceCompare > | FaceSet |
A set of faces. | |
typedef std::set< FaceIterator, FaceIteratorCompare > | FaceIteratorSet |
A set of face iterators. | |
Public Member Functions | |
Constructors and Destructor. | |
SimpMeshRed () | |
Default constructor. Empty containers. | |
SimpMeshRed (const SimpMeshRed &other) | |
Copy constructor. | |
template<bool A, typename V , typename IS > | |
SimpMeshRed (const IndSimpSet< N, M, A, Number, V, IS > &iss) | |
Construct from an indexed simplex set. | |
SimpMeshRed & | operator= (const SimpMeshRed &other) |
Assignment operator. | |
template<typename VertInIter , typename SimpInIter > | |
void | build (VertInIter verticesBeginning, VertInIter verticesEnd, SimpInIter simplicesBeginning, SimpInIter simplicesEnd) |
Build from an indexed simplex set. | |
template<bool A, typename V , typename IS > | |
void | build (const IndSimpSet< N, M, A, Number, V, IS > &iss) |
Build from an indexed simplex set. | |
void | swap (SimpMeshRed &x) |
Swap. | |
void | clear () |
Clear the mesh. | |
~SimpMeshRed () | |
Destructor. | |
Dimension accessors. | |
int | getSpaceDimension () const |
Return the space dimension. | |
int | getSimplexDimension () const |
Return the simplex dimension. | |
Node accessors. | |
bool | areNodesEmpty () const |
Return true if there are no nodes. | |
SizeType | computeNodesSize () const |
Return the number of nodes. | |
NodeConstIterator | getNodesBeginning () const |
Return the beginning of the nodes. | |
NodeConstIterator | getNodesEnd () const |
Return the end of the nodes. | |
VertexIterator | getVerticesBeginning () const |
Return the beginning of the node vertices. | |
VertexIterator | getVerticesEnd () const |
Return the end of the node vertices. | |
NodeIdentifierIterator | getNodeIdentifiersBeginning () const |
Return the beginning of the node identifiers. | |
NodeIdentifierIterator | getNodeIdentifiersEnd () const |
Return the end of the vertex identifiers. | |
int | computeMaximumNodeIdentifier () const |
Return the maximum node identifier. | |
Cell accessors. | |
bool | areCellsEmpty () const |
Return true if there are no cells. | |
SizeType | computeCellsSize () const |
Return the number of cells. | |
CellConstIterator | getCellsBeginning () const |
Return the beginning of the cells. | |
CellConstIterator | getCellsEnd () const |
Return the end of the cells. | |
void | getSimplex (CellConstIterator i, Simplex *s) const |
Get the simplex given a const iterator to the cell. | |
CellIdentifierIterator | getCellIdentifiersBeginning () const |
Return the beginning of the cell identifiers. | |
CellIdentifierIterator | getCellIdentifiersEnd () const |
Return the end of the cell identifiers. | |
int | computeMaximumCellIdentifier () const |
Return the maximum cell identifier. | |
Simplex accessors. | |
IndexedSimplexIterator | getIndexedSimplicesBeginning () const |
Return the beginning of the indexed simplices. | |
IndexedSimplexIterator | getIndexedSimplicesEnd () const |
Return the end of the indexed simplices. | |
SimplexIterator | getSimplicesBeginning () const |
Return the beginning of the simplices. | |
SimplexIterator | getSimplicesEnd () const |
Return the end of the simplices. | |
Face accessors. | |
SizeType | computeFacesSize () const |
Return the number of faces. | |
FaceConstIterator | getFacesBeginning () const |
Return the beginning of the faces. | |
FaceConstIterator | getFacesEnd () const |
Return the end of the faces. | |
Edge accessors. | |
SizeType | computeEdgesSize () const |
Return the number of edges. | |
EdgeConstIterator | getEdgesBeginning () const |
Return the beginning of the edges. | |
EdgeConstIterator | getEdgesEnd () const |
Return the end of the edges. | |
Node manipulators. | |
NodeIterator | getNodesBeginning () |
Return the beginning of the nodes. | |
NodeIterator | getNodesEnd () |
Return the end of the nodes. | |
void | setNodeIdentifiers () const |
Set the node identifiers. | |
template<typename VertexInIter > | |
void | setVertices (VertexInIter begin, VertexInIter end) |
Set the locations of the vertices. | |
Cell manipulators. | |
CellIterator | getCellsBeginning () |
Return the beginning of the cells. | |
CellIterator | getCellsEnd () |
Return the end of the cells. | |
void | setCellIdentifiers () const |
Set the cell identifiers. | |
Face manipulators. | |
FaceIterator | getFacesBeginning () |
Return the beginning of the faces. | |
FaceIterator | getFacesEnd () |
Return the end of the faces. | |
Edge manipulators. | |
EdgeIterator | getEdgesBeginning () |
Return the beginning of the edges. | |
EdgeIterator | getEdgesEnd () |
Return the end of the edges. | |
Insert/erase nodes. | |
NodeIterator | insertNode (const Node &node=Node()) |
Insert the node into the mesh. | |
NodeIterator | insertNode (const NodeIterator node) |
Insert a copy of the node into the mesh. | |
void | eraseNode (const NodeIterator node) |
Erase a vertex. | |
void | merge (NodeIterator x, NodeIterator y) |
Merge two nodes. Erase the second. | |
Insert/erase cells. | |
CellIterator | insertCell (const Cell &c=Cell()) |
Insert the cell into the mesh and set the self iterator and identifier. | |
CellIterator | insertCell (const CellIterator c) |
Insert a copy of the cell into the mesh. | |
void | eraseCell (const CellIterator c) |
Erase a cell. | |
template<typename InIter > | |
void | eraseCells (InIter begin, InIter end) |
Erase a range of cells. | |
Related Functions | |
(Note that these are not member functions.) | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
bool | isOriented (const SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh) |
Return true if the simplices of the mesh have consistent orientations. | |
template<class DistortionFunction , int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
BEGIN_NAMESPACE_GEOM int | flip (SimpMeshRed< N, 2, T, Node, Cell, Cont > *mesh) |
Flip faces for as long as the quality of the mesh is improved. | |
template<class DistortionFunction , int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
int | flip (SimpMeshRed< N, 2, T, Node, Cell, Cont > *mesh, T maxAngle) |
Flip faces for as long as the quality of the mesh is improved. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
int | flipUsingModifiedMeanRatio (SimpMeshRed< N, 2, T, Node, Cell, Cont > *mesh) |
Flip faces using the modified mean ratio metric for as long as the quality of the mesh is improved. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
int | flipUsingModifiedMeanRatio (SimpMeshRed< N, 2, T, Node, Cell, Cont > *mesh, const T maxAngle) |
Flip faces using the modified mean ratio metric for as long as the quality of the mesh is improved. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
int | flipUsingModifiedConditionNumber (SimpMeshRed< N, 2, T, Node, Cell, Cont > *mesh) |
Flip faces using the modified condition number metric for as long as the quality of the mesh is improved. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
int | flipUsingModifiedConditionNumber (SimpMeshRed< N, 2, T, Node, Cell, Cont > *mesh, const T maxAngle) |
Flip faces using the modified condition number metric for as long as the quality of the mesh is improved. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class DistortionFunction > | |
bool | flip (SimpMeshRed< N, 2, T, Node, Cell, Cont > *mesh, const typename SimpMeshRed< N, 2, T, Node, Cell, Cont >::Face &face, DistortionFunction &distortionFunction) |
Flip the specified face if it improves the quality of the mesh. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class DistortionFunction > | |
bool | flip (SimpMeshRed< N, 2, T, Node, Cell, Cont > *mesh, const typename SimpMeshRed< N, 2, T, Node, Cell, Cont >::Face &face, DistortionFunction &distortionFunction, T minCosine) |
Flip the specified face if it improves the quality of the mesh. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class DistortionFunction > | |
bool | shouldFlip (const SimpMeshRed< N, 2, T, Node, Cell, Cont > &mesh, const typename SimpMeshRed< N, 2, T, Node, Cell, Cont >::Face &face, DistortionFunction &distortionFunction) |
Return true if flipping the specified interior face will improve the quality of the mesh. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class DistortionFunction > | |
bool | shouldFlip (const SimpMeshRed< N, 2, T, Node, Cell, Cont > &mesh, const typename SimpMeshRed< N, 2, T, Node, Cell, Cont >::Face &face, DistortionFunction &distortionFunction, T minCosine) |
Return true if flipping the specified interior face will improve the quality of the mesh. | |
template<typename SMR > | |
void | flip (typename SMR::CellIterator cell, int faceIndex) |
Flip the face between ch and ch->neighbor(i) . | |
template<typename SMR > | |
void | flip (const typename SMR::Face &face) |
Flip the specified face. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
void | applyLaplacianAtNode (SimpMeshRed< N, M, T, Node, Cell, Cont > *mesh, typename SimpMeshRed< N, M, T, Node, Cell, Cont >::NodeIterator node) |
Perform Laplacian smoothing on the specified interior node. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class NodeIterInIter > | |
void | applyLaplacian (SimpMeshRed< N, N, T, Node, Cell, Cont > *mesh, NodeIterInIter begin, NodeIterInIter end, int numSweeps=1) |
Perform Laplacian smoothing on the specified interior nodes. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont> | |
void | applyLaplacian (SimpMeshRed< N, N, T, Node, Cell, Cont > *mesh, int numSweeps=1) |
Perform a sweep of Laplacian smoothing on the interior nodes. | |
template<int N, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class BoundaryCondition > | |
void | applyLaplacian (SimpMeshRed< N, N, T, Node, Cell, Cont > *mesh, const BoundaryCondition &condition, T minAngle, int numSweeps) |
Perform a sweep of Laplacian smoothing on the boundary nodes. | |
template<int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class LevelSet , class NodeIterInIter > | |
void | applyLaplacian (SimpMeshRed< M+1, M, T, Node, Cell, Cont > *mesh, const LevelSet &levelSet, NodeIterInIter begin, NodeIterInIter end, int numSweeps=1) |
Perform a sweep of Laplacian smoothing on the specified interior nodes. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class LSF , typename OutIter > | |
void | determineNodesOutside (const SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, const LSF &f, OutIter iter) |
Get the nodes that are outside the object. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class LSF , typename OutIter > | |
void | determineNodesOutside (SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, const LSF &f, OutIter iter) |
Get the nodes that are outside the object. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class LSF , typename OutIter > | |
void | determineCellsOutside (const SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, const LSF &f, OutIter iter) |
Get the cells whose centroids are outside the object. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, class LSF , typename OutIter > | |
void | determineCellsOutside (SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, const LSF &f, OutIter iter) |
Get the cells whose centroids are outside the object. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | getNodes (const SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, OutIter iter) |
Get the node const iterators for the all of the nodes in the mesh. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | getNodes (SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, OutIter iter) |
Get the node iterators for the all of the nodes in the mesh. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | determineInteriorNodes (const SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, OutIter iter) |
Get the node const iterators for the interior nodes. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | determineInteriorNodes (SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, OutIter iter) |
Get the node iterators for the interior nodes. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | determineBoundaryNodes (const SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, OutIter iter) |
Get the node const iterators for the boundary nodes. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | determineBoundaryNodes (SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, OutIter iter) |
Get the node iterators for the boundary nodes. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | determineCellsWithRequiredAdjacencies (const SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, const int minimumRequiredAdjacencies, OutIter iter) |
Get the cell const iterators with at least the specified number of adjacencies. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | determineCellsWithRequiredAdjacencies (SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, const int minimumRequiredAdjacencies, OutIter iter) |
Get the cell iterators with at least the specified number of adjacencies. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | determineCellsWithLowAdjacencies (const SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, const int minimumRequiredAdjacencies, OutIter iter) |
Get the cell const iterators with adjacencies less than specified. | |
template<int N, int M, typename T , template< class > class Node, template< class > class Cell, template< class, class > class Cont, typename OutIter > | |
void | determineCellsWithLowAdjacencies (SimpMeshRed< N, M, T, Node, Cell, Cont > &mesh, const int minimumRequiredAdjacencies, OutIter iter) |
Get the cell iterators with adjacencies less than specified. | |
template<class SMR > | |
BEGIN_NAMESPACE_GEOM bool | isOnBoundary (const typename SMR::ConstFace &f) |
Return true if the face is on the boundary. | |
template<class SMR > | |
bool | isOnBoundary (const typename SMR::Face &f) |
Return true if the face is on the boundary. | |
template<class SMR > | |
bool | isOnBoundary (const typename SMR::FaceConstIterator &f) |
Return true if the face is on the boundary. | |
template<class SMR > | |
bool | isOnBoundary (const typename SMR::FaceIterator &f) |
Return true if the face is on the boundary. | |
template<class SMR > | |
bool | areMirrorNodes (typename SMR::NodeConstIterator x, typename SMR::NodeConstIterator y) |
Return true if they are mirror nodes. | |
template<typename SMR , typename CellIteratorOutputIterator > | |
void | determineCellsIncidentToEdge (typename SMR::CellIterator c, const int i, const int j, CellIteratorOutputIterator output) |
Determine the cells incident to the edge. | |
template<typename SMR , typename NodeIteratorInsertIterator > | |
void | determineNodesInLink (typename SMR::NodeIterator node, NodeIteratorInsertIterator nodesInLink) |
Determine the nodes in the link of the specified node. |
A simplicial mesh data structure.
_N | is the space dimension. | |
_M | is the simplex dimension By default it is _N. | |
T | is the number type. By default it is double. | |
_Node | is the node type. | |
_Cell | is the cell (simplex) type. | |
Container | is the container for storing the vertices and cells. |
void SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::build | ( | VertInIter | verticesBeginning, | |
VertInIter | verticesEnd, | |||
SimpInIter | simplicesBeginning, | |||
SimpInIter | simplicesEnd | |||
) | [inline] |
Build from an indexed simplex set.
The value type for the vertices must be ads::FixedArray<N,T>
. The value type for the simplices must be subscriptable.
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::build(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::SimpMeshRed(), and tile().
SizeType SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::computeCellsSize | ( | ) | const [inline] |
Return the number of cells.
SizeType SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::computeEdgesSize | ( | ) | const [inline] |
Return the number of edges.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getEdgesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getEdgesEnd().
SizeType SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::computeFacesSize | ( | ) | const [inline] |
Return the number of faces.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getFacesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getFacesEnd().
int SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::computeMaximumCellIdentifier | ( | ) | const [inline] |
Return the maximum cell identifier.
CONTINUE: when I implement a scheme for managing identifiers I won't need this.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::areCellsEmpty(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellIdentifiersBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellIdentifiersEnd().
int SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::computeMaximumNodeIdentifier | ( | ) | const [inline] |
Return the maximum node identifier.
CONTINUE: when I implement a scheme for managing identifiers I won't need this.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::areNodesEmpty(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodeIdentifiersBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodeIdentifiersEnd().
SizeType SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::computeNodesSize | ( | ) | const [inline] |
Return the number of nodes.
Referenced by printQualityStatistics().
void SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::eraseCell | ( | const CellIterator | c | ) | [inline] |
Erase a cell.
Unlink the cell and erase it from the mesh.
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::eraseCells().
void SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::eraseCells | ( | InIter | begin, | |
InIter | end | |||
) | [inline] |
Erase a range of cells.
Unlink the cells and erase them from the mesh.
InIter
is an input iterator for cell iterators.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::eraseCell().
void SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::eraseNode | ( | const NodeIterator | node | ) | [inline] |
Erase a vertex.
No cell should be incident to this vertex.
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::merge().
NodeIterator SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::insertNode | ( | const Node & | node = Node() |
) |
Insert the node into the mesh.
Set the self iterator and the identifier.
void SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::merge | ( | NodeIterator | x, | |
NodeIterator | y | |||
) | [inline] |
Merge two nodes. Erase the second.
The two nodes should not have any incident cells in common.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::eraseNode().
void SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::setCellIdentifiers | ( | ) | const |
Set the cell identifiers.
void SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::setNodeIdentifiers | ( | ) | const |
Set the node identifiers.
bool areMirrorNodes | ( | typename SMR::NodeConstIterator | x, | |
typename SMR::NodeConstIterator | y | |||
) | [related] |
Return true if they are mirror nodes.
They are mirror nodes if:
This function is used to determine if an edge may be collapsed. If not for the second condition, it would be possible for collapsing an edge to create a sliver on the boundary. If a tetrahedran has a face on the boundary and an edge incident to the remaining node is collapsed, that node could be moved to the boundary. This creates a tetrahedron with four nodes on the boundary. (There is an analogous case in 2-D.)
void determineBoundaryNodes | ( | SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
OutIter | iter | |||
) | [related] |
Get the node iterators for the boundary nodes.
mesh | is the simplicial mesh. | |
iter | is an output iterator for the node iterators. |
This function calls the function of the same name with iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineBoundaryNodes(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesEnd().
void determineBoundaryNodes | ( | const SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
OutIter | iter | |||
) | [related] |
Get the node const iterators for the boundary nodes.
mesh | is the simplicial mesh. | |
iter | is an output iterator for the node const iterators. |
This function calls the function of the same name with const iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesEnd().
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineBoundaryNodes().
void determineCellsIncidentToEdge | ( | typename SMR::CellIterator | c, | |
const int | i, | |||
const int | j, | |||
CellIteratorOutputIterator | output | |||
) | [related] |
Determine the cells incident to the edge.
void determineCellsOutside | ( | SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
const LSF & | f, | |||
OutIter | iter | |||
) | [related] |
Get the cells whose centroids are outside the object.
mesh | is the simplicial mesh. | |
f | is the level set function that describes the object. Points inside/outside the object have negative/positive values. | |
iter | is an output iterator for the cell iterators. |
This function calls the function of the same name with iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineCellsOutside(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsEnd().
void determineCellsOutside | ( | const SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
const LSF & | f, | |||
OutIter | iter | |||
) | [related] |
Get the cells whose centroids are outside the object.
mesh | is the simplicial mesh. | |
f | is the level set function that describes the object. Points inside/outside the object have negative/positive values. | |
iter | is an output iterator for the cell const iterators. |
This function calls the function of the same name with const iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsEnd().
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineCellsOutside().
void determineCellsWithLowAdjacencies | ( | SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
const int | minimumRequiredAdjacencies, | |||
OutIter | iter | |||
) | [related] |
Get the cell iterators with adjacencies less than specified.
mesh | is the simplicial mesh. | |
minimumRequiredAdjacencies | The minimum required adjacencies. | |
iter | is an output iterator for the cell iterators. |
This function calls the function of the same name with iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineCellsWithLowAdjacencies(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsEnd().
void determineCellsWithLowAdjacencies | ( | const SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
const int | minimumRequiredAdjacencies, | |||
OutIter | iter | |||
) | [related] |
Get the cell const iterators with adjacencies less than specified.
mesh | is the simplicial mesh. | |
minimumRequiredAdjacencies | The minimum required adjacencies. | |
iter | is an output iterator for the cell const iterators. |
This function calls the function of the same name with const iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsEnd().
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineCellsWithLowAdjacencies().
void determineCellsWithRequiredAdjacencies | ( | SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
const int | minimumRequiredAdjacencies, | |||
OutIter | iter | |||
) | [related] |
Get the cell iterators with at least the specified number of adjacencies.
mesh | is the simplicial mesh. | |
minimumRequiredAdjacencies | This function gets the cells that have at least as many adjacencies as minimumRequiredAdjacencies. | |
iter | is an output iterator for the cell iterators. |
This function calls the function of the same name with iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineCellsWithRequiredAdjacencies(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsEnd().
void determineCellsWithRequiredAdjacencies | ( | const SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
const int | minimumRequiredAdjacencies, | |||
OutIter | iter | |||
) | [related] |
Get the cell const iterators with at least the specified number of adjacencies.
mesh | is the simplicial mesh. | |
minimumRequiredAdjacencies | The minimum required adjacencies. | |
iter | is an output iterator for the cell const iterators. |
This function calls the function of the same name with const iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getCellsEnd().
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineCellsWithRequiredAdjacencies().
void determineInteriorNodes | ( | SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
OutIter | iter | |||
) | [related] |
Get the node iterators for the interior nodes.
mesh | is the simplicial mesh. | |
iter | is an output iterator for the node iterators. |
This function calls the function of the same name with iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineInteriorNodes(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesEnd().
void determineInteriorNodes | ( | const SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
OutIter | iter | |||
) | [related] |
Get the node const iterators for the interior nodes.
mesh | is the simplicial mesh. | |
iter | is an output iterator for the node const iterators. |
This function calls the function of the same name with const iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesEnd().
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineInteriorNodes().
void determineNodesInLink | ( | typename SMR::NodeIterator | node, | |
NodeIteratorInsertIterator | nodesInLink | |||
) | [related] |
Determine the nodes in the link of the specified node.
void determineNodesOutside | ( | SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
const LSF & | f, | |||
OutIter | iter | |||
) | [related] |
Get the nodes that are outside the object.
mesh | is the simplicial mesh. | |
f | is the level set function that describes the object. Points inside/outside the object have negative/positive values. | |
iter | is an output iterator for the node iterators. |
This function calls the function of the same name with iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineNodesOutside(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesEnd().
void determineNodesOutside | ( | const SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
const LSF & | f, | |||
OutIter | iter | |||
) | [related] |
Get the nodes that are outside the object.
mesh | is the simplicial mesh. | |
f | is the level set function that describes the object. Points inside/outside the object have negative/positive values. | |
iter | is an output iterator for the node const iterators. |
This function calls the function of the same name with const iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesEnd().
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::determineNodesOutside().
void flip | ( | const typename SMR::Face & | face | ) | [related] |
Flip the specified face.
This function just calls flip(CellIterator, int).
void flip | ( | typename SMR::CellIterator | cell, | |
int | faceIndex | |||
) | [related] |
Flip the face between ch
and ch->neighbor(i)
.
Flipping an edge between two triangle cells.
bool flip | ( | SimpMeshRed< N, 2, T, Node, Cell, Cont > * | mesh, | |
const typename SimpMeshRed< N, 2, T, Node, Cell, Cont >::Face & | face, | |||
DistortionFunction & | distortionFunction, | |||
T | minCosine | |||
) | [related] |
Flip the specified face if it improves the quality of the mesh.
Boundary faces will not be flipped.
bool flip | ( | SimpMeshRed< N, 2, T, Node, Cell, Cont > * | mesh, | |
const typename SimpMeshRed< N, 2, T, Node, Cell, Cont >::Face & | face, | |||
DistortionFunction & | distortionFunction | |||
) | [related] |
Flip the specified face if it improves the quality of the mesh.
Boundary faces will not be flipped.
int flip | ( | SimpMeshRed< N, 2, T, Node, Cell, Cont > * | mesh, | |
T | maxAngle | |||
) | [related] |
Flip faces for as long as the quality of the mesh is improved.
Boundary faces will not be flipped. The edge will only be flipped if the angle between the incident face normals is no greater than maxAngle
.
BEGIN_NAMESPACE_GEOM int flip | ( | SimpMeshRed< N, 2, T, Node, Cell, Cont > * | mesh | ) | [related] |
Flip faces for as long as the quality of the mesh is improved.
Boundary faces will not be flipped.
int flipUsingModifiedConditionNumber | ( | SimpMeshRed< N, 2, T, Node, Cell, Cont > * | mesh, | |
const T | maxAngle | |||
) | [related] |
Flip faces using the modified condition number metric for as long as the quality of the mesh is improved.
Boundary faces will not be flipped.
int flipUsingModifiedConditionNumber | ( | SimpMeshRed< N, 2, T, Node, Cell, Cont > * | mesh | ) | [related] |
Flip faces using the modified condition number metric for as long as the quality of the mesh is improved.
Boundary faces will not be flipped.
int flipUsingModifiedMeanRatio | ( | SimpMeshRed< N, 2, T, Node, Cell, Cont > * | mesh, | |
const T | maxAngle | |||
) | [related] |
Flip faces using the modified mean ratio metric for as long as the quality of the mesh is improved.
Boundary faces will not be flipped.
int flipUsingModifiedMeanRatio | ( | SimpMeshRed< N, 2, T, Node, Cell, Cont > * | mesh | ) | [related] |
Flip faces using the modified mean ratio metric for as long as the quality of the mesh is improved.
Boundary faces will not be flipped.
void getNodes | ( | SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
OutIter | iter | |||
) | [related] |
Get the node iterators for the all of the nodes in the mesh.
mesh | is the simplicial mesh. | |
iter | is an output iterator for the node iterators. |
This function calls the function of the same name with iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodes(), SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesEnd().
void getNodes | ( | const SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh, | |
OutIter | iter | |||
) | [related] |
Get the node const iterators for the all of the nodes in the mesh.
mesh | is the simplicial mesh. | |
iter | is an output iterator for the node const iterators. |
This function calls the function of the same name with const iterators as the initial arguments.
References SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesBeginning(), and SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodesEnd().
Referenced by SimpMeshRed< _N, _M, T, _Node, _Cell, Container >::getNodes().
bool isOriented | ( | const SimpMeshRed< N, M, T, Node, Cell, Cont > & | mesh | ) | [related] |
Return true if the simplices of the mesh have consistent orientations.