AbstractMeshReader< ELEMENT_DIM, SPACE_DIM > Class Template Reference

#include <AbstractMeshReader.hpp>

Inheritance diagram for AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >:

Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual unsigned GetNumElements () const =0
virtual unsigned GetNumNodes () const =0
virtual unsigned GetNumFaces () const =0
virtual unsigned GetNumElementAttributes () const
virtual unsigned GetNumFaceAttributes () const
virtual std::vector< double > GetNodeAttributes ()
unsigned GetNumEdges () const
virtual std::vector< double > GetNextNode ()=0
virtual void Reset ()=0
virtual ElementData GetNextElementData ()=0
virtual ElementData GetNextFaceData ()=0
ElementData GetNextEdgeData ()
virtual std::vector< double > GetNode (unsigned index)
virtual ElementData GetElementData (unsigned index)
virtual ElementData GetFaceData (unsigned index)
ElementData GetEdgeData (unsigned index)
virtual std::vector< unsigned > GetContainingElementIndices (unsigned index)
virtual std::string GetMeshFileBaseName ()
virtual bool IsFileFormatBinary ()
virtual bool HasNclFile ()


Detailed Description

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
class AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >

An abstract mesh reader class. Reads output generated by a mesh generator and converts it to a standard format for use in constructing a finite element mesh structure.

A derived class TrianglesMeshReader exists for reading meshes generated by Triangles (in 2-d) and TetGen (in 3-d).

A derived class MemfemMeshReader reads 3D data from the Tulane University code

A derived class FemlabMeshReader reads 2D data from Femlab or Matlab PDEToolbox

Definition at line 60 of file AbstractMeshReader.hpp.


Member Function Documentation

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
virtual unsigned AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNumElements (  )  const [pure virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
virtual unsigned AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNumNodes (  )  const [pure virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
virtual unsigned AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNumFaces (  )  const [pure virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
unsigned AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNumElementAttributes (  )  const [inline, virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
unsigned AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNumFaceAttributes (  )  const [inline, virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
std::vector< double > AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNodeAttributes (  )  [inline, virtual]

Returns:
the vector of node attributes Returns an empty vector here. Over-ride in child classes if needed. Ideally, this method would be in AbstractCachedMeshReader (where it would retrun the cached attribuites) but TrianglesMeshReaedr (the class this method was created for) does not inherit from AbstractCachedMeshReader, so it needs to be here.

Reimplemented in TrianglesMeshReader< ELEMENT_DIM, SPACE_DIM >.

Definition at line 59 of file AbstractMeshReader.cpp.

Referenced by TetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ConstructFromMeshReader(), and DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ConstructFromMeshReader().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
unsigned AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNumEdges (  )  const [inline]

Returns the number of edges in the mesh (synonym of GetNumFaces())

Reimplemented in VtkMeshReader< ELEMENT_DIM, SPACE_DIM >, and VertexMeshReader< ELEMENT_DIM, SPACE_DIM >.

Definition at line 45 of file AbstractMeshReader.cpp.

References AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNumFaces().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
virtual std::vector<double> AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNextNode (  )  [pure virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
virtual void AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::Reset (  )  [pure virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
virtual ElementData AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNextElementData (  )  [pure virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
virtual ElementData AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNextFaceData (  )  [pure virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
ElementData AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNextEdgeData (  )  [inline]

Returns a vector of the node indices of each edge (and any attribute/containment infomation, if there is any) in turn (synonym of GetNextFaceData())

Definition at line 68 of file AbstractMeshReader.cpp.

References AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNextFaceData().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
std::vector< double > AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetNode ( unsigned  index  )  [inline, virtual]

Normally throws an exception. Only implemented for tetrahedral mesh reader of binary files.

Parameters:
index The global node index
Returns:
a vector of the coordinates of the node

Reimplemented in GenericMeshReader< ELEMENT_DIM, SPACE_DIM >, and TrianglesMeshReader< ELEMENT_DIM, SPACE_DIM >.

Definition at line 75 of file AbstractMeshReader.cpp.

References EXCEPTION.

Referenced by DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ConstructFromMeshReader().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
ElementData AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetElementData ( unsigned  index  )  [inline, virtual]

Normally throws an exception. Only implemented for tetrahedral mesh reader of binary files.

Parameters:
index The global element index
Returns:
a vector of the node indices of the element (and any attribute infomation, if there is any)

Reimplemented in GenericMeshReader< ELEMENT_DIM, SPACE_DIM >, and TrianglesMeshReader< ELEMENT_DIM, SPACE_DIM >.

Definition at line 81 of file AbstractMeshReader.cpp.

References EXCEPTION.

Referenced by DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ComputeMeshPartitioning(), DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ConstructFromMeshReader(), DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ParMetisLibraryNodePartitioning(), and DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::PetscMatrixPartitioning().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
ElementData AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetFaceData ( unsigned  index  )  [inline, virtual]

Normally throws an exception. Only implemented for tetrahedral mesh reader of binary files.

Parameters:
index The global face index
Returns:
a vector of the node indices of the face (and any attribute/containment infomation, if there is any)

Reimplemented in GenericMeshReader< ELEMENT_DIM, SPACE_DIM >, and TrianglesMeshReader< ELEMENT_DIM, SPACE_DIM >.

Definition at line 87 of file AbstractMeshReader.cpp.

References EXCEPTION.

Referenced by AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetEdgeData().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
ElementData AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetEdgeData ( unsigned  index  )  [inline]

Synonym of GetFaceData(index)

Parameters:
index The global edge index
Returns:
a vector of the node indices of the edge (and any attribute/containment infomation, if there is any)

Definition at line 93 of file AbstractMeshReader.cpp.

References AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetFaceData().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
std::vector< unsigned > AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetContainingElementIndices ( unsigned  index  )  [inline, virtual]

Normally throws an exception. When implemented by derived classes, returns a list of the elements that contain the node (only available for binary files).

Parameters:
index The global node index
Returns:
a vector of the node indices of the face (and any attribute/containment infomation, if there is any)

Reimplemented in GenericMeshReader< ELEMENT_DIM, SPACE_DIM >, and TrianglesMeshReader< ELEMENT_DIM, SPACE_DIM >.

Definition at line 99 of file AbstractMeshReader.cpp.

References EXCEPTION.

Referenced by DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ComputeMeshPartitioning().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
std::string AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::GetMeshFileBaseName (  )  [inline, virtual]

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
bool AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::IsFileFormatBinary (  )  [inline, virtual]

Returns true if reading binary files, false if reading ascii files.

Note, this will always return false unless over-ridden by a derived class that is able to support binary file formats.

Reimplemented in GenericMeshReader< ELEMENT_DIM, SPACE_DIM >, and TrianglesMeshReader< ELEMENT_DIM, SPACE_DIM >.

Definition at line 111 of file AbstractMeshReader.cpp.

Referenced by DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ConstructFromMeshReader(), DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ParMetisLibraryNodePartitioning(), and DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::PetscMatrixPartitioning().

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM>
bool AbstractMeshReader< ELEMENT_DIM, SPACE_DIM >::HasNclFile (  )  [inline, virtual]

Returns true if there is a node connectivity list (NCL) file available.

Note, this will always return false unless over-ridden by a derived class that is able to support NCL files.

Returns:
whether there is a node connectivity list (NCL) file available

Reimplemented in GenericMeshReader< ELEMENT_DIM, SPACE_DIM >, and TrianglesMeshReader< ELEMENT_DIM, SPACE_DIM >.

Definition at line 117 of file AbstractMeshReader.cpp.

Referenced by DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ComputeMeshPartitioning().


The documentation for this class was generated from the following files:

Generated on Mon Apr 18 11:36:04 2011 for Chaste by  doxygen 1.5.5