Go to the documentation of this file.
59 Info<<
"sampledIsoSurface::getIsoFields() : lookup volField "
71 Info<<
"sampledIsoSurface::getIsoFields() : checking "
84 Info<<
"sampledIsoSurface::getIsoFields() : reading volField "
114 <<
"Cannot find isosurface field " <<
isoField_
115 <<
" in database or directory " << vfHeader.
path()
136 const word pointFldName =
137 "volPointInterpolate_"
147 Info<<
"sampledIsoSurface::getIsoFields() :"
148 <<
" lookup pointField " << pointFldName <<
endl;
159 Info<<
"sampledIsoSurface::getIsoFields() :"
160 <<
" updating pointField " << pointFldName <<
endl;
178 Info<<
"sampledIsoSurface::getIsoFields() :"
179 <<
" creating and storing pointField "
180 << pointFldName <<
" for time "
212 Info<<
"sampledIsoSurface::getIsoFields() : volField "
215 Info<<
"sampledIsoSurface::getIsoFields() : pointField "
232 Info<<
"sampledIsoSurface::getIsoFields() :"
233 <<
" submesh lookup volField "
243 Info<<
"sampledIsoSurface::getIsoFields() : "
260 const word pointFldName =
261 "volPointInterpolate_"
271 Info<<
"sampledIsoSurface::getIsoFields() :"
272 <<
" submesh lookup pointField " << pointFldName <<
endl;
283 Info<<
"sampledIsoSurface::getIsoFields() :"
284 <<
" updating submesh pointField "
285 << pointFldName <<
endl;
301 Info<<
"sampledIsoSurface::getIsoFields() :"
302 <<
" interpolating submesh volField "
304 <<
" to get submesh pointField " << pointFldName <<
endl;
332 Info<<
"sampledIsoSurface::getIsoFields() : volSubField "
334 <<
" min:" <<
min(*volSubFieldPtr_).
value()
336 Info<<
"sampledIsoSurface::getIsoFields() : pointSubField "
356 if (zoneID_.index() != -1 && !subMeshPtr_.valid())
361 const label exposedPatchI =
patches.findPatchID(exposedPatchName_);
365 Info<<
"Allocating subset of size "
367 <<
" with exposed faces into patch "
375 subMeshPtr_().setLargeCellSubset
393 if (subMeshPtr_.valid())
431 Pout<<
"sampledIsoSurface::updateGeometry() : constructed iso:"
433 <<
" regularise : " << regularise_ <<
nl
434 <<
" average : " << average_ <<
nl
435 <<
" isoField : " << isoField_ <<
nl
436 <<
" isoValue : " << isoVal_ <<
nl;
437 if (subMeshPtr_.valid())
439 Pout<<
" zone size : " << subMeshPtr_().subMesh().nCells()
444 <<
" cut cells : " <<
surface().meshCells().size()
473 storedVolFieldPtr_(NULL),
482 ) <<
"Non-interpolated iso surface not supported since triangles"
486 if (zoneID_.index() != -1)
488 dict.
lookup(
"exposedPatchName") >> exposedPatchName_;
495 ) <<
"Cannot find patch " << exposedPatchName_
496 <<
" in which to put exposed faces." <<
endl
501 if (debug && zoneID_.index() != -1)
503 Info<<
"Restricting to cellZone " << zoneID_.name()
504 <<
" with exposed internal faces into patch "
505 << exposedPatchName_ <<
endl;
537 if (prevTimeIndex_ == -1)
550 return updateGeometry();
559 return sampleField(vField);
568 return sampleField(vField);
577 return sampleField(vField);
586 return sampleField(vField);
595 return sampleField(vField);
604 return interpolateField(interpolator);
613 return interpolateField(interpolator);
621 return interpolateField(interpolator);
630 return interpolateField(interpolator);
639 return interpolateField(interpolator);
645 os <<
"sampledIsoSurface: " <<
name() <<
" :"
646 <<
" field :" << isoField_
647 <<
" value :" << isoVal_;
GeometricField< tensor, fvPatchField, volMesh > volTensorField
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
bool updateGeometry() const
Create iso surface (if time has changed)
addNamedToRunTimeSelectionTable(fvPatch, cyclicAMIFvPatch, polyPatch, cyclicPeriodicAMI)
label findPatchID(const word &patchName) const
Find patch index given a name.
A class for handling words, derived from string.
virtual tmp< scalarField > sample(const volScalarField &) const
Sample field on surface.
virtual bool needsUpdate() const
Does the surface need an update?
tmp< GeometricField< Type, fvPatchField, volMesh > > pointAverage(const GeometricField< Type, pointPatchField, pointMesh > &pfld) const
Interpolate from points to cell centre.
A class for managing temporary objects.
Post-processing mesh subset tool. Given the original mesh and the list of selected cells,...
const pointScalarField * pointSubFieldPtr_
Cached pointfield.
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
T lookupOrDefault(const word &, const T &, bool recursive=false, bool patternMatch=true) const
Find and return a T,.
const cellZoneMesh & cellZones() const
Return cell zone mesh.
autoPtr< volScalarField > storedVolFieldPtr_
Cached volfield.
const polyBoundaryMesh & boundaryMesh() const
Return boundary mesh.
Ostream & endl(Ostream &os)
Add newline and flush stream.
const Type & value() const
Return const reference to value.
virtual bool update()
Update the surface as required.
virtual void print(Ostream &) const
Write.
Mesh consisting of general polyhedral cells.
static const volPointInterpolation & New(const fvMesh &mesh)
wordList names() const
Return a list of patch names.
bool headerOk()
Read and check header info.
A surface formed by the iso value. After "Regularised Marching Tetrahedra: improved iso-surface extra...
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
GeometricField< symmTensor, fvPatchField, volMesh > volSymmTensorField
const volScalarField * volSubFieldPtr_
InternalField & internalField()
Return internal field.
An abstract class for surfaces with sampling.
virtual bool expire()
Mark the surface as needing an update.
A list of keyword definitions, which are a keyword followed by any number of values (e....
const word isoField_
Field to get isoSurface of.
Macros for easy insertion into run-time selection tables.
Mesh data needed to do the Finite Volume discretisation.
T * ptr() const
Return tmp pointer for reuse.
const double e
Elementary charge.
tmp< GeometricField< Type, pointPatchField, pointMesh > > interpolate(const GeometricField< Type, fvPatchField, volMesh > &) const
Interpolate volField using inverse distance weighting.
errorManipArg< error, int > exit(error &err, const int errNo=1)
void getIsoFields() const
Get fields needed to recreate iso surface.
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
bool foundObject(const word &name) const
Is the named Type found?
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const Switch average_
Whether to recalculate cell values as average of point values.
bool readScalar(const char *buf, doubleScalar &s)
Read whole of buf as a scalar. Return true if succesful.
prefixOSstream Pout(cout, "Pout")
static const boundBox greatBox
A very large boundBox: min/max == -/+ VGREAT.
const pointScalarField * pointFieldPtr_
Cached pointfield.
static word timeName(const scalar, const int precision=precision_)
Return time name of given scalar time.
static const word null
An empty word.
autoPtr< volScalarField > storedVolSubFieldPtr_
Cached volfield.
const Time & time() const
Return the top-level database.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
autoPtr< fvMeshSubset > subMeshPtr_
Cached submesh.
const polyMesh & mesh() const
Access to the underlying mesh.
const Type & lookupObject(const word &name) const
Lookup and return the object of the given Type.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Type gMin(const FieldField< Field, Type > &f)
label timeIndex() const
Return current time index.
fileName::Type type(const fileName &)
Return the file type: DIRECTORY or FILE.
HashSet< label, Hash< label > > labelHashSet
A HashSet with label keys.
Generic GeometricField class.
fileName path() const
Return complete path.
bool interpolate() const
Interpolation requested for surface.
virtual ~sampledIsoSurface()
Destructor.
defineTypeNameAndDebug(combustionModel, 0)
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
Type gMax(const FieldField< Field, Type > &f)
word name(const complex &)
Return a string representation of a complex.
sampledIsoSurface(const word &name, const polyMesh &mesh, const dictionary &dict)
Construct from dictionary.
const volScalarField * volFieldPtr_