#include "petscts.h" PetscErrorCode TSSetCostGradients(TS ts,PetscInt numcost,Vec *lambda,Vec *mu)Logically Collective on TS and Vec
ts | - the TS context obtained from TSCreate() | |
lambda | - gradients with respect to the initial condition variables, the dimension and parallel layout of these vectors is the same as the ODE solution vector | |
mu | - gradients with respect to the parameters, the number of entries in these vectors is the same as the number of parameters |
Notes: the entries in these vectors must be correctly initialized with the values lamda_i = df/dy|finaltime mu_i = df/dp|finaltime
Level:beginner
Location:src/ts/interface/ts.c
Index of all TS routines
Table of Contents for all manual pages
Index of all manual pages