Tempus Version of the Day
Time Integration
Loading...
Searching...
No Matches
Tempus_StepperRKModifierDefault.hpp
Go to the documentation of this file.
1//@HEADER
2// *****************************************************************************
3// Tempus: Time Integration and Sensitivity Analysis Package
4//
5// Copyright 2017 NTESS and the Tempus contributors.
6// SPDX-License-Identifier: BSD-3-Clause
7// *****************************************************************************
8//@HEADER
9
10#ifndef Tempus_StepperRKModifierDefault_hpp
11#define Tempus_StepperRKModifierDefault_hpp
12
13#include "Tempus_config.hpp"
15
16// Applications can uncomment this include in their implementation,
17// if they need access to the stepper methods.
18//#include "Tempus_StepperRKBase.hpp"
19
20namespace Tempus {
21
30template <class Scalar>
32 : virtual public Tempus::StepperRKModifierBase<Scalar> {
33 public:
36
39
41 virtual void modify(
42 Teuchos::RCP<SolutionHistory<Scalar> > /* sh */,
43 Teuchos::RCP<StepperRKBase<Scalar> > /* stepper */,
45 {
46 switch (actLoc) {
54 // No-op.
55 break;
56 }
57 default:
58 TEUCHOS_TEST_FOR_EXCEPTION(
59 true, std::logic_error,
60 "Error - unknown action location = " + std::to_string(actLoc) +
61 "\n"
62 " Valid actions are\n"
63 " StepperRKAppAction<Scalar>::BEGIN_STEP = " +
65 "\n"
66 " StepperRKAppAction<Scalar>::BEGIN_STAGE = " +
68 "\n"
69 " StepperRKAppAction<Scalar>::BEFORE_SOLVE = " +
71 "\n"
72 " StepperRKAppAction<Scalar>::AFTER_SOLVE = " +
74 "\n"
75 " StepperRKAppAction<Scalar>::BEFORE_EXPLICIT_EVAL = " +
76 std::to_string(
78 "\n"
79 " StepperRKAppAction<Scalar>::END_STAGE = " +
81 "\n"
82 " StepperRKAppAction<Scalar>::END_STEP = " +
83 std::to_string(StepperRKAppAction<Scalar>::END_STEP) + "\n");
84 }
85 }
86};
87
88} // namespace Tempus
89
90#endif // Tempus_StepperRKModifierDefault_hpp
SolutionHistory is basically a container of SolutionStates. SolutionHistory maintains a collection of...
Application Action for StepperRKBase.
ACTION_LOCATION
Indicates the location of application action (see algorithm).
Base class for Runge-Kutta methods, ExplicitRK, DIRK and IMEX.
virtual void modify(Teuchos::RCP< SolutionHistory< Scalar > >, Teuchos::RCP< StepperRKBase< Scalar > >, const typename StepperRKAppAction< Scalar >::ACTION_LOCATION actLoc)
Modify RK Stepper.