52 stateFunctionObject& state
55 runTimeCondition(
name, obr,
dict, state),
56 valueAverageBase(
name, obr_,
dict, state, false),
57 nIterStartUp_(
dict.getOrDefault<label>(
"nIterStartUp", 10)),
77 bool running = iter_ > nIterStartUp_;
81 dictionary& conditionDict = this->conditionDict();
94 dictionary& conditionDict = this->conditionDict();
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Average run time condition - satisfied when average does not change by more than a given value.
virtual bool apply()
Apply the condition.
averageCondition(const word &name, const objectRegistry &obr, const dictionary &dict, stateFunctionObject &state)
Constructor.
label nIterStartUp_
Number of start-up iterations before allowing satisfied checks.
virtual void write()
Write.
label iter_
Current iteration count.
virtual void reset()
Reset.
Base class for run time conditions.
bool active_
On/off switch.
const objectRegistry & obr_
Reference to the object registry.
const dictionary & conditionDict() const
Return const access to the conditions dictionary.
runTimeCondition(const word &name, const objectRegistry &obr, const dictionary &dict, stateFunctionObject &state)
Constructor.
virtual const word & name() const
Return the condition name.
Base class for function objects, adding functionality to read/write state information (data required ...
virtual void readState(dictionary &dict)
Read state from dictionary.
virtual void writeState(dictionary &dict)
Write state to dictionary for restarts.
virtual bool calculate(dictionary &dict)
Calculate the averages.
valueAverageBase(const word &name, const objectRegistry &obr, const dictionary &dict, stateFunctionObject &state, const bool writeToFile=true)
Construct from Time and dictionary.
virtual void resetState(dictionary &dict)
Reset state.
Registry of regIOobjects.
A class for handling words, derived from Foam::string.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
Function objects are OpenFOAM utilities to ease workflow configurations and enhance workflows.
messageStream Info
Information stream (stdout output on master, null elsewhere).
Ostream & incrIndent(Ostream &os)
Increment the indent level.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for expressions::valueTypeCode::INVALID.
Ostream & decrIndent(Ostream &os)
Decrement the indent level.