175 class ccmGlobalState;
200 static const char* cellTableOpti[];
203 static const char* cellTableOptstr[];
209 const std::unique_ptr<options> options_;
215 UNKNOWN, BAD, OKAY, READ
220 nodeStatus geometryStatus_;
223 nodeStatus solutionStatus_;
240 label nInternalFaces_;
305 void operator=(
const reader&) =
delete;
309 inline labelList patchStartList(label initial)
const;
312 void printSizes()
const;
315 int ccmGetEntityIndex(ccmNODE node);
319 std::string ccmReadNodestr(
const char* opt, ccmNODE node);
323 std::string ccmReadOptstr(
const char* opt, ccmID node);
329 bool detectGeometry();
332 void readProblemDescription(
const ccmID& probNode);
337 void readInterfaceDefinitions();
340 void readProblemDescription_boundaryRegion(
const ccmID& probNode);
343 void readProblemDescription_cellTable(
const ccmID& probNode);
346 void readMeshTopology(
const scalar scaleFactor=1.0);
351 const ccmID& verticesNode,
352 const scalar scaleFactor = 1.0
356 void readCells(
const ccmID& topoNode);
359 void readInterfaces(
const ccmID& cellsNode);
362 void readMonitoring(
const ccmID& topoId);
369 void removeUnwanted();
375 void renumberInterfaces(
const labelUList& oldToNew);
380 void cleanupInterfaces();
383 void mergeInplaceInterfaces();
392 void writeMeshLabelList
395 const word& propertyName,
407 bool detectSolution();
411 void determineFieldInfo
413 const ccmID& fieldSetNode,
525 return interfaceDefinitions_;
531 return boundaryRegion_;
543 return cellTable_.
fluids();
549 return cellTable_.
solids();
556 return solutionTable_;
570 return lagrangianTable_;
576 const word& solutionName,
577 const word& fieldName,
578 const bool wallData =
false 602 bool mergeInterfaces_;
606 bool renameInterfaces_;
613 bool useNumberedNames_;
options()
Construct with the defaults.
void printInfo() const
Print general information about the mesh.
A class for handling file names.
const interfaceDefinitions & interfaceDefinitionsInfo() const
Return interface definitions map.
bool removeBaffles() const
Remove baffles by merging their respective faces (default false)
Containers for holding STARCCM interface definitions.
Base functionality common to reader and writer classes.
static const fileName null
An empty fileName.
static void warnDuplicates(const word &context, const wordList &lst)
Warn about repeated name.
bool useNumberedNames() const
Use numbered names (eg, patch_0, zone_0) instead of human-readable.
Map< word > solids() const
Return a Map of (id => name) for solids.
Reads CCM files as written by PROSTAR/STARCCM.
A simple container for options an IOstream can normally have.
A list of available interface definitions.
scalar mergeTol() const
Merge tolerance for points (default 0.05e-3)
const boundaryRegion & boundaryTableInfo() const
Return boundaryRegion table.
bool mergeInterfaces() const
Merge in-place interfaces (default true)
scalar undefScalar() const
Value to assign for undefined solutions (default: NaN)
Various functions to operate on Lists.
const reader::options & option() const
Reference to the reader options.
const dimensionedScalar b
Wien displacement law constant: default SI units: [m.K].
A class for handling words, derived from Foam::string.
void clearGeom()
Clear out some information after obtaining a polyMesh.
bool hasGeometry()
Return true if file has geometry associated with it.
bool keepFluid() const
Keep fluid regions (default true)
Map< word > fluids() const
Return a Map of (id => name) for fluids.
A HashTable similar to std::unordered_map.
The cellTable persistent data saved as a Map<dictionary>.
const fieldTable & fields()
Return table of available fields.
Map< word > fluids() const
Return a list of names corresponding to fluids.
bool hasSolution()
Return true if file has solutions associated with it.
~reader()
Destructor (closes file)
Database for solution data, solver performance and other reduced data.
Containers for holding ccm solution and field listings.
tmp< scalarField > readField(const word &solutionName, const word &fieldName, const bool wallData=false)
Read solution and field combination.
Map< word > solids() const
Return a list of names corresponding to solids.
void writeAux(const objectRegistry ®istry) const
Write cellTable, boundaryRegion and interface information.
const cellTable & cellTableInfo() const
Return cell table.
A list of the available fields.
const labelList & origFaceId() const
Map to original face Id.
bool remapMeshInfo(const objectRegistry ®istry, const fileName &remappingDictName=fileName::null)
Remap cellTable and boundaryRegion according to dictionary.
autoPtr< polyMesh > mesh(const objectRegistry ®istry, const fileName &remappingDictName=fileName::null)
Construct the polyMesh from the read geometry.
bool renameInterfaces() const
Rename interface boundaries as InterfaceN_0, InterfaceN_1.
bool readGeometry(const scalar scaleFactor=1.0)
Detect and read geometry if possible.
void writeMesh(const polyMesh &mesh, IOstreamOption streamOpt=IOstreamOption(IOstreamOption::BINARY)) const
Write the polyMesh.
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
Mesh consisting of general polyhedral cells.
const labelList & origCellId() const
Map to original cell Id.
bool keptSomeRegion() const
Some region (fluid, porous, solid) is kept.
A class for managing temporary objects.
Registry of regIOobjects.
bool keepSolid() const
Keep solid regions (default true)
The boundaryRegion persistent data saved as a Map<dictionary>.
const fieldTable & lagrangian()
Return table of available lagrangian fields.
const solutionTable & solutions()
Return table of available solutions.
bool keepPorous() const
Keep porous regions (default true)
A HashTable to objects of type <T> with a label key.