[petsc-users] PetscFV and TS implicit

Thibault Bridel-Bertomeu thibault.bridelbertomeu at gmail.com
Thu Aug 20 06:44:06 CDT 2020

Dear all,

I have a finite volume code inspired from TS example ex11.c (with a riemann
solver, etc...).
So far, I used only explicit time stepping through the TSSSP, and to set
the RHS of my hyperbolic system I used :

TSSetType(ts, TSSSP);
DMTSSetRHSFunctionLocal(dm, DMPlexTSComputeRHSFunctionFVM

after setting the right Riemann solver in the TS associated to the DM.
Now, in some cases where the physics is stationary, I would like to reach
the steady state faster and use an implicit timestepping operator to do so.
After looking through the examples, especially TS examples ex48.c and
ex53.c, I simply tried to set

TSSetType(ts, TSBEULER);
DMTSSetIFunctionLocal(dm, DMPlexTSComputeIFunctionFEM
DMTSSetIJacobianLocal(dm, DMPlexTSComputeIJacobianFEM

instead of the previous calls. It compiles fine, and it runs. However,
nothing happens : it behaves like there is no time evolution at all, the
solution does not change from its initial state.
>From the source code, it is my understanding that the
DMPlexTSComputeIFunctionFEM and DMPlexTSComputeIJacobianFEM methods, in
spite of their names, call respectively DMPlexComputeResidual_Internal and
DMPlexComputeJacobian_Internal that can handle a FVM discretization.

What am I missing ? Are there other steps to take before I can simply try
to run with a finite volume discretization and an implicit time stepping
algorithm ?

Thank you very much for your help in advance !

Thibault Bridel-Bertomeu
Eng, MSc, PhD
Research Engineer
33114 LE BARP
Tel.: (+33)557046924
Mob.: (+33)611025322
Mail: thibault.bridelbertomeu at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20200820/a285f5d7/attachment-0001.html>

More information about the petsc-users mailing list