State-Space Models

To control a system we first need a clean mathematical picture of how it moves. The state-space model is that picture: collect into one vector x(t) everything needed to predict the system's future, and write its evolution as a first-order system of differential equations driven by the control:

\dot{x} = f(x, u, t), \qquad x \in \mathbb{R}^n, \quad u \in \mathbb{R}^m.

The word state is precise: x(t) is a complete summary of the past. Given x(t) and the future controls, the entire future is determined — nothing about the history before t can add anything.

The linear time-invariant case

The workhorse of the whole theory is the linear time-invariant (LTI) model, where f is linear in the state and control and the coefficient matrices do not depend on time:

\dot{x} = A x + B u, \qquad y = C x + D u.

Here x \in \mathbb{R}^n is the state, u \in \mathbb{R}^m the control, and y \in \mathbb{R}^p the output — the part we actually measure. The four matrices each carry one job, and reading Ax as a matrix acting on a vector makes them concrete:

From a high-order ODE to first-order vector form

Most physical laws arrive as a single high-order equation. The headline example is the spring–mass–damper: a mass m on a spring of stiffness k with damping c, pushed by a force F, obeying Newton's second law

m\,\ddot{q} + c\,\dot{q} + k\,q = F.

This is second order, but state space wants first order. The trick is universal: promote each derivative up to one below the highest into its own state variable.

Step 1 — name the states. Let x_1 = q (position) and x_2 = \dot{q} (velocity). The state vector is x = \begin{bmatrix} q \\ \dot{q} \end{bmatrix}, and the control is the force, u = F.

Step 2 — differentiate the definitions. The first row is free, just the definition of x_2:

\dot{x}_1 = \dot{q} = x_2.

Step 3 — use the physics for the last row. Solve Newton's law for the highest derivative \ddot{q} and substitute the state names:

\dot{x}_2 = \ddot{q} = \frac{1}{m}\big(F - c\,\dot{q} - k\,q\big) = -\frac{k}{m}\,x_1 - \frac{c}{m}\,x_2 + \frac{1}{m}\,u.

Step 4 — stack the rows into matrices. The two scalar equations are exactly one matrix equation \dot{x} = Ax + Bu:

\begin{bmatrix} \dot{x}_1 \\ \dot{x}_2 \end{bmatrix} = \underbrace{\begin{bmatrix} 0 & 1 \\ -\dfrac{k}{m} & -\dfrac{c}{m} \end{bmatrix}}_{A} \begin{bmatrix} x_1 \\ x_2 \end{bmatrix} + \underbrace{\begin{bmatrix} 0 \\ \dfrac{1}{m} \end{bmatrix}}_{B} u.

If we only measure position, the output map picks off the first coordinate, y = q = \begin{bmatrix} 1 & 0 \end{bmatrix} x, so C = \begin{bmatrix} 1 & 0 \end{bmatrix} and D = 0. The same recipe turns any order-n scalar ODE into an n-state first-order system — a companion form with 1s on the super-diagonal and the equation's coefficients along the bottom row.

Watch the state evolve

Set the unforced spring–mass–damper going from a stretched, still start (q, \dot{q}) = (2, 0) with m = 1 and u = 0, and trace its trajectory in the phase plane — position across, velocity up. The whole motion is one curve produced by A = \begin{bmatrix} 0 & 1 \\ -k & -c \end{bmatrix}. Add damping c and the curve spirals inward to the origin (energy bleeding away); stiffen the spring k and it winds faster. With c = 0 it closes into a loop — undamped oscillation forever.

Phase space is older than control theory — Poincaré and the dynamicists drew trajectories of planets in it a century earlier. Its modern triumph in engineering, due largely to Rudolf Kálmán around 1960, was the realisation that recasting a tangle of high-order input–output relations as one clean first-order vector equation \dot{x}=Ax+Bu makes the full machinery of eigenvalues and matrices available. Stability, controllability, optimal feedback — every question in this branch becomes a question about the matrix A. That single change of viewpoint is why the rest of this stage is linear algebra.