petsc-3.5.4 2015-05-23
Report Typos and Errors

TSSetRHSJacobian

Sets the function to compute the Jacobian of F, where U_t = G(U,t), as well as the location to store the matrix.

Synopsis

#include "petscts.h"  
PetscErrorCode  TSSetRHSJacobian(TS ts,Mat Amat,Mat Pmat,TSRHSJacobian f,void *ctx)
Logically Collective on TS

Input Parameters

ts - the TS context obtained from TSCreate()
Amat - (approximate) Jacobian matrix
Pmat - matrix from which preconditioner is to be constructed (usually the same as Amat)
f - the Jacobian evaluation routine
ctx - [optional] user-defined context for private data for the Jacobian evaluation routine (may be NULL)

Calling sequence of func

    func (TS ts,PetscReal t,Vec u,Mat A,Mat B,void *ctx);

t - current timestep
u - input vector
Amat - (approximate) Jacobian matrix
Pmat - matrix from which preconditioner is to be constructed (usually the same as Amat)
ctx - [optional] user-defined context for matrix evaluation routine

Keywords

TS, timestep, set, right-hand-side, Jacobian

See Also

SNESComputeJacobianDefaultColor(), TSSetRHSFunction(), TSRHSJacobianSetReuse(), TSSetIJacobian()

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

Examples

src/ts/examples/tutorials/ex1.c.html
src/ts/examples/tutorials/ex2.c.html
src/ts/examples/tutorials/ex3.c.html
src/ts/examples/tutorials/ex4.c.html
src/ts/examples/tutorials/ex5.c.html
src/ts/examples/tutorials/ex6.c.html
src/ts/examples/tutorials/ex13.c.html
src/ts/examples/tutorials/ex21.c.html
src/ts/examples/tutorials/ex1f.F.html
src/ts/examples/tutorials/ex2f.F.html