Nektar++
|
Converter for Gmsh files. More...
#include <OutputNekpp.h>
Public Member Functions | |
OutputNekpp (NekMeshUtils::MeshSharedPtr m) | |
virtual | ~OutputNekpp () |
virtual void | Process () |
Write mesh to output file. More... | |
Public Member Functions inherited from Nektar::NekMeshUtils::OutputModule | |
NEKMESHUTILS_EXPORT | OutputModule (MeshSharedPtr p_m) |
NEKMESHUTILS_EXPORT void | OpenStream () |
Open a file for output. More... | |
Public Member Functions inherited from Nektar::NekMeshUtils::Module | |
NEKMESHUTILS_EXPORT | Module (MeshSharedPtr p_m) |
NEKMESHUTILS_EXPORT void | RegisterConfig (std::string key, std::string value) |
Register a configuration option with a module. More... | |
NEKMESHUTILS_EXPORT void | PrintConfig () |
Print out all configuration options for a module. More... | |
NEKMESHUTILS_EXPORT void | SetDefaults () |
Sets default configuration options for those which have not been set. More... | |
NEKMESHUTILS_EXPORT MeshSharedPtr | GetMesh () |
virtual NEKMESHUTILS_EXPORT void | ProcessVertices () |
Extract element vertices. More... | |
virtual NEKMESHUTILS_EXPORT void | ProcessEdges (bool ReprocessEdges=true) |
Extract element edges. More... | |
virtual NEKMESHUTILS_EXPORT void | ProcessFaces (bool ReprocessFaces=true) |
Extract element faces. More... | |
virtual NEKMESHUTILS_EXPORT void | ProcessElements () |
Generate element IDs. More... | |
virtual NEKMESHUTILS_EXPORT void | ProcessComposites () |
Generate composites. More... | |
virtual NEKMESHUTILS_EXPORT void | ClearElementLinks () |
Static Public Member Functions | |
static boost::shared_ptr< Module > | create (NekMeshUtils::MeshSharedPtr m) |
Creates an instance of this class. More... | |
Static Public Attributes | |
static NekMeshUtils::ModuleKey | className |
Private Member Functions | |
void | WriteXmlNodes (TiXmlElement *pRoot) |
Writes the <NODES> section of the XML file. More... | |
void | WriteXmlEdges (TiXmlElement *pRoot) |
Writes the <EDGES> section of the XML file. More... | |
void | WriteXmlFaces (TiXmlElement *pRoot) |
Writes the <FACES> section of the XML file if needed. More... | |
void | WriteXmlElements (TiXmlElement *pRoot) |
Writes the <ELEMENTS> section of the XML file. More... | |
void | WriteXmlCurves (TiXmlElement *pRoot) |
Writes the <CURVES> section of the XML file if needed. More... | |
void | WriteXmlComposites (TiXmlElement *pRoot) |
Writes the <COMPOSITES> section of the XML file. More... | |
void | WriteXmlDomain (TiXmlElement *pRoot) |
Writes the <DOMAIN> section of the XML file. More... | |
void | WriteXmlExpansions (TiXmlElement *pRoot) |
Writes the <EXPANSIONS> section of the XML file. More... | |
void | WriteXmlConditions (TiXmlElement *pRoot) |
Writes the <CONDITIONS> section of the XML file. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from Nektar::NekMeshUtils::Module | |
NEKMESHUTILS_EXPORT void | ReorderPrisms (PerMap &perFaces) |
Reorder node IDs so that prisms and tetrahedra are aligned correctly. More... | |
NEKMESHUTILS_EXPORT void | PrismLines (int prism, PerMap &perFaces, std::set< int > &prismsDone, std::vector< ElementSharedPtr > &line) |
Protected Attributes inherited from Nektar::NekMeshUtils::OutputModule | |
io::filtering_ostream | m_mshFile |
Output stream. More... | |
std::ofstream | m_mshFileStream |
Input stream. More... | |
Protected Attributes inherited from Nektar::NekMeshUtils::Module | |
MeshSharedPtr | m_mesh |
Mesh object. More... | |
std::map< std::string, ConfigOption > | m_config |
List of configuration values. More... | |
Converter for Gmsh files.
Definition at line 49 of file OutputNekpp.h.
Nektar::Utilities::OutputNekpp::OutputNekpp | ( | NekMeshUtils::MeshSharedPtr | m | ) |
Definition at line 65 of file OutputNekpp.cpp.
References Nektar::NekMeshUtils::Module::m_config.
|
virtual |
Definition at line 75 of file OutputNekpp.cpp.
|
inlinestatic |
Creates an instance of this class.
Definition at line 53 of file OutputNekpp.h.
References Nektar::MemoryManager< DataType >::AllocateSharedPtr().
|
virtual |
Write mesh to output file.
Implements Nektar::NekMeshUtils::Module.
Definition at line 96 of file OutputNekpp.cpp.
References CellMLToNektar.pycml::copy(), Nektar::LibUtilities::SessionReader::CreateInstance(), Nektar::LibUtilities::ePolyEvenlySpaced, Nektar::NekMeshUtils::Module::m_config, Nektar::NekMeshUtils::Module::m_mesh, Nektar::SpatialDomains::MeshGraph::Read(), WriteXmlComposites(), WriteXmlConditions(), WriteXmlCurves(), WriteXmlDomain(), WriteXmlEdges(), WriteXmlElements(), WriteXmlExpansions(), WriteXmlFaces(), and WriteXmlNodes().
|
private |
Writes the <COMPOSITES> section of the XML file.
Definition at line 992 of file OutputNekpp.cpp.
References Nektar::SpatialDomains::ePeriodic, Nektar::StdRegions::find(), Nektar::iterator, and Nektar::NekMeshUtils::Module::m_mesh.
Referenced by Process().
|
private |
Writes the <CONDITIONS> section of the XML file.
Definition at line 1113 of file OutputNekpp.cpp.
References Nektar::SpatialDomains::eDirichlet, Nektar::NekMeshUtils::eHOPCondition, Nektar::SpatialDomains::eNeumann, Nektar::SpatialDomains::ePeriodic, Nektar::iterator, and Nektar::NekMeshUtils::Module::m_mesh.
Referenced by Process().
|
private |
Writes the <CURVES> section of the XML file if needed.
Definition at line 609 of file OutputNekpp.cpp.
References Nektar::LibUtilities::MeshCurvedInfo::entityid, Nektar::LibUtilities::CompressData::GetBitSizeStr(), Nektar::LibUtilities::CompressData::GetCompressString(), Nektar::LibUtilities::MeshVertex::id, Nektar::LibUtilities::MeshCurvedInfo::id, Nektar::LibUtilities::MeshCurvedPts::id, Nektar::LibUtilities::MeshCurvedPts::index, Nektar::iterator, Nektar::LibUtilities::kPointsTypeStr, Nektar::NekMeshUtils::Module::m_config, Nektar::NekMeshUtils::Module::m_mesh, Nektar::LibUtilities::MeshCurvedInfo::npoints, Nektar::LibUtilities::MeshCurvedInfo::ptid, Nektar::LibUtilities::MeshCurvedInfo::ptoffset, Nektar::LibUtilities::MeshCurvedPts::pts, Nektar::LibUtilities::MeshCurvedInfo::ptype, Nektar::LibUtilities::MeshVertex::x, Nektar::LibUtilities::MeshVertex::y, Nektar::LibUtilities::MeshVertex::z, and Nektar::LibUtilities::CompressData::ZlibEncodeToBase64Str().
Referenced by Process().
|
private |
Writes the <DOMAIN> section of the XML file.
Definition at line 1050 of file OutputNekpp.cpp.
References Nektar::iterator, and Nektar::NekMeshUtils::Module::m_mesh.
Referenced by Process().
|
private |
Writes the <EDGES> section of the XML file.
Definition at line 230 of file OutputNekpp.cpp.
References Nektar::LibUtilities::CompressData::GetBitSizeStr(), Nektar::LibUtilities::CompressData::GetCompressString(), Nektar::LibUtilities::MeshEdge::id, Nektar::iterator, Nektar::NekMeshUtils::Module::m_config, Nektar::NekMeshUtils::Module::m_mesh, Nektar::LibUtilities::MeshEdge::v0, Nektar::LibUtilities::MeshEdge::v1, and Nektar::LibUtilities::CompressData::ZlibEncodeToBase64Str().
Referenced by Process().
|
private |
Writes the <ELEMENTS> section of the XML file.
Definition at line 396 of file OutputNekpp.cpp.
References ASSERTL0, Nektar::LibUtilities::MeshTri::e, Nektar::LibUtilities::MeshQuad::e, Nektar::LibUtilities::MeshTet::f, Nektar::LibUtilities::MeshPyr::f, Nektar::LibUtilities::MeshPrism::f, Nektar::LibUtilities::MeshHex::f, Nektar::LibUtilities::CompressData::GetBitSizeStr(), Nektar::LibUtilities::CompressData::GetCompressString(), GetXmlString(), Nektar::LibUtilities::MeshEdge::id, Nektar::LibUtilities::MeshTri::id, Nektar::LibUtilities::MeshQuad::id, Nektar::LibUtilities::MeshTet::id, Nektar::LibUtilities::MeshPyr::id, Nektar::LibUtilities::MeshPrism::id, Nektar::LibUtilities::MeshHex::id, Nektar::NekMeshUtils::Module::m_config, Nektar::NekMeshUtils::Module::m_mesh, Nektar::LibUtilities::MeshEdge::v0, Nektar::LibUtilities::MeshEdge::v1, and Nektar::LibUtilities::CompressData::ZlibEncodeToBase64Str().
Referenced by Process().
|
private |
Writes the <EXPANSIONS> section of the XML file.
Definition at line 1073 of file OutputNekpp.cpp.
References Nektar::iterator, and Nektar::NekMeshUtils::Module::m_mesh.
Referenced by Process().
|
private |
Writes the <FACES> section of the XML file if needed.
Definition at line 283 of file OutputNekpp.cpp.
References ASSERTL0, Nektar::LibUtilities::MeshTri::e, Nektar::LibUtilities::MeshQuad::e, Nektar::LibUtilities::CompressData::GetBitSizeStr(), Nektar::LibUtilities::CompressData::GetCompressString(), Nektar::LibUtilities::MeshTri::id, Nektar::LibUtilities::MeshQuad::id, Nektar::iterator, Nektar::NekMeshUtils::Module::m_config, Nektar::NekMeshUtils::Module::m_mesh, and Nektar::LibUtilities::CompressData::ZlibEncodeToBase64Str().
Referenced by Process().
|
private |
Writes the <NODES> section of the XML file.
Definition at line 180 of file OutputNekpp.cpp.
References Nektar::LibUtilities::CompressData::GetBitSizeStr(), Nektar::LibUtilities::CompressData::GetCompressString(), Nektar::LibUtilities::MeshVertex::id, Nektar::iterator, Nektar::NekMeshUtils::Module::m_config, Nektar::NekMeshUtils::Module::m_mesh, Nektar::LibUtilities::MeshVertex::x, Nektar::LibUtilities::MeshVertex::y, Nektar::LibUtilities::MeshVertex::z, and Nektar::LibUtilities::CompressData::ZlibEncodeToBase64Str().
Referenced by Process().
|
static |
Definition at line 57 of file OutputNekpp.h.