Chi-Tech
|
#include <TimeStepper.h>
Public Member Functions | |
double | TimeStepSize () const |
double | Time () const |
size_t | TimeStepIndex () const |
double | StartTime () const |
double | EndTime () const |
double | MaxTimeSteps () const |
bool | IsActive () const |
void | SetTimeStepSize (double dt) |
void | SetTime (double time) |
void | SetStartTime (double time) |
void | SetEndTime (double time) |
void | SetMaxTimeSteps (int n) |
void | SetMinimumTimeStepSize (double dt_min) |
virtual void | Advance () |
virtual bool | Adapt (TimeStepStatus time_step_status) |
std::string | StringTimeInfo (bool old_time=false) const |
Public Member Functions inherited from ChiObject | |
ChiObject () | |
ChiObject (const chi::InputParameters ¶ms) | |
void | SetStackID (size_t stack_id) |
size_t | StackID () const |
virtual void | PushOntoStack (std::shared_ptr< ChiObject > &new_object) |
virtual | ~ChiObject ()=default |
Protected Member Functions | |
TimeStepper (const chi::InputParameters ¶ms) | |
Static Protected Member Functions | |
static chi::InputParameters | GetInputParameters () |
Protected Attributes | |
double | dt_ |
double | time_ |
size_t | t_index_ |
double | start_time_ |
double | end_time_ |
int | max_time_steps_ |
double | dt_min_ |
const double | general_tolerance_ |
double | last_dt_ |
Additional Inherited Members | |
Static Public Member Functions inherited from ChiObject | |
static chi::InputParameters | GetInputParameters () |
Base class for all timestep controllers.
Definition at line 17 of file TimeStepper.h.
|
explicitprotected |
Definition at line 32 of file TimeStepper.cc.
|
inlinevirtual |
Adapts according to the timestep status. If it could provide a change it returns true, otherwise false.
Definition at line 67 of file TimeStepper.h.
|
virtual |
Advances the controller's state. The most basic action here is to advance time and the time index.
Advances the controller's state. The most basic action here is to advance time and the time index. If the solver is at or beyond its end time then it will return false. Otherwise it will advance and return true.
Definition at line 110 of file TimeStepper.cc.
double chi_physics::TimeStepper::EndTime | ( | ) | const |
Returns the current controller end_time.
Definition at line 61 of file TimeStepper.cc.
|
staticprotected |
Definition at line 8 of file TimeStepper.cc.
bool chi_physics::TimeStepper::IsActive | ( | ) | const |
If start_time <= time <= end_time, this will return true.
Definition at line 67 of file TimeStepper.cc.
double chi_physics::TimeStepper::MaxTimeSteps | ( | ) | const |
Returns the current controller max time steps.
Definition at line 64 of file TimeStepper.cc.
void chi_physics::TimeStepper::SetEndTime | ( | double | time | ) |
Manually set the end_time.
Definition at line 94 of file TimeStepper.cc.
void chi_physics::TimeStepper::SetMaxTimeSteps | ( | int | n | ) |
Manually set the maximum number of time steps. A negative number disables this check.
Definition at line 102 of file TimeStepper.cc.
void chi_physics::TimeStepper::SetMinimumTimeStepSize | ( | double | dt_min | ) |
Manually sets the minimum time step size.
Definition at line 105 of file TimeStepper.cc.
void chi_physics::TimeStepper::SetStartTime | ( | double | time | ) |
Manually set the start_time.
Definition at line 91 of file TimeStepper.cc.
void chi_physics::TimeStepper::SetTime | ( | double | time | ) |
Manually set the current time.
Definition at line 88 of file TimeStepper.cc.
void chi_physics::TimeStepper::SetTimeStepSize | ( | double | dt | ) |
Manually set the time step size.
Definition at line 80 of file TimeStepper.cc.
double chi_physics::TimeStepper::StartTime | ( | ) | const |
Returns the current controller start_time.
Definition at line 58 of file TimeStepper.cc.
std::string chi_physics::TimeStepper::StringTimeInfo | ( | bool | old_time = false | ) | const |
Builds a formatted string of the time information.
Definition at line 122 of file TimeStepper.cc.
double chi_physics::TimeStepper::Time | ( | ) | const |
Returns the current controller time.
Definition at line 52 of file TimeStepper.cc.
size_t chi_physics::TimeStepper::TimeStepIndex | ( | ) | const |
Returns the current time index.
Definition at line 55 of file TimeStepper.cc.
double chi_physics::TimeStepper::TimeStepSize | ( | ) | const |
Overridable method to get the timestep size.
Definition at line 49 of file TimeStepper.cc.
|
protected |
Definition at line 76 of file TimeStepper.h.
|
protected |
Definition at line 83 of file TimeStepper.h.
|
protected |
Definition at line 81 of file TimeStepper.h.
|
protected |
Definition at line 85 of file TimeStepper.h.
|
protected |
Last dt before finishing.
Definition at line 87 of file TimeStepper.h.
|
protected |
Definition at line 82 of file TimeStepper.h.
|
protected |
Definition at line 80 of file TimeStepper.h.
|
protected |
Definition at line 78 of file TimeStepper.h.
|
protected |
Definition at line 77 of file TimeStepper.h.