[petsc-dev] TSComputeIJacobian() no IJacobian function provided and no IMEX slow?

Barry Smith bsmith at mcs.anl.gov
Mon Aug 26 07:06:06 CDT 2013


On Aug 25, 2013, at 11:32 PM, Jed Brown <jedbrown at mcs.anl.gov> wrote:

> Barry Smith <bsmith at mcs.anl.gov> writes:
>> Not that axpy is DIFFERENT_NONZERO_PATTERN which means a very slow
>> MatAXPY(). If I understand things correctly after the first time
>> through here *A will have a nonzero pattern at least as big as Arhs?
> 
> Yes, but what happens when Arhs is reassembled with a different nonzero
> pattern?

PetscErrorCode (*TSRHSJacobian)(TS,PetscReal,Vec,Mat*,Mat*,MatStructure*,void*);

Which is available as flg2 in TSComputeIJacobian()  So the only thing missing is know that this is a repeat call to 


> 
>> If so how can the code be organized so that slow MatAXPY() is not used
>> for an eternity and switches to using subset for much faster
>> performance?
> 
> We just need a reliable way to know when the nonzero pattern of Arhs
> changes.




More information about the petsc-dev mailing list