48template<
class GeometricField>
99 gf_.timeIndex() = gf_.time().timeIndex();
123template<
class GeometricField>
135 void operator=(
const subCycle<GeometricField>&) =
delete;
Generic GeometricField class.
static tmp< GeometricField< Type, PatchField, GeoMesh > > New(const word &name, IOobjectOption::registerOption regOpt, const Mesh &mesh, const dimensionSet &dims, const word &patchFieldType=PatchField< Type >::calculatedType())
Return tmp field (NO_READ, NO_WRITE) from name, mesh, dimensions and patch type. [Takes current timeN...
label timeIndex() const noexcept
The time index of the field.
const GeometricField< Type, PatchField, GeoMesh > & oldTime() const
Return old time field.
const Time & time() const noexcept
Return Time associated with the objectRegistry.
label timeIndex() const noexcept
Return the current time index.
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
void updateTimeIndex()
Correct the time index of the field to correspond to.
~subCycleField()
Destructor.
subCycleField(GeometricField &gf)
Construct field and number of sub-cycles.
A class for managing sub-cycling times.
subCycleTime(Time &runTime, const label nCycle)
Construct referencing the original time and number of sub-cycles.
void endSubCycle()
End the sub-cycling and reset the time-state.
Perform a subCycleTime on a field.
subCycle(GeometricField &gf, const label nCycles)
Construct field and number of sub-cycles.
A class for managing temporary objects.
bool valid() const noexcept
Identical to good(), or bool operator.
Info<< "Creating field kinetic energy K\n"<< endl;volScalarField K("K", 0.5 *magSqr(U));if(U.nOldTimes()){ volVectorField *Uold=&U.oldTime();volScalarField *Kold=&K.oldTime(); *Kold==0.5 *magSqr(*Uold);while(Uold->nOldTimes()) { Uold=&Uold-> oldTime()