157 #ifndef functionObjects_surfaceFieldValue_H
158 #define functionObjects_surfaceFieldValue_H
168 class sampledSurface;
171 namespace functionObjects
173 namespace fieldValues
180 class surfaceFieldValue
229 void setFaceZoneFaces();
232 void setPatchFaces();
235 void sampledSurfaceFaces(
const dictionary&);
238 void combineMeshGeometry
245 void combineSurfaceGeometry
252 scalar totalArea()
const;
324 template<
class Type,
class ResultType>
449 const word& fieldName,
456 template<
class Type,
class ResultType>
459 const word& fieldName,
484 virtual bool write();
Pre-declare SubField and related Field type.
Generic GeometricField class.
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
A list of keyword definitions, which are a keyword followed by any number of values (e....
A class for handling file names.
const word & name() const
Return the name of this functionObject.
const dictionary & dict() const
Return the reference to the construction dictionary.
surfaceFieldValue(const word &name, const Time &runTime, const dictionary &dict)
Construct from name, Time and dictionary.
TypeName("surfaceFieldValue")
Run-time type information.
const labelList & faceSign() const
Return the list of +1/-1 representing face flip map.
scalar scaleFactor_
Scale factor - optional.
label nFaces_
Global number of faces.
bool writeArea_
Optionally write the area of the surfaceFieldValue.
tmp< Field< Type > > getFieldValues(const word &fieldName) const
Return field values by looking up field name.
bool writeValues(const word &fieldName, const scalarField &signs, const scalarField &weights, const vectorField &Sf)
Templated helper function to output field values.
autoPtr< sampledSurface > surfacePtr_
Underlying sampledSurface.
virtual void topoChange(const polyTopoChangeMap &)
Update topology using the given map.
dictionary dict_
Input dictionary.
virtual void distribute(const polyDistributionMap &)
Redistribute or update using the given distribution map.
void initialise(const dictionary &dict)
Initialise, e.g. face addressing.
operationType operation_
Operation to apply to values.
static const NamedEnum< operationType, 14 > operationTypeNames_
Operation type names.
const selectionTypes & selectionType() const
Return the selection type.
bool processValuesTypeType(const Field< Type > &values, const scalarField &signs, const scalarField &weights, const vectorField &Sf, Type &result) const
Apply a Type -> Type operation to the values.
word selectionName_
Name of face selection (patch, faceZone, etc.)
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
selectionTypes selectionType_
Selection type.
virtual void writeFileHeader(const label i)
Output file header information.
fileName outputDir() const
Return the output directory.
wordList weightFieldNames_
Weight field names - optional.
virtual void movePoints(const polyMesh &)
Update for mesh point-motion.
bool validField(const word &fieldName) const
Return true if the field name is valid.
autoPtr< surfaceWriter > surfaceWriterPtr_
Surface writer.
static const NamedEnum< selectionTypes, 3 > selectionTypeNames
Selection type names.
bool processValues(const Field< Type > &values, const scalarField &signs, const scalarField &weights, const vectorField &Sf, ResultType &result) const
Apply the operation to the values, and return true if successful.
labelList faceId_
Local list of face IDs.
const labelList & faceId() const
Return the local list of face IDs.
const word & selectionName() const
Return the selection name.
labelList facePatchId_
Local list of patch ID per face.
tmp< Field< Type > > filterField(const SurfaceField< Type > &field) const
Filter a surface field according to faceIds.
virtual bool write()
Calculate and write.
scalar totalArea_
Total area of the surfaceFieldValue.
labelList faceSign_
List of +1/-1 representing face flip map.
virtual ~surfaceFieldValue()
Destructor.
const labelList & facePatch() const
Return the local list of patch ID per face.
virtual bool read(const dictionary &)
Read from dictionary.
selectionTypes
Selection type enumeration.
operationType
Operation type enumeration.
Registry of regIOobjects.
Class containing mesh-to-mesh mapping information after a mesh distribution where we send parts of me...
Class containing mesh-to-mesh mapping information.
Mesh consisting of general polyhedral cells.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
A class for managing temporary objects.
A class for handling words, derived from string.
List< word > wordList
A List of words.
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.
vectorField pointField
pointField is a vectorField.