solprop.stepper.low_storage#

The low-storage interaction-picture Runge-Kutta march as a run’s integrator (SEP 24).

A third integrator beside solprop.stepper.multistep.Multistep and solprop.stepper.runge_kutta.RungeKutta: the classical fourth-order Runge-Kutta method in the interaction picture anchored at the step’s midpoint, Lawson’s transformation [1] in Hult’s arrangement [2] (RK4IP). It replays a prescribed FixedSchedule and holds three field-sized registers beside the source pipeline’s scratch: the state, overwritten in place by its interaction-picture image and then by the accepted step, one accumulator and one stage register. It has no embedded error estimate; its accuracy is calibrated from outside, on the measured observable, by calibrate() (docs/guide/numerics/fixed-schedules.md).

This module holds the specification a run carries. The march and its register passes are in solprop.backends.low_storage.

References#

[1]

J. D. Lawson, “Generalized Runge-Kutta processes for stable systems with large Lipschitz constants”, SIAM Journal on Numerical Analysis 4, 372 (1967). doi:10.1137/0704033

[2]

J. Hult, “A fourth-order Runge-Kutta in the interaction picture method for simulating supercontinuum generation in optical fibers”, J. Lightwave Technol. 25, 3770 (2007). doi:10.1109/JLT.2007.909373

Module Attributes

LowStorageScheme

The register schemes LowStorageRungeKutta steps with.

LOW_STORAGE_REAL_INTERVAL

Negative-real-axis stability interval of classical RK4, rounded down.

Classes

LowStorageRungeKutta([scheme])

RK4 in the midpoint interaction picture, replaying a schedule in three registers.

solprop.stepper.low_storage.LOW_STORAGE_REAL_INTERVAL = 2.785#

Negative-real-axis stability interval of classical RK4, rounded down.

RK4’s stability function is R(x) = 1 + x + x**2/2 + x**3/6 + x**4/24; on the negative real axis |R(x)| <= 1 for x >= -2.7853 (the root of |R| = 1), so a damping rate integrated explicitly – the in-stage collars, plasma loss – must keep h alpha_max / 2 at most 2.785, against 3.3 for DOPRI5 (solprop.boundaries.STABILITY_RADIUS). Checked against the stability function in tests/stepper/test_low_storage.py.

class solprop.stepper.low_storage.LowStorageRungeKutta(scheme='rk4ip')[source]#

Bases: object

RK4 in the midpoint interaction picture, replaying a schedule in three registers.

The integrator for a fixed-step run whose state is too large for the Runge-Kutta march’s stage rows or the Adams history: a Cartesian free-space grid of gigabytes, an ensemble or a scan on one schedule. Each step makes four source evaluations and accepts its result in place, so the march needs a schedule (FixedSchedule.uniform for plain fixed steps) and records no error estimate: the step history’s norm column is 0.0, meaning “not estimated”. Calibrate the schedule on the observable that matters with calibrate() at order=4 (docs/guide/numerics/choosing-a-stepper.md).

Attributes:
scheme{‘rk4ip’}

The register scheme; "rk4ip", the only one, is Hult’s RK4IP.

Raises:
StepperError

If the scheme is not one of LowStorageScheme.

Examples

>>> from solprop.stepper.low_storage import LowStorageRungeKutta
>>> LowStorageRungeKutta()
LowStorageRungeKutta(scheme='rk4ip')
>>> LowStorageRungeKutta().name, LowStorageRungeKutta().order
('low-storage-rk4ip', 4)
property evaluations: int[source]#

Return the source evaluations a step makes.

Returns:
int

Four: no slope carries over, because the fourth is taken at a predicted state, not at the accepted one.

property name: str[source]#

Return the method’s record name.

Returns:
str

low-storage-<scheme>.

property order: int[source]#

Return the scheme’s classical order, the order to calibrate at.

Returns:
int

Four.

property real_stability_interval: float[source]#

Return the negative-real stability interval for a damping term.

Returns:
float

LOW_STORAGE_REAL_INTERVAL: the largest h |lambda| for a damping rate lambda integrated explicitly.

scheme: Literal['rk4ip'] = 'rk4ip'#
solprop.stepper.low_storage.LowStorageScheme#

The register schemes LowStorageRungeKutta steps with.

"rk4ip" is classical RK4 in the midpoint interaction picture, four source evaluations a step and no estimate (SEP 24 section 4.2).

alias of Literal[‘rk4ip’]