Go to the documentation of this file.
37 namespace functionObjects
58 bool Foam::functionObjects::blendingFactor::calc()
60 bool processed =
false;
62 processed = processed || calcScheme<scalar>();
63 processed = processed || calcScheme<vector>();
99 zeroGradientFvPatchScalarField::typeName
112 phiName_ =
dict.getOrDefault<
word>(
"phi",
"phi");
115 dict.getCheckOrDefault
119 [&](
const scalar tol){
return (tol > 0) && (tol < 1); }
134 lookupObject<volScalarField>(resultName_);
137 label nCellsScheme1 = 0;
138 label nCellsScheme2 = 0;
139 label nCellsBlended = 0;
140 for (
const auto i : indicator)
146 else if (i > (1 - tolerance_))
156 reduce(nCellsScheme1, sumOp<label>());
157 reduce(nCellsScheme2, sumOp<label>());
158 reduce(nCellsBlended, sumOp<label>());
160 Log <<
" scheme 1 cells : " << nCellsScheme1 <<
nl
161 <<
" scheme 2 cells : " << nCellsScheme2 <<
nl
162 <<
" blended cells : " << nCellsBlended <<
nl
165 writeCurrentTime(file());
Defines the attributes of an object for which implicit objectRegistry management is supported,...
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
A class for handling words, derived from Foam::string.
virtual OFstream & file()
static constexpr const zero Zero
bool read(const char *buf, int32_t &val)
static word timeName(const scalar t, const int precision=precision_)
blendingFactor(const word &name, const Time &runTime, const dictionary &dict)
virtual bool read(const dictionary &dict)
Ostream & endl(Ostream &os)
bool store(word &fieldName, const tmp< ObjectType > &tfield, bool cacheable=false)
Abstract base-class for Time/database function objects.
virtual void writeHeader(Ostream &os, const string &str) const
virtual bool read(const dictionary &dict)
void reduce(const List< UPstream::commsStruct > &comms, T &Value, const BinaryOp &bop, const int tag, const label comm)
void setResultName(const word &typeName, const word &defaultArg)
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
OBJstream os(runTime.globalPath()/outputName)
Macros for easy insertion into run-time selection tables.
Generic dimensioned Type class.
virtual void writeFileHeader(Ostream &os) const
Computes the blending coefficient employed by blended divergence schemes, giving an indicator as to w...
virtual bool read(const dictionary &)
virtual void writeCommented(Ostream &os, const string &str) const
Intermediate class for handling field expression function objects (e.g. blendingFactor etc....
addToRunTimeSelectionTable(functionObject, ObukhovLength, dictionary)
static tmp< T > New(Args &&... args)
defineTypeNameAndDebug(ObukhovLength, 0)
word name(const expressions::valueTypeCode typeCode)
Base class for writing single files from the function objects.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Generic GeometricField class.
virtual void writeTabbed(Ostream &os, const string &str) const
const dimensionSet dimless