Periodic mesh in 1D. More...
Public Member Functions | |
| PeriodicMesh1D (double xMin, double xMax, int numElems) | |
| virtual | ~PeriodicMesh1D () |
| virtual dtor | |
| int | numCells (int dim) const |
| Get the number of cells having dimension dim. | |
| Point | nodePosition (int i) const |
| Return the position of the i-th node. | |
| const double * | nodePositionView (int i) const |
| Return a view of the i-th node's position. | |
| virtual void | getJacobians (int cellDim, const Array< int > &cellLID, CellJacobianBatch &jBatch) const |
| Compute the jacobians of a batch of cells, returning the result via reference argument. | |
| virtual void | getCellDiameters (int cellDim, const Array< int > &cellLID, Array< double > &cellDiameters) const |
| Compute the diameters of a batch of cells, result via reference argument. | |
| virtual void | pushForward (int cellDim, const Array< int > &cellLID, const Array< Point > &refQuadPts, Array< Point > &physQuadPts) const |
| Map reference quadrature points to physical points on the given cells. | |
| virtual int | ownerProcID (int cellDim, int cellLID) const |
| Return the rank of the processor that owns the given cell. | |
| virtual int | numFacets (int cellDim, int cellLID, int facetDim) const |
| Return the number of facets of the given cell. | |
| virtual int | facetLID (int cellDim, int cellLID, int facetDim, int facetIndex, int &facetOrientation) const |
| Return the local ID of a facet cell. | |
| virtual void | getFacetLIDs (int cellDim, const Array< int > &cellLID, int facetDim, Array< int > &facetLID, Array< int > &facetSign) const |
| Return by reference argument an array containing&(elemVerts_.value(cellLID, 0)) the LIDs of the facetDim-dimensional facets of the given batch of cells. | |
| const int * | elemZeroFacetView (int cellLID) const |
| Return a view of an element's zero-dimensional facets,. | |
| virtual int | numMaxCofacets (int cellDim, int cellLID) const |
| Return the number of maximal cofacets of the given cell. | |
| virtual int | maxCofacetLID (int cellDim, int cellLID, int cofacetIndex, int &facetIndex) const |
| Return the local ID of a maximal cofacet cell. | |
| virtual void | getMaxCofacetLIDs (const Array< int > &cellLIDs, MaximalCofacetBatch &cofacets) const |
| Get the LIDs of the maximal cofacets for a batch of codimension-one cells. | |
| void | getCofacets (int cellDim, int cellLID, int cofacetDim, Array< int > &cofacetLIDs) const |
| Find the cofacets of the given cell. | |
| virtual int | mapGIDToLID (int cellDim, int globalIndex) const |
| Find the local ID of a cell given its global index. | |
| virtual bool | hasGID (int cellDim, int globalIndex) const |
| Determine whether a given cell GID exists on this processor. | |
| virtual int | mapLIDToGID (int cellDim, int localIndex) const |
| Find the global ID of a cell given its local index. | |
| virtual CellType | cellType (int cellDim) const |
| Get the type of the given cell. | |
| virtual int | label (int cellDim, int cellLID) const |
| Get the label of the given cell. | |
| virtual void | getLabels (int cellDim, const Array< int > &cellLID, Array< int > &labels) const |
| Get the labels for a batch of cells. | |
| virtual Set< int > | getAllLabelsForDimension (int cellDim) const |
| Get the list of all labels defined for cells of the given dimension. | |
| virtual void | getLIDsForLabel (int cellDim, int label, Array< int > &cellLIDs) const |
| Get the cells associated with a specified label. | |
| virtual void | setLabel (int cellDim, int cellLID, int label) |
| Set the label of the given cell. | |
| virtual void | assignIntermediateCellGIDs (int cellDim) |
| Coordinate intermediate cell definitions across processors. | |
| virtual bool | hasIntermediateGIDs (int dim) const |
| Return if cells of dimension cellDim have been assigned global IDs or not. | |
Private Attributes | |
| int | numElems_ |
| double | xMin_ |
| double | xMax_ |
| Array< Point > | x_ |
| Array< Array< int > > | verts_ |
| Array< Array< int > > | labels_ |
Periodic mesh in 1D.
Definition at line 51 of file SundancePeriodicMesh1D.hpp.
| PeriodicMesh1D::PeriodicMesh1D | ( | double | xMin, |
| double | xMax, | ||
| int | numElems | ||
| ) |
| virtual Sundance::PeriodicMesh1D::~PeriodicMesh1D | ( | ) | [inline, virtual] |
virtual dtor
Definition at line 58 of file SundancePeriodicMesh1D.hpp.
| virtual void Sundance::PeriodicMesh1D::assignIntermediateCellGIDs | ( | int | cellDim | ) | [inline, virtual] |
Coordinate intermediate cell definitions across processors.
Implements Sundance::MeshBase.
Definition at line 240 of file SundancePeriodicMesh1D.hpp.
| CellType PeriodicMesh1D::cellType | ( | int | cellDim | ) | const [virtual] |
Get the type of the given cell.
Implements Sundance::MeshBase.
Definition at line 283 of file SundancePeriodicMesh1D.cpp.
References Sundance::LineCell, Sundance::NullCell, and Sundance::PointCell.
| const int * PeriodicMesh1D::elemZeroFacetView | ( | int | cellLID | ) | const [virtual] |
Return a view of an element's zero-dimensional facets,.
Implements Sundance::MeshBase.
Definition at line 230 of file SundancePeriodicMesh1D.cpp.
References verts_.
| int PeriodicMesh1D::facetLID | ( | int | cellDim, |
| int | cellLID, | ||
| int | facetDim, | ||
| int | facetIndex, | ||
| int & | facetOrientation | ||
| ) | const [virtual] |
Return the local ID of a facet cell.
| cellDim | dimension of the cell whose facets are being obtained |
| cellLID | local index of the cell whose facets are being obtained |
| facetDim | dimension of the desired facet |
| facetIndex | index into the list of the cell's facets |
| facetOrientation | orientation of the facet as seen from the given cell (returned via reference) |
Implements Sundance::MeshBase.
Definition at line 199 of file SundancePeriodicMesh1D.cpp.
References numElems_, and verts_.
Referenced by getFacetLIDs().
| Set< int > PeriodicMesh1D::getAllLabelsForDimension | ( | int | cellDim | ) | const [virtual] |
Get the list of all labels defined for cells of the given dimension.
Implements Sundance::MeshBase.
Definition at line 306 of file SundancePeriodicMesh1D.cpp.
References labels_, and Sundance::Set< Key, Compare >::put().
| void PeriodicMesh1D::getCellDiameters | ( | int | cellDim, |
| const Array< int > & | cellLID, | ||
| Array< double > & | cellDiameters | ||
| ) | const [virtual] |
Compute the diameters of a batch of cells, result via reference argument.
| cellDim | dimension of the cells whose diameters are to be computed |
| cellLID | local indices of the cells for which diameters are to be computed |
| diameters | reference to the array of cell diameters |
Reimplemented from Sundance::MeshBase.
Definition at line 134 of file SundancePeriodicMesh1D.cpp.
References x_.
| void PeriodicMesh1D::getCofacets | ( | int | cellDim, |
| int | cellLID, | ||
| int | cofacetDim, | ||
| Array< int > & | cofacetLIDs | ||
| ) | const [virtual] |
Find the cofacets of the given cell.
| cellDim | dimension of the cell whose cofacets are being obtained |
| cellLID | local index of the cell whose cofacets are being obtained |
| cofacetDim | dimension of the cofacets to get |
| cofacetLIDs | LIDs of the cofacet |
Implements Sundance::MeshBase.
Definition at line 257 of file SundancePeriodicMesh1D.cpp.
References numElems_.
| void PeriodicMesh1D::getFacetLIDs | ( | int | cellDim, |
| const Array< int > & | cellLID, | ||
| int | facetDim, | ||
| Array< int > & | facetLID, | ||
| Array< int > & | facetSign | ||
| ) | const [virtual] |
Return by reference argument an array containing&(elemVerts_.value(cellLID, 0)) the LIDs of the facetDim-dimensional facets of the given batch of cells.
Implements Sundance::MeshBase.
Definition at line 213 of file SundancePeriodicMesh1D.cpp.
References facetLID().
| void PeriodicMesh1D::getJacobians | ( | int | cellDim, |
| const Array< int > & | cellLID, | ||
| CellJacobianBatch & | jBatch | ||
| ) | const [virtual] |
Compute the jacobians of a batch of cells, returning the result via reference argument.
| cellDim | dimension of the cells whose Jacobians are to be computed |
| cellLID | local indices of the cells for which Jacobians are to be computed |
| jBatch | reference to the resulting Jacobian batch |
Reimplemented from Sundance::MeshBase.
Definition at line 100 of file SundancePeriodicMesh1D.cpp.
References Sundance::CellJacobianBatch::detJ(), Sundance::CellJacobianBatch::jVals(), Sundance::CellJacobianBatch::resize(), Sundance::MeshBase::spatialDim(), and x_.
| void PeriodicMesh1D::getLabels | ( | int | cellDim, |
| const Array< int > & | cellLID, | ||
| Array< int > & | labels | ||
| ) | const [virtual] |
Get the labels for a batch of cells.
Implements Sundance::MeshBase.
Definition at line 295 of file SundancePeriodicMesh1D.cpp.
References labels_.
| void PeriodicMesh1D::getLIDsForLabel | ( | int | cellDim, |
| int | label, | ||
| Array< int > & | cellLIDs | ||
| ) | const [virtual] |
Get the cells associated with a specified label.
The array cellLID will be filled with those cells of dimension cellDim having the given label.
Implements Sundance::MeshBase.
Definition at line 325 of file SundancePeriodicMesh1D.cpp.
References labels_.
| void PeriodicMesh1D::getMaxCofacetLIDs | ( | const Array< int > & | cellLIDs, |
| MaximalCofacetBatch & | cofacets | ||
| ) | const [virtual] |
Get the LIDs of the maximal cofacets for a batch of codimension-one cells.
| cellLIDs | [in] array of LIDs of the cells whose cofacets are being obtained |
| cofacets | [out] the batch of cofacets |
Implements Sundance::MeshBase.
Definition at line 251 of file SundancePeriodicMesh1D.cpp.
| bool PeriodicMesh1D::hasGID | ( | int | cellDim, |
| int | globalIndex | ||
| ) | const [virtual] |
Determine whether a given cell GID exists on this processor.
Implements Sundance::MeshBase.
Definition at line 273 of file SundancePeriodicMesh1D.cpp.
| virtual bool Sundance::PeriodicMesh1D::hasIntermediateGIDs | ( | int | cellDim | ) | const [inline, virtual] |
Return if cells of dimension cellDim have been assigned global IDs or not.
| cellDim | [in] Dimension of the cell |
Implements Sundance::MeshBase.
Definition at line 243 of file SundancePeriodicMesh1D.hpp.
| int PeriodicMesh1D::label | ( | int | cellDim, |
| int | cellLID | ||
| ) | const [virtual] |
Get the label of the given cell.
Implements Sundance::MeshBase.
Definition at line 290 of file SundancePeriodicMesh1D.cpp.
References labels_.
Referenced by setLabel().
| int PeriodicMesh1D::mapGIDToLID | ( | int | cellDim, |
| int | globalIndex | ||
| ) | const [virtual] |
Find the local ID of a cell given its global index.
Implements Sundance::MeshBase.
Definition at line 268 of file SundancePeriodicMesh1D.cpp.
| int PeriodicMesh1D::mapLIDToGID | ( | int | cellDim, |
| int | localIndex | ||
| ) | const [virtual] |
Find the global ID of a cell given its local index.
Implements Sundance::MeshBase.
Definition at line 278 of file SundancePeriodicMesh1D.cpp.
| int PeriodicMesh1D::maxCofacetLID | ( | int | cellDim, |
| int | cellLID, | ||
| int | cofacetIndex, | ||
| int & | facetIndex | ||
| ) | const [virtual] |
Return the local ID of a maximal cofacet cell.
| cellDim | dimension of the cell whose cofacets are being obtained |
| cellLID | local index of the cell whose cofacets are being obtained |
| cofacetIndex | which maximal cofacet to get |
| facetIndex | index of the cell cellLID into the list of the maximal cell's facets |
Implements Sundance::MeshBase.
Definition at line 242 of file SundancePeriodicMesh1D.cpp.
References numElems_.
| Point PeriodicMesh1D::nodePosition | ( | int | i | ) | const [virtual] |
Return the position of the i-th node.
Implements Sundance::MeshBase.
Definition at line 89 of file SundancePeriodicMesh1D.cpp.
References x_.
| const double * PeriodicMesh1D::nodePositionView | ( | int | i | ) | const [virtual] |
Return a view of the i-th node's position.
Implements Sundance::MeshBase.
Definition at line 95 of file SundancePeriodicMesh1D.cpp.
References x_.
| int PeriodicMesh1D::numCells | ( | int | dim | ) | const [virtual] |
Get the number of cells having dimension dim.
Implements Sundance::MeshBase.
Definition at line 74 of file SundancePeriodicMesh1D.cpp.
References numElems_.
| int PeriodicMesh1D::numFacets | ( | int | cellDim, |
| int | cellLID, | ||
| int | facetDim | ||
| ) | const [virtual] |
Return the number of facets of the given cell.
Implements Sundance::MeshBase.
Definition at line 189 of file SundancePeriodicMesh1D.cpp.
References numElems_.
| int PeriodicMesh1D::numMaxCofacets | ( | int | cellDim, |
| int | cellLID | ||
| ) | const [virtual] |
Return the number of maximal cofacets of the given cell.
Implements Sundance::MeshBase.
Definition at line 236 of file SundancePeriodicMesh1D.cpp.
| virtual int Sundance::PeriodicMesh1D::ownerProcID | ( | int | cellDim, |
| int | cellLID | ||
| ) | const [inline, virtual] |
Return the rank of the processor that owns the given cell.
Implements Sundance::MeshBase.
Definition at line 115 of file SundancePeriodicMesh1D.hpp.
| void PeriodicMesh1D::pushForward | ( | int | cellDim, |
| const Array< int > & | cellLID, | ||
| const Array< Point > & | refQuadPts, | ||
| Array< Point > & | physQuadPts | ||
| ) | const [virtual] |
Map reference quadrature points to physical points on the given cells.
Reimplemented from Sundance::MeshBase.
Definition at line 159 of file SundancePeriodicMesh1D.cpp.
References x_.
| void PeriodicMesh1D::setLabel | ( | int | cellDim, |
| int | cellLID, | ||
| int | label | ||
| ) | [virtual] |
Set the label of the given cell.
Implements Sundance::MeshBase.
Definition at line 319 of file SundancePeriodicMesh1D.cpp.
Array<Array<int> > Sundance::PeriodicMesh1D::labels_ [private] |
Definition at line 254 of file SundancePeriodicMesh1D.hpp.
Referenced by getAllLabelsForDimension(), getLabels(), getLIDsForLabel(), label(), PeriodicMesh1D(), and setLabel().
int Sundance::PeriodicMesh1D::numElems_ [private] |
Definition at line 249 of file SundancePeriodicMesh1D.hpp.
Referenced by facetLID(), getCofacets(), maxCofacetLID(), numCells(), numFacets(), and PeriodicMesh1D().
Array<Array<int> > Sundance::PeriodicMesh1D::verts_ [private] |
Definition at line 253 of file SundancePeriodicMesh1D.hpp.
Referenced by elemZeroFacetView(), facetLID(), and PeriodicMesh1D().
Array<Point> Sundance::PeriodicMesh1D::x_ [private] |
Definition at line 252 of file SundancePeriodicMesh1D.hpp.
Referenced by getCellDiameters(), getJacobians(), nodePosition(), nodePositionView(), PeriodicMesh1D(), and pushForward().
double Sundance::PeriodicMesh1D::xMax_ [private] |
Definition at line 251 of file SundancePeriodicMesh1D.hpp.
Referenced by PeriodicMesh1D().
double Sundance::PeriodicMesh1D::xMin_ [private] |
Definition at line 250 of file SundancePeriodicMesh1D.hpp.
Referenced by PeriodicMesh1D().