[petsc-users] Newton methods that converge all the time

Buesing, Henrik hbuesing at eonerc.rwth-aachen.de
Fri Dec 1 03:24:09 CST 2017


> >
> >    Please describe in some detail how you are handling phase change.
> > If you have if () tests of any sort in your FormFunction() or
> > FormJacobian() this can kill Newton's method. If you are using
> > "variable switching" this WILL kill Newtons' method. Are you monkeying
> > with phase definitions in TSPostStep or with
> > SNESLineSearchSetPostCheck(). This will also kill Newton's method.
> 
> I'm doing variable switching (in a geothermal flow application) with
> Newton's method (in SNESLineSearchSetPostCheck()) and it generally works
> fine.
> 
> For pure water (no other components present) my variables are pressure
> and temperature for single-phase (liquid or vapour) and pressure and
> vapour saturation for two-phase.
> 
> You have to be pretty careful how you do the switching though.

The beauty of the pressure-enthalpy formulation is that you do not need to initialize the saturations with small epsilon when you go into two-phase. You can directly compute a correct enthalpy (and from it a saturation) and "jump" into the two-phase region. 
Anyhow, no one says that you are not jumping in and out of the two-phase region. Consequently, there are examples for which either method works best. 

I am trying to simulate a supercritical reservoir (T>450 °C, p>35 MPa) from surface down to 3.5 km depth. (It is in Italy so geothermal gradient is large). 

There is a steam region, which forms and either I get osciallations in enthalpy (saturations) or small time-steps kill me. I want to simulate a quasi steady-state after 1 million years. 

Henrik


> 
> - Adrian
> --
> Dr Adrian Croucher
> Senior Research Fellow
> Department of Engineering Science
> University of Auckland, New Zealand
> email: a.croucher at auckland.ac.nz
> tel: +64 (0)9 923 4611


More information about the petsc-users mailing list