9 #ifndef Tempus_PhysicsStateTest_StepperForwardEuler_hpp
10 #define Tempus_PhysicsStateTest_StepperForwardEuler_hpp
12 #include "Tempus_config.hpp"
13 #include "Tempus_StepperForwardEuler.hpp"
16 namespace Tempus_Test {
23 template <
class Scalar>
54 TEMPUS_FUNC_TIME_MONITOR(
"Tempus::StepperPhysicsStateTest::takeStep()");
57 solutionHistory->getCurrentState();
60 this->
inArgs_.set_x(currentState->getX());
61 if (this->
inArgs_.supports(MEB::IN_ARG_t))
62 this->
inArgs_.set_t(currentState->getTime());
69 if (this->
inArgs_.supports(MEB::IN_ARG_x_dot))
70 this->
inArgs_.set_x_dot(Teuchos::null);
71 this->
outArgs_.set_f(currentState->getXDot());
77 solutionHistory->getWorkingState();
78 const Scalar dt = workingState->getTimeStep();
79 Thyra::V_VpStV(Teuchos::outArg(*(workingState->getX())),
80 *(currentState->getX()), dt, *(currentState->getXDot()));
84 workingState->getPhysicsState());
85 int counter = pSC->getCounter();
87 pSC->setCounter(counter);
90 workingState->setOrder(this->
getOrder());
103 #endif // Tempus_PhysicsStateTest_StepperForwardEuler_hpp
Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > appModel_
Explicit ODE ModelEvaluator.
This is a Forward Euler time stepper to test the PhysicsState.
virtual void takeStep(const Teuchos::RCP< Tempus::SolutionHistory< Scalar > > &solutionHistory)
Take the specified timestep, dt, and return true if successful.
Teuchos::RCP< Tempus::StepperState< Scalar > > getDefaultStepperState()
Scalar getOrderMax() const
Thyra::ModelEvaluatorBase::OutArgs< Scalar > outArgs_
Teuchos::RCP< const Teuchos::ParameterList > getValidParameters() const
virtual std::string description() const
void setICConsistencyCheck(bool c)
SolutionHistory is basically a container of SolutionStates. SolutionHistory maintains a collection of...
virtual void setModel(const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &appModel)
Set model.
PhysicsStateCounter is a simple PhysicsState that counts steps.
Stepper integrates first-order ODEs.
void initialize()
Initialize after construction and changing input parameters.
Thyra::ModelEvaluatorBase::InArgs< Scalar > inArgs_
virtual void setUseFSAL(bool a)
Scalar getOrderMin() const
Tempus::OrderODE getOrderODE() const
Thyra Base interface for implicit time steppers.
void setStepperType(std::string s)
Set the stepper type.
StepperPhysicsStateTest(const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &appModel)
Constructor.
void setICConsistency(std::string s)