|
Tempus Version of the Day
Time Integration
|
This example introduces Tempus::TimeStepControl, which manages timestep-size selection independently of the stepper and application time loop. The van der Pol model is still provided through a Thyra::ModelEvaluator, the Forward Euler step is still performed by Tempus::StepperForwardEuler, and the application still manages the overall time loop and Tempus::SolutionHistory. However, timestep-size selection is now delegated to a Tempus::TimeStepControl object rather than being hardcoded directly in the application.
The main purpose of this step is to separate timestep-selection policy from both the stepping algorithm and the surrounding application logic. It should be noted that a Tempus::Stepper may suggest a future timestep size, but the final timestep-size selection occurs in Tempus::TimeStepControl.
Relative to Example 5: Introduce Stepper:
The central idea behind Tempus::TimeStepControl is that timestep size should be managed by a dedicated object that can enforce integration limits, policies, and strategies independently of the stepper itself.
This example uses only part of the full Tempus::TimeStepControl capability:
The example continues to print the evolving solution in a simple table with columns for step index, time, 
