57 ofstream fluentMeshFile
73 <<
"(0 \"Grid dimensions:\")" <<
std::endl;
107 fluentMeshFile.setf(
ios::hex, ios::basefield);
121 <<
p[pointi].x() <<
" "
143 fluentMeshFile <<
" ";
145 fluentMeshFile << l.
size() <<
" ";
149 fluentMeshFile << l[lI] + 1 <<
" ";
152 fluentMeshFile << nei[facei] + 1 <<
" ";
153 fluentMeshFile << own[facei] + 1 <<
std::endl;
158 label nWrittenFaces = own.size();
172 <<
"(13 (" <<
patchi + 10 <<
" " << nWrittenFaces + 1
173 <<
" " << nWrittenFaces + patchFaces.size() <<
" ";
175 nWrittenFaces += patchFaces.size();
202 fluentMeshFile <<
" ";
204 fluentMeshFile << l.
size() <<
" ";
211 fluentMeshFile << l[lI] + 1 <<
" ";
214 fluentMeshFile << patchFaceCells[facei] + 1 <<
" 0" <<
std::endl;
232 bool hasWarned =
false;
236 if (
cells[celli].model() == tet)
238 fluentMeshFile <<
" " << 2;
240 else if (
cells[celli].model() ==
hex)
242 fluentMeshFile <<
" " << 4;
244 else if (
cells[celli].model() == pyr)
246 fluentMeshFile <<
" " << 5;
248 else if (
cells[celli].model() == prism)
250 fluentMeshFile <<
" " << 6;
259 <<
"foamMeshToFluent: cell shape for cell "
260 << celli <<
" only supported by Fluent polyhedral meshes."
262 <<
" Suppressing any further messages for polyhedral"
263 <<
" cells." <<
endl;
265 fluentMeshFile <<
" " << 7;
275 fluentMeshFile <<
"(39 (1 fluid fluid-1)())" <<
std::endl;
276 fluentMeshFile <<
"(39 (2 interior interior-1)())" <<
std::endl;
282 <<
"(39 (" <<
patchi + 10 <<
" ";
287 fluentMeshFile <<
"wall ";
295 fluentMeshFile <<
"symmetry ";
299 fluentMeshFile <<
"pressure-outlet ";
Functions used by OpenFOAM that are specific to POSIX compliant operating systems and need to be repl...
#define forAll(list, i)
Loop across all elements in list.
#define forAllReverse(list, i)
Reverse loop across all elements in list.
const fileName & rootPath() const
ios_base::fmtflags setf(const ios_base::fmtflags f)
Set flags of stream.
void size(const label)
Override size to be inconsistent with allocated storage.
virtual int precision() const =0
Get precision of output field.
static const cellModel * lookup(const word &)
Look up a model by name and return a pointer to the model or nullptr.
fluentFvMesh(const IOobject &io)
Construct from IOobject.
void writeFluentMesh() const
Write Fluent mesh.
const Time & time() const
Return the top-level database.
const labelUList & owner() const
Internal face owner.
const fvBoundaryMesh & boundary() const
Return reference to boundary mesh.
const labelUList & neighbour() const
Internal face neighbour.
virtual const faceList & faces() const
Return raw faces.
const polyBoundaryMesh & boundaryMesh() const
Return boundary mesh.
virtual const pointField & points() const
Return raw points.
const cellShapeList & cellShapes() const
Return cell shapes.
const cellList & cells() const
const fileName & caseName() const
#define WarningInFunction
Report a warning using Foam::Warning.
List< cellShape > cellShapeList
List of cellShapes and PtrList of List of cellShape.
List< label > labelList
A List of labels.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
bool mkDir(const fileName &, mode_t=0777)
Make a directory and return an error if it could not be created.
Ostream & endl(Ostream &os)
Add newline and flush stream.
IOstream & dec(IOstream &io)
IOstream & hex(IOstream &io)
vectorField pointField
pointField is a vectorField.
IOstream & scientific(IOstream &io)
UList< label > labelUList