# sfepy.solvers.ts_dg_solvers module

Explicit time stepping solvers for use with DG FEM

class sfepy.solvers.ts_dg_solvers.DGMultiStageTSS(conf, nls=None, context=None, **kwargs)

  Explicit time stepping solver with multistage solve_step method

  Kind: ‘ts.multistaged’

  For common configuration parameters, see `Solver`.

  Specific configuration parameters:

  Parameters:
    t0 float (default: 0.0)

      The initial time.

    t1 float (default: 1.0)

      The final time.

    dt float

      The time step. Used if n_step is not given.

    n_step int (default: 10)

      The number of time steps. Has precedence over dt.

    quasistatic bool (default: False)

      If True, assume a quasistatic time-stepping. Then the non-linear solver is invoked also for the initial time.

    limiters dictionary

      Limiters for DGFields, keys: field name, values: limiter class

  name = 'ts.multistaged'
  output_step_info(ts)
  solve_step(ts, nls, vec, prestep_fun=None, poststep_fun=None, status=None)
  solve_step0(nls, vec0)

class sfepy.solvers.ts_dg_solvers.EulerStepSolver(conf, nls=None, context=None, **kwargs)

  Simple forward euler method

  Kind: ‘ts.euler’

  For common configuration parameters, see `Solver`.

  Specific configuration parameters:

  Parameters:

  name = 'ts.euler'
  solve_step(ts, nls, vec_x0, status=None, prestep_fun=None, poststep_fun=None)

class sfepy.solvers.ts_dg_solvers.RK4StepSolver(conf, nls=None, context=None, **kwargs)

  Classical 4th order Runge-Kutta method, implemetantions is based on [1]

  [1]

  Hesthaven, J. S., & Warburton, T. (2008). Nodal Discontinuous Galerkin Methods. Journal of Physics A: Mathematical and Theoretical (Vol. 54). New York, NY: Springer New York. http://doi.org/10.1007/978-0-387-72067-8, p. 63

  > Kind: ‘ts.runge_kutta_4’

  > For common configuration parameters, see `Solver`.

  > Specific configuration parameters:

  Parameters:

  name = 'ts.runge_kutta_4'
  solve_step(ts, nls, vec_x0, status=None, prestep_fun=None, poststep_fun=None)
  stage_updates = (<function RK4StepSolver.<lambda>>, <function RK4StepSolver.<lambda>>, <function RK4StepSolver.<lambda>>, <function RK4StepSolver.<lambda>>)

class sfepy.solvers.ts_dg_solvers.TVDRK3StepSolver(conf, nls=None, context=None, **kwargs)

  3rd order Total Variation Diminishing Runge-Kutta method based on [1]

  \begin{aligned} \mathbf{p}^{(1)} &= \mathbf{p}^n - \Delta t \bar{\mathcal{L}}(\mathbf{p}^n),\\ \mathbf{\mathbf{p}}^{(2)} &= \frac{3}{4}\mathbf{p}^n +\frac{1}{4}\mathbf{p}^{(1)} - \frac{1}{4}\Delta t \bar{\mathcal{L}}(\mathbf{p}^{(1)}),\\ \mathbf{p}^{(n+1)} &= \frac{1}{3}\mathbf{p}^n +\frac{2}{3}\mathbf{p}^{(2)} - \frac{2}{3}\Delta t \bar{\mathcal{L}}(\mathbf{p}^{(2)}). \end{aligned}

  [1]

  Gottlieb, S., & Shu, C.-W. (2002). Total variation diminishing Runge-Kutta schemes. Mathematics of Computation of the American Mathematical Society, 67(221), 73–85. https://doi.org/10.1090/s0025-5718-98-00913-2

  > Kind: ‘ts.tvd_runge_kutta_3’

  > For common configuration parameters, see `Solver`.

  > Specific configuration parameters:

  Parameters:

  name = 'ts.tvd_runge_kutta_3'
  solve_step(ts, nls, vec_x0, status=None, prestep_fun=None, poststep_fun=None)