#include "petscts.h" PetscErrorCode TSComputeIJacobianDefaultColor(TS ts,PetscReal t,Vec U,Vec Udot,PetscReal shift,Mat J,Mat B,void *ctx)Collective on SNES
|ts||- the TS context|
|t||- current timestep|
|U||- state vector|
|Udot||- time derivative of state vector|
|shift||- shift to apply, see note below|
|ctx||- an optional user context|
|J||- Jacobian matrix (not altered in this routine)|
|B||- newly computed Jacobian matrix to use with preconditioner (generally the same as J)|
dF/dU + shift*dF/dUdot
Most users should not need to explicitly call this routine, as it is used internally within the nonlinear solvers.
This will first try to get the coloring from the DM. If the DM type has no coloring routine, then it will try to get the coloring from the matrix. This requires that the matrix have nonzero entries precomputed.