A sampledSurface that calculates the PLIC interface in VoF simulations Only works in combination with isoAdvector and a reconstruction scheme. More...
Public Member Functions | |
TypeName ("sampledInterface") | |
Runtime type information. More... | |
sampledInterface (const word &name, const polyMesh &mesh, const dictionary &dict) | |
Construct from dictionary. More... | |
virtual | ~sampledInterface ()=default |
Destructor. More... | |
const reconstructionSchemes::interface & | surface () const |
virtual bool | needsUpdate () const |
Does the surface need an update? More... | |
virtual bool | expire () |
Mark the surface as needing an update. More... | |
virtual bool | update () |
Update the surface as required. More... | |
virtual const pointField & | points () const |
Points of surface. More... | |
virtual const faceList & | faces () const |
Faces of surface. More... | |
virtual const labelList & | zoneIds () const |
Const access to per-face zone/region information. More... | |
virtual const vectorField & | Sf () const |
Face area magnitudes. More... | |
virtual const scalarField & | magSf () const |
Face area magnitudes. More... | |
virtual const vectorField & | Cf () const |
Face centres. More... | |
virtual tmp< scalarField > | sample (const interpolation< scalar > &sampler) const |
Sample volume field onto surface faces. More... | |
virtual tmp< vectorField > | sample (const interpolation< vector > &sampler) const |
Sample volume field onto surface faces. More... | |
virtual tmp< sphericalTensorField > | sample (const interpolation< sphericalTensor > &sampler) const |
Sample volume field onto surface faces. More... | |
virtual tmp< symmTensorField > | sample (const interpolation< symmTensor > &sampler) const |
Sample volume field onto surface faces. More... | |
virtual tmp< tensorField > | sample (const interpolation< tensor > &sampler) const |
Sample volume field onto surface faces. More... | |
virtual tmp< scalarField > | interpolate (const interpolation< scalar > &interpolator) const |
Interpolate volume field onto surface points. More... | |
virtual tmp< vectorField > | interpolate (const interpolation< vector > &interpolator) const |
Interpolate volume field onto surface points. More... | |
virtual tmp< sphericalTensorField > | interpolate (const interpolation< sphericalTensor > &interpolator) const |
Interpolate volume field onto surface points. More... | |
virtual tmp< symmTensorField > | interpolate (const interpolation< symmTensor > &interpolator) const |
Interpolate volume field onto surface points. More... | |
virtual tmp< tensorField > | interpolate (const interpolation< tensor > &interpolator) const |
Interpolate volume field onto surface points. More... | |
virtual void | print (Ostream &) const |
Write. More... | |
template<class Type > | |
Foam::tmp< Foam::Field< Type > > | sampleOnFaces (const interpolation< Type > &sampler) const |
template<class Type > | |
Foam::tmp< Foam::Field< Type > > | sampleOnPoints (const interpolation< Type > &interpolator) const |
Public Member Functions inherited from sampledSurface | |
TypeName ("sampledSurface") | |
Runtime type information. More... | |
declareRunTimeSelectionTable (autoPtr, sampledSurface, word,(const word &name, const polyMesh &mesh, const dictionary &dict),(name, mesh, dict)) | |
Declare run-time constructor selection table. More... | |
sampledSurface (const word &name, const polyMesh &mesh, const bool interpolate=false) | |
Construct from name, mesh. More... | |
sampledSurface (const word &name, const polyMesh &mesh, const dictionary &dict) | |
Construct from dictionary. More... | |
autoPtr< sampledSurface > | clone () const |
Clone. More... | |
virtual | ~sampledSurface () |
Destructor - calls clearGeom() More... | |
const polyMesh & | mesh () const |
Access to the underlying mesh. More... | |
const word & | name () const |
Name of surface. More... | |
bool | enabled () const |
Surface is enabled. More... | |
bool | invariant () const |
Surface is invariant with geometry change (caution) More... | |
bool | interpolate () const |
Interpolation to nodes requested for surface. More... | |
scalar | area () const |
The total surface area. More... | |
virtual bool | hasFaceIds () const |
If element ids/order of the original surface are available. More... | |
polySurface * | getRegistrySurface (const objectRegistry &obr, word lookupName="") const |
Get surface from registry if available. More... | |
polySurface * | storeRegistrySurface (objectRegistry &obr, word lookupName="") const |
Copy surface into registry. More... | |
bool | removeRegistrySurface (objectRegistry &obr, word lookupName="") const |
Remove surface from registry. More... | |
template<class Type , class GeoMeshType > | |
bool | storeRegistryField (const objectRegistry &obr, const word &fieldName, const dimensionSet &dims, const Field< Type > &values, word lookupName="") const |
Copy/store sampled field onto registered surface (if it exists) More... | |
template<class Type , class GeoMeshType > | |
bool | storeRegistryField (const objectRegistry &obr, const word &fieldName, const dimensionSet &dims, Field< Type > &&values, word lookupName="") const |
Move/store sampled field onto registered surface (if it exists) More... | |
surfMesh * | getSurfMesh (word lookupName="") const |
Get surface from registry if available. More... | |
surfMesh * | storeSurfMesh (word lookupName="") const |
Copy surface into registry. More... | |
bool | removeSurfMesh (word lookupName="") const |
Remove surface from registry. More... | |
template<class Type , class GeoMeshType > | |
bool | storeSurfMeshField (const word &fieldName, const dimensionSet &dims, const Field< Type > &values, word lookupName="") const |
Copy/store sampled Face field onto surfMesh (if it exists) More... | |
template<class Type , class GeoMeshType > | |
bool | storeSurfMeshField (const word &fieldName, const dimensionSet &dims, Field< Type > &&values, word lookupName="") const |
Move/store sampled Face field onto surfMesh (if it exists) More... | |
virtual bool | withSurfaceFields () const |
Can it sample surface-fields? More... | |
virtual tmp< scalarField > | sample (const surfaceScalarField &sField) const |
Sample surface field onto surface. More... | |
virtual tmp< vectorField > | sample (const surfaceVectorField &sField) const |
Sample surface field onto surface. More... | |
virtual tmp< sphericalTensorField > | sample (const surfaceSphericalTensorField &sField) const |
Sample surface field onto surface. More... | |
virtual tmp< symmTensorField > | sample (const surfaceSymmTensorField &sField) const |
Sample surface field onto surface. More... | |
virtual tmp< tensorField > | sample (const surfaceTensorField &sField) const |
Sample surface field onto surface. More... | |
virtual void | rename (const word &newName) |
Rename. More... | |
template<class Type > | |
Foam::tmp< Foam::Field< Type > > | sampleOnFaces (const interpolation< Type > &sampler, const labelUList &elements, const faceList &fcs, const pointField &pts) |
template<class Type > | |
Foam::tmp< Foam::GeometricField< Type, Foam::fvPatchField, Foam::volMesh > > | pointAverage (const GeometricField< Type, pointPatchField, pointMesh > &pfld) |
Public Member Functions inherited from meshedSurf | |
constexpr | meshedSurf () noexcept=default |
Default construct. More... | |
virtual | ~meshedSurf ()=default |
Destructor. More... | |
virtual const labelList & | faceIds () const |
Per-face identifier (eg, element Id) More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from sampledSurface | |
static autoPtr< sampledSurface > | New (const word &name, const polyMesh &mesh, const dictionary &dict) |
Return a reference to the selected surface. More... | |
Static Public Attributes inherited from sampledSurface | |
static const wordList | surfaceFieldTypes |
Class names for surface field types. More... | |
Protected Member Functions inherited from sampledSurface | |
virtual void | clearGeom () const |
Additional cleanup when clearing the geometry. More... | |
sampledSurface (const word &name, std::nullptr_t) | |
Construct null. More... | |
Static Protected Member Functions inherited from sampledSurface | |
template<class Type > | |
static tmp< Field< Type > > | sampleOnFaces (const interpolation< Type > &sampler, const labelUList &elements, const faceList &fcs, const pointField &pts) |
General loop for sampling elements to faces. More... | |
template<class Type > | |
static tmp< GeometricField< Type, fvPatchField, volMesh > > | pointAverage (const GeometricField< Type, pointPatchField, pointMesh > &pfld) |
Create cell values by averaging the point values. More... | |
A sampledSurface that calculates the PLIC interface in VoF simulations Only works in combination with isoAdvector and a reconstruction scheme.
This is often embedded as part of a sampled surfaces function object.
surfaces { freeSurf { type interface; interpolate false; } }
Where the sub-entries comprise:
Property | Description | Required | Default |
---|---|---|---|
type | interface | yes |
Original code supplied by Henning Scheufler, DLR (2019)
Definition at line 87 of file sampledInterface.H.
sampledInterface | ( | const word & | name, |
const polyMesh & | mesh, | ||
const dictionary & | dict | ||
) |
Construct from dictionary.
Definition at line 106 of file sampledInterface.C.
References polyMesh::boundaryMesh(), DebugInfo, dict, Foam::endl(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, polyBoundaryMesh::findPatchID(), mesh, polyBoundaryMesh::names(), and dictionary::readEntry().
|
virtualdefault |
Destructor.
TypeName | ( | "sampledInterface" | ) |
Runtime type information.
|
inline |
Definition at line 154 of file sampledInterface.H.
Referenced by sampledInterface::Cf(), sampledInterface::faces(), sampledInterface::magSf(), sampledInterface::points(), and sampledInterface::Sf().
|
virtual |
Does the surface need an update?
Implements sampledSurface.
Definition at line 142 of file sampledInterface.C.
References mesh, fvMesh::time(), and TimeState::timeIndex().
|
virtual |
Mark the surface as needing an update.
May also free up unneeded data. Return false if surface was already marked as expired.
Implements sampledSurface.
Definition at line 150 of file sampledInterface.C.
|
virtual |
Update the surface as required.
Do nothing (and return false) if no update was needed
Implements sampledSurface.
Definition at line 170 of file sampledInterface.C.
|
inlinevirtual |
Points of surface.
Implements sampledSurface.
Definition at line 173 of file sampledInterface.H.
References sampledInterface::surface().
|
inlinevirtual |
Faces of surface.
Implements sampledSurface.
Definition at line 179 of file sampledInterface.H.
References sampledInterface::surface(), and MeshedSurface< Face >::surfFaces().
|
inlinevirtual |
Const access to per-face zone/region information.
Reimplemented from meshedSurf.
Definition at line 185 of file sampledInterface.H.
References List< label >::null().
|
inlinevirtual |
Face area magnitudes.
Implements sampledSurface.
Definition at line 191 of file sampledInterface.H.
References MeshedSurface< Face >::Sf(), and sampledInterface::surface().
|
inlinevirtual |
Face area magnitudes.
Implements sampledSurface.
Definition at line 197 of file sampledInterface.H.
References MeshedSurface< Face >::magSf(), and sampledInterface::surface().
|
inlinevirtual |
Face centres.
Implements sampledSurface.
Definition at line 203 of file sampledInterface.H.
References MeshedSurface< Face >::Cf(), and sampledInterface::surface().
|
virtual |
Sample volume field onto surface faces.
Implements sampledSurface.
Definition at line 177 of file sampledInterface.C.
|
virtual |
Sample volume field onto surface faces.
Implements sampledSurface.
Definition at line 186 of file sampledInterface.C.
|
virtual |
Sample volume field onto surface faces.
Implements sampledSurface.
Definition at line 195 of file sampledInterface.C.
|
virtual |
Sample volume field onto surface faces.
Implements sampledSurface.
Definition at line 204 of file sampledInterface.C.
|
virtual |
Sample volume field onto surface faces.
Implements sampledSurface.
Definition at line 213 of file sampledInterface.C.
|
virtual |
Interpolate volume field onto surface points.
Implements sampledSurface.
Definition at line 222 of file sampledInterface.C.
|
virtual |
Interpolate volume field onto surface points.
Implements sampledSurface.
Definition at line 231 of file sampledInterface.C.
|
virtual |
Interpolate volume field onto surface points.
Implements sampledSurface.
Definition at line 239 of file sampledInterface.C.
|
virtual |
Interpolate volume field onto surface points.
Implements sampledSurface.
Definition at line 248 of file sampledInterface.C.
|
virtual |
Interpolate volume field onto surface points.
Implements sampledSurface.
Definition at line 257 of file sampledInterface.C.
|
virtual |
Write.
Reimplemented from sampledSurface.
Definition at line 265 of file sampledInterface.C.
References Foam::name().
Foam::tmp<Foam::Field<Type> > sampleOnFaces | ( | const interpolation< Type > & | sampler | ) | const |
Definition at line 39 of file sampledInterfaceTemplates.C.
References points.
Foam::tmp<Foam::Field<Type> > sampleOnPoints | ( | const interpolation< Type > & | interpolator | ) | const |
Definition at line 58 of file sampledInterfaceTemplates.C.
References notImplemented.