#include "petscts.h" PetscErrorCode TSDiscGradSetFormulation(TS ts, PetscErrorCode (*Sfunc)(TS, PetscReal, Vec, Mat, void *), PetscErrorCode (*Ffunc)(TS, PetscReal, Vec , PetscScalar *, void *), PetscErrorCode (*Gfunc)(TS, PetscReal, Vec, Vec, void *), void *ctx)Not Collective
ts | - timestepping context | |
Sfunc | - constructor for the S matrix from the formulation | |
Ffunc | - functional F from the formulation | |
Gfunc | - constructor for the gradient of F from the formulation Calling sequence of Sfunc: |
PetscErrorCode func(TS ts, PetscReal time, Vec u, Mat S, void *)
PetscErrorCode func(TS ts, PetscReal time, Vec u, PetscScalar *F, void *)
PetscErrorCode func(TS ts, PetscReal time, Vec u, Vec G, void *)