Timestepping

Fourth-order LSERK

class hedge.timestep.rk4.RK4TimeStepper(*args, **kwargs)
__call__(y, t, dt, rhs)
__init__(*args, **kwargs)

Adams-Bashforth

hedge.timestep.ab.make_generic_ab_coefficients(levels, int_start, tap)

Find coefficients (αᵢ) such that ∑ᵢ αᵢ F(tᵢ) = ∫[int_start..tap] f(t) dt.

hedge.timestep.ab.make_ab_coefficients(order)
class hedge.timestep.ab.AdamsBashforthTimeStepper(order, startup_stepper=None, dtype=<type 'numpy.float64'>, rcon=None)
__call__(y, t, dt, rhs)
__init__(order, startup_stepper=None, dtype=<type 'numpy.float64'>, rcon=None)

Multirate Adams-Bashforth

class hedge.timestep.multirate_ab.TwoRateAdamsBashforthTimeStepper(method, large_dt, substep_count, order, order_f2f=None, order_s2f=None, order_f2s=None, order_s2s=None, startup_stepper=None)

Simultaneously timesteps two parts of an ODE system, the first with a small timestep, the second with a large timestep.

[1] C.W. Gear and D.R. Wells, “Multirate linear multistep methods,” BIT Numerical Mathematics, vol. 24, Dec. 1984, pg. 484-502.

__call__(ys, t, rhss)
Parameters:rhss – Matrix of right-hand sides, stored in row-major order, i.e. [f2f, s2f, f2s, s2s].
__init__(method, large_dt, substep_count, order, order_f2f=None, order_s2f=None, order_f2s=None, order_s2s=None, startup_stepper=None)