Nektar++
|
Tecplot output class. More...
#include <OutputTecplot.h>
Public Member Functions | |
OutputTecplot (FieldSharedPtr f) | |
~OutputTecplot () override | |
Public Member Functions inherited from Nektar::FieldUtils::OutputFileBase | |
OutputFileBase (FieldSharedPtr f) | |
~OutputFileBase () override | |
Public Member Functions inherited from Nektar::FieldUtils::OutputModule | |
OutputModule (FieldSharedPtr p_f) | |
FIELD_UTILS_EXPORT void | OpenStream () |
Open a file for output. More... | |
Public Member Functions inherited from Nektar::FieldUtils::Module | |
FIELD_UTILS_EXPORT | Module (FieldSharedPtr p_f) |
virtual | ~Module ()=default |
void | Process (po::variables_map &vm) |
std::string | GetModuleName () |
std::string | GetModuleDescription () |
const ConfigOption & | GetConfigOption (const std::string &key) const |
ModulePriority | GetModulePriority () |
std::vector< ModuleKey > | GetModulePrerequisites () |
FIELD_UTILS_EXPORT void | RegisterConfig (std::string key, std::string value="") |
Register a configuration option with a module. More... | |
FIELD_UTILS_EXPORT void | PrintConfig () |
Print out all configuration options for a module. More... | |
FIELD_UTILS_EXPORT void | SetDefaults () |
Sets default configuration options for those which have not been set. More... | |
FIELD_UTILS_EXPORT void | AddFile (std::string fileType, std::string fileName) |
FIELD_UTILS_EXPORT void | EvaluateTriFieldAtEquiSpacedPts (LocalRegions::ExpansionSharedPtr &exp, const Array< OneD, const NekDouble > &infield, Array< OneD, NekDouble > &outfield) |
Static Public Member Functions | |
static std::shared_ptr< Module > | create (FieldSharedPtr f) |
Creates an instance of this class. More... | |
Static Public Attributes | |
static ModuleKey | m_className |
Protected Member Functions | |
void | v_Process (po::variables_map &vm) override |
Write fld to output file. More... | |
std::string | v_GetModuleName () override |
void | v_OutputFromPts (po::variables_map &vm) override |
Write from pts to output file. More... | |
void | v_OutputFromExp (po::variables_map &vm) override |
Write from m_exp to output file. More... | |
void | v_OutputFromData (po::variables_map &vm) override |
Write from data to output file. More... | |
fs::path | v_GetPath (std::string &filename, po::variables_map &vm) override |
fs::path | v_GetFullOutName (std::string &filename, po::variables_map &vm) override |
virtual void | v_WriteTecplotHeader (std::ofstream &outfile, std::vector< std::string > &var) |
Write Tecplot files header. More... | |
void | WriteTecplotHeader (std::ofstream &outfile, std::vector< std::string > &var) |
virtual void | v_WriteTecplotZone (std::ofstream &outfile) |
void | WriteTecplotZone (std::ofstream &outfile) |
virtual void | v_WriteTecplotConnectivity (std::ofstream &outfile) |
Write Tecplot connectivity information (ASCII) More... | |
void | WriteTecplotConnectivity (std::ofstream &outfile) |
void | WriteTecplotFile (po::variables_map &vm) |
int | GetNumTecplotBlocks () |
Calculate number of Tecplot blocks. More... | |
void | CalculateConnectivity () |
Calculate connectivity information for each expansion dimension. More... | |
Protected Member Functions inherited from Nektar::FieldUtils::OutputFileBase | |
void | v_Process (po::variables_map &vm) override |
Write fld to output file. More... | |
std::string | v_GetModuleName () override |
std::string | v_GetModuleDescription () override |
ModulePriority | v_GetModulePriority () override |
virtual void | v_OutputFromPts (po::variables_map &vm)=0 |
Write from pts to output file. More... | |
virtual void | v_OutputFromExp (po::variables_map &vm)=0 |
Write from m_exp to output file. More... | |
virtual void | v_OutputFromData (po::variables_map &vm)=0 |
Write from data to output file. More... | |
virtual fs::path | v_GetPath (std::string &filename, po::variables_map &vm) |
fs::path | GetPath (std::string &filename, po::variables_map &vm) |
virtual fs::path | v_GetFullOutName (std::string &filename, po::variables_map &vm) |
fs::path | GetFullOutName (std::string &filename, po::variables_map &vm) |
Protected Member Functions inherited from Nektar::FieldUtils::Module | |
Module () | |
virtual void | v_Process (po::variables_map &vm) |
virtual std::string | v_GetModuleName () |
virtual std::string | v_GetModuleDescription () |
virtual ModulePriority | v_GetModulePriority () |
virtual std::vector< ModuleKey > | v_GetModulePrerequisites () |
Protected Attributes | |
bool | m_binary |
True if writing binary field output. More... | |
bool | m_oneOutputFile |
True if writing a single output file. More... | |
bool | m_writeHeader |
True if writing header. More... | |
TecplotZoneType | m_zoneType |
Tecplot zone type of output. More... | |
std::vector< int > | m_numPoints |
Number of points per block in Tecplot file. More... | |
int | m_numBlocks |
Number of blocks in Tecplot file. More... | |
int | m_coordim |
Coordinate dimension of output. More... | |
int | m_totConn |
Total number of connectivity entries. More... | |
std::vector< Array< OneD, int > > | m_conn |
Connectivty for each block: one per element. More... | |
Array< OneD, int > | m_rankFieldSizes |
Each rank's field sizes. More... | |
Array< OneD, int > | m_rankConnSizes |
Each rank's connectivity sizes. More... | |
Array< OneD, Array< OneD, NekDouble > > | m_fields |
Field data to output. More... | |
Protected Attributes inherited from Nektar::FieldUtils::OutputFileBase | |
bool | m_requireEquiSpaced |
bool | m_prohibitWrite = false |
bool | m_equispacedSetup = false |
Protected Attributes inherited from Nektar::FieldUtils::OutputModule | |
std::ofstream | m_fldFile |
Output stream. More... | |
Protected Attributes inherited from Nektar::FieldUtils::Module | |
std::map< std::string, ConfigOption > | m_config |
List of configuration values. More... | |
std::set< std::string > | m_allowedFiles |
List of allowed file formats. More... | |
Additional Inherited Members | |
Public Attributes inherited from Nektar::FieldUtils::Module | |
FieldSharedPtr | m_f |
Field object. More... | |
Tecplot output class.
Definition at line 59 of file OutputTecplot.h.
Nektar::FieldUtils::OutputTecplot::OutputTecplot | ( | FieldSharedPtr | f | ) |
Definition at line 61 of file OutputTecplot.cpp.
References Nektar::FieldUtils::Module::m_config, and Nektar::FieldUtils::OutputFileBase::m_requireEquiSpaced.
|
override |
Definition at line 71 of file OutputTecplot.cpp.
|
protected |
Calculate connectivity information for each expansion dimension.
outfile | Output file |
Definition at line 984 of file OutputTecplot.cpp.
References ASSERTL0, Nektar::MultiRegions::e2DH1D, Nektar::MultiRegions::e3DH1D, m_conn, and Nektar::FieldUtils::Module::m_f.
Referenced by v_OutputFromExp().
|
inlinestatic |
Creates an instance of this class.
Definition at line 63 of file OutputTecplot.h.
References Nektar::MemoryManager< DataType >::AllocateSharedPtr().
|
protected |
Calculate number of Tecplot blocks.
outfile | Output file |
Definition at line 947 of file OutputTecplot.cpp.
References Nektar::FieldUtils::Module::m_f.
Referenced by v_OutputFromExp().
|
overrideprotectedvirtual |
Reimplemented from Nektar::FieldUtils::OutputFileBase.
Definition at line 371 of file OutputTecplot.cpp.
References Nektar::FieldUtils::OutputFileBase::GetPath().
|
inlineoverrideprotectedvirtual |
Reimplemented from Nektar::FieldUtils::OutputFileBase.
Definition at line 75 of file OutputTecplot.h.
|
overrideprotectedvirtual |
Reimplemented from Nektar::FieldUtils::OutputFileBase.
Definition at line 352 of file OutputTecplot.cpp.
References Nektar::FieldUtils::Module::m_f, and m_oneOutputFile.
|
overrideprotectedvirtual |
Write from data to output file.
Implements Nektar::FieldUtils::OutputFileBase.
Definition at line 346 of file OutputTecplot.cpp.
References Nektar::ErrorUtil::efatal, and NEKERROR.
|
overrideprotectedvirtual |
Write from m_exp to output file.
Implements Nektar::FieldUtils::OutputFileBase.
Definition at line 232 of file OutputTecplot.cpp.
References CalculateConnectivity(), Nektar::MultiRegions::e3DH1D, GetNumTecplotBlocks(), m_coordim, Nektar::FieldUtils::Module::m_f, m_fields, m_numBlocks, m_writeHeader, m_zoneType, Vmath::Sadd(), Vmath::Vcopy(), WriteTecplotFile(), and Nektar::UnitTests::z().
|
overrideprotectedvirtual |
Write from pts to output file.
Implements Nektar::FieldUtils::OutputFileBase.
Definition at line 147 of file OutputTecplot.cpp.
References ASSERTL0, Nektar::FieldUtils::eFETetrahedron, Nektar::FieldUtils::eFETriangle, Nektar::FieldUtils::eOrdered, Nektar::LibUtilities::ePtsBox, Nektar::LibUtilities::ePtsFile, Nektar::LibUtilities::ePtsLine, Nektar::LibUtilities::ePtsPlane, Nektar::LibUtilities::ePtsTetBlock, Nektar::LibUtilities::ePtsTriBlock, m_binary, m_conn, m_coordim, Nektar::FieldUtils::Module::m_f, m_fields, m_numBlocks, m_numPoints, m_writeHeader, m_zoneType, Nektar::LibUtilities::ReduceSum, and WriteTecplotFile().
|
overrideprotectedvirtual |
Write fld to output file.
Reimplemented from Nektar::FieldUtils::OutputFileBase.
Definition at line 75 of file OutputTecplot.cpp.
References Nektar::FieldUtils::Module::m_config, Nektar::FieldUtils::Module::m_f, m_oneOutputFile, and Nektar::FieldUtils::OutputFileBase::v_Process().
|
protectedvirtual |
Write Tecplot connectivity information (ASCII)
outfile | Output file |
Reimplemented in Nektar::FieldUtils::OutputTecplotBinary.
Definition at line 833 of file OutputTecplot.cpp.
References Nektar::FieldUtils::eOrdered, m_conn, Nektar::FieldUtils::Module::m_f, m_oneOutputFile, m_rankConnSizes, m_rankFieldSizes, m_totConn, m_zoneType, and Vmath::Vcopy().
Referenced by WriteTecplotConnectivity().
|
protectedvirtual |
Write Tecplot files header.
outfile | Output file name |
var | Variables names |
Reimplemented in Nektar::FieldUtils::OutputTecplotBinary.
Definition at line 447 of file OutputTecplot.cpp.
Referenced by WriteTecplotHeader().
|
protectedvirtual |
Write Tecplot zone output in ASCII
outfile | Output file name. |
expansion | Expansion that is considered |
Reimplemented in Nektar::FieldUtils::OutputTecplotBinary.
Definition at line 502 of file OutputTecplot.cpp.
References Nektar::FieldUtils::eOrdered, Nektar::FieldUtils::Module::m_config, Nektar::FieldUtils::Module::m_f, m_fields, m_numBlocks, m_numPoints, m_oneOutputFile, m_rankFieldSizes, m_zoneType, Nektar::FieldUtils::TecplotZoneTypeMap, and Vmath::Vsum().
Referenced by WriteTecplotZone().
|
inlineprotected |
Definition at line 132 of file OutputTecplot.h.
References v_WriteTecplotConnectivity().
Referenced by WriteTecplotFile().
|
protected |
Definition at line 377 of file OutputTecplot.cpp.
References Nektar::FieldUtils::OutputFileBase::GetFullOutName(), m_binary, Nektar::FieldUtils::Module::m_config, m_conn, m_coordim, Nektar::FieldUtils::Module::m_f, m_fields, m_numBlocks, m_oneOutputFile, m_rankConnSizes, m_rankFieldSizes, m_totConn, m_writeHeader, Nektar::LibUtilities::PortablePath(), Nektar::LibUtilities::ReduceSum, WriteTecplotConnectivity(), WriteTecplotHeader(), and WriteTecplotZone().
Referenced by v_OutputFromExp(), and v_OutputFromPts().
|
inlineprotected |
Definition at line 121 of file OutputTecplot.h.
References v_WriteTecplotHeader().
Referenced by WriteTecplotFile().
|
inlineprotected |
Definition at line 127 of file OutputTecplot.h.
References v_WriteTecplotZone().
Referenced by WriteTecplotFile().
|
protected |
True if writing binary field output.
Definition at line 95 of file OutputTecplot.h.
Referenced by Nektar::FieldUtils::OutputTecplotBinary::OutputTecplotBinary(), v_OutputFromPts(), and WriteTecplotFile().
|
static |
Definition at line 68 of file OutputTecplot.h.
Connectivty for each block: one per element.
Definition at line 111 of file OutputTecplot.h.
Referenced by CalculateConnectivity(), v_OutputFromPts(), v_WriteTecplotConnectivity(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotConnectivity(), and WriteTecplotFile().
|
protected |
Coordinate dimension of output.
Definition at line 107 of file OutputTecplot.h.
Referenced by v_OutputFromExp(), v_OutputFromPts(), and WriteTecplotFile().
Field data to output.
Definition at line 117 of file OutputTecplot.h.
Referenced by v_OutputFromExp(), v_OutputFromPts(), v_WriteTecplotZone(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotZone(), and WriteTecplotFile().
|
protected |
Number of blocks in Tecplot file.
Definition at line 105 of file OutputTecplot.h.
Referenced by v_OutputFromExp(), v_OutputFromPts(), v_WriteTecplotZone(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotZone(), and WriteTecplotFile().
|
protected |
Number of points per block in Tecplot file.
Definition at line 103 of file OutputTecplot.h.
Referenced by v_OutputFromPts(), v_WriteTecplotZone(), and Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotZone().
|
protected |
True if writing a single output file.
Definition at line 97 of file OutputTecplot.h.
Referenced by v_GetPath(), v_Process(), v_WriteTecplotConnectivity(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotConnectivity(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotHeader(), v_WriteTecplotZone(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotZone(), and WriteTecplotFile().
Each rank's connectivity sizes.
Definition at line 115 of file OutputTecplot.h.
Referenced by v_WriteTecplotConnectivity(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotConnectivity(), and WriteTecplotFile().
Each rank's field sizes.
Definition at line 113 of file OutputTecplot.h.
Referenced by v_WriteTecplotConnectivity(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotConnectivity(), v_WriteTecplotZone(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotZone(), and WriteTecplotFile().
|
protected |
Total number of connectivity entries.
Definition at line 109 of file OutputTecplot.h.
Referenced by v_WriteTecplotConnectivity(), Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotConnectivity(), and WriteTecplotFile().
|
protected |
True if writing header.
Definition at line 99 of file OutputTecplot.h.
Referenced by v_OutputFromExp(), v_OutputFromPts(), and WriteTecplotFile().
|
protected |
Tecplot zone type of output.
Definition at line 101 of file OutputTecplot.h.
Referenced by v_OutputFromExp(), v_OutputFromPts(), v_WriteTecplotConnectivity(), v_WriteTecplotZone(), and Nektar::FieldUtils::OutputTecplotBinary::v_WriteTecplotZone().