# Lorenz system

The Lorenz system is a system of ordinary differential equations first studied by Edward Lorenz and Ellen Fetter. It is notable for having chaotic solutions for certain parameter values and initial conditions. In particular, the Lorenz attractor is a set of chaotic solutions of the Lorenz system. In popular media the 'butterfly effect' stems from the real-world implications of the Lorenz attractor, i.e. that in any physical system, in the absence of perfect knowledge of the initial conditions (even the minuscule disturbance of the air due to a butterfly flapping its wings), our ability to predict its future course will always fail. This underscores that physical systems can be completely deterministic and yet still be inherently unpredictable even in the absence of quantum effects. The shape of the Lorenz attractor itself, when plotted graphically, may also be seen to resemble a butterfly.

## Overview

In 1963, Edward Lorenz, with the help of Ellen Fetter, developed a simplified mathematical model for atmospheric convection. The model is a system of three ordinary differential equations now known as the Lorenz equations:

{\begin{aligned}{\frac {\mathrm {d} x}{\mathrm {d} t}}&=\sigma (y-x),\\[6pt]{\frac {\mathrm {d} y}{\mathrm {d} t}}&=x(\rho -z)-y,\\[6pt]{\frac {\mathrm {d} z}{\mathrm {d} t}}&=xy-\beta z.\end{aligned}}

The equations relate the properties of a two-dimensional fluid layer uniformly warmed from below and cooled from above. In particular, the equations describe the rate of change of three quantities with respect to time: $x$  is proportional to the rate of convection, $y$  to the horizontal temperature variation, and $z$  to the vertical temperature variation. The constants $\sigma$ , $\rho$ , and $\beta$  are system parameters proportional to the Prandtl number, Rayleigh number, and certain physical dimensions of the layer itself.

The Lorenz equations also arise in simplified models for lasers, dynamos, thermosyphons, brushless DC motors, electric circuits, chemical reactions and forward osmosis. The Lorenz equations are also the governing equations in Fourier space for the Malkus waterwheel. The Malkus waterwheel exhibits chaotic motion where instead of spinning in one direction at a constant speed, its rotation will speed up, slow down, stop, change directions, and oscillate back and forth between combinations of such behaviors in an unpredictable manner.

From a technical standpoint, the Lorenz system is nonlinear, non-periodic, three-dimensional and deterministic. The Lorenz equations have been the subject of hundreds of research articles, and at least one book-length study.

## Analysis

One normally assumes that the parameters $\sigma$ , $\rho$ , and $\beta$  are positive. Lorenz used the values $\sigma =10$ , $\beta =8/3$  and $\rho =28$ . The system exhibits chaotic behavior for these (and nearby) values.

If $\rho <1$  then there is only one equilibrium point, which is at the origin. This point corresponds to no convection. All orbits converge to the origin, which is a global attractor, when $\rho <1$ .

A pitchfork bifurcation occurs at $\rho =1$ , and for $\rho >1$  two additional critical points appear at: $\left({\sqrt {\beta (\rho -1)}},{\sqrt {\beta (\rho -1)}},\rho -1\right)$  and $\left(-{\sqrt {\beta (\rho -1)}},-{\sqrt {\beta (\rho -1)}},\rho -1\right).$  These correspond to steady convection. This pair of equilibrium points is stable only if

$\rho <\sigma {\frac {\sigma +\beta +3}{\sigma -\beta -1}},$

which can hold only for positive $\rho$  if $\sigma >\beta +1$ . At the critical value, both equilibrium points lose stability through a subcritical Hopf bifurcation.

When $\rho =28$ , $\sigma =10$ , and $\beta =8/3$ , the Lorenz system has chaotic solutions (but not all solutions are chaotic). Almost all initial points will tend to an invariant set – the Lorenz attractor – a strange attractor, a fractal, and a self-excited attractor with respect to all three equilibria. Its Hausdorff dimension is estimated from above by the Lyapunov dimension (Kaplan-Yorke dimension) as 2.06 ± 0.01, and the correlation dimension is estimated to be 2.05 ± 0.01. The exact Lyapunov dimension formula of the global attractor can be found analytically under classical restrictions on the parameters:$3-{\frac {2(\sigma +\beta +1)}{\sigma +1+{\sqrt {(\sigma -1)^{2}+4\sigma \rho }}}}.$

The Lorenz attractor is difficult to analyze, but the action of the differential equation on the attractor is described by a fairly simple geometric model. Proving that this is indeed the case is the fourteenth problem on the list of Smale's problems. This problem was the first one to be resolved, by Warwick Tucker in 2002.

For other values of $\rho$ , the system displays knotted periodic orbits. For example, with $\rho =99.96$  it becomes a T(3,2) torus knot.

Example solutions of the Lorenz system for different values of ρ

ρ = 14, σ = 10, β = 8/3 (Enlarge) ρ = 13, σ = 10, β = 8/3 (Enlarge)

ρ = 15, σ = 10, β = 8/3 (Enlarge) ρ = 28, σ = 10, β = 8/3 (Enlarge)
For small values of ρ, the system is stable and evolves to one of two fixed point attractors. When ρ is larger than 24.74, the fixed points become repulsors and the trajectory is repelled by them in a very complex way.
Sensitive dependence on the initial condition
Time t = 1 (Enlarge) Time t = 2 (Enlarge) Time t = 3 (Enlarge)

These figures — made using ρ = 28, σ = 10 and β = 8/3 — show three time segments of the 3-D evolution of two trajectories (one in blue, the other in yellow) in the Lorenz attractor starting at two initial points that differ only by 10−5 in the x-coordinate. Initially, the two trajectories seem coincident (only the yellow one can be seen, as it is drawn over the blue one) but, after some time, the divergence is obvious.

## Simulations

### MATLAB simulation

% Solve over time interval [0,100] with initial conditions [1,1,1]
% ''f'' is set of differential equations
% ''a'' is array containing x, y, and z variables
% ''t'' is time variable

sigma = 10;
beta = 8/3;
rho = 28;
f = @(t,a) [-sigma*a(1) + sigma*a(2); rho*a(1) - a(2) - a(1)*a(3); -beta*a(3) + a(1)*a(2)];
[t,a] = ode45(f,[0 100],[1 1 1]);     % Runge-Kutta 4th/5th order ODE solver
plot3(a(:,1),a(:,2),a(:,3))


### Mathematica simulation

Standard way:

tend = 50;
eq = {x'[t] == σ (y[t] - x[t]),
y'[t] == x[t] (ρ - z[t]) - y[t],
z'[t] == x[t] y[t] - β z[t]};
init = {x == 10, y == 10, z == 10};
pars = {σ->10, ρ->28, β->8/3};
{xs, ys, zs} =
NDSolveValue[{eq /. pars, init}, {x, y, z}, {t, 0, tend}];
ParametricPlot3D[{xs[t], ys[t], zs[t]}, {t, 0, tend}]


Less verbose:

lorenz = NonlinearStateSpaceModel[{{σ (y - x), x (ρ - z) - y, x y - β z}, {}}, {x, y, z}, {σ, ρ, β}];
soln[t_] = StateResponse[{lorenz, {10, 10, 10}}, {10, 28, 8/3}, {t, 0, 50}];
ParametricPlot3D[soln[t], {t, 0, 50}]


Dynamically interactive solution:

eqs = {
x'[t] == σ (y[t] - x[t]), y'[t] == x[t] (ρ - z[t]) - y[t], z'[t] == x[t] y[t] - β z[t],
x == 10, y == 10, z == 10
};
tmax = 50;
sol = ParametricNDSolveValue[eqs, Function[t, {x[t], y[t], z[t]}], {t, 0, tmax}, {σ, ρ, β}];
Manipulate[
fun = sol[σ, ρ, β];
plot = ParametricPlot3D[fun[t], {t, 0, tmax}, PlotRange -> All, PerformanceGoal -> "Quality"];
Animate[
Show[plot, Graphics3D[{PointSize[0.05], Red, Point[fun[t]]}]],
{t, 0, tmax}, AnimationRunning -> True, AnimationRate -> 1
],
{{σ, 10}, 0, 100}, {{ρ, 28}, 0, 100}, {{β, 8/3}, 0, 100},
TrackedSymbols :> {σ, ρ, β}
]


### Python simulation

import numpy as np
import matplotlib.pyplot as plt
from scipy.integrate import odeint
from mpl_toolkits.mplot3d import Axes3D

rho = 28.0
sigma = 10.0
beta = 8.0 / 3.0

def f(state, t):
x, y, z = state  # Unpack the state vector
return sigma * (y - x), x * (rho - z) - y, x * y - beta * z  # Derivatives

state0 = [1.0, 1.0, 1.0]
t = np.arange(0.0, 40.0, 0.01)

states = odeint(f, state0, t)

fig = plt.figure()
ax = fig.gca(projection="3d")
ax.plot(states[:, 0], states[:, 1], states[:, 2])
plt.draw()
plt.show()


### Modelica simulation

model LorenzSystem

parameter Real sigma = 10;
parameter Real rho = 28;
parameter Real beta = 8/3;

parameter Real x_start = 1 "Initial x-coordinate";
parameter Real y_start = 1 "Initial y-coordinate";
parameter Real z_start = 1 "Initial z-coordinate";

Real x "x-coordinate";
Real y "y-coordinate";
Real z "z-coordinate";

initial equation
x = x_start;
y = y_start;
z = z_start;

equation

der(x) = sigma*(y-x);
der(y) = rho*x - y - x*z;
der(z) = x*y - beta*z;

end LorenzSystem;


### Julia simulation

using DifferentialEquations, ParameterizedFunctions, Plots

lorenz = @ode_def begin                  # define the system
dx = σ * (y - x)
dy = x * (ρ - z) - y
dz = x * y - β*z
end σ ρ β

u0 = [1.0,0.0,0.0]                       # initial conditions
tspan = (0.0,100.0)                      # timespan
p = [10.0,28.0,8/3]                      # parameters
prob = ODEProblem(lorenz, u0, tspan, p)  # define the problem
sol = solve(prob)                        # solve it
plot(sol, vars = (1, 2, 3))              # plot solution in phase space - variables ordered with 1 based indexing


### Maxima simulation

load(dynamics)$load(draw)$

/* System parameters */
a: 10; b: 8/3; r: 28;

lorenzSystem: [a*(y-x), -x*z+r*x-y, x*y-b*z];
dependentVariables: [x, y, z]$initialValues: [1, 1, 1]$
timeRange: [t, 0, 50, 0.01]$/* solution via 4th order Runge-Kutta method */ systemSolution: rk(lorenzSystem, dependentVariables, initialValues, timeRange)$
solutionPoints: map(lambda([x], rest(x)), systemSolution)\$

draw3d(point_type=none, points_joined=true, color=blue,
xlabel="x(t)", ylabel="y(t)", zlabel="z(t)",
points(solutionPoints));


## Derivation of the Lorenz equations as a model for atmospheric convection

The Lorenz equations are derived from the Oberbeck–Boussinesq approximation to the equations describing fluid circulation in a shallow layer of fluid, heated uniformly from below and cooled uniformly from above. This fluid circulation is known as Rayleigh–Bénard convection. The fluid is assumed to circulate in two dimensions (vertical and horizontal) with periodic rectangular boundary conditions.

The partial differential equations modeling the system's stream function and temperature are subjected to a spectral Galerkin approximation: the hydrodynamic fields are expanded in Fourier series, which are then severely truncated to a single term for the stream function and two terms for the temperature. This reduces the model equations to a set of three coupled, nonlinear ordinary differential equations. A detailed derivation may be found, for example, in nonlinear dynamics texts. The Lorenz system is a reduced version of a larger system studied earlier by Barry Saltzman.

## Resolution of Smale's 14th problem

Smale's 14th problem says 'Do the properties of the Lorenz attractor exhibit that of a strange attractor?', it was answered affirmatively by Warwick Tucker in 2002. To prove this result, Tucker used rigorous numerics methods like interval arithmetic and normal forms. First, Tucker defined a cross section $\Sigma \subset \{x_{3}=r-1\}$  that is cut transversely by the flow trajectories. From this, one can define the first-return map $P$ , which assigns to each $x\in \Sigma$  the point $P(x)$  where the trajectory of $x$  first intersects $\Sigma$ .

Then the proof is split in three main points that are proved and imply the existence of a strange attractor. The three points are:

• There exists a region $N\subset \Sigma$  invariant under the first-return map, meaning $P(N)\subset N$
• The return map admits a forward invariant cone field
• Vectors inside this invariant cone field are uniformly expanded by the derivative $DP$  of the return map.

To prove the first point, we notice that the cross section $\Sigma$  is cut by two arcs formed by $P(\Sigma )$  (see ). Tucker covers the location of these two arcs by small rectangles $R_{i}$ , the union of these rectangles gives $N$ . Now, the goal is to prove that for all points in $N$ , the flow will bring back the points in $\Sigma$ , in $N$ . To do that, we take a plan $\Sigma '$  below $\Sigma$  at a distance $h$  small, then by taking the center $c_{i}$  of $R_{i}$  and using Euler integration method, one can estimate where the flow will bring $c_{i}$  in $\Sigma '$  which gives us a new point $c_{i}'$ . Then, one can estimate where the points in $\Sigma$  will be mapped in $\Sigma '$  using Taylor expansion, this gives us a new rectangle $R_{i}'$  centered on $c_{i}$ . Thus we know that all points in $R_{i}$  will be mapped in $R_{i}'$ . The goal is to do this method recursively until the flow comes back to $\Sigma$  and we obtain a rectangle $Rf_{i}$  in $\Sigma$  such that we know that $P(R_{i})\subset Rf_{i}$ . The problem is that our estimation may become imprecise after several iterations, thus what Tucker does is to split $R_{i}'$  into smaller rectangles $R_{i,j}$  and then apply the process recursively. Another problem is that as we are applying this algorithm, the flow becomes more 'horizontal' (see ), leading to a dramatic increase in imprecision. To prevent this, the algorithm changes the orientation of the cross sections, becoming either horizontal or vertical.

## Contributions

Lorenz acknowledges the contributions from Ellen Fetter in his paper, who is responsible for the numerical simulations and figures. Also, Margaret Hamilton helped in the initial, numerical computations leading up to the findings of the Lorenz model.