Class for objects than can be advanced in time by an Explicit Timestepper. WARNING: For explicit time stepping to work the object's residual function (as used by get_inverse_mass_matrix_times_residuals(..)) MUST be in the form r = f(t, u) - [timestepper approximation to dudt]! Standard implicit time stepping will work with plenty of residuals that don't fit into this form. Some examples where implicit time stepping will work fine but explicit will fail: 1) The negation of the above formula, this implementation will end up using dudt = - f(u,t). 2) A residual which is implicit or non-linear in dudt, such as r = dudt. More...
#include <explicit_timesteppers.h>
Public Member Functions | |
ExplicitTimeSteppableObject () | |
Empty constructor. More... | |
ExplicitTimeSteppableObject (const ExplicitTimeSteppableObject &)=delete | |
Broken copy constructor. More... | |
void | operator= (const ExplicitTimeSteppableObject &)=delete |
Broken assignment operator. More... | |
virtual | ~ExplicitTimeSteppableObject () |
Empty destructor. More... | |
virtual void | get_dvaluesdt (DoubleVector &minv_res) |
A single virtual function that returns the residuals vector multiplied by the inverse mass matrix. More... | |
virtual void | get_dofs (DoubleVector &dofs) const |
Function that gets the values of the dofs in the object. More... | |
virtual void | get_dofs (const unsigned &t, DoubleVector &dofs) const |
Function that gets the history values of the dofs in the object. More... | |
virtual void | set_dofs (const DoubleVector &dofs) |
Function that sets the values of the dofs in the object. More... | |
virtual void | add_to_dofs (const double &lambda, const DoubleVector &increment_dofs) |
Function that adds the values to the dofs. More... | |
virtual void | actions_before_explicit_stage () |
Empty virtual function to do anything needed before a stage of an explicit time step (Runge-Kutta steps contain multiple stages per time step, most others only contain one). More... | |
virtual void | actions_after_explicit_stage () |
Empty virtual function that should be overloaded to update any dependent data or boundary conditions that should be advanced after each stage of an explicit time step (Runge-Kutta steps contain multiple stages per time step, most others only contain one). More... | |
virtual void | actions_before_explicit_timestep () |
Empty virtual function that can be overloaded to do anything needed before an explicit step. More... | |
virtual void | actions_after_explicit_timestep () |
Empty virtual function that can be overloaded to do anything needed after an explicit step. More... | |
virtual double & | time () |
Broken virtual function that should be overloaded to return access to the local time in the object. More... | |
virtual Time * | time_pt () const |
Virtual function that should be overloaded to return a pointer to a Time object. More... | |
Static Private Attributes | |
static double | Dummy_time_value = 0.0 |
Dummy value of time always set to zero. More... | |
Class for objects than can be advanced in time by an Explicit Timestepper. WARNING: For explicit time stepping to work the object's residual function (as used by get_inverse_mass_matrix_times_residuals(..)) MUST be in the form r = f(t, u) - [timestepper approximation to dudt]! Standard implicit time stepping will work with plenty of residuals that don't fit into this form. Some examples where implicit time stepping will work fine but explicit will fail: 1) The negation of the above formula, this implementation will end up using dudt = - f(u,t). 2) A residual which is implicit or non-linear in dudt, such as r = dudt.
Definition at line 64 of file explicit_timesteppers.h.
|
inline |
Empty constructor.
Definition at line 71 of file explicit_timesteppers.h.
|
delete |
Broken copy constructor.
|
inlinevirtual |
Empty destructor.
Definition at line 80 of file explicit_timesteppers.h.
|
inlinevirtual |
Empty virtual function that should be overloaded to update any dependent data or boundary conditions that should be advanced after each stage of an explicit time step (Runge-Kutta steps contain multiple stages per time step, most others only contain one).
Definition at line 108 of file explicit_timesteppers.h.
Referenced by oomph::RungeKutta< ORDER >::timestep(), oomph::LowStorageRungeKutta< ORDER >::timestep(), oomph::Euler::timestep(), and oomph::EBDF3::timestep().
|
inlinevirtual |
Empty virtual function that can be overloaded to do anything needed after an explicit step.
Reimplemented in oomph::Problem.
Definition at line 116 of file explicit_timesteppers.h.
Referenced by oomph::RungeKutta< ORDER >::timestep(), oomph::LowStorageRungeKutta< ORDER >::timestep(), oomph::Euler::timestep(), and oomph::EBDF3::timestep().
|
inlinevirtual |
Empty virtual function to do anything needed before a stage of an explicit time step (Runge-Kutta steps contain multiple stages per time step, most others only contain one).
Definition at line 102 of file explicit_timesteppers.h.
Referenced by oomph::RungeKutta< ORDER >::timestep(), oomph::LowStorageRungeKutta< ORDER >::timestep(), oomph::Euler::timestep(), and oomph::EBDF3::timestep().
|
inlinevirtual |
Empty virtual function that can be overloaded to do anything needed before an explicit step.
Reimplemented in oomph::Problem.
Definition at line 112 of file explicit_timesteppers.h.
Referenced by oomph::RungeKutta< ORDER >::timestep(), oomph::LowStorageRungeKutta< ORDER >::timestep(), oomph::Euler::timestep(), and oomph::EBDF3::timestep().
|
virtual |
Function that adds the values to the dofs.
Function that adds the lambda multiplied by the increment_dofs vector to the dofs in the object.
Reimplemented in oomph::Problem.
Definition at line 112 of file explicit_timesteppers.cc.
Referenced by oomph::RungeKutta< ORDER >::timestep(), oomph::LowStorageRungeKutta< ORDER >::timestep(), and oomph::Euler::timestep().
|
virtual |
Function that gets the history values of the dofs in the object.
Function that should get the values of the dofs in the object.
Reimplemented in oomph::Problem.
Definition at line 77 of file explicit_timesteppers.cc.
|
virtual |
Function that gets the values of the dofs in the object.
Function that should get the values of the dofs in the object.
Reimplemented in oomph::Problem.
Definition at line 60 of file explicit_timesteppers.cc.
Referenced by oomph::RungeKutta< ORDER >::timestep(), and oomph::EBDF3::timestep().
|
virtual |
A single virtual function that returns the residuals vector multiplied by the inverse mass matrix.
Reimplemented in oomph::Problem.
Definition at line 41 of file explicit_timesteppers.cc.
Referenced by oomph::RungeKutta< ORDER >::timestep(), oomph::LowStorageRungeKutta< ORDER >::timestep(), oomph::Euler::timestep(), and oomph::EBDF3::timestep().
|
delete |
Broken assignment operator.
|
virtual |
Function that sets the values of the dofs in the object.
Reimplemented in oomph::Problem.
Definition at line 95 of file explicit_timesteppers.cc.
Referenced by oomph::RungeKutta< ORDER >::timestep(), and oomph::EBDF3::timestep().
|
virtual |
Broken virtual function that should be overloaded to return access to the local time in the object.
Virtual function that should be overloaded to return access to the local time in the object.
Reimplemented in oomph::Problem.
Definition at line 132 of file explicit_timesteppers.cc.
References Dummy_time_value.
Referenced by oomph::RungeKutta< ORDER >::timestep(), oomph::LowStorageRungeKutta< ORDER >::timestep(), oomph::Euler::timestep(), and oomph::EBDF3::timestep().
|
virtual |
Virtual function that should be overloaded to return a pointer to a Time object.
Reimplemented in oomph::Problem.
Definition at line 147 of file explicit_timesteppers.cc.
Referenced by oomph::EBDF3::timestep().
|
staticprivate |
Dummy value of time always set to zero.
Definition at line 67 of file explicit_timesteppers.h.
Referenced by time().