63 #include "setDeltaT.H"
69 int main(
int argc,
char *argv[])
84 runTime.controlDict().lookupOrDefault(
"solver",
word::null)
96 <<
"solver not specified in the controlDict or on the command-line"
131 Info<<
"Time = " << runTime.userTimeName() <<
nl <<
endl;
195 Info<<
"ExecutionTime = " << runTime.elapsedCpuTime() <<
" s"
196 <<
" ClockTime = " << runTime.elapsedClockTime() <<
" s"
static void addOption(const word &opt, const string ¶m="", const string &usage="")
Add to an option to validOptions with usage information.
const word & executable() const
Name of executable without the path.
bool optionReadIfPresent(const word &opt, T &) const
Read a value from the named option if present.
void printUsage() const
Print usage.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
bool thermophysics() const
Flag to indicate to solve for the thermophysics.
bool models() const
Flag to indicate to solve for the options models.
bool flow() const
Flag to indicate to solve for the flow.
virtual void correct()
Correct the fvModels.
bool run(Time &time)
Time run loop.
bool correctTransport() const
Flag to indicate whether to correct the transport models.
bool predictTransport() const
Flag to indicate whether to predict the transport models.
Pimple single region control class. Provides time-loop control methods which exit the simulation once...
Abstract base class for run-time selectable region solvers.
virtual void momentumTransportCorrector()=0
Correct the momentum transport.
virtual void motionCorrector()=0
Corrections that follow mesh motion.
virtual void preSolve()=0
Called at the start of the time-step, before the PIMPLE loop.
virtual void thermophysicalPredictor()=0
Construct and solve the thermophysical property equations,.
Foam::fvModels & fvModels() const
Return the fvModels that are created on demand.
pimpleNoLoopControl pimple
PIMPLE inner-loop controls.
static autoPtr< solver > New(const word &solverName, fvMesh &mesh)
Select, construct and return the solver.
virtual void thermophysicalTransportCorrector()=0
Correct the thermophysical transport.
virtual void pressureCorrector()=0
Construct and solve the pressure equation in the PISO loop.
virtual void moveMesh()=0
Called at the start of the PIMPLE loop to move the mesh.
virtual void momentumPredictor()=0
Construct and optionally solve the momentum equation.
virtual void prePredictor()=0
Called at the start of the PIMPLE loop.
static void load(const word &solverName)
Load the specified solver library.
virtual void postSolve()=0
Called after the PIMPLE loop at the end of the time-step.
virtual void thermophysicalTransportPredictor()=0
Predict thermophysical transport.
virtual void momentumTransportPredictor()=0
Predict the momentum transport.
A class for handling words, derived from string.
static const word null
An empty word.
pimpleControl pimple(mesh)
Foam::fvMesh mesh(Foam::IOobject(regionName, runTime.name(), runTime, Foam::IOobject::MUST_READ), false)
#define FatalErrorIn(functionName)
Report an error message using Foam::FatalError.
int main(int argc, char *argv[])
errorManipArg< error, int > exit(error &err, const int errNo=1)
void adjustDeltaT(Time &runTime, const PtrList< solver > &solvers)
Adjust the time-step according to the solver maxDeltaT.
void setDeltaT(Time &runTime, const PtrList< solver > &solvers)
Set the initial time-step according to the solver maxDeltaT.
Ostream & endl(Ostream &os)
Add newline and flush stream.
Foam::argList args(argc, argv)