[petsc-dev] Why does TSDefaultComputeJacobianColor exist?

Jed Brown jed at 59A2.org
Thu Apr 15 09:43:36 CDT 2010

And MatFDColoringApplyTS?  It seems to me that TS defines the nonlinear
function and SNES already has the ability to do these things.  I ask
because the DAE variants can't use these, and I'd rather not duplicate
code for IJacobian variants.  The trouble seems to be that the interface
of just passing in a different function to TSSet{RHS,I}Jacobian doesn't
work any more.  SNES has all the necessary information, using an
interface like this seems unnecessary since it seems like all we really
need is to get the MatFDColoring to the SNES.

Note that if the shift is scaled very much differently from the right
hand side, it is conceivable that the SNES operator may have poor
conditioning compared to the RHS, but I think this case will be
overwhelmed by the cases where the SNES operator is better conditioned
(because transient Jacobians usually have better conditioning than
steady-state Jacobians).

Am I missing something?


More information about the petsc-dev mailing list