70 void Foam::meshReader::addCellZones(polyMesh& mesh)
const
77 void Foam::meshReader::addFaceZones(polyMesh& mesh)
const
79 label nZone = monitoringSets_.size();
80 mesh.faceZones().setSize(nZone);
90 HashTable<List<label>, word, string::hash>::const_iterator
91 iter = monitoringSets_.begin();
92 iter != monitoringSets_.end();
96 Info<<
"faceZone " << nZone
97 <<
" (size: " << iter().size() <<
") name: "
98 << iter.key() <<
endl;
107 List<bool>(iter().size(),
false),
116 warnDuplicates(
"faceZones", mesh.faceZones().names());
127 Info<<
"Creating a polyMesh" <<
endl;
130 Info<<
"Number of internal faces: " << nInternalFaces_ <<
endl;
132 createPolyBoundary();
152 mesh().addPatches(polyBoundaryPatches(mesh));
157 warnDuplicates(
"boundaries", mesh().boundaryMesh().names());
159 addCellZones(mesh());
160 addFaceZones(mesh());
186 void Foam::meshReader::clearExtraStorage()
189 baffleFaces_.clear();
190 boundaryIds_.clear();
202 const scalar scaleFactor
205 pointCellsPtr_(nullptr),
213 geometryFile_(fileOrPrefix),
214 scaleFactor_(scaleFactor),
220 patchPhysicalTypes_(0),
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
static const versionNumber currentVersion
Current version number.
streamFormat
Enumeration for the format of data in the stream.
static const word & constant()
Return constant name.
Maps a geometry to a set of cell primitives, which enables geometric cell data to be calculated witho...
static const cellModel * lookup(const word &)
Look up a model by name and return a pointer to the model or nullptr.
void addCellZones(polyMesh &, const labelList &tableIds) const
Classify tableIds into cellZones according to the cellTable.
A class for handling file names.
static void warnDuplicates(const word &context, const wordList &)
Warn about repeated names.
virtual ~meshReader()
Destructor.
static const cellModel * prismModel
static const cellModel * unknownModel
Pointers to cell shape models.
meshReader(const fileName &, const scalar scaleFactor=1.0)
Construct from fileName.
virtual autoPtr< polyMesh > mesh(const objectRegistry &)
Create and return polyMesh.
cellTable cellTable_
Cell table persistent data saved as a dictionary.
labelList cellTableId_
Cell table id for each cell.
void writeMesh(const polyMesh &, IOstream::streamFormat fmt=IOstream::BINARY) const
Write mesh.
static const cellModel * hexModel
static const cellModel * tetModel
static const cellModel * pyrModel
Registry of regIOobjects.
const Time & time() const
Return time.
Mesh consisting of general polyhedral cells.
static word defaultRegion
Return the default region name.
virtual bool writeObject(IOstream::streamFormat fmt, IOstream::versionNumber ver, IOstream::compressionType cmp, const bool write=true) const
Write the underlying polyMesh.
void removeFiles(const fileName &instanceDir) const
Remove all files from mesh instance.
Template functions to aid in the implementation of demand driven data.
void polyMeshUnMergeCyclics(polyMesh &mesh, const scalar includedAngle=165)
Find all patches of type "mergedCyclic" in the given mesh and split them.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.
void deleteDemandDrivenData(DataPtr &dataPtr)