|
Tempus Version of the Day
Time Integration
|
This example moves the van der Pol model into a Thyra::ModelEvaluator. The time integration loop still performs a hand-written Forward Euler update, but the right-hand-side evaluation and nominal initial conditions are now obtained through the model interface.
The main purpose of this step is to separate the problem physics from the time integration algorithm.
Relative to Example 1: Utilize Thyra:
VanDerPol_ModelEvaluator_02getNominalValues()evalModel()Thyra::ModelEvaluator provides a common Trilinos interface between application models and abstract numerical algorithms. For Tempus, this interface is the standard mechanism for exposing governing equations to steppers and integrators.
This example focuses only on the subset of Thyra::ModelEvaluator behavior needed for explicit first-order ODEs.
As in the previous examples, the code prints the evolving solution in a simple table with columns for the step index, time, 

passed still indicates whether the hand-written stepping loop succeeds, while overall tutorial success additionally requires the final regression comparison to pass.