Tempus  Version of the Day
Time Integration
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Tempus_CombinedForwardSensitivityModelEvaluator_decl.hpp
Go to the documentation of this file.
1 // @HEADER
2 // ****************************************************************************
3 // Tempus: Copyright (2017) Sandia Corporation
4 //
5 // Distributed under BSD 3-clause license (See accompanying file Copyright.txt)
6 // ****************************************************************************
7 // @HEADER
8 
9 #ifndef Tempus_CombinedForwardSensitivityModelEvaluator_decl_hpp
10 #define Tempus_CombinedForwardSensitivityModelEvaluator_decl_hpp
11 
12 #include "Tempus_config.hpp"
14 #include "Thyra_StateFuncModelEvaluatorBase.hpp"
15 #include "Thyra_DefaultMultiVectorProductVectorSpace.hpp"
16 
17 namespace Tempus {
18 
37 template <typename Scalar>
40  public SensitivityModelEvaluatorBase<Scalar> {
41 public:
44 
46 
70  const Teuchos::RCP<const Thyra::ModelEvaluator<Scalar> > & model,
71  const Teuchos::RCP<const Teuchos::ParameterList>& pList = Teuchos::null,
72  const Teuchos::RCP<MultiVector>& dxdp_init = Teuchos::null,
73  const Teuchos::RCP<MultiVector>& dx_dotdp_init = Teuchos::null,
74  const Teuchos::RCP<MultiVector>& dx_dotdot_dp_init = Teuchos::null);
75 
78 
81  { return model_; }
82 
84 
86  int getSensitivityParamIndex() const { return p_index_; }
87 
90 
92 
94 
96 
98 
100 
102 
104 
106 
108 
110 
112  get_W_factory() const;
113 
115 
117 
119 
121 
122 private:
123 
125 
126  void evalModelImpl(
128  const Thyra::ModelEvaluatorBase::OutArgs<Scalar> &outArgs) const;
129 
130 
133 
138  int p_index_;
143 
149 
153 };
154 
155 } // namespace Tempus
156 
157 #endif
Transform a ModelEvaluator&#39;s sensitivity equations to its residual.
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_p_space(int p) const
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_g_space(int j) const
Teuchos::RCP< Thyra::LinearOpBase< Scalar > > create_DgDx_dot_op(int j) const
Teuchos::RCP< const Thyra::DefaultMultiVectorProductVectorSpace< Scalar > > dxdp_space_
Teuchos::RCP< const Teuchos::Array< std::string > > get_p_names(int p) const
Teuchos::RCP< Thyra::LinearOpBase< Scalar > > create_DgDp_op(int j, int l) const
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_x_space() const
Teuchos::RCP< const Thyra::DefaultMultiVectorProductVectorSpace< Scalar > > x_dxdp_space_
Teuchos::RCP< Thyra::LinearOpBase< Scalar > > create_DgDx_op(int j) const
Teuchos::RCP< const Thyra::DefaultMultiVectorProductVectorSpace< Scalar > > f_dfdp_space_
void evalModelImpl(const Thyra::ModelEvaluatorBase::InArgs< Scalar > &inArgs, const Thyra::ModelEvaluatorBase::OutArgs< Scalar > &outArgs) const
Teuchos::RCP< const Thyra::DefaultMultiVectorProductVectorSpace< Scalar > > dfdp_space_
Teuchos::RCP< const Thyra::LinearOpWithSolveFactoryBase< Scalar > > get_W_factory() const
Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_f_space() const
CombinedForwardSensitivityModelEvaluator(const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &model, const Teuchos::RCP< const Teuchos::ParameterList > &pList=Teuchos::null, const Teuchos::RCP< MultiVector > &dxdp_init=Teuchos::null, const Teuchos::RCP< MultiVector > &dx_dotdp_init=Teuchos::null, const Teuchos::RCP< MultiVector > &dx_dotdot_dp_init=Teuchos::null)
Constructor.
Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > getForwardModel() const
Get the underlying model &#39;f&#39;.
A ModelEvaluator decorator for sensitivity analysis.