112#ifndef Foam_functionObjects_fieldStatistics_H
113#define Foam_functionObjects_fieldStatistics_H
140 enum class modeType :
char
147 static const Enum<modeType> modeTypeNames_;
150 enum class meanType :
char
157 static const Enum<meanType> meanTypeNames_;
160 enum class calcType :
char
170 static const Enum<calcType> calcTypeNames_;
176 using variantInput = std::variant
186 using variantOutput = std::variant
202 std::function<variantOutput(variantInput)> calc;
209 variantOutput value_;
237 volFieldSelection fieldSet_;
258 statistic createStatistic(
const word& statName,
const modeType
mode);
262 bool calcStat(
const word& fieldName);
289 template<
class GeoField>
291 flatten(
const GeoField&
field)
const;
294 template<
class GeoField>
301 void writeStatData();
307 void writeExtremaFileHeader(
Ostream&
os,
const word& fieldName);
310 void writeExtremaData();
313 void logExtremaData();
355 virtual bool write();
Enum is a wrapper around a list of names/values that represent particular enumeration (or int) values...
Generic templated field type that is much like a Foam::List except that it is expected to hold numeri...
A HashTable of pointers to objects of type <T>, with deallocation management of the pointers.
A HashTable similar to std::unordered_map.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
An ordered pair of two objects of type <T> with first() and second() elements.
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 a number of values (eg,...
Calculates various statistics of the specified fields.
virtual bool read(const dictionary &dict)
Read the function-object dictionary.
fieldStatistics(const word &name, const Time &runTime, const dictionary &dict)
Construct from name, Time and dictionary.
virtual bool execute()
Execute the function-object operations.
virtual bool write()
Write the function-object results.
virtual ~fieldStatistics()=default
Destructor.
void operator=(const fieldStatistics &)=delete
No copy assignment.
TypeName("fieldStatistics")
Runtime type information.
fieldStatistics(const fieldStatistics &)=delete
No copy construct.
Specialization of Foam::functionObject for an Foam::fvMesh, providing a reference to the Foam::fvMesh...
fvMeshFunctionObject(const fvMeshFunctionObject &)=delete
No copy construct.
Helper class to manage solver field selections.
Base class for writing single files from the function objects.
writeFile(const objectRegistry &obr, const fileName &prefix, const word &name="undefined", const bool writeToFile=true, const string &ext=".dat")
Construct from objectRegistry, prefix, fileName.
A class for managing temporary objects.
A class for handling words, derived from Foam::string.
OBJstream os(runTime.globalPath()/outputName)
Function objects are OpenFOAM utilities to ease workflow configurations and enhance workflows.
mode_t mode(const fileName &name, const bool followLink=true)
Return the file mode, normally following symbolic links.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
Field< sphericalTensor > sphericalTensorField
Specialisation of Field<T> for sphericalTensor.
Field< vector > vectorField
Specialisation of Field<T> for vector.
vector point
Point is a vector.
Field< symmTensor > symmTensorField
Specialisation of Field<T> for symmTensor.
Field< tensor > tensorField
Specialisation of Field<T> for tensor.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for expressions::valueTypeCode::INVALID.
SphericalTensor< scalar > sphericalTensor
SphericalTensor of scalars, i.e. SphericalTensor<scalar>.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
SymmTensor< scalar > symmTensor
SymmTensor of scalars, i.e. SymmTensor<scalar>.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.