124 #ifndef functionObjects_momentum_H 125 #define functionObjects_momentum_H 141 namespace functionObjects
150 public fvMeshFunctionObject,
163 template<
class GeoField>
164 autoPtr<GeoField> newField
166 const word& baseName,
167 const dimensionSet& dims,
168 bool registerObject=
true 199 coordSystem::cylindrical
csys_;
242 const dictionary&
dict,
275 virtual bool write();
Computes linear/angular momentum, reporting integral values and optionally writing the fields...
bool writeMomentum_
Write fields flag.
void operator=(const momentum &)=delete
No copy assignment.
momentum(const word &name, const Time &runTime, const dictionary &dict, const bool readFields=true)
Construct from Time and dictionary.
Forwards and collection of common volume field types.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
vector sumMomentum_
Integral (linear) momentum.
bool hasCsys_
Are we using the cylindrical coordinate system?
bool writePosition_
Write fields flag.
virtual bool execute()
Calculate and report the integral momentum.
scalar rhoRef_
Reference density (for incompressible)
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
const word & name() const noexcept
Return the name of this functionObject.
bool initialised_
Initialised flag.
word UName_
The velocity field name (optional)
coordSystem::cylindrical csys_
Coordinate system for evaluating angular momentum.
A class for handling words, derived from Foam::string.
vector sumAngularMom_
Integral angular momentum.
void writeValues(Ostream &os)
Write momentum data.
void initialise()
Initialise the fields.
Reads fields from the time directories and adds them to the mesh database for further post-processing...
OBJstream os(runTime.globalPath()/outputName)
virtual ~momentum()=default
Destructor.
TypeName("momentum")
Runtime type information.
word pName_
The pressure field name (optional)
word rhoName_
The density field name (optional)
virtual bool write()
Write the momentum, possibly angular momentum and velocity.
virtual void updateMesh(const mapPolyMesh &)
Update for changes of mesh.
Mesh consisting of general polyhedral cells.
virtual bool read(const dictionary &)
Read the momentum data.
virtual void writeFileHeader(Ostream &os)
Output file header information.
bool writeVelocity_
Write fields flag.
Registry of regIOobjects.
virtual void movePoints(const polyMesh &)
Update for mesh point-motion.
virtual const objectRegistry & obr() const
The region or sub-region registry being used.