Nektar++
|
Converter for Gmsh files. More...
#include <OutputNekpp.h>
Public Member Functions | |
OutputNekpp (MeshSharedPtr m) | |
virtual | ~OutputNekpp () |
virtual void | Process () |
Write mesh to output file. More... | |
Public Member Functions inherited from Nektar::Utilities::OutputModule | |
OutputModule (FieldSharedPtr p_f) | |
void | OpenStream () |
Open a file for output. More... | |
OutputModule (MeshSharedPtr p_m) | |
void | OpenStream () |
Public Member Functions inherited from Nektar::Utilities::Module | |
Module (FieldSharedPtr p_f) | |
virtual void | Process (po::variables_map &vm)=0 |
void | RegisterConfig (string key, string value) |
Register a configuration option with a module. More... | |
void | PrintConfig () |
Print out all configuration options for a module. More... | |
void | SetDefaults () |
Sets default configuration options for those which have not been set. More... | |
bool | GetRequireEquiSpaced (void) |
void | SetRequireEquiSpaced (bool pVal) |
void | EvaluateTriFieldAtEquiSpacedPts (LocalRegions::ExpansionSharedPtr &exp, const Array< OneD, const NekDouble > &infield, Array< OneD, NekDouble > &outfield) |
Module (MeshSharedPtr p_m) | |
void | RegisterConfig (std::string key, std::string value) |
void | PrintConfig () |
void | SetDefaults () |
MeshSharedPtr | GetMesh () |
virtual void | ProcessVertices () |
Extract element vertices. More... | |
virtual void | ProcessEdges (bool ReprocessEdges=true) |
Extract element edges. More... | |
virtual void | ProcessFaces (bool ReprocessFaces=true) |
Extract element faces. More... | |
virtual void | ProcessElements () |
Generate element IDs. More... | |
virtual void | ProcessComposites () |
Generate composites. More... | |
virtual void | ClearElementLinks () |
Static Public Member Functions | |
static boost::shared_ptr< Module > | create (MeshSharedPtr m) |
Creates an instance of this class. More... | |
Static Public Attributes | |
static 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::Utilities::Module | |
Module () | |
void | ReorderPrisms (PerMap &perFaces) |
Reorder node IDs so that prisms and tetrahedra are aligned correctly. More... | |
void | PrismLines (int prism, PerMap &perFaces, std::set< int > &prismsDone, std::vector< ElementSharedPtr > &line) |
Protected Attributes inherited from Nektar::Utilities::OutputModule | |
ofstream | m_fldFile |
Output stream. More... | |
std::ofstream | m_mshFile |
Output stream. More... | |
Protected Attributes inherited from Nektar::Utilities::Module | |
FieldSharedPtr | m_f |
Field object. More... | |
map< string, ConfigOption > | m_config |
List of configuration values. More... | |
bool | m_requireEquiSpaced |
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 | ( | MeshSharedPtr | m | ) |
Definition at line 64 of file OutputNekpp.cpp.
References Nektar::Utilities::Module::m_config.
|
virtual |
Definition at line 73 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::Utilities::Module.
Definition at line 94 of file OutputNekpp.cpp.
References Nektar::LibUtilities::SessionReader::CreateInstance(), Nektar::Utilities::Module::m_config, Nektar::Utilities::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 982 of file OutputNekpp.cpp.
References Nektar::SpatialDomains::ePeriodic, Nektar::StdRegions::find(), Nektar::iterator, and Nektar::Utilities::Module::m_mesh.
Referenced by Process().
|
private |
Writes the <CONDITIONS> section of the XML file.
Definition at line 1103 of file OutputNekpp.cpp.
References Nektar::SpatialDomains::eDirichlet, Nektar::NekMeshUtils::eHOPCondition, Nektar::SpatialDomains::eNeumann, Nektar::SpatialDomains::ePeriodic, Nektar::iterator, and Nektar::Utilities::Module::m_mesh.
Referenced by Process().
|
private |
Writes the <CURVES> section of the XML file if needed.
Definition at line 600 of file OutputNekpp.cpp.
References Nektar::NekMeshUtils::curve, 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::Utilities::Module::m_config, Nektar::Utilities::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 1040 of file OutputNekpp.cpp.
References Nektar::iterator, and Nektar::Utilities::Module::m_mesh.
Referenced by Process().
|
private |
Writes the <EDGES> section of the XML file.
Definition at line 221 of file OutputNekpp.cpp.
References Nektar::LibUtilities::CompressData::GetBitSizeStr(), Nektar::LibUtilities::CompressData::GetCompressString(), Nektar::LibUtilities::MeshEdge::id, Nektar::iterator, Nektar::Utilities::Module::m_config, Nektar::Utilities::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 387 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::Utilities::Module::m_config, Nektar::Utilities::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 1063 of file OutputNekpp.cpp.
References Nektar::iterator, and Nektar::Utilities::Module::m_mesh.
Referenced by Process().
|
private |
Writes the <FACES> section of the XML file if needed.
Definition at line 274 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::Utilities::Module::m_config, Nektar::Utilities::Module::m_mesh, and Nektar::LibUtilities::CompressData::ZlibEncodeToBase64Str().
Referenced by Process().
|
private |
Writes the <NODES> section of the XML file.
Definition at line 171 of file OutputNekpp.cpp.
References Nektar::LibUtilities::CompressData::GetBitSizeStr(), Nektar::LibUtilities::CompressData::GetCompressString(), Nektar::LibUtilities::MeshVertex::id, Nektar::iterator, Nektar::Utilities::Module::m_config, Nektar::Utilities::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.