TSAdjointSolve#

Solves the discrete ajoint problem for an ODE/DAE

Synopsis#

#include <petscts.h>  
PetscErrorCode TSAdjointSolve(TS ts)

Collective `

Input Parameter#

Options Database Key#

  • -ts_adjoint_view_solution - views the first gradient with respect to the initial values

Notes#

This must be called after a call to TSSolve() that solves the forward problem

By default this will integrate back to the initial time, one can use TSAdjointSetSteps() to step back to a later time

See Also#

TS: Scalable ODE and DAE Solvers, TSCreate(), TSSetCostGradients(), TSSetSolution(), TSAdjointStep()

Level#

intermediate

Location#

src/ts/interface/sensitivity/tssen.c

Examples#

src/ts/tutorials/ex23fwdadj.c
src/tao/unconstrained/tutorials/burgers_spectral.c
src/ts/tutorials/ex20adj.c
src/ts/tutorials/ex20opt_p.c
src/ts/tutorials/ex20td.c
src/tao/unconstrained/tutorials/spectraladjointassimilation.c
src/ts/tutorials/ex20opt_ic.c


Index of all Sensitivity routines
Table of Contents for all manual pages
Index of all manual pages