Skip to content

Evolve: align stepper logic between all ERK implementations

Florian Atteneder requested to merge fa/fix-erk-steppers into main

This assumes that the first row in the a matrix of the Butcher tableau for ERK methods has only zeros, which seems to be the case for the all the methods have atm.


Problem explanation:

So far the LSERK4 and the remaining ERK steppers worked slightly different. The former used for the first substep the initial data array u0, and u! for the remaining steps. That shortcut avoids a copy and appears natural for the LSERK4 algorithm. OTOH, in the ERK stepper we first copy u0 into u!, then accumulate some substep ks into u!, and then call the RHS with u!. (the reason we always copied u0 over was that we did not account for the above assumption on a before)

The problem was now that in the GRHD evolutions we sometimes alter the state vector in the RHS computation. This influenced the results to the extent that we could not run the (newly added) reftest only with the LSERK4 method. What was happening was that when using the ERK method we never altered u0 directly, only u!, whereas u0 was altered in case the GRHD RHS decided to do so on the first step. Subsequent substeps of the ERK method depend upon u0, and so this broke things.

Merge request reports