39namespace functionObjects
50Foam::functionObjects::CourantNo::byRho
52 const tmp<volScalarField::Internal>& Co
64bool Foam::functionObjects::CourantNo::calc()
66 if (foundObject<surfaceScalarField>(fieldName_))
69 lookupObject<surfaceScalarField>(fieldName_);
71 tmp<volScalarField::Internal> Coi
75 (0.5*mesh_.time().deltaT())
81 if (foundObject<volScalarField>(resultName_,
false))
84 lookupObjectRef<volScalarField>(resultName_);
87 Co.correctBoundaryConditions();
96 mesh_.time().timeName(),
103 zeroGradientFvPatchScalarField::typeName
105 tCo.ref().ref() = Coi();
106 tCo.ref().correctBoundaryConditions();
107 mesh_.objectRegistry::store(tCo.ptr());
140 rhoName_ =
dict.getOrDefault<
word>(
"rho",
"rho");
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
virtual bool read()
Re-read model coefficients if they have changed.
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
static autoPtr< Time > New()
Construct (dummy) Time - no functionObjects or libraries.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Abstract base-class for Time/database function objects.
Computes the Courant number field for time-variant simulations.
virtual bool read(const dictionary &)
Read the CourantNo data.
Intermediate class for handling field expression function objects (e.g. blendingFactor etc....
void setResultName(const word &typeName, const word &defaultArg)
Set the name of result field.
const objectRegistry & obr_
Reference to the region objectRegistry.
const Type & lookupObject(const word &name, const bool recursive=false) const
A class for managing temporary objects.
A class for handling words, derived from Foam::string.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
Surface integrate surfaceField creating a volField. Surface sum a surfaceField creating a volField.
tmp< GeometricField< Type, fvPatchField, volMesh > > surfaceSum(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
const dimensionSet dimless
Dimensionless.
GeometricField< scalar, fvPatchField, volMesh > volScalarField
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
static constexpr const zero Zero
Global zero (0)
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
const dimensionSet dimDensity