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


set a local residual evaluation function


#include "petscdmda.h" 
#include "petscts.h" 
PetscErrorCode DMDATSSetIJacobianLocal(DM dm,DMDATSIJacobianLocal func,void *ctx)
Logically Collective

Input Arguments

dm - DM to associate callback with
func - local residual evaluation
ctx - optional context for local residual evaluation

Calling sequence for func

func(DMDALocalInfo* info,PetscReal t,void* x,void *xdot,Mat J,Mat B,MatStructure *flg,void *ctx);

info - DMDALocalInfo defining the subdomain to evaluate the residual on
t - time at which to evaluate the jacobian
x - array of local state information
xdot - time derivative at this state
J - Jacobian matrix
B - preconditioner matrix; often same as J
flg - flag indicating information about the preconditioner matrix structure (same as flag in KSPSetOperators())
ctx - optional context passed above

See Also

DMTSSetJacobian(), DMDATSSetIFunctionLocal(), DMDASNESSetJacobianLocal()

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