9 #ifndef Tempus_ModelEvaluatorPairPartIMEX_Basic_decl_hpp
10 #define Tempus_ModelEvaluatorPairPartIMEX_Basic_decl_hpp
13 #include "Thyra_StateFuncModelEvaluatorBase.hpp"
36 template <
typename Scalar>
47 const Teuchos::RCP<
const Thyra::ModelEvaluator<Scalar> >& explicitModel,
48 const Teuchos::RCP<
const Thyra::ModelEvaluator<Scalar> >& implicitModel,
49 int numExplicitOnlyBlocks = 0,
int parameterIndex = -1);
60 const Teuchos::RCP<
const Thyra::ModelEvaluator<Scalar> > & me);
61 virtual Teuchos::RCP<const Thyra::ModelEvaluator<Scalar> >
65 virtual void setInArgs(Thyra::ModelEvaluatorBase::InArgs<Scalar> inArgs)
69 virtual Thyra::ModelEvaluatorBase::InArgs<Scalar>
getInArgs()
73 virtual void setOutArgs(Thyra::ModelEvaluatorBase::OutArgs<Scalar> outArgs)
77 virtual Thyra::ModelEvaluatorBase::OutArgs<Scalar>
getOutArgs()
82 Thyra::ModelEvaluatorBase::InArgs<Scalar> inArgs,
83 Thyra::ModelEvaluatorBase::OutArgs<Scalar> outArgs,
97 virtual Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> >
101 virtual Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> >
105 virtual Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> >
113 const Teuchos::RCP<
const Thyra::ModelEvaluator<Scalar> > & model )
116 const Teuchos::RCP<
const Thyra::ModelEvaluator<Scalar> > & model );
117 virtual Teuchos::RCP<const Thyra::ModelEvaluator<Scalar> >
119 virtual Teuchos::RCP<const Thyra::ModelEvaluator<Scalar> >
125 virtual Teuchos::RCP<Thyra::VectorBase<Scalar> >
getIMEXVector(
126 const Teuchos::RCP<Thyra::VectorBase<Scalar> > & full)
const;
129 virtual Teuchos::RCP<const Thyra::VectorBase<Scalar> >
getIMEXVector(
130 const Teuchos::RCP<
const Thyra::VectorBase<Scalar> > & full)
const;
134 const Teuchos::RCP<Thyra::VectorBase<Scalar> > & full)
const;
138 const Teuchos::RCP<
const Thyra::VectorBase<Scalar> > & full)
const;
153 virtual Teuchos::RCP<Thyra::LinearOpBase<Scalar> >
create_W_op()
const
156 Teuchos::RCP<const Thyra::LinearOpWithSolveFactoryBase<Scalar> >
159 virtual Teuchos::RCP<const Thyra::VectorSpaceBase<Scalar> >
163 virtual Thyra::ModelEvaluatorBase::InArgs<Scalar>
createInArgs()
const;
167 const Thyra::ModelEvaluatorBase::InArgs<Scalar> & in,
168 const Thyra::ModelEvaluatorBase::OutArgs<Scalar> & out)
const;
175 const Teuchos::RCP<
const Thyra::ModelEvaluator<Scalar> >& explicitModel,
176 const Teuchos::RCP<
const Thyra::ModelEvaluator<Scalar> >& implicitModel,
177 int numExplicitOnlyBlocks = 0,
int parameterIndex = -1);
193 #endif // Tempus_ModelEvaluatorPairPartIMEX_Basic_decl_hpp
virtual Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > getAppModel() const
Get the underlying application ModelEvaluator.
EVALUATION_TYPE
EVALUATION_TYPE indicates the evaluation to apply to the implicit ODE.
virtual void setInArgs(Thyra::ModelEvaluatorBase::InArgs< Scalar > inArgs)
Set InArgs the wrapper ModelEvalutor.
virtual Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_g_space(int i) const
Get the g space.
virtual void setExplicitModel(const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &model)
Thyra::ModelEvaluatorBase::OutArgs< Scalar > wrapperImplicitOutArgs_
virtual int getParameterIndex() const
Get the parameter index for explicit-only vector.
Teuchos::RCP< TimeDerivative< Scalar > > timeDer_
ModelEvaluator pair for implicit and explicit (IMEX) evaluations.
virtual Thyra::ModelEvaluatorBase::InArgs< Scalar > getInArgs()
Get InArgs the wrapper ModelEvalutor.
virtual Teuchos::RCP< Thyra::VectorBase< Scalar > > getExplicitOnlyVector(const Teuchos::RCP< Thyra::VectorBase< Scalar > > &full) const
Extract explicit-only vector from a full solution vector.
virtual Thyra::ModelEvaluatorBase::InArgs< Scalar > createInArgs() const
virtual void setParameterIndex(int parameterIndex=-1)
Set the parameter index for explicit-only vector.
virtual Thyra::ModelEvaluatorBase::OutArgs< Scalar > getOutArgs()
Get OutArgs the wrapper ModelEvalutor.
virtual void initialize()
Initialize after setting member data.
Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > implicitModel_
virtual Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_x_space() const
Get the x-solution space.
ModelEvaluator pair for implicit and explicit (IMEX) evaulations.
virtual Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > getImplicitModel() const
virtual void setNumExplicitOnlyBlocks(int numExp)
virtual void setUseImplicitModel(bool tf)
Set parameter to switch wrapperME base functions between explicit and implicit functions.
virtual ~WrapperModelEvaluatorPairPartIMEX_Basic()
Destructor.
virtual Thyra::ModelEvaluatorBase::InArgs< Scalar > getNominalValues() const
int parameterIndex_
implicit parameter index for explicit-only vector
bool useImplicitModel_
if true, use implicitModel_ else explicitModel_
void setup(const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &explicitModel, const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &implicitModel, int numExplicitOnlyBlocks=0, int parameterIndex=-1)
Setup ME when using default constructor – for derived classes.
virtual void setOutArgs(Thyra::ModelEvaluatorBase::OutArgs< Scalar > outArgs)
Set OutArgs the wrapper ModelEvalutor.
virtual Thyra::ModelEvaluatorBase::OutArgs< Scalar > createOutArgsImpl() const
virtual void setImplicitModel(const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &model)
Thyra::ModelEvaluatorBase::InArgs< Scalar > wrapperImplicitInArgs_
Teuchos::RCP< const Thyra::LinearOpWithSolveFactoryBase< Scalar > > get_W_factory() const
virtual void setAppModel(const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &me)
Set the underlying application ModelEvaluator.
virtual Teuchos::RCP< Thyra::LinearOpBase< Scalar > > create_W_op() const
int numExplicitOnlyBlocks_
virtual Teuchos::RCP< Thyra::VectorBase< Scalar > > getIMEXVector(const Teuchos::RCP< Thyra::VectorBase< Scalar > > &full) const
Extract IMEX vector from a full solution vector.
This interface defines the time derivative connection between an implicit Stepper and WrapperModelEva...
WrapperModelEvaluatorPairPartIMEX_Basic()
Default constructor – Still requires setting the models and running initialize.
virtual Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > getExplicitModel() const
virtual Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_f_space() const
virtual void setForSolve(Teuchos::RCP< TimeDerivative< Scalar > > timeDer, Thyra::ModelEvaluatorBase::InArgs< Scalar > inArgs, Thyra::ModelEvaluatorBase::OutArgs< Scalar > outArgs, EVALUATION_TYPE=SOLVE_FOR_X)
Set parameters for application implicit ModelEvaluator solve.
virtual Teuchos::RCP< const Thyra::VectorSpaceBase< Scalar > > get_p_space(int i) const
Get the p space.
virtual bool getUseImplicitModel() const
Get parameter to switch wrapperME base functions between explicit and implicit functions.
Solve for x and determine xDot from x.
virtual void evalModelImpl(const Thyra::ModelEvaluatorBase::InArgs< Scalar > &in, const Thyra::ModelEvaluatorBase::OutArgs< Scalar > &out) const
virtual int getNumExplicitOnlyBlocks() const
Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > explicitModel_