Lorenz 96

class otp.lorenz96.Lorenz96Problem

Bases: otp.Problem

A chaotic system modeling nonlinear transfer of a dimensionless quantity along a cyclic one dimensional domain.

The \(N\) variable dynamics [Lor96] are represented by the equation,

\[ y_i' = -y_{i-1} (y_{i-2} - y_{i+1}) - y_i + f(t), \qquad i = 1, …, N, \]

where \(y_0 = y_N\), \(y_{-1} = y_{N - 1}\), and \(y_{N + 1} = y_2\), exhibits chaotic behavior for certain pairs of values of the dimension \(N\) and forcing function \(f\).

Notes

Type

ODE

Number of Variables

\(N\) for any positive integer four or greater

Stiff

no

Example

>>> problem = otp.lorenz96.presets.Canonical('Forcing', @(t) 8 + 4*sin(t));
>>> sol = problem.solve();
>>> problem.movie(sol);
Constructor Summary
Lorenz96Problem(timeSpan, y0, parameters)

Create a Lorenz ‘96 problem object.

Parameters:
  • timeSpan (numeric(1, 2)) – The start and final time.

  • y0 (numeric(:, 1)) – The initial conditions.

  • parameters (otp.lorenz96.Lorenz96Parameters) – The parameters.

Parameters

class otp.lorenz96.Lorenz96Parameters

Bases: otp.Parameters

Parameters for the Lorenz ‘96 problem.

Constructor Summary
Lorenz96Parameters(varargin)

Create a Lorenz ‘96 parameters object.

Parameters:

varargin – A variable number of name-value pairs. A name can be any property of this class, and the subsequent value initializes that property.

Property Summary
F

A forcing function, scalar, or vector.

Presets

class otp.lorenz96.presets.PopovSandu

Bases: otp.lorenz96.Lorenz96Problem

A preset that has a cyclic forcing function that is different for every variable. This preset was created for [PS19]. This preset uses time span \(t ∈ [0, 720]\), \(N = 40\), and initial conditions of \(y_i = 8\) for all \(i\) except for \(y_{⌊N/2⌋}=8.008\). The forcing as a function of time is given by

\[ f(t) = 8 + 4\cos(2 π ω (t+\text{mod}(i - 1, q)/q)) \]

where by default \(q=4\) is the number of partitions, and \(ω = 1\) is a forcing period of one time unit.

Constructor Summary
PopovSandu(varargin)

Create the Popov–Sandu Lorenz ‘96 problem object.

Parameters:

varargin

A variable number of name-value pairs. The accepted names are

  • N – The size of the problem as a positive integer.

  • Partitions – The number of partitions into which to divide the variables.

  • ForcingPeriod – The period of the forcing function in radians per unit time.

class otp.lorenz96.presets.Canonical

Bases: otp.lorenz96.Lorenz96Problem

Original Lorenz ‘96 preset presented in [Lor96] which uses time span \(t ∈ [0, 720]\), \(N = 40\), \(F=8\), and initial conditions of \(y_i = 8\) for all \(i\) except for \(y_{⌊N/2⌋}=8.008\).

Constructor Summary
Canonical(varargin)

Create the canonical Lorenz ‘96 problem object.

Parameters:

varargin

A variable number of name-value pairs. The accepted names are

  • N – The size of the problem as a positive integer.

  • Forcing – The forcing as a scalar, vector of N constants, or as a function.