[petsc-dev] How come TSBDF has its own flag for turning on adaptivity?

Lisandro Dalcin dalcinl at gmail.com
Wed Apr 19 04:29:27 CDT 2017

On 19 April 2017 at 02:36, Barry Smith <bsmith at mcs.anl.gov> wrote:
>    Lisandro,
>      How come TSBDF has its own flag for turning on adaptivity?

Well, it is there from the time this code was inside PetIGA. I started
BDF following my ALPHA implementations, where the error estimator is
not sharp but approximate (and this strategy was also implemented in

In the case of BDF, the error estimator is sharp (I mean, it is
computed of BDF formulas of lower order), so I think you are right,
there is no point on having this flag.

Finally, I would like to mention that adaptivity with BDF has not been
tested exhaustively by me or my collaborators, so I was not completely
confident to turn it on by default.

Anyway, some day we should also consider defaulting to use adaptivity
in ALPHA and THETA, even if the error estimator is approximate.

> Is there anyway this can be removed so the standard TS flags can be used to control turning on adaptivity for TSBDF?

Yes, the changes should be quite easy to implement.

> Even if TSBDF needs its own custom adapt code that is fine, but it should be able to be turned on (probably should be on by default anyways) without a special switch.

I would like your opinion on code located at TSSetUp_BDF() related to
clipping factors. I'm restricting the high clipping factor to 2.0, as
the default (10.0) is too much in practice, there are theoretical
reasons related to stability (although the value depends on the order
of the BDF), and this factor of 2.0 is used also on Sundials
(regardless of the order). I'm not going to object the default factor
of 10.0, otherwise Jed Brown will get mad and start MOABing me from
the highs of a mountain...

If you are OK with that piece of code, then I can put a PR for your review.

Lisandro Dalcin
Research Scientist
Computer, Electrical and Mathematical Sciences & Engineering (CEMSE)
Extreme Computing Research Center (ECRC)
King Abdullah University of Science and Technology (KAUST)

4700 King Abdullah University of Science and Technology
al-Khawarizmi Bldg (Bldg 1), Office # 0109
Thuwal 23955-6900, Kingdom of Saudi Arabia

Office Phone: +966 12 808-0459

More information about the petsc-dev mailing list