10 #ifndef Tempus_IntegratorAdjointSensitivity_impl_hpp
11 #define Tempus_IntegratorAdjointSensitivity_impl_hpp
14 #include "Thyra_DefaultMultiVectorProductVectorSpace.hpp"
15 #include "Thyra_DefaultMultiVectorProductVector.hpp"
16 #include "Thyra_DefaultProductVectorSpace.hpp"
17 #include "Thyra_DefaultProductVector.hpp"
18 #include "Thyra_VectorStdOps.hpp"
19 #include "Thyra_MultiVectorStdOps.hpp"
21 #include "Thyra_LinearOpWithSolveFactoryHelpers.hpp"
25 template <
class Scalar>
34 const int p_index,
const int g_index,
const bool g_depends_on_p,
35 const bool f_depends_on_p,
const bool ic_depends_on_p,
36 const bool mass_matrix_is_identity)
38 state_integrator_(state_integrator),
39 adjoint_model_(adjoint_model),
40 adjoint_aux_model_(adjoint_aux_model),
41 adjoint_integrator_(adjoint_integrator),
42 solutionHistory_(solutionHistory),
45 g_depends_on_p_(g_depends_on_p),
46 f_depends_on_p_(f_depends_on_p),
47 ic_depends_on_p_(ic_depends_on_p),
48 mass_matrix_is_identity_(mass_matrix_is_identity),
53 "Error - IntegratorAdjointSensitivity(): Cannot use FSAL with\n"
54 " IntegratorAdjointSensitivity, because the state and adjoint\n"
55 " integrators require ModelEvaluator evaluation in the\n"
56 " constructor to make the initial conditions consistent.\n"
57 " For the adjoint integrator, this requires special construction\n"
58 " which has not been implemented yet.\n");
61 template <
class Scalar>
64 state_integrator_ = createIntegratorBasic<Scalar>();
65 adjoint_integrator_ = createIntegratorBasic<Scalar>();
69 template <
class Scalar>
72 const Scalar tfinal = state_integrator_->getTimeStepControl()->getFinalTime();
73 return advanceTime(tfinal);
76 template <
class Scalar>
79 TEMPUS_FUNC_TIME_MONITOR_DIFF(
80 "Tempus::IntegratorAdjointSensitivity::advanceTime()", TEMPUS_AS_AT);
83 using Teuchos::rcp_dynamic_cast;
85 using Thyra::createMember;
86 using Thyra::createMembers;
100 RCP<const SolutionHistory<Scalar>> state_solution_history =
101 state_integrator_->getSolutionHistory();
102 RCP<const SolutionState<Scalar>> initial_state = (*state_solution_history)[0];
105 bool state_status =
true;
107 TEMPUS_FUNC_TIME_MONITOR_DIFF(
108 "Tempus::IntegratorAdjointSensitivity::advanceTime::state",
111 state_status = state_integrator_->advanceTime(timeFinal);
118 adjoint_aux_model_->setFinalTime(state_integrator_->getTime());
121 adjoint_aux_model_->setForwardSolutionHistory(state_solution_history);
124 RCP<const VectorSpaceBase<Scalar>> g_space = model_->get_g_space(g_index_);
125 RCP<const VectorSpaceBase<Scalar>> x_space = model_->get_x_space();
126 const int num_g = g_space->dim();
127 RCP<MultiVectorBase<Scalar>> dgdx = createMembers(x_space, num_g);
128 MEB::InArgs<Scalar> inargs = model_->getNominalValues();
129 RCP<const SolutionState<Scalar>> state =
130 state_solution_history->getCurrentState();
131 inargs.set_t(state->getTime());
132 inargs.set_x(state->getX());
133 inargs.set_x_dot(state->getXDot());
134 MEB::OutArgs<Scalar> outargs = model_->createOutArgs();
135 MEB::OutArgs<Scalar> adj_outargs = adjoint_model_->createOutArgs();
136 outargs.set_DgDx(g_index_,
137 MEB::Derivative<Scalar>(dgdx, MEB::DERIV_MV_GRADIENT_FORM));
138 model_->evalModel(inargs, outargs);
139 outargs.set_DgDx(g_index_, MEB::Derivative<Scalar>());
145 RCP<DPV> adjoint_init = rcp_dynamic_cast<DPV>(
146 Thyra::createMember(adjoint_aux_model_->get_x_space()));
147 RCP<MultiVectorBase<Scalar>> adjoint_init_mv =
148 rcp_dynamic_cast<DMVPV>(adjoint_init->getNonconstVectorBlock(0))
149 ->getNonconstMultiVector();
150 assign(adjoint_init->getNonconstVectorBlock(1).ptr(),
152 if (mass_matrix_is_identity_)
153 assign(adjoint_init_mv.ptr(), *dgdx);
155 inargs.set_alpha(1.0);
156 inargs.set_beta(0.0);
157 RCP<LinearOpWithSolveBase<Scalar>> W;
158 if (adj_outargs.supports(MEB::OUT_ARG_W)) {
160 W = adjoint_model_->create_W();
161 adj_outargs.set_W(W);
162 adjoint_model_->evalModel(inargs, adj_outargs);
163 adj_outargs.set_W(Teuchos::null);
167 RCP<const LinearOpWithSolveFactoryBase<Scalar>> lowsfb =
168 adjoint_model_->get_W_factory();
170 "Adjoint ME must support W out-arg or provide "
171 "a W_factory for non-identity mass matrix");
174 RCP<LinearOpBase<Scalar>> W_op = adjoint_model_->create_W_op();
175 adj_outargs.set_W_op(W_op);
176 RCP<PreconditionerFactoryBase<Scalar>> prec_factory =
177 lowsfb->getPreconditionerFactory();
178 RCP<PreconditionerBase<Scalar>> W_prec;
179 if (prec_factory != Teuchos::null)
180 W_prec = prec_factory->createPrec();
181 else if (adj_outargs.supports(MEB::OUT_ARG_W_prec)) {
182 W_prec = adjoint_model_->create_W_prec();
183 adj_outargs.set_W_prec(W_prec);
185 adjoint_model_->evalModel(inargs, adj_outargs);
186 adj_outargs.set_W_op(Teuchos::null);
187 if (adj_outargs.supports(MEB::OUT_ARG_W_prec))
188 adj_outargs.set_W_prec(Teuchos::null);
191 W = lowsfb->createOp();
192 if (W_prec != Teuchos::null) {
193 if (prec_factory != Teuchos::null)
194 prec_factory->initializePrec(
195 Thyra::defaultLinearOpSource<Scalar>(W_op), W_prec.get());
196 Thyra::initializePreconditionedOp<Scalar>(*lowsfb, W_op, W_prec,
200 Thyra::initializeOp<Scalar>(*lowsfb, W_op, W.ptr());
203 W == Teuchos::null, std::logic_error,
204 "A null W has been encountered in "
205 "Tempus::IntegratorAdjointSensitivity::advanceTime!\n");
213 bool sens_status =
true;
215 TEMPUS_FUNC_TIME_MONITOR_DIFF(
216 "Tempus::IntegratorAdjointSensitivity::advanceTime::adjoint",
220 adjoint_integrator_->getTimeStepControl()->getInitTime();
221 adjoint_integrator_->initializeSolutionHistory(tinit, adjoint_init);
222 sens_status = adjoint_integrator_->advanceTime(timeFinal);
224 RCP<const SolutionHistory<Scalar>> adjoint_solution_history =
225 adjoint_integrator_->getSolutionHistory();
228 RCP<const VectorSpaceBase<Scalar>> p_space = model_->get_p_space(p_index_);
229 dgdp_ = createMembers(p_space, num_g);
230 if (g_depends_on_p_) {
231 MEB::DerivativeSupport dgdp_support =
232 outargs.supports(MEB::OUT_ARG_DgDp, g_index_, p_index_);
233 if (dgdp_support.supports(MEB::DERIV_MV_GRADIENT_FORM)) {
236 MEB::Derivative<Scalar>(dgdp_, MEB::DERIV_MV_GRADIENT_FORM));
237 model_->evalModel(inargs, outargs);
239 else if (dgdp_support.supports(MEB::DERIV_MV_JACOBIAN_FORM)) {
240 const int num_p = p_space->dim();
241 RCP<MultiVectorBase<Scalar>> dgdp_trans = createMembers(g_space, num_p);
244 MEB::Derivative<Scalar>(dgdp_trans, MEB::DERIV_MV_JACOBIAN_FORM));
245 model_->evalModel(inargs, outargs);
248 for (
int i = 0; i < num_p; ++i)
249 for (
int j = 0; j < num_g; ++j) dgdp_view(i, j) = dgdp_trans_view(j, i);
253 "Invalid dg/dp support");
254 outargs.set_DgDp(g_index_, p_index_, MEB::Derivative<Scalar>());
257 assign(dgdp_.ptr(), Scalar(0.0));
261 if (ic_depends_on_p_ && dxdp_init_ != Teuchos::null) {
262 RCP<const SolutionState<Scalar>> adjoint_state =
263 adjoint_solution_history->getCurrentState();
264 RCP<const VectorBase<Scalar>> adjoint_x =
265 rcp_dynamic_cast<
const DPV>(adjoint_state->getX())->getVectorBlock(0);
266 RCP<const MultiVectorBase<Scalar>> adjoint_mv =
267 rcp_dynamic_cast<
const DMVPV>(adjoint_x)->getMultiVector();
268 if (mass_matrix_is_identity_)
272 inargs.set_t(initial_state->getTime());
273 inargs.set_x(initial_state->getX());
274 inargs.set_x_dot(initial_state->getXDot());
275 inargs.set_alpha(1.0);
276 inargs.set_beta(0.0);
277 RCP<LinearOpBase<Scalar>> W_op = adjoint_model_->create_W_op();
278 adj_outargs.set_W_op(W_op);
279 adjoint_model_->evalModel(inargs, adj_outargs);
280 adj_outargs.set_W_op(Teuchos::null);
281 RCP<MultiVectorBase<Scalar>> tmp = createMembers(x_space, num_g);
292 if (f_depends_on_p_) {
293 RCP<const SolutionState<Scalar>> adjoint_state =
294 adjoint_solution_history->getCurrentState();
295 RCP<const VectorBase<Scalar>> z =
296 rcp_dynamic_cast<
const DPV>(adjoint_state->getX())->getVectorBlock(1);
297 RCP<const MultiVectorBase<Scalar>> z_mv =
298 rcp_dynamic_cast<
const DMVPV>(z)->getMultiVector();
299 Thyra::V_VmV(dgdp_.ptr(), *dgdp_, *z_mv);
302 buildSolutionHistory(state_solution_history, adjoint_solution_history);
304 return state_status && sens_status;
307 template <
class Scalar>
310 return solutionHistory_->getCurrentTime();
313 template <
class Scalar>
316 return solutionHistory_->getCurrentIndex();
319 template <
class Scalar>
322 Status state_status = state_integrator_->getStatus();
323 Status sens_status = adjoint_integrator_->getStatus();
329 template <
class Scalar>
332 state_integrator_->setStatus(st);
333 adjoint_integrator_->setStatus(st);
336 template <
class Scalar>
340 return state_integrator_->getStepper();
343 template <
class Scalar>
347 return solutionHistory_;
350 template <
class Scalar>
354 return state_integrator_->getSolutionHistory();
357 template <
class Scalar>
361 return adjoint_integrator_->getSolutionHistory();
364 template <
class Scalar>
368 return solutionHistory_;
371 template <
class Scalar>
375 return state_integrator_->getTimeStepControl();
378 template <
class Scalar>
382 return state_integrator_->getNonConstTimeStepControl();
385 template <
class Scalar>
389 return state_integrator_->getNonConstTimeStepControl();
392 template <
class Scalar>
396 return adjoint_integrator_->getNonConstTimeStepControl();
399 template <
class Scalar>
408 state_integrator_->initializeSolutionHistory(t0, x0, xdot0, xdotdot0);
412 template <
class Scalar>
416 return state_integrator_->getObserver();
419 template <
class Scalar>
423 state_integrator_->setObserver(obs);
429 template <
class Scalar>
432 state_integrator_->initialize();
433 adjoint_integrator_->initialize();
436 template <
class Scalar>
440 return state_integrator_->getX();
443 template <
class Scalar>
447 return state_integrator_->getXDot();
450 template <
class Scalar>
454 return state_integrator_->getXDotDot();
457 template <
class Scalar>
462 using Teuchos::rcp_dynamic_cast;
465 RCP<const DPV> pv = rcp_dynamic_cast<
const DPV>(adjoint_integrator_->getX());
466 RCP<const DMVPV> mvpv = rcp_dynamic_cast<
const DMVPV>(pv->getVectorBlock(0));
470 template <
class Scalar>
475 using Teuchos::rcp_dynamic_cast;
479 rcp_dynamic_cast<
const DPV>(adjoint_integrator_->getXDot());
480 RCP<const DMVPV> mvpv = rcp_dynamic_cast<
const DMVPV>(pv->getVectorBlock(0));
484 template <
class Scalar>
489 using Teuchos::rcp_dynamic_cast;
493 rcp_dynamic_cast<
const DPV>(adjoint_integrator_->getXDotDot());
494 RCP<const DMVPV> mvpv = rcp_dynamic_cast<
const DMVPV>(pv->getVectorBlock(0));
498 template <
class Scalar>
505 template <
class Scalar>
508 std::string name =
"Tempus::IntegratorAdjointSensitivity";
512 template <
class Scalar>
516 auto l_out = Teuchos::fancyOStream(out.
getOStream());
518 l_out->setOutputToRootOnly(0);
520 *l_out << description() <<
"::describe" << std::endl;
521 state_integrator_->describe(*l_out, verbLevel);
522 adjoint_integrator_->describe(*l_out, verbLevel);
525 template <
class Scalar>
531 template <
class Scalar>
542 RCP<ParameterList> spl = Teuchos::parameterList();
543 if (inputPL != Teuchos::null) {
544 *spl = inputPL->
sublist(
"Sensitivities");
546 if (spl->isParameter(
"Response Depends on Parameters"))
547 spl->
remove(
"Response Depends on Parameters");
548 if (spl->isParameter(
"Residual Depends on Parameters"))
549 spl->remove(
"Residual Depends on Parameters");
550 if (spl->isParameter(
"IC Depends on Parameters"))
551 spl->remove(
"IC Depends on Parameters");
553 const Scalar tinit = state_integrator_->getTimeStepControl()->getInitTime();
554 const Scalar tfinal = state_integrator_->getTimeStepControl()->getFinalTime();
556 model, adjoint_model, tinit, tfinal, spl));
559 template <
class Scalar>
567 using Teuchos::rcp_dynamic_cast;
569 using Thyra::createMembers;
571 using Thyra::multiVectorProductVector;
577 RCP<const VectorSpaceBase<Scalar>> x_space = model_->get_x_space();
578 RCP<const VectorSpaceBase<Scalar>> adjoint_space =
579 rcp_dynamic_cast<
const DPVS>(adjoint_aux_model_->get_x_space())
583 spaces[1] = adjoint_space;
584 RCP<const DPVS> prod_space = Thyra::productVectorSpace(spaces());
586 int num_states = state_solution_history->getNumStates();
587 const Scalar t_init = state_integrator_->getTimeStepControl()->getInitTime();
588 const Scalar t_final = state_integrator_->getTime();
589 for (
int i = 0; i < num_states; ++i) {
590 RCP<const SolutionState<Scalar>> forward_state =
591 (*state_solution_history)[i];
592 RCP<const SolutionState<Scalar>> adjoint_state =
593 adjoint_solution_history->findState(t_final + t_init -
594 forward_state->getTime());
597 RCP<DPV> x = Thyra::defaultProductVector(prod_space);
598 RCP<const VectorBase<Scalar>> adjoint_x =
599 rcp_dynamic_cast<
const DPV>(adjoint_state->getX())->getVectorBlock(0);
600 assign(x->getNonconstVectorBlock(0).ptr(), *(forward_state->getX()));
601 assign(x->getNonconstVectorBlock(1).ptr(), *(adjoint_x));
602 RCP<VectorBase<Scalar>> x_b = x;
605 RCP<DPV> x_dot = Thyra::defaultProductVector(prod_space);
606 RCP<const VectorBase<Scalar>> adjoint_x_dot =
607 rcp_dynamic_cast<
const DPV>(adjoint_state->getXDot())
609 assign(x_dot->getNonconstVectorBlock(0).ptr(), *(forward_state->getXDot()));
610 assign(x_dot->getNonconstVectorBlock(1).ptr(), *(adjoint_x_dot));
611 RCP<VectorBase<Scalar>> x_dot_b = x_dot;
615 if (forward_state->getXDotDot() != Teuchos::null) {
616 x_dot_dot = Thyra::defaultProductVector(prod_space);
617 RCP<const VectorBase<Scalar>> adjoint_x_dot_dot =
618 rcp_dynamic_cast<
const DPV>(adjoint_state->getXDotDot())
620 assign(x_dot_dot->getNonconstVectorBlock(0).ptr(),
621 *(forward_state->getXDotDot()));
622 assign(x_dot_dot->getNonconstVectorBlock(1).ptr(), *(adjoint_x_dot_dot));
624 RCP<VectorBase<Scalar>> x_dot_dot_b = x_dot_dot;
626 RCP<SolutionState<Scalar>> prod_state = forward_state->clone();
627 prod_state->setX(x_b);
628 prod_state->setXDot(x_dot_b);
629 prod_state->setXDotDot(x_dot_dot_b);
630 prod_state->setPhysicsState(Teuchos::null);
631 solutionHistory_->addState(prod_state);
636 template <
class Scalar>
645 if (inputPL != Teuchos::null) *spl = inputPL->
sublist(
"Sensitivities");
647 int p_index = spl->
get<
int>(
"Sensitivity Parameter Index", 0);
648 int g_index = spl->
get<
int>(
"Response Function Index", 0);
649 bool g_depends_on_p = spl->
get<
bool>(
"Response Depends on Parameters",
true);
650 bool f_depends_on_p = spl->
get<
bool>(
"Residual Depends on Parameters",
true);
651 bool ic_depends_on_p = spl->
get<
bool>(
"IC Depends on Parameters",
true);
652 bool mass_matrix_is_identity =
653 spl->
get<
bool>(
"Mass Matrix Is Identity",
false);
655 auto state_integrator = createIntegratorBasic<Scalar>(inputPL, model);
658 if (spl->
isParameter(
"Response Depends on Parameters"))
659 spl->
remove(
"Response Depends on Parameters");
660 if (spl->
isParameter(
"Residual Depends on Parameters"))
661 spl->
remove(
"Residual Depends on Parameters");
663 spl->
remove(
"IC Depends on Parameters");
665 const Scalar tinit = state_integrator->getTimeStepControl()->getInitTime();
666 const Scalar tfinal = state_integrator->getTimeStepControl()->getFinalTime();
672 if (adjoint_model == Teuchos::null)
675 auto adjoint_aux_model =
677 model, adjt_model, tinit, tfinal, spl));
681 auto integrator_name = inputPL->get<std::string>(
"Integrator Name");
682 auto integratorPL = Teuchos::sublist(inputPL, integrator_name,
true);
683 auto shPL = Teuchos::sublist(integratorPL,
"Solution History",
true);
684 auto combined_solution_History = createSolutionHistoryPL<Scalar>(shPL);
686 auto adjoint_integrator =
687 createIntegratorBasic<Scalar>(inputPL, adjoint_aux_model);
691 model, state_integrator, adjt_model, adjoint_aux_model,
692 adjoint_integrator, combined_solution_History, p_index, g_index,
693 g_depends_on_p, f_depends_on_p, ic_depends_on_p,
694 mass_matrix_is_identity));
700 template <
class Scalar>
710 #endif // Tempus_IntegratorAdjointSensitivity_impl_hpp
void describe(Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel) const override
virtual Teuchos::RCP< const Thyra::MultiVectorBase< Scalar > > getYDot() const
Get the current time derivative of the adjoint solution, ydot.
SensitivityStepMode getStepMode() const
What mode the current time integration step is in.
virtual Teuchos::RCP< TimeStepControl< Scalar > > getNonConstTimeStepControl() override
virtual void setObserver(Teuchos::RCP< IntegratorObserver< Scalar >> obs=Teuchos::null)
Set the Observer.
T & get(const std::string &name, T def_value)
virtual Teuchos::RCP< const Thyra::VectorBase< Scalar > > getXDotDot() const
Get the current second time derivative of the solution, xdotdot.
virtual void setStatus(const Status st) override
Set Status.
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
void buildSolutionHistory(const Teuchos::RCP< const SolutionHistory< Scalar >> &state_solution_history, const Teuchos::RCP< const SolutionHistory< Scalar >> &adjoint_solution_history)
virtual Teuchos::RCP< SolutionHistory< Scalar > > getNonConstSolutionHistory() override
Get the SolutionHistory.
ModelEvaluator for forming adjoint sensitivity equations.
virtual Teuchos::RCP< const Thyra::VectorBase< Scalar > > getXDot() const
Get the current time derivative of the solution, xdot.
virtual Teuchos::RCP< IntegratorObserver< Scalar > > getObserver()
Get the Observer.
virtual Teuchos::RCP< const Thyra::VectorBase< Scalar > > getX() const
Get the current solution, x.
bool isParameter(const std::string &name) const
bool remove(std::string const &name, bool throwIfNotExists=true)
Teuchos::RCP< IntegratorAdjointSensitivity< Scalar > > createIntegratorAdjointSensitivity(Teuchos::RCP< Teuchos::ParameterList > pList, const Teuchos::RCP< Thyra::ModelEvaluator< Scalar >> &model, const Teuchos::RCP< Thyra::ModelEvaluator< Scalar >> &adjoint_model=Teuchos::null)
Nonmember constructor.
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
std::string description() const override
virtual Teuchos::RCP< const SolutionHistory< Scalar > > getSolutionHistory() const override
Get the SolutionHistory.
Status
Status for the Integrator, the Stepper and the SolutionState.
IntegratorObserver class for time integrators.
virtual Teuchos::RCP< const Thyra::MultiVectorBase< Scalar > > getYDotDot() const
Get the current second time derivative of the adjoint solution, ydotdot.
Teuchos::RCP< AdjointAuxSensitivityModelEvaluator< Scalar > > createAdjointModel(const Teuchos::RCP< Thyra::ModelEvaluator< Scalar >> &model, const Teuchos::RCP< Thyra::ModelEvaluator< Scalar >> &adjoint_model, const Teuchos::RCP< Teuchos::ParameterList > &inputPL)
virtual Teuchos::RCP< const TimeStepControl< Scalar > > getTimeStepControl() const override
Get the TimeStepControl.
RCP< const MultiVectorBase< Scalar > > getMultiVector() const
SolutionHistory is basically a container of SolutionStates. SolutionHistory maintains a collection of...
virtual bool advanceTime()
Advance the solution to timeMax, and return true if successful.
Teuchos::RCP< TimeStepControl< Scalar > > getSensNonConstTimeStepControl()
Teuchos::RCP< const SolutionHistory< Scalar > > getSensSolutionHistory() const
virtual Teuchos::RCP< const Thyra::MultiVectorBase< Scalar > > getY() const
Get the current adjoint solution, y.
virtual void initializeSolutionHistory(Scalar t0, Teuchos::RCP< const Thyra::VectorBase< Scalar >> x0, Teuchos::RCP< const Thyra::VectorBase< Scalar >> xdot0=Teuchos::null, Teuchos::RCP< const Thyra::VectorBase< Scalar >> xdotdot0=Teuchos::null, Teuchos::RCP< const Thyra::MultiVectorBase< Scalar >> DxDp0=Teuchos::null, Teuchos::RCP< const Thyra::MultiVectorBase< Scalar >> DxdotDp0=Teuchos::null, Teuchos::RCP< const Thyra::MultiVectorBase< Scalar >> DxdotdotDp0=Teuchos::null)
Set the initial state from Thyra::VectorBase(s)
Teuchos::RCP< const SolutionHistory< Scalar > > getStateSolutionHistory() const
RCP< ImplicitAdjointModelEvaluator< Scalar > > implicitAdjointModelEvaluator(const RCP< const ModelEvaluator< Scalar > > &model)
RCP< std::basic_ostream< char_type, traits_type > > getOStream()
Time integrator suitable for adjoint sensitivity analysis.
virtual int getIndex() const override
Get current index.
Teuchos::RCP< TimeStepControl< Scalar > > getStateNonConstTimeStepControl()
ParameterList & sublist(const std::string &name, bool mustAlreadyExist=false, const std::string &docString="")
virtual Scalar getTime() const override
Get current time.
virtual Status getStatus() const override
Get Status.
virtual void initialize()
Initializes the Integrator after set* function calls.
virtual Teuchos::RCP< Stepper< Scalar > > getStepper() const override
Get the Stepper.
virtual Teuchos::RCP< const Thyra::MultiVectorBase< Scalar > > getDgDp() const
Return adjoint sensitivity stored in gradient format.
IntegratorAdjointSensitivity()
Constructor that requires a subsequent setParameterList, setStepper, and initialize calls...