Part 8 · Chapter 27

State-Space Representation of Systems

A transfer function answers only one question — what comes out when something goes in — and answers it only for a system starting from rest; replacing it with a first-order vector equation in the system's internal variables recovers the initial conditions, the internal behaviour, and a description that scales to many inputs and many outputs at once.

Signals and Systems Prof. Mithun Mondal Reading time ≈ 65 min
i What you'll learn
  • The three things the transfer function of Chapters 19 and 25 cannot express — initial conditions, internal variables, and many inputs and outputs at once — and why state space supplies all three.
  • What a state actually is: the smallest set of numbers at time \(t_0\) that, with the future input, determines the future completely.
  • The standard form \(\dot{\mathbf{x}} = A\mathbf{x} + B\mathbf{u}\), \(\mathbf{y} = C\mathbf{x} + D\mathbf{u}\), and its discrete twin with \(\mathbf{x}[n+1]\) on the left.
  • How to build \(A, B, C, D\) from a circuit, from a differential equation in controllable canonical form, and from a difference equation — and how to draw the matching simulation diagram of integrators or delays.
  • The matrix exponential \(e^{At}\), why it solves the state equation, three ways to compute it, and the split of the answer into zero-input and zero-state parts.
  • The bridge back: \(H(s) = C(sI-A)^{-1}B + D\), whose poles are among the eigenvalues of \(A\) — among, not equal to, and the difference is the whole point.
  • Natural modes, diagonalisation, asymptotic versus BIBO stability, and how a system can look perfectly stable at its terminals while a hidden state runs away inside.
Section 27-1

What the Transfer Function Hides

Twenty-six chapters have been built on a single description of a system: a relation between one input and one output. Chapter 7 wrote it as a convolution, Chapter 19 as a transfer function \(H(s)\), Chapter 25 as \(H(z)\). It is a powerful description and it is not a complete one, and three separate cracks in it are worth setting out plainly before the repair is offered.

The first crack is initial conditions. The transfer function is defined as the ratio \(Y(s)/U(s)\) with all initial conditions zero — it is a zero-state description by construction. Chapter 19 had to reach for the unilateral Laplace transform, dragging \(y(0^-)\) and \(\dot y(0^-)\) into the algebra by hand, precisely because \(H(s)\) has no room for them. For a system that starts from a charged capacitor or a spinning flywheel, the transfer function is telling only part of the story.

The second crack is internal behaviour. A transfer function describes the terminals and nothing else. If an amplifier inside a feedback loop is saturating, or a capacitor voltage is exceeding its rating, or an internal signal is growing without bound while the output stays polite, \(H(s)\) will not say so. Section 27-9 constructs a system that is perfectly well behaved at its output while a state inside it grows like \(e^{3t}\).

The third crack is scale. Real systems have several inputs and several outputs. A power converter has a duty ratio and a load current going in, an output voltage and an inductor current coming out. With transfer functions this means a matrix of them, one per input–output pair, each with its own algebra; and a system of \(p\) inputs and \(q\) outputs needs \(pq\) of them, all sharing the same denominator and all recomputed from scratch whenever the plant changes.

State space repairs all three at once, and it does so by a change of viewpoint that is almost embarrassingly simple: instead of one equation of order \(n\), write \(n\) equations of order one.

This is not a new theory. Nothing in this chapter contradicts anything earlier. The transfer function will reappear in Section 27-8 as a quantity computed from the state description, and the impulse response, the modes and the stability conditions will all be recognisable. What changes is that the internal variables are now carried along explicitly instead of being eliminated at the start.
Section 27-2

The Idea of State

Chapter 5 defined a system with memory as one whose output depends on more than the present input. That definition raises a question it does not answer: how much memory, and stored in what? The state is the answer.

🔑
Definition of state
\[ \big\{\mathbf{x}(t_0),\ u(t)\ \text{for}\ t \ge t_0\big\} \;\Longrightarrow\; \mathbf{y}(t)\ \text{for all}\ t \ge t_0 \]

The state at time \(t_0\) is the smallest collection of numbers such that knowing them, together with the input from \(t_0\) onwards, determines the output from \(t_0\) onwards. Everything about the past that still matters is compressed into \(\mathbf{x}(t_0)\); nothing else about the history is needed.

The word smallest is doing real work. A record of the entire past input would certainly determine the future, but it is not a state — it is not minimal, and it is not finite. The state is the minimal sufficient summary, and for a lumped system of order \(n\) it consists of exactly \(n\) numbers.

In physical systems the state variables are almost always the energy-storage variables, and this is a reliable way to find them. A capacitor stores \(\tfrac12 Cv^2\), so its voltage is a state; an inductor stores \(\tfrac12 Li^2\), so its current is a state. A mass stores kinetic energy, so its velocity is a state, and a spring stores potential energy, so its extension is a state. The reason is physical: energy cannot change instantaneously without infinite power, so these variables are continuous, and their values at any instant summarise everything the past has deposited in the system.

Counting them gives the order for free. A circuit with two capacitors and one inductor is third order and needs three state variables; a mass–spring–damper is second order and needs two. That agrees with the order of the differential equation, as it must, and it is often much easier to count storage elements than to derive and inspect the equation.

State is not unique — the number of state variables is. For the circuit of Worked Example 1 the natural choice is \((i_L, v_C)\), but \((i_L,\ i_L + 2v_C)\) works just as well, and so does any other invertible combination. Different choices give different matrices \(A, B, C, D\) describing the identical system. Section 27-9 shows that all such choices are related by a similarity transformation, and that the eigenvalues — the physically meaningful part — survive it unchanged.
Section 27-3

The Standard Form

Collect the \(n\) state variables into a column vector \(\mathbf{x}(t)\), the \(p\) inputs into \(\mathbf{u}(t)\) and the \(q\) outputs into \(\mathbf{y}(t)\). For a linear time-invariant system, the derivative of each state variable is a linear combination of the states and the inputs, and each output is likewise. Writing all of those linear combinations at once gives two matrix equations.

🔑
The continuous-time state-space model
\[ \dot{\mathbf{x}}(t) = A\,\mathbf{x}(t) + B\,\mathbf{u}(t), \qquad \mathbf{y}(t) = C\,\mathbf{x}(t) + D\,\mathbf{u}(t) \]

The first is the state equation, a set of \(n\) coupled first-order differential equations. The second is the output equation, pure algebra with no derivatives in it at all.

The four matrices have fixed sizes and fixed meanings, and it is worth learning them as roles rather than as symbols.

MatrixSizeNameWhat it governs
\(A\)\(n \times n\)System (or state) matrixThe internal dynamics — how the system evolves with no input at all
\(B\)\(n \times p\)Input matrixHow the inputs push on each state variable
\(C\)\(q \times n\)Output matrixWhich combinations of the states are visible at the outputs
\(D\)\(q \times p\)Feedthrough matrixThe instantaneous path from input to output, bypassing the dynamics

Only \(A\) contains the system's natural behaviour; everything else concerns how the world is connected to it. That separation is what makes state space so convenient for design, and it is why Section 27-8 finds the poles inside \(A\) alone.

The matrix \(D\) is non-zero only when a change in the input reaches the output with no delay whatever. For a strictly proper transfer function — one whose numerator degree is less than its denominator degree — \(D\) is zero, and this is the usual case for physical systems, which cannot respond instantaneously. It is non-zero for something like a resistive divider in parallel with a filter, where part of the signal takes a direct path.

The discrete-time form replaces the derivative by a one-step advance, and is otherwise identical.

The discrete-time state-space model
\[ \mathbf{x}[n+1] = A\,\mathbf{x}[n] + B\,\mathbf{u}[n], \qquad \mathbf{y}[n] = C\,\mathbf{x}[n] + D\,\mathbf{u}[n] \]

Here the state has an unusually concrete meaning: it is exactly the contents of the delay registers in an implementation. The state equation says what the registers will hold on the next clock edge, and the output equation says what to present at the terminals now. A digital filter's state vector is, quite literally, its memory.

Section 27-4

Building State Equations

There are two routes into the standard form. The physical route is to pick the energy-storage variables and write one equation per storage element, which is what Worked Example 1 does for a series RLC circuit. The algebraic route starts from a differential equation, and it is worth doing in general because the resulting pattern is used everywhere.

Start with the simplest case, an \(n\)-th order equation with no derivatives of the input:

An \(n\)-th order system, input undifferentiated
\[ y^{(n)} + a_{n-1}y^{(n-1)} + \cdots + a_1\dot y + a_0 y \;=\; u \]

Choose as state variables the output and its first \(n-1\) derivatives: \(x_1 = y\), \(x_2 = \dot y\), up to \(x_n = y^{(n-1)}\). These are called phase variables. Then \(n-1\) of the state equations are free — each state's derivative is simply the next state — and the last one is the original differential equation rearranged for the highest derivative.

The chain of trivial equations, and the one real one
\[ \dot x_1 = x_2, \quad \dot x_2 = x_3, \quad \dots, \quad \dot x_{n-1} = x_n, \qquad \dot x_n = -a_0x_1 - a_1x_2 - \cdots - a_{n-1}x_n + u \]

Assembled into matrices this is the controllable canonical form, sometimes called the phase-variable form. Every row of \(A\) but the last is a shifted 1; the last row carries the coefficients of the differential equation, negated and in reverse order.

🔑
Controllable canonical form
\[ A = \begin{bmatrix} 0 & 1 & 0 & \cdots & 0\\ 0 & 0 & 1 & \cdots & 0\\ \vdots & & & \ddots & \vdots\\ 0 & 0 & 0 & \cdots & 1\\ -a_0 & -a_1 & -a_2 & \cdots & -a_{n-1}\end{bmatrix}, \qquad B = \begin{bmatrix}0\\0\\\vdots\\0\\1\end{bmatrix} \]

The characteristic polynomial of this \(A\) is \(\lambda^n + a_{n-1}\lambda^{n-1} + \cdots + a_0\), the same polynomial as the differential equation's — which is why the form can be written down by inspection, with no algebra at all.

Now allow derivatives of the input on the right-hand side. The naive extension fails immediately: if \(x_1 = y\) then \(\dot x_n\) would contain \(u^{(n-1)}\), and derivatives of the input are not permitted in the standard form. The way round is a device that recurs throughout linear systems — solve an auxiliary problem and then superpose.

Consider

The general single-input single-output case
\[ y^{(n)} + a_{n-1}y^{(n-1)} + \cdots + a_0y \;=\; b_{n-1}u^{(n-1)} + \cdots + b_1\dot u + b_0 u \]

and define an intermediate signal \(w(t)\) that solves the same equation driven by \(u\) alone:

The auxiliary variable
\[ w^{(n)} + a_{n-1}w^{(n-1)} + \cdots + a_0 w \;=\; u \]

Because the system is linear and time-invariant, if \(u\) produces \(w\) then \(\dot u\) produces \(\dot w\), and any linear combination of derivatives of \(u\) produces the same combination of derivatives of \(w\). The right-hand side we actually want is such a combination, so

The output, read off from the auxiliary variable
\[ y \;=\; b_{n-1}w^{(n-1)} + \cdots + b_1\dot w + b_0 w \]

Now take the phase variables of \(w\), namely \(x_i = w^{(i-1)}\). The state equation is exactly the canonical form above, because \(w\) obeys the undifferentiated equation. And the output equation is just the linear combination written out, with no derivatives left in it:

The output matrix carries the numerator
\[ C = \begin{bmatrix} b_0 & b_1 & \cdots & b_{n-1}\end{bmatrix}, \qquad D = 0 \]

The denominator coefficients live in the bottom row of \(A\); the numerator coefficients live in \(C\). Both can be read straight off a transfer function, which makes this the standard way of turning \(H(s)\) into a state model. If the numerator and denominator have the same degree the transfer function is not strictly proper; divide out first to leave a constant plus a strictly proper remainder, and that constant is \(D\).

Section 27-5

Simulation Diagrams

The standard form has a picture, and the picture is close to being a wiring diagram. Every state variable is the output of one integrator; the state equation says what to feed into that integrator, and the output equation says what to tap off. Drawing it makes the roles of the four matrices immediately visible.

B Σ C Σ A D u(t) ẋ(t) x(t) y(t) internal dynamics direct feedthrough
The general state-space model — the loop through \(A\) is the system, everything else is wiring

Note where the feedback is. The only closed loop in the diagram runs from the state, through \(A\), back into the integrator. That loop is the system's own dynamics; \(B\), \(C\) and \(D\) sit outside it. This is the picture behind the claim that the natural behaviour is a property of \(A\) alone.

For the canonical form of the previous section the diagram becomes very concrete. Take the second-order case \(\ddot y + a_1\dot y + a_0 y = b_1\dot u + b_0 u\), with \(x_1 = w\) and \(x_2 = \dot w\). Two integrators in cascade generate \(x_2\) and then \(x_1\); the coefficients \(-a_1\) and \(-a_0\) feed those signals back to the input summer; and \(b_1\), \(b_0\) tap them forward to the output.

Σ b₀ Σ b₁ −a₁ −a₀ u(t) ẋ₂ x₂ x₁ y(t) denominator coefficients feed back · numerator coefficients feed forward
Controllable canonical form for \(\ddot y + a_1\dot y + a_0 y = b_1\dot u + b_0 u\) — one integrator per order

Replace each integrator by a unit delay \(z^{-1}\) and the same diagram becomes the direct-form realisation of a digital filter that Chapter 25 drew from the difference equation. This is not a coincidence or an analogy: the state-space form and the direct forms are the same structure described in two notations, and the state vector is the contents of the delay line.

Why "controllable" canonical. The input enters this structure at a single point, right at the head of the integrator chain, and from there it can reach every state variable in turn. That property — that the input can steer the state anywhere — is what the word controllable means, and Section 27-9 gives the test for it. Its mirror image, the observable canonical form, is the same diagram with the signal flow reversed and the roles of \(B\) and \(C\) exchanged.
Section 27-6

Solving the State Equation: the Matrix Exponential

Everything so far has been description. Now solve \(\dot{\mathbf{x}} = A\mathbf{x} + B\mathbf{u}\) with \(\mathbf{x}(0)\) given.

Begin with the unforced case \(\dot{\mathbf{x}} = A\mathbf{x}\). If \(A\) were a scalar \(a\), the answer would be \(x(t) = e^{at}x(0)\), and the reasonable guess is that the matrix case is the same with a matrix exponential. Define it by the series that defines the scalar one:

The matrix exponential
\[ e^{At} \;=\; I + At + \frac{A^2t^2}{2!} + \frac{A^3t^3}{3!} + \cdots \;=\; \sum_{k=0}^{\infty}\frac{A^kt^k}{k!} \]

The series converges for every square \(A\) and every \(t\), because the factorials outrun the growth of \(\|A^k\|\). Two properties follow directly from it. Setting \(t=0\) leaves \(e^{A\cdot 0} = I\). And differentiating term by term gives

The property that makes it the solution
\[ \frac{d}{dt}e^{At} = A + A^2t + \frac{A^3t^2}{2!} + \cdots = A\left(I + At + \frac{A^2t^2}{2!} + \cdots\right) = A\,e^{At} = e^{At}A \]

So \(\mathbf{x}(t) = e^{At}\mathbf{x}(0)\) satisfies the unforced equation and matches the initial condition, and by uniqueness it is the solution. The matrix \(\Phi(t) = e^{At}\) is called the state transition matrix, because it transports the state from one instant to another: \(\mathbf{x}(t_2) = \Phi(t_2-t_1)\mathbf{x}(t_1)\).

For the forced case use an integrating factor, exactly as for the scalar first-order equation. Multiply through by \(e^{-At}\) and collect:

The integrating-factor derivation
\[ e^{-At}\dot{\mathbf{x}} - e^{-At}A\mathbf{x} = e^{-At}B\mathbf{u} \quad\Longrightarrow\quad \frac{d}{dt}\Big[e^{-At}\mathbf{x}(t)\Big] = e^{-At}B\,\mathbf{u}(t) \]

The left side is an exact derivative because \(\tfrac{d}{dt}e^{-At} = -Ae^{-At}\), by the property just proved. Integrating from \(0\) to \(t\) and multiplying by \(e^{At}\) — which is legitimate since \(e^{At}e^{-At} = I\), so the matrix exponential is always invertible — gives the complete answer.

🔑
The complete state and output response
\[ \mathbf{x}(t) = \underbrace{e^{At}\mathbf{x}(0)}_{\text{zero-input}} + \underbrace{\int_{0}^{t} e^{A(t-\tau)}B\,\mathbf{u}(\tau)\,d\tau}_{\text{zero-state}}, \qquad \mathbf{y}(t) = C\mathbf{x}(t) + D\mathbf{u}(t) \]

The two terms are exactly the decomposition of Chapters 9 and 19. The first depends only on the initial state, the second only on the input, and their sum is the whole response — a consequence of linearity, now visible as two separate terms in one formula.

The zero-state term is a convolution. Reading it against Chapter 7, the kernel \(Ce^{A(t-\tau)}B\) plays the part of \(h(t-\tau)\), so the impulse response of the state-space system is

The impulse response in state-space terms
\[ h(t) \;=\; C\,e^{At}B\,u(t) \;+\; D\,\delta(t) \]

The impulse in \(D\delta(t)\) is the direct feedthrough, and it is present only when \(D \ne 0\) — a further confirmation that \(D\) represents an instantaneous path.

Computing \(e^{At}\) by summing the series is almost never practical. Three better methods are standard. The first, and the one used in the worked examples, transforms the problem: taking the Laplace transform of \(\dot{\mathbf{x}} = A\mathbf{x}\) with initial state \(\mathbf{x}(0)\) gives \(s\mathbf{X}(s) - \mathbf{x}(0) = A\mathbf{X}(s)\), hence \(\mathbf{X}(s) = (sI-A)^{-1}\mathbf{x}(0)\), and comparing with \(\mathbf{x}(t) = e^{At}\mathbf{x}(0)\) identifies the pair.

🔑
The matrix exponential by Laplace transform
\[ e^{At} \;=\; \mathcal{L}^{-1}\Big\{(sI-A)^{-1}\Big\} \]

The matrix \((sI-A)^{-1}\) is called the resolvent. Invert it as a matrix of rational functions, take the inverse Laplace transform of each entry with the partial fractions of Chapter 19, and \(e^{At}\) appears entry by entry.

The second method diagonalises \(A\), and is developed in Section 27-9. The third uses the Cayley–Hamilton theorem — every matrix satisfies its own characteristic equation, so \(A^n\) is a combination of lower powers, so the infinite series collapses to a polynomial of degree \(n-1\) with time-dependent coefficients. For hand computation on second-order problems the Laplace route is usually quickest, and it has the advantage of reusing machinery already built.

Section 27-7

Discrete-Time State Equations

The discrete case needs no calculus at all — just iteration, which is the honest advantage of discrete time noted as far back as Chapter 3. Starting from \(\mathbf{x}[n+1] = A\mathbf{x}[n] + B\mathbf{u}[n]\) and \(\mathbf{x}[0]\), step forward:

Iterating the state recursion
\[ \begin{aligned} \mathbf{x}[1] &= A\mathbf{x}[0] + B\mathbf{u}[0]\\ \mathbf{x}[2] &= A\mathbf{x}[1] + B\mathbf{u}[1] = A^2\mathbf{x}[0] + AB\mathbf{u}[0] + B\mathbf{u}[1]\\ \mathbf{x}[3] &= A^3\mathbf{x}[0] + A^2B\mathbf{u}[0] + AB\mathbf{u}[1] + B\mathbf{u}[2] \end{aligned} \]

The pattern is unmistakable, and an induction on \(n\) confirms it.

🔑
The discrete-time solution
\[ \mathbf{x}[n] = A^{n}\mathbf{x}[0] + \sum_{m=0}^{n-1} A^{\,n-1-m}B\,\mathbf{u}[m], \qquad \mathbf{y}[n] = C\mathbf{x}[n] + D\mathbf{u}[n] \]

The matrix power \(A^n\) is the discrete state transition matrix, playing the part \(e^{At}\) plays in continuous time. The sum is again a convolution, this time the discrete convolution of Chapter 7.

Reading the convolution off gives the impulse response directly. Setting \(\mathbf{x}[0] = \mathbf{0}\) and \(u[m] = \delta[m]\) leaves only the \(m=0\) term, so \(\mathbf{x}[n] = A^{n-1}B\) for \(n \ge 1\), and

The discrete impulse response — the Markov parameters
\[ h[n] = \begin{cases} D, & n = 0\\ C\,A^{\,n-1}B, & n \ge 1\end{cases} \]

These coefficients \(D,\ CB,\ CAB,\ CA^2B,\dots\) are called the Markov parameters of the system. They are exactly the impulse response samples, and they show that the entire input–output behaviour is determined by those particular products — a fact that Section 27-9 uses to explain how a mode can be present in \(A\) and yet absent from every one of them.

Building the discrete model from a difference equation follows the continuous recipe with delays in place of integrators. For

A second-order difference equation in canonical form
\[ y[n] + a_1y[n-1] + a_0y[n-2] = b_1u[n-1] + b_0u[n-2] \quad\Longrightarrow\quad A = \begin{bmatrix}0 & 1\\ -a_0 & -a_1\end{bmatrix},\ \ B = \begin{bmatrix}0\\1\end{bmatrix},\ \ C = \begin{bmatrix}b_0 & b_1\end{bmatrix} \]

with \(D = 0\) whenever there is no \(u[n]\) term on the right. The transfer function follows the same route as in continuous time, with \(z\) replacing \(s\): \(H(z) = C(zI-A)^{-1}B + D\).

Section 27-8

The Transfer Function and the Eigenvalues

State space did not replace the transfer function; it contains it. Transform the state equation with zero initial state, which is the condition under which a transfer function is defined in the first place:

Deriving \(H(s)\) from the state model
\[ s\mathbf{X}(s) = A\mathbf{X}(s) + B\mathbf{U}(s) \;\Longrightarrow\; (sI - A)\mathbf{X}(s) = B\mathbf{U}(s) \;\Longrightarrow\; \mathbf{X}(s) = (sI-A)^{-1}B\,\mathbf{U}(s) \]

Substituting into \(\mathbf{Y}(s) = C\mathbf{X}(s) + D\mathbf{U}(s)\) gives the bridge between the two descriptions.

🔑
The transfer function of a state-space model
\[ H(s) = C\,(sI-A)^{-1}B + D, \qquad\qquad H(z) = C\,(zI-A)^{-1}B + D \]

For a system with \(p\) inputs and \(q\) outputs this is a \(q \times p\) matrix of transfer functions, produced by one matrix inversion rather than \(pq\) separate derivations. That economy is the practical reason state space dominates multivariable work.

Now use the cofactor formula for the inverse, \(M^{-1} = \operatorname{adj}(M)/\det(M)\):

Where the poles come from
\[ H(s) \;=\; \frac{C\,\operatorname{adj}(sI-A)\,B \;+\; D\,\det(sI-A)}{\det(sI-A)} \]

The denominator is \(\det(sI-A)\), which is precisely the characteristic polynomial of \(A\). Its roots are the eigenvalues of \(A\). So the poles of the transfer function are eigenvalues of \(A\) — and the qualification matters enormously: they are among the eigenvalues, not necessarily all of them. If a factor of \(\det(sI-A)\) also divides the numerator, it cancels, and that eigenvalue disappears from \(H(s)\) while remaining perfectly present in the system.

🔑
Poles are a subset of the eigenvalues
\[ \{\text{poles of } H(s)\} \;\subseteq\; \{\text{eigenvalues of } A\} = \{\lambda : \det(\lambda I - A) = 0\} \]

Equality holds when no cancellation occurs — that is, when the realisation is minimal. Otherwise \(A\) carries dynamics that \(H(s)\) cannot see, and the resulting behaviour is the subject of the next section.

One more property is worth recording because it justifies the remark in Section 27-2 that the choice of state variables does not matter. Suppose new states \(\bar{\mathbf{x}} = T^{-1}\mathbf{x}\) are defined by an invertible matrix \(T\). Substituting throughout gives a new model with

Similarity transformation of a state model
\[ \bar A = T^{-1}AT, \qquad \bar B = T^{-1}B, \qquad \bar C = CT, \qquad \bar D = D \]

and the transfer function is unchanged, since

Why the transfer function survives the change of coordinates
\[ \bar C(sI-\bar A)^{-1}\bar B = CT\big(T^{-1}(sI-A)T\big)^{-1}T^{-1}B = CT\,T^{-1}(sI-A)^{-1}T\,T^{-1}B = C(sI-A)^{-1}B \]

Similar matrices have the same characteristic polynomial and therefore the same eigenvalues. The matrices \(A,B,C,D\) are a description; the eigenvalues and the transfer function are the system.

Section 27-9

Modes, Stability, and Hidden Dynamics

Suppose \(A\) has \(n\) distinct eigenvalues \(\lambda_1,\dots,\lambda_n\) with eigenvectors \(\mathbf{v}_1,\dots,\mathbf{v}_n\). Put the eigenvectors side by side as the columns of \(M\); then \(AM = M\Lambda\) with \(\Lambda\) diagonal, so \(A = M\Lambda M^{-1}\). Since \(A^k = M\Lambda^kM^{-1}\), every term of the exponential series carries the same \(M\), and the sum simplifies dramatically:

Diagonalisation of the matrix exponential
\[ e^{At} = M\,e^{\Lambda t}M^{-1} = M\begin{bmatrix} e^{\lambda_1 t} & & \\ & \ddots & \\ & & e^{\lambda_n t}\end{bmatrix}M^{-1} \]

The zero-input response is therefore a combination of exponentials in the eigenvalues:

The natural modes
\[ \mathbf{x}(t) = e^{At}\mathbf{x}(0) = \sum_{i=1}^{n} c_i\,e^{\lambda_i t}\,\mathbf{v}_i, \qquad \mathbf{c} = M^{-1}\mathbf{x}(0) \]

Each term is a natural mode. Its time behaviour is fixed by the eigenvalue \(\lambda_i\); the eigenvector \(\mathbf{v}_i\) fixes the pattern across the state variables — the relative proportions in which they move when that mode alone is excited. If the initial state happens to be a pure eigenvector, only one mode is present, and the state decays or grows along a fixed direction without ever changing shape.

This is the same conclusion Chapter 9 reached from the characteristic equation of a differential equation, and it is now visible as a statement about a matrix. Complex eigenvalues occur in conjugate pairs for a real \(A\), and their pair of terms combines into a real damped sinusoid, exactly as in Chapter 19.

Stability follows immediately. Every mode decays if and only if every eigenvalue lies strictly in the left half-plane; a single eigenvalue with positive real part guarantees that some initial state grows without bound.

🔑
Asymptotic stability
\[ \text{continuous time: } \operatorname{Re}\{\lambda_i\} \lt 0 \ \ \forall i \qquad\qquad \text{discrete time: } |\lambda_i| \lt 1 \ \ \forall i \]

In discrete time the modes are \(\lambda_i^n\) rather than \(e^{\lambda_i t}\), so the condition becomes a magnitude test against the unit circle — the same left-half-plane-to-unit-circle correspondence that Chapters 23 to 25 established for the z-transform.

Re Im stable unstable Re{λ} < 0
Continuous time — eigenvalues of \(A\) in the open left half-plane
Re Im stable unstable |λ| < 1
Discrete time — eigenvalues of \(A\) inside the unit circle

Which brings us back to the crack identified in Section 27-1. Asymptotic stability is a statement about the eigenvalues of \(A\); BIBO stability, as defined in Chapter 8 and tested in Chapters 19 and 25, is a statement about the poles of \(H(s)\). Section 27-8 showed that the poles are a subset of the eigenvalues. Asymptotic stability therefore implies BIBO stability, and the converse fails exactly when a cancellation removes a bad eigenvalue from the transfer function.

Such an eigenvalue is called a hidden mode, and there are two ways for a mode to hide. It is uncontrollable if the input cannot excite it — no choice of \(u\) puts any energy into it. It is unobservable if it never reaches the output — it may be raging inside, but \(C\) is blind to it. Either failure removes the mode from every Markov parameter \(CA^{k}B\), hence from the impulse response, hence from \(H(s)\).

The standard tests are matrix rank conditions, and for an \(n\)-th order system they take a compact form.

Controllability and observability matrices
\[ \mathcal{C} = \begin{bmatrix} B & AB & A^2B & \cdots & A^{n-1}B\end{bmatrix}, \qquad \mathcal{O} = \begin{bmatrix} C \\ CA \\ CA^2 \\ \vdots \\ CA^{n-1}\end{bmatrix} \]

The system is controllable when \(\mathcal{C}\) has rank \(n\), and observable when \(\mathcal{O}\) has rank \(n\); for a single-input single-output system both are square, so the test is simply whether the determinant is non-zero. A realisation that is both controllable and observable is minimal: it uses the fewest possible state variables, no cancellation occurs, and the eigenvalues and the poles coincide exactly. Worked Example 6 builds a system that fails the first test and shows what goes wrong.

Why an engineer should care. A control loop closed around a transfer function that has quietly cancelled an unstable pole will look stable on paper, behave well in simulation, and destroy itself in the laboratory the moment a disturbance or a modelling error excites the hidden mode. Cancellation of a left-half-plane pole is a modelling convenience; cancellation of a right-half-plane pole is never acceptable, and the state-space description is what makes the difference visible.
Section 27-10

Worked Examples

1 A series RLC circuit in state form

Problem. A voltage source \(u(t)\) drives a series connection of \(R = 3\,\Omega\), \(L = 1\) H and \(C = \tfrac12\) F. Take the output to be the capacitor voltage. Write the state model and recover the transfer function.

Solution. There are two storage elements, so the system is second order and the natural states are the inductor current \(i\) and the capacitor voltage \(v_C\). Write one equation per element. Kirchhoff's voltage law around the loop gives the inductor equation, and the capacitor's own relation gives the other:

Working — one equation per storage element
\[ L\frac{di}{dt} = u - Ri - v_C \;\Longrightarrow\; \dot i = -3i - v_C + u, \qquad C\frac{dv_C}{dt} = i \;\Longrightarrow\; \dot v_C = 2i \]

Both equations are first order and neither contains a derivative of the input, so the standard form is already in front of us. With \(\mathbf{x} = [\,i\ \ v_C\,]^{\mathsf T}\) and \(y = v_C\),

Working — the four matrices
\[ A = \begin{bmatrix}-3 & -1\\ 2 & 0\end{bmatrix}, \qquad B = \begin{bmatrix}1\\0\end{bmatrix}, \qquad C = \begin{bmatrix}0 & 1\end{bmatrix}, \qquad D = 0 \]

For the transfer function, form the resolvent. Since \(sI-A = \begin{bmatrix}s+3 & 1\\ -2 & s\end{bmatrix}\) with \(\det = s(s+3)+2 = s^2+3s+2\),

Working — \(H(s) = C(sI-A)^{-1}B\)
\[ (sI-A)^{-1}B = \frac{1}{s^2+3s+2}\begin{bmatrix}s & -1\\ 2 & s+3\end{bmatrix}\begin{bmatrix}1\\0\end{bmatrix} = \frac{1}{s^2+3s+2}\begin{bmatrix}s\\ 2\end{bmatrix} \;\Longrightarrow\; H(s) = \frac{2}{s^2+3s+2} \]

Two checks. The standard series-RLC result for capacitor voltage is \(\dfrac{1/LC}{s^2 + (R/L)s + 1/LC}\), and with these values \(1/LC = 2\) and \(R/L = 3\), which agrees. And \(H(0) = 1\), as it must: at DC the capacitor is open, the inductor is a short, and the whole source voltage appears across the capacitor. The eigenvalues are \(-1\) and \(-2\), both in the left half-plane, so the circuit is overdamped and stable.

2 Differential equation to canonical form, and back

Problem. Put \(\ddot y + 5\dot y + 6y = \dot u + 4u\) into controllable canonical form, then verify by recomputing \(H(s)\).

Solution. Introduce the auxiliary variable \(w\) satisfying \(\ddot w + 5\dot w + 6w = u\), so that \(y = \dot w + 4w\) by linearity. Take \(x_1 = w\), \(x_2 = \dot w\). Then \(\dot x_1 = x_2\) by definition, and the auxiliary equation rearranged gives \(\dot x_2 = -6x_1 - 5x_2 + u\). The output equation is \(y = 4x_1 + x_2\):

Working — the canonical matrices
\[ A = \begin{bmatrix}0 & 1\\ -6 & -5\end{bmatrix}, \qquad B = \begin{bmatrix}0\\1\end{bmatrix}, \qquad C = \begin{bmatrix}4 & 1\end{bmatrix}, \qquad D = 0 \]

The pattern promised in Section 27-4 is visible: the denominator coefficients \(6, 5\) appear negated in the bottom row of \(A\), and the numerator coefficients \(4, 1\) appear in \(C\) in ascending order of derivative. To verify, invert \(sI-A = \begin{bmatrix}s & -1\\ 6 & s+5\end{bmatrix}\), whose determinant is \(s^2+5s+6\):

Working — the check
\[ (sI-A)^{-1}B = \frac{1}{s^2+5s+6}\begin{bmatrix}s+5 & 1\\ -6 & s\end{bmatrix}\begin{bmatrix}0\\1\end{bmatrix} = \frac{1}{s^2+5s+6}\begin{bmatrix}1\\ s\end{bmatrix} \]
Working — and the output equation
\[ H(s) = \begin{bmatrix}4 & 1\end{bmatrix}\frac{1}{s^2+5s+6}\begin{bmatrix}1\\ s\end{bmatrix} = \frac{s+4}{s^2+5s+6} = \frac{s+4}{(s+2)(s+3)} \]

which is the transfer function of the original differential equation. The poles are \(-2\) and \(-3\), and since the numerator root is at \(-4\) nothing cancels — this realisation is minimal, and the eigenvalues and poles are the same two numbers.

3 Computing a matrix exponential

Problem. Find \(e^{At}\) for \(A = \begin{bmatrix}0 & 1\\ -2 & -3\end{bmatrix}\).

Solution. Use the Laplace route. First the resolvent:

Working — the resolvent
\[ sI - A = \begin{bmatrix}s & -1\\ 2 & s+3\end{bmatrix}, \quad \det = s^2+3s+2 = (s+1)(s+2), \quad (sI-A)^{-1} = \frac{1}{(s+1)(s+2)}\begin{bmatrix}s+3 & 1\\ -2 & s\end{bmatrix} \]

Now invert each entry with partial fractions. Only two elementary expansions are needed, since the other two are multiples of them:

Working — the partial fractions
\[ \frac{s+3}{(s+1)(s+2)} = \frac{2}{s+1} - \frac{1}{s+2}, \qquad \frac{1}{(s+1)(s+2)} = \frac{1}{s+1} - \frac{1}{s+2}, \qquad \frac{s}{(s+1)(s+2)} = \frac{-1}{s+1} + \frac{2}{s+2} \]

Transforming term by term gives the matrix exponential:

Working — the result
\[ e^{At} = \begin{bmatrix} 2e^{-t}-e^{-2t} & e^{-t}-e^{-2t}\\[3pt] -2e^{-t}+2e^{-2t} & -e^{-t}+2e^{-2t}\end{bmatrix} \]

Two checks, and both should be made every time. At \(t=0\) the entries are \(2-1=1\), \(1-1=0\), \(-2+2=0\) and \(-1+2=1\), so \(e^{A\cdot 0} = I\). Differentiating and setting \(t=0\) gives \(0,\ 1,\ -2,\ -3\) in the four positions, which is \(A\) itself — as the defining property \(\tfrac{d}{dt}e^{At}\big|_{0} = A\) requires. Every entry is a combination of \(e^{-t}\) and \(e^{-2t}\), the two modes belonging to the eigenvalues \(-1\) and \(-2\).

4 Zero-input plus zero-state, added up

Problem. With \(A\) as in Example 3, take \(B = \begin{bmatrix}0\\1\end{bmatrix}\), \(C = \begin{bmatrix}1 & 0\end{bmatrix}\), \(D = 0\) and \(\mathbf{x}(0) = \begin{bmatrix}1\\0\end{bmatrix}\). Find the complete output response to a unit step.

Solution. Treat the two parts separately, as the solution formula invites. The zero-input state response is \(e^{At}\mathbf{x}(0)\), which picks out the first column of the matrix exponential, and the output takes its first component:

Working — zero-input response
\[ \mathbf{x}_{\text{zi}}(t) = \begin{bmatrix}2e^{-t}-e^{-2t}\\ -2e^{-t}+2e^{-2t}\end{bmatrix}, \qquad y_{\text{zi}}(t) = 2e^{-t}-e^{-2t} \]

For the zero-state part, the transfer function is quicker than the convolution integral. With this \(B\) and \(C\),

Working — the transfer function and the step response
\[ H(s) = \begin{bmatrix}1&0\end{bmatrix}\frac{1}{(s+1)(s+2)}\begin{bmatrix}1\\ s\end{bmatrix} = \frac{1}{(s+1)(s+2)}, \qquad Y_{\text{zs}}(s) = \frac{1}{s(s+1)(s+2)} \]
Working — partial fractions
\[ \frac{1}{s(s+1)(s+2)} = \frac{1/2}{s} - \frac{1}{s+1} + \frac{1/2}{s+2} \;\Longrightarrow\; y_{\text{zs}}(t) = \tfrac12 - e^{-t} + \tfrac12 e^{-2t}, \quad t \ge 0 \]

Adding the two gives the complete response:

Working — the total
\[ y(t) = \tfrac12 + e^{-t} - \tfrac12 e^{-2t}, \qquad t \ge 0 \]

Check it at both ends. At \(t=0\), \(y = \tfrac12 + 1 - \tfrac12 = 1\), which equals \(C\mathbf{x}(0) = x_1(0) = 1\) as it must since \(D=0\). As \(t\to\infty\) the exponentials vanish and \(y \to \tfrac12 = H(0)\), the DC gain. The initial condition affects only the transient; the eigenvalues \(-1,-2\) govern how fast that transient disappears, and the input alone determines where the output settles.

5 A difference equation as a state machine

Problem. Put \(y[n] = 1.2\,y[n-1] - 0.32\,y[n-2] + u[n-1]\) into state-space form, find its eigenvalues, and obtain the impulse response.

Solution. Rearranged, the equation reads \(y[n] - 1.2y[n-1] + 0.32y[n-2] = u[n-1]\), so \(a_1 = -1.2\), \(a_0 = 0.32\), \(b_1 = 1\), \(b_0 = 0\). Applying the canonical pattern of Section 27-7,

Working — the discrete state model
\[ A = \begin{bmatrix}0 & 1\\ -0.32 & 1.2\end{bmatrix}, \qquad B = \begin{bmatrix}0\\1\end{bmatrix}, \qquad C = \begin{bmatrix}0 & 1\end{bmatrix}, \qquad D = 0 \]

The characteristic polynomial is \(\det(zI-A) = z(z-1.2)+0.32 = z^2-1.2z+0.32\), whose roots are

Working — the eigenvalues
\[ z = \frac{1.2 \pm \sqrt{1.44-1.28}}{2} = \frac{1.2 \pm 0.4}{2} = 0.8 \ \text{and}\ 0.4 \]

Both have magnitude less than 1, so the system is asymptotically stable. For the transfer function, \((zI-A)^{-1}B = \dfrac{1}{z^2-1.2z+0.32}\begin{bmatrix}1\\ z\end{bmatrix}\), and multiplying by \(C = [\,0\ \ 1\,]\) leaves

Working — \(H(z)\) and its inversion
\[ H(z) = \frac{z}{(z-0.8)(z-0.4)}, \qquad \frac{H(z)}{z} = \frac{2.5}{z-0.8} - \frac{2.5}{z-0.4} \]

so by the Chapter 24 pairs, \(h[n] = 2.5\big[(0.8)^n - (0.4)^n\big]u[n]\) — one term per eigenvalue, exactly as the modal picture predicts.

Verify against the difference equation directly. The formula gives \(h[0] = 0\), \(h[1] = 2.5(0.8-0.4) = 1\), \(h[2] = 2.5(0.64-0.16) = 1.2\) and \(h[3] = 2.5(0.512-0.064) = 1.12\). Iterating the recursion with \(u[n]=\delta[n]\) gives \(y[0]=0\); \(y[1] = u[0] = 1\); \(y[2] = 1.2(1) = 1.2\); \(y[3] = 1.2(1.2) - 0.32(1) = 1.12\). The two agree.

6 A stable transfer function hiding an unstable system

Problem. A system has \(A = \begin{bmatrix}-1 & 0\\ 0 & 3\end{bmatrix}\), \(B = \begin{bmatrix}1\\0\end{bmatrix}\), \(C = \begin{bmatrix}1 & 1\end{bmatrix}\), \(D = 0\). Find \(H(s)\), test controllability and observability, and describe what the system actually does.

Solution. The matrix \(A\) is already diagonal, so the resolvent is diagonal too and the transfer function is a one-line calculation:

Working — the transfer function
\[ (sI-A)^{-1}B = \begin{bmatrix}\tfrac{1}{s+1} & 0\\[2pt] 0 & \tfrac{1}{s-3}\end{bmatrix}\begin{bmatrix}1\\0\end{bmatrix} = \begin{bmatrix}\tfrac{1}{s+1}\\ 0\end{bmatrix} \;\Longrightarrow\; H(s) = \frac{1}{s+1} \]

A single pole at \(-1\): a first-order lag, perfectly BIBO stable, and no trace of the eigenvalue \(+3\). The eigenvalue has not gone anywhere — the numerator and denominator of \(H(s)\) both carried a factor \((s-3)\) and it cancelled.

The rank tests say which failure occurred. With \(AB = \begin{bmatrix}-1\\0\end{bmatrix}\) and \(CA = \begin{bmatrix}-1 & 3\end{bmatrix}\),

Working — the two tests
\[ \mathcal{C} = \begin{bmatrix}1 & -1\\ 0 & 0\end{bmatrix}, \ \det\mathcal{C} = 0 \ \text{(uncontrollable)}; \qquad \mathcal{O} = \begin{bmatrix}1 & 1\\ -1 & 3\end{bmatrix}, \ \det\mathcal{O} = 4 \ \text{(observable)} \]

So the unstable mode cannot be excited by the input, which is why the zero-state response — and therefore \(H(s)\) — never shows it. But it is observable, and the state equations say plainly what happens: \(\dot x_2 = 3x_2\), so \(x_2(t) = e^{3t}x_2(0)\), and since \(y = x_1 + x_2\) the output contains that growing term. Start the system from rest and it behaves like a well-mannered first-order lag forever. Start it with \(x_2(0)\) even slightly non-zero — a stray charge, a numerical rounding error, a disturbance that the model of \(B\) did not include — and the output grows without bound.

Changing to \(B = \begin{bmatrix}1\\1\end{bmatrix}\) and \(C = \begin{bmatrix}1 & 0\end{bmatrix}\) gives the same \(H(s) = 1/(s+1)\), but now \(\det\mathcal{C} = 4\) and \(\det\mathcal{O} = 0\): the mode is controllable and unobservable. That case is worse, because the input drives \(x_2\) hard while the output stays serene, and the first sign of trouble is a saturated amplifier or a component destroyed. In neither case does the transfer function warn you, which is precisely the argument of Section 27-1.

Review

Chapter Summary

State

The smallest set of numbers that, with the future input, determines the future output. In physical systems, the energy-storage variables.

The standard form

\(\dot{\mathbf{x}} = A\mathbf{x}+B\mathbf{u}\), \(\mathbf{y}=C\mathbf{x}+D\mathbf{u}\); discrete-time with \(\mathbf{x}[n+1]\). \(A\) alone carries the dynamics.

Canonical form

Denominator coefficients in the last row of \(A\), numerator coefficients in \(C\). One integrator, or one delay, per order.

The solution

\(\mathbf{x}(t)=e^{At}\mathbf{x}(0)+\int_0^t e^{A(t-\tau)}B\mathbf{u}\,d\tau\); discrete \(A^n\mathbf{x}[0]+\sum A^{n-1-m}B\mathbf{u}[m]\).

Back to \(H\)

\(H(s)=C(sI-A)^{-1}B+D\), denominator \(\det(sI-A)\). Poles are a subset of the eigenvalues of \(A\).

Modes and hiding

Stable iff \(\operatorname{Re}\lambda_i \lt 0\), or \(|\lambda_i| \lt 1\). An uncontrollable or unobservable mode vanishes from \(H\) but not from the system.

Practice

Problems

Problems 1 to 3 build state models; 4 and 5 solve them; 6 and 7 return to the transfer function; 8 concerns what the transfer function cannot tell you. In every numerical problem, check \(e^{A\cdot 0} = I\) and check the DC gain against \(H(0)\) before believing the answer.

  1. A parallel RLC circuit is driven by a current source \(u(t)\), with \(R = 1\,\Omega\), \(L = 1\) H, \(C = 1\) F, and the output taken as the resistor voltage. Choose state variables, write \(A, B, C, D\), and find the eigenvalues.
  2. Put \(\dddot y + 6\ddot y + 11\dot y + 6y = 2\ddot u + 3u\) into controllable canonical form. State \(A, B, C, D\) and write down the characteristic polynomial without expanding a determinant.
  3. Draw the simulation diagram for \(H(s) = \dfrac{3s+2}{s^2+4s+5}\), labelling every integrator output as a state variable, and read the matrices off your own drawing.
  4. Compute \(e^{At}\) for \(A = \begin{bmatrix}0 & 1\\ -6 & -5\end{bmatrix}\) using the resolvent, and verify both that \(e^{A\cdot 0}=I\) and that its derivative at the origin is \(A\).
  5. For the system of Problem 4 with \(B = [0\ \ 1]^{\mathsf T}\), \(C = [1\ \ 0]\), \(D=0\) and \(\mathbf{x}(0) = [0\ \ 2]^{\mathsf T}\), find the complete response to a unit step and identify the zero-input and zero-state parts.
  6. Show by direct calculation that \(A = \begin{bmatrix}0 & 1\\ -2 & -3\end{bmatrix}\) and \(\bar A = \begin{bmatrix}-1 & 0\\ 0 & -2\end{bmatrix}\) describe the same dynamics, by finding a matrix \(T\) with \(\bar A = T^{-1}AT\). What are the columns of \(T\)?
  7. A discrete system has \(A = \begin{bmatrix}0 & 1\\ -0.15 & 0.8\end{bmatrix}\), \(B = [0\ \ 1]^{\mathsf T}\), \(C = [1\ \ 0]\), \(D = 0\). Find \(H(z)\), the eigenvalues, the first four Markov parameters, and state whether the system is stable.
  8. A system has \(A = \begin{bmatrix}2 & 0\\ 0 & -4\end{bmatrix}\), \(B = [0\ \ 1]^{\mathsf T}\), \(C = [1\ \ 1]\), \(D=0\). Find \(H(s)\), test controllability and observability, and explain in one sentence what an engineer would observe if this system were built and switched on.
Tip: when a problem gives you a differential equation, count the storage elements or the order before doing anything else — that number is the size of every matrix in the answer. When it gives you \(A\), find \(\det(sI-A)\) first: the eigenvalues determine the modes, the stability and the denominator of \(H(s)\), and almost every question is really asking about one of the three.