zoomy_core.symsolver.discretization.time

zoomy_core.symsolver.discretization.time#

Time discretization of the solver templates: the SSP-RK stages, the IMEX Runge-Kutta tableaux and the CFL step size.

Module Contents#

Classes#

Imex

How a step treats the SystemModel’s implicit slots: lie splits them off after the SSP-RK step (first order), ssp2 solves the implicit source in every stage of IMEX-SSP2(2,2,2).

CflWaveSpeed

Where the CFL step takes its wave speeds.

ImexTableau

Double Butcher tableau: explicit (At, wt, ct) and diagonally implicit (A, w, c).

Functions#

cfl_dt

CFL step cfl * 2 r_f / (d |lambda|_f), min over faces, from the wave speeds of the cell states of each face and capped by dt_max.

cell_wavespeed

Max |eigenvalue| per face over the cell states of its two cells.

face_dt

The CFL step from the face wave speeds speed, capped by dt_max.

step_size

Adaptive CFL step, or a constant step that warns when above it.

face_rule

dt_rule taking the step from the first stage’s face wave speeds (no eigensolve of its own), capped by cap.

checked

dt, warning once if it exceeds the CFL step dt_cfl(); tested every every steps (1: each step, 0: never).

Data#

API#

zoomy_core.symsolver.discretization.time.SSP_RK#

None

class zoomy_core.symsolver.discretization.time.Imex#

Bases: zoomy_core.misc.options.Option

How a step treats the SystemModel’s implicit slots: lie splits them off after the SSP-RK step (first order), ssp2 solves the implicit source in every stage of IMEX-SSP2(2,2,2).

Initialization

Initialize self. See help(type(self)) for accurate signature.

lie#

‘lie’

ssp2#

‘ssp2’

class zoomy_core.symsolver.discretization.time.CflWaveSpeed#

Bases: zoomy_core.misc.options.Option

Where the CFL step takes its wave speeds.

Initialization

Initialize self. See help(type(self)) for accurate signature.

faces#

‘faces’

cells#

‘cells’

class zoomy_core.symsolver.discretization.time.ImexTableau#

Bases: typing.NamedTuple

Double Butcher tableau: explicit (At, wt, ct) and diagonally implicit (A, w, c).

References

  • Pareschi, Russo 2005, https://doi.org/10.1007/s10915-004-4636-4

At: tuple#

None

wt: tuple#

None

ct: tuple#

None

A: tuple#

None

w: tuple#

None

c: tuple#

None

zoomy_core.symsolver.discretization.time.IMEX_RK#

None

zoomy_core.symsolver.discretization.time.cfl_dt(nsm, Q, Qaux, p, mesh, cfl, dimension)#

CFL step cfl * 2 r_f / (d |lambda|_f), min over faces, from the wave speeds of the cell states of each face and capped by dt_max.

References

  • Audusse et al. 2004, https://doi.org/10.1137/S1064827503431090

zoomy_core.symsolver.discretization.time.cell_wavespeed(nsm, Q, Qaux, p, mesh)#

Max |eigenvalue| per face over the cell states of its two cells.

zoomy_core.symsolver.discretization.time.face_dt(nsm, speed, mesh, cfl, dimension)#

The CFL step from the face wave speeds speed, capped by dt_max.

References

  • Audusse et al. 2004, https://doi.org/10.1137/S1064827503431090

zoomy_core.symsolver.discretization.time.step_size(nsm, Q, Qaux, p, mesh, cfl, dimension, dt_constant, time, check_every=10)#

Adaptive CFL step, or a constant step that warns when above it.

zoomy_core.symsolver.discretization.time.face_rule(nsm, mesh, cfl, dimension, dt_constant, time, cap, check_every=10)#

dt_rule taking the step from the first stage’s face wave speeds (no eigensolve of its own), capped by cap.

zoomy_core.symsolver.discretization.time.checked(dt, time, every, dt_cfl)#

dt, warning once if it exceeds the CFL step dt_cfl(); tested every every steps (1: each step, 0: never).