[petsc-users] TS question 1: how to stop explicit methods because they do not use SNES(VI)?

Zhang, Hong hongzhang at anl.gov
Tue Feb 14 14:33:03 CST 2017


I think many users (including me) would like to start with academic examples, e.g. u_t=f(u)+g(u), when they try to learn PETSc TS solvers. This simple form allows for easy switch between all kinds of different integration methods.

Experienced users or experts who need to solve DAEs or complicate problems involving nontrivial mass matrix should be encouraged to try IFunction/IJacobian. Of course, we need better documentation to help them realize the switching is not always possible. Personally it took me a long time to get used to the IFunction business since I had been using u_t=f(u)+g(u) for a couple years before I jumped on PETSc. If we add support for this simple form, the learning curve would be less steep than it currently is.

Hong (Mr.)
 
> On Feb 14, 2017, at 11:55 AM, Jed Brown <jed at jedbrown.org> wrote:
> 
> Barry Smith <bsmith at mcs.anl.gov> writes:
>>  Hence my suggestion to have TSSetLeftHandSideFunction() (or Jed's suggestion to have multiple Right Hand side functions) this will allow comparison of implicit, explicit, imex without recompiling (which we don't have currently) for the case with no mass matrix. With a mass matrix, unless we use mass lumping and have a TSSetMassMatrix() you cannot switch to full explicit, but that is due to mathematics, not the interface.
> 
> Who in reality has a problem that looks like
> 
>  u_t = f(u) + g(u) + h(u)
> 
> where it may make sense to move some of this to the left (implicit)?
> I'm concerned that this isn't natural for many applications so adding an
> interface would be solving a problem that doesn't really exist outside
> perhaps a few academic examples.


More information about the petsc-users mailing list