Nektar++
|
#include <MeshPartition.h>
Classes | |
struct | GraphEdgeProperties |
struct | GraphVertexProperties |
struct | MeshComposite |
struct | MeshCurved |
struct | MeshEdge |
struct | MeshElement |
struct | MeshEntity |
struct | MeshFace |
struct | MeshVertex |
Public Member Functions | |
MeshPartition (const SessionReaderSharedPtr &pSession) | |
virtual | ~MeshPartition () |
void | PartitionMesh (int nParts, bool shared=false) |
void | WriteLocalPartition (SessionReaderSharedPtr &pSession) |
void | WriteAllPartitions (SessionReaderSharedPtr &pSession) |
void | PrintPartInfo (std::ostream &out) |
void | GetCompositeOrdering (CompositeOrdering &composites) |
void | GetBndRegionOrdering (BndRegionOrdering &composites) |
void | GetElementIDs (const int procid, std::vector< unsigned int > &tmp) |
Private Types | |
typedef std::pair< std::string, int > | MeshCurvedKey |
typedef std::vector< unsigned int > | MultiWeight |
typedef boost::adjacency_list < boost::setS, boost::vecS, boost::undirectedS, GraphVertexProperties, boost::property < boost::edge_index_t, unsigned int, GraphEdgeProperties > > | BoostGraph |
typedef boost::subgraph < BoostGraph > | BoostSubGraph |
typedef boost::graph_traits < BoostGraph > ::vertex_descriptor | BoostVertex |
typedef boost::graph_traits < BoostGraph > ::edge_descriptor | BoostEdge |
typedef boost::graph_traits < BoostGraph >::edge_iterator | BoostEdgeIterator |
typedef boost::graph_traits < BoostGraph > ::vertex_iterator | BoostVertexIterator |
typedef boost::graph_traits < BoostGraph > ::adjacency_iterator | BoostAdjacencyIterator |
typedef std::vector< unsigned int > | NumModes |
typedef std::map< std::string, NumModes > | NummodesPerField |
Private Member Functions | |
void | ReadExpansions (const SessionReaderSharedPtr &pSession) |
void | ReadGeometry (const SessionReaderSharedPtr &pSession) |
void | ReadConditions (const SessionReaderSharedPtr &pSession) |
void | WeightElements () |
void | CreateGraph (BoostSubGraph &pGraph) |
void | PartitionGraph (BoostSubGraph &pGraph, int nParts, std::vector< BoostSubGraph > &pLocalPartition) |
virtual void | PartitionGraphImpl (int &nVerts, int &nVertConds, Nektar::Array< Nektar::OneD, int > &xadj, Nektar::Array< Nektar::OneD, int > &adjcy, Nektar::Array< Nektar::OneD, int > &vertWgt, Nektar::Array< Nektar::OneD, int > &vertSize, int &nparts, int &volume, Nektar::Array< Nektar::OneD, int > &part)=0 |
void | OutputPartition (SessionReaderSharedPtr &pSession, BoostSubGraph &pGraph, TiXmlElement *pGeometry) |
void | CheckPartitions (int nParts, Array< OneD, int > &pPart) |
int | CalculateElementWeight (char elmtType, bool bndWeight, int na, int nb, int nc) |
Private Attributes | |
int | m_dim |
int | m_numFields |
std::map< int, MeshVertex > | m_meshVertices |
std::map< int, MeshEntity > | m_meshEdges |
std::map< int, MeshEntity > | m_meshFaces |
std::map< int, MeshEntity > | m_meshElements |
std::map< MeshCurvedKey, MeshCurved > | m_meshCurved |
std::map< int, MeshEntity > | m_meshComposites |
std::vector< unsigned int > | m_domain |
std::map< std::string, std::string > | m_vertexAttributes |
std::map< int, NummodesPerField > | m_expansions |
std::map< std::string, int > | m_fieldNameToId |
std::vector< MultiWeight > | m_vertWeights |
BndRegionOrdering | m_bndRegOrder |
BoostSubGraph | m_mesh |
std::vector< BoostSubGraph > | m_localPartition |
CommSharedPtr | m_comm |
bool | m_weightingRequired |
bool | m_shared |
Definition at line 61 of file MeshPartition.h.
|
private |
Definition at line 186 of file MeshPartition.h.
|
private |
Definition at line 177 of file MeshPartition.h.
|
private |
Definition at line 180 of file MeshPartition.h.
|
private |
Definition at line 167 of file MeshPartition.h.
|
private |
Definition at line 170 of file MeshPartition.h.
|
private |
Definition at line 174 of file MeshPartition.h.
|
private |
Definition at line 183 of file MeshPartition.h.
|
private |
Definition at line 128 of file MeshPartition.h.
|
private |
Definition at line 137 of file MeshPartition.h.
|
private |
Definition at line 188 of file MeshPartition.h.
|
private |
Definition at line 189 of file MeshPartition.h.
Nektar::LibUtilities::MeshPartition::MeshPartition | ( | const SessionReaderSharedPtr & | pSession | ) |
Definition at line 73 of file MeshPartition.cpp.
References ReadConditions(), ReadExpansions(), and ReadGeometry().
|
virtual |
Definition at line 84 of file MeshPartition.cpp.
|
private |
Definition at line 1268 of file MeshPartition.cpp.
References Nektar::LibUtilities::StdSegData::getNumberOfBndCoefficients(), and Nektar::LibUtilities::StdSegData::getNumberOfCoefficients().
Referenced by PrintPartInfo(), and WeightElements().
|
private |
Definition at line 824 of file MeshPartition.cpp.
Referenced by PartitionGraph().
|
private |
Definition at line 669 of file MeshPartition.cpp.
References m_meshElements, m_vertWeights, and m_weightingRequired.
Referenced by PartitionMesh().
void Nektar::LibUtilities::MeshPartition::GetBndRegionOrdering | ( | BndRegionOrdering & | composites | ) |
Definition at line 176 of file MeshPartition.cpp.
References m_bndRegOrder.
void Nektar::LibUtilities::MeshPartition::GetCompositeOrdering | ( | CompositeOrdering & | composites | ) |
Definition at line 166 of file MeshPartition.cpp.
References Nektar::iterator, and m_meshComposites.
void Nektar::LibUtilities::MeshPartition::GetElementIDs | ( | const int | procid, |
std::vector< unsigned int > & | tmp | ||
) |
Definition at line 1253 of file MeshPartition.cpp.
References ASSERTL0, m_localPartition, and m_meshElements.
|
private |
Definition at line 855 of file MeshPartition.cpp.
References Nektar::LibUtilities::MeshPartition::MeshCurved::data, Nektar::LibUtilities::MeshPartition::MeshCurved::entityid, Nektar::LibUtilities::MeshPartition::MeshCurved::entitytype, Nektar::ParseUtils::GenerateSeqVector(), Nektar::LibUtilities::MeshPartition::MeshCurved::id, Nektar::iterator, m_bndRegOrder, m_dim, m_domain, m_meshComposites, m_meshCurved, m_meshEdges, m_meshElements, m_meshFaces, m_meshVertices, m_vertexAttributes, Nektar::LibUtilities::MeshPartition::MeshCurved::npoints, and Nektar::LibUtilities::MeshPartition::MeshCurved::type.
Referenced by WriteAllPartitions(), and WriteLocalPartition().
|
private |
Definition at line 706 of file MeshPartition.cpp.
References CheckPartitions(), ErrorUtil::efatal, m_comm, m_shared, m_weightingRequired, NEKERROR, and PartitionGraphImpl().
Referenced by PartitionMesh().
|
privatepure virtual |
Referenced by PartitionGraph().
void Nektar::LibUtilities::MeshPartition::PartitionMesh | ( | int | nParts, |
bool | shared = false |
||
) |
Definition at line 89 of file MeshPartition.cpp.
References ASSERTL0, CreateGraph(), m_localPartition, m_mesh, m_meshElements, m_shared, m_weightingRequired, PartitionGraph(), and WeightElements().
void Nektar::LibUtilities::MeshPartition::PrintPartInfo | ( | std::ostream & | out | ) |
Definition at line 483 of file MeshPartition.cpp.
References ASSERTL0, CalculateElementWeight(), Nektar::iterator, m_dim, m_domain, m_expansions, m_localPartition, m_mesh, and m_meshComposites.
|
private |
Definition at line 553 of file MeshPartition.cpp.
References ASSERTL0, and m_weightingRequired.
Referenced by MeshPartition().
|
private |
Expansiontypes will contain plenty of data, where relevant at this stage are composite ID(s) that this expansion type describes, nummodes and a list of fields that this expansion relates to. If this does not exist the variable is only set to "DefaultVar".
Definition at line 182 of file MeshPartition.cpp.
References ASSERTL0, Nektar::ParseUtils::GenerateOrderedStringVector(), Nektar::ParseUtils::GenerateOrderedVector(), Nektar::ParseUtils::GenerateSeqVector(), m_dim, m_expansions, m_fieldNameToId, and m_numFields.
Referenced by MeshPartition().
|
private |
Definition at line 285 of file MeshPartition.cpp.
References ASSERTL0, Nektar::LibUtilities::MeshPartition::MeshCurved::data, Nektar::LibUtilities::MeshPartition::MeshCurved::entityid, Nektar::LibUtilities::MeshPartition::MeshCurved::entitytype, Nektar::ParseUtils::GenerateSeqVector(), Nektar::LibUtilities::MeshPartition::MeshEntity::id, Nektar::LibUtilities::MeshPartition::MeshVertex::id, Nektar::LibUtilities::MeshPartition::MeshCurved::id, Nektar::LibUtilities::MeshPartition::MeshEntity::list, m_dim, m_domain, m_meshComposites, m_meshCurved, m_meshEdges, m_meshElements, m_meshFaces, m_meshVertices, m_vertexAttributes, Nektar::LibUtilities::MeshPartition::MeshCurved::npoints, Nektar::LibUtilities::MeshPartition::MeshEntity::type, Nektar::LibUtilities::MeshPartition::MeshCurved::type, Nektar::LibUtilities::MeshPartition::MeshVertex::x, Nektar::LibUtilities::MeshPartition::MeshVertex::y, and Nektar::LibUtilities::MeshPartition::MeshVertex::z.
Referenced by MeshPartition().
|
private |
Definition at line 622 of file MeshPartition.cpp.
References ASSERTL0, CalculateElementWeight(), Nektar::iterator, m_dim, m_domain, m_expansions, m_fieldNameToId, m_meshComposites, m_meshElements, m_numFields, and m_vertWeights.
Referenced by PartitionMesh().
void Nektar::LibUtilities::MeshPartition::WriteAllPartitions | ( | LibUtilities::SessionReaderSharedPtr & | pSession | ) |
Definition at line 133 of file MeshPartition.cpp.
References m_localPartition, OutputPartition(), and Nektar::LibUtilities::PortablePath().
void Nektar::LibUtilities::MeshPartition::WriteLocalPartition | ( | LibUtilities::SessionReaderSharedPtr & | pSession | ) |
Definition at line 103 of file MeshPartition.cpp.
References m_comm, m_localPartition, OutputPartition(), and Nektar::LibUtilities::PortablePath().
|
private |
Definition at line 210 of file MeshPartition.h.
Referenced by GetBndRegionOrdering(), and OutputPartition().
|
private |
Definition at line 215 of file MeshPartition.h.
Referenced by PartitionGraph(), and WriteLocalPartition().
|
private |
Definition at line 191 of file MeshPartition.h.
Referenced by OutputPartition(), PrintPartInfo(), ReadExpansions(), ReadGeometry(), and WeightElements().
|
private |
Definition at line 200 of file MeshPartition.h.
Referenced by OutputPartition(), PrintPartInfo(), ReadGeometry(), and WeightElements().
|
private |
Definition at line 205 of file MeshPartition.h.
Referenced by PrintPartInfo(), ReadExpansions(), and WeightElements().
|
private |
Definition at line 207 of file MeshPartition.h.
Referenced by ReadExpansions(), and WeightElements().
|
private |
Definition at line 213 of file MeshPartition.h.
Referenced by GetElementIDs(), PartitionMesh(), PrintPartInfo(), WriteAllPartitions(), and WriteLocalPartition().
|
private |
Definition at line 212 of file MeshPartition.h.
Referenced by PartitionMesh(), and PrintPartInfo().
|
private |
Definition at line 199 of file MeshPartition.h.
Referenced by GetCompositeOrdering(), OutputPartition(), PrintPartInfo(), ReadGeometry(), and WeightElements().
|
private |
Definition at line 198 of file MeshPartition.h.
Referenced by OutputPartition(), and ReadGeometry().
|
private |
Definition at line 195 of file MeshPartition.h.
Referenced by OutputPartition(), and ReadGeometry().
|
private |
Definition at line 197 of file MeshPartition.h.
Referenced by CreateGraph(), GetElementIDs(), OutputPartition(), PartitionMesh(), ReadGeometry(), and WeightElements().
|
private |
Definition at line 196 of file MeshPartition.h.
Referenced by OutputPartition(), and ReadGeometry().
|
private |
Definition at line 194 of file MeshPartition.h.
Referenced by OutputPartition(), and ReadGeometry().
|
private |
Definition at line 192 of file MeshPartition.h.
Referenced by ReadExpansions(), and WeightElements().
|
private |
Definition at line 218 of file MeshPartition.h.
Referenced by PartitionGraph(), and PartitionMesh().
|
private |
Definition at line 201 of file MeshPartition.h.
Referenced by OutputPartition(), and ReadGeometry().
|
private |
Definition at line 208 of file MeshPartition.h.
Referenced by CreateGraph(), and WeightElements().
|
private |
Definition at line 217 of file MeshPartition.h.
Referenced by CreateGraph(), PartitionGraph(), PartitionMesh(), and ReadConditions().