Tempus Version of the Day
Time Integration
Loading...
Searching...
No Matches
Public Member Functions | List of all members
Tempus_Test::DahlquistTestModel< Scalar > Class Template Reference

The classic Dahlquist Test Problem. More...

#include <DahlquistTestModel_decl.hpp>

Inheritance diagram for Tempus_Test::DahlquistTestModel< Scalar >:

Public Member Functions

 DahlquistTestModel ()
 
 DahlquistTestModel (Scalar lambda, bool includeXDot)
 
void constructDahlquistTestModel (Scalar lambda, bool includeXDot)
 
 ~DahlquistTestModel ()=default
 Default destructor.
 
Thyra::ModelEvaluatorBase::InArgs< Scalar > getExactSolution (double t) const
 Exact solution.
 
Scalar getLambda () const
 

Private functions overridden from ModelEvaluatorDefaultBase.

int dim_
 
int Np_
 
int np_
 
int Ng_
 
int ng_
 
bool haveIC_
 
bool acceptModelParams_
 
Scalar lambda_
 
bool includeXDot_
 
bool isInitialized_
 
Thyra::ModelEvaluatorBase::InArgs< Scalar > inArgs_
 
Thyra::ModelEvaluatorBase::OutArgs< Scalar > outArgs_
 
Thyra::ModelEvaluatorBase::InArgs< Scalar > nominalValues_
 
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > x_space_
 
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > f_space_
 
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > p_space_
 
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > g_space_
 
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > DxDp_space_
 
Scalar xIC_
 Initial condition for x.
 
Scalar xDotIC_
 Initial condition for xDot.
 
Thyra::ModelEvaluatorBase::OutArgs< Scalar > createOutArgsImpl () const
 
void evalModelImpl (const Thyra::ModelEvaluatorBase::InArgs< Scalar > &inArgs_bar, const Thyra::ModelEvaluatorBase::OutArgs< Scalar > &outArgs_bar) const
 

Public functions overridden from ModelEvaluator.

Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_x_space () const
 
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_f_space () const
 
Thyra::ModelEvaluatorBase::InArgs< Scalar > getNominalValues () const
 
Teuchos::RCP< Thyra::LinearOpWithSolveBase< Scalar > > create_W () const
 
Teuchos::RCP< Thyra::LinearOpBase< Scalar > > create_W_op () const
 
Teuchos::RCP< const Thyra::LinearOpWithSolveFactoryBase< Scalar > > get_W_factory () const
 
Thyra::ModelEvaluatorBase::InArgs< Scalar > createInArgs () const
 
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_p_space (int l) const
 
Teuchos::RCP< const Teuchos::Array< std::string > > get_p_names (int l) const
 
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_g_space (int j) const
 

Detailed Description

template<class Scalar>
class Tempus_Test::DahlquistTestModel< Scalar >

The classic Dahlquist Test Problem.

This is the canonical Dahlquist test equation

\[
  \mathbf{\dot{x}} = \lambda \mathbf{x}.
  \]

where $\lambda \in \mathbf{C}$ with the initial condition $\mathbf{x}(0) = 1$. The exact solution is

\[
  \mathbf{x}(t) = \exp{\lambda t}.
  \]

When $\mathbf{R}(\lambda) < 0$, $ \mathbf{x} \rightarrow 0$ as $t \rightarrow \infty$. Numerical methods that exhibit this property are said to be A-stable.

Definition at line 35 of file DahlquistTestModel_decl.hpp.

Constructor & Destructor Documentation

◆ DahlquistTestModel() [1/2]

template<class Scalar >
Tempus_Test::DahlquistTestModel< Scalar >::DahlquistTestModel ( )

Definition at line 28 of file DahlquistTestModel_impl.hpp.

◆ DahlquistTestModel() [2/2]

template<class Scalar >
Tempus_Test::DahlquistTestModel< Scalar >::DahlquistTestModel ( Scalar lambda,
bool includeXDot )

Definition at line 33 of file DahlquistTestModel_impl.hpp.

◆ ~DahlquistTestModel()

template<class Scalar >
Tempus_Test::DahlquistTestModel< Scalar >::~DahlquistTestModel ( )
default

Default destructor.

Member Function Documentation

◆ constructDahlquistTestModel()

template<class Scalar >
void Tempus_Test::DahlquistTestModel< Scalar >::constructDahlquistTestModel ( Scalar lambda,
bool includeXDot )

Definition at line 40 of file DahlquistTestModel_impl.hpp.

◆ getExactSolution()

template<class Scalar >
Thyra::ModelEvaluatorBase::InArgs< Scalar > Tempus_Test::DahlquistTestModel< Scalar >::getExactSolution ( double t) const

Exact solution.

Definition at line 123 of file DahlquistTestModel_impl.hpp.

◆ getLambda()

template<class Scalar >
Scalar Tempus_Test::DahlquistTestModel< Scalar >::getLambda ( ) const
inline

Definition at line 54 of file DahlquistTestModel_decl.hpp.

◆ get_x_space()

template<class Scalar >
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > Tempus_Test::DahlquistTestModel< Scalar >::get_x_space ( ) const

Definition at line 154 of file DahlquistTestModel_impl.hpp.

◆ get_f_space()

template<class Scalar >
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > Tempus_Test::DahlquistTestModel< Scalar >::get_f_space ( ) const

Definition at line 163 of file DahlquistTestModel_impl.hpp.

◆ getNominalValues()

template<class Scalar >
Thyra::ModelEvaluatorBase::InArgs< Scalar > Tempus_Test::DahlquistTestModel< Scalar >::getNominalValues ( ) const

Definition at line 172 of file DahlquistTestModel_impl.hpp.

◆ create_W()

template<class Scalar >
Teuchos::RCP< Thyra::LinearOpWithSolveBase< Scalar > > Tempus_Test::DahlquistTestModel< Scalar >::create_W ( ) const

Definition at line 263 of file DahlquistTestModel_impl.hpp.

◆ create_W_op()

template<class Scalar >
Teuchos::RCP< Thyra::LinearOpBase< Scalar > > Tempus_Test::DahlquistTestModel< Scalar >::create_W_op ( ) const

Definition at line 290 of file DahlquistTestModel_impl.hpp.

◆ get_W_factory()

template<class Scalar >
Teuchos::RCP< const Thyra::LinearOpWithSolveFactoryBase< Scalar > > Tempus_Test::DahlquistTestModel< Scalar >::get_W_factory ( ) const

Definition at line 301 of file DahlquistTestModel_impl.hpp.

◆ createInArgs()

template<class Scalar >
Thyra::ModelEvaluatorBase::InArgs< Scalar > Tempus_Test::DahlquistTestModel< Scalar >::createInArgs ( ) const

Definition at line 181 of file DahlquistTestModel_impl.hpp.

◆ get_p_space()

template<class Scalar >
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > Tempus_Test::DahlquistTestModel< Scalar >::get_p_space ( int l) const

Definition at line 311 of file DahlquistTestModel_impl.hpp.

◆ get_p_names()

template<class Scalar >
Teuchos::RCP< const Teuchos::Array< std::string > > Tempus_Test::DahlquistTestModel< Scalar >::get_p_names ( int l) const

Definition at line 328 of file DahlquistTestModel_impl.hpp.

◆ get_g_space()

template<class Scalar >
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > Tempus_Test::DahlquistTestModel< Scalar >::get_g_space ( int j) const

Definition at line 351 of file DahlquistTestModel_impl.hpp.

◆ createOutArgsImpl()

template<class Scalar >
Thyra::ModelEvaluatorBase::OutArgs< Scalar > Tempus_Test::DahlquistTestModel< Scalar >::createOutArgsImpl ( ) const
private

Definition at line 190 of file DahlquistTestModel_impl.hpp.

◆ evalModelImpl()

template<class Scalar >
void Tempus_Test::DahlquistTestModel< Scalar >::evalModelImpl ( const Thyra::ModelEvaluatorBase::InArgs< Scalar > & inArgs_bar,
const Thyra::ModelEvaluatorBase::OutArgs< Scalar > & outArgs_bar ) const
private

Definition at line 199 of file DahlquistTestModel_impl.hpp.

Member Data Documentation

◆ dim_

template<class Scalar >
int Tempus_Test::DahlquistTestModel< Scalar >::dim_
private

Definition at line 83 of file DahlquistTestModel_decl.hpp.

◆ Np_

template<class Scalar >
int Tempus_Test::DahlquistTestModel< Scalar >::Np_
private

Definition at line 84 of file DahlquistTestModel_decl.hpp.

◆ np_

template<class Scalar >
int Tempus_Test::DahlquistTestModel< Scalar >::np_
private

Definition at line 85 of file DahlquistTestModel_decl.hpp.

◆ Ng_

template<class Scalar >
int Tempus_Test::DahlquistTestModel< Scalar >::Ng_
private

Definition at line 86 of file DahlquistTestModel_decl.hpp.

◆ ng_

template<class Scalar >
int Tempus_Test::DahlquistTestModel< Scalar >::ng_
private

Definition at line 87 of file DahlquistTestModel_decl.hpp.

◆ haveIC_

template<class Scalar >
bool Tempus_Test::DahlquistTestModel< Scalar >::haveIC_
private

Definition at line 88 of file DahlquistTestModel_decl.hpp.

◆ acceptModelParams_

template<class Scalar >
bool Tempus_Test::DahlquistTestModel< Scalar >::acceptModelParams_
private

Definition at line 89 of file DahlquistTestModel_decl.hpp.

◆ lambda_

template<class Scalar >
Scalar Tempus_Test::DahlquistTestModel< Scalar >::lambda_
private

Definition at line 90 of file DahlquistTestModel_decl.hpp.

◆ includeXDot_

template<class Scalar >
bool Tempus_Test::DahlquistTestModel< Scalar >::includeXDot_
private

Definition at line 91 of file DahlquistTestModel_decl.hpp.

◆ isInitialized_

template<class Scalar >
bool Tempus_Test::DahlquistTestModel< Scalar >::isInitialized_
mutableprivate

Definition at line 93 of file DahlquistTestModel_decl.hpp.

◆ inArgs_

template<class Scalar >
Thyra::ModelEvaluatorBase::InArgs<Scalar> Tempus_Test::DahlquistTestModel< Scalar >::inArgs_
mutableprivate

Definition at line 94 of file DahlquistTestModel_decl.hpp.

◆ outArgs_

template<class Scalar >
Thyra::ModelEvaluatorBase::OutArgs<Scalar> Tempus_Test::DahlquistTestModel< Scalar >::outArgs_
mutableprivate

Definition at line 95 of file DahlquistTestModel_decl.hpp.

◆ nominalValues_

template<class Scalar >
Thyra::ModelEvaluatorBase::InArgs<Scalar> Tempus_Test::DahlquistTestModel< Scalar >::nominalValues_
mutableprivate

Definition at line 96 of file DahlquistTestModel_decl.hpp.

◆ x_space_

template<class Scalar >
Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> > Tempus_Test::DahlquistTestModel< Scalar >::x_space_
private

Definition at line 97 of file DahlquistTestModel_decl.hpp.

◆ f_space_

template<class Scalar >
Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> > Tempus_Test::DahlquistTestModel< Scalar >::f_space_
private

Definition at line 98 of file DahlquistTestModel_decl.hpp.

◆ p_space_

template<class Scalar >
Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> > Tempus_Test::DahlquistTestModel< Scalar >::p_space_
private

Definition at line 99 of file DahlquistTestModel_decl.hpp.

◆ g_space_

template<class Scalar >
Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> > Tempus_Test::DahlquistTestModel< Scalar >::g_space_
private

Definition at line 100 of file DahlquistTestModel_decl.hpp.

◆ DxDp_space_

template<class Scalar >
Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> > Tempus_Test::DahlquistTestModel< Scalar >::DxDp_space_
private

Definition at line 101 of file DahlquistTestModel_decl.hpp.

◆ xIC_

template<class Scalar >
Scalar Tempus_Test::DahlquistTestModel< Scalar >::xIC_
private

Initial condition for x.

Definition at line 103 of file DahlquistTestModel_decl.hpp.

◆ xDotIC_

template<class Scalar >
Scalar Tempus_Test::DahlquistTestModel< Scalar >::xDotIC_
private

Initial condition for xDot.

Definition at line 104 of file DahlquistTestModel_decl.hpp.


The documentation for this class was generated from the following files: