3.5.29 · D2Guidance, Navigation & Control (GNC)

Visual walkthrough — State-space representation — x' = Ax + Bu, y = Cx + Du

2,016 words9 min readBack to topic

Prerequisites we lean on (all in your vault): the parent topic, and later Matrix exponential, Eigenvalues and stability.


Step 1 — What does even say?

WHAT. Forget matrices. Start with ONE number — think of it as the height of water in a tank, or the position of a dot on a line at time . The little dot over the letter, , is shorthand for "how fast is changing right now" — its speed.

WHY this equation. The simplest possible rule a system can obey is: "my speed is proportional to my current size." Written out: . The number is the growth rate constant. If , the bigger you are the faster you grow (runaway). If , the bigger you are the faster you shrink toward zero (decay). This is the seed of everything — the whole state-space solution is just this idea wearing a matrix costume.

PICTURE. Look at the figure. The horizontal axis is (how big we are). The vertical arrows show — the speed at each spot. Where is large, the arrow is long; where the arrow has zero length (a dot sitting at never moves — that is the equilibrium).

Figure — State-space representation — x' = Ax + Bu, y = Cx + Du

Step 2 — Why the answer is (and where comes from)

WHAT. We want a formula for that obeys "my speed equals times myself" at every instant.

WHY . Ask: which function is its own derivative (up to a factor )? Most functions change their shape when you differentiate. But there is one special number, , built exactly so that differentiates into itself. Multiply the exponent by and the chain rule hands us a factor : That is precisely . So , where is the starting value (the size at time zero) — it just scales the whole curve up or down.

PICTURE. The figure plots three cases on the same axes so you see all signs at once: teal (decays toward ), plum (flat line — never changes), orange (explodes upward). The slope of each curve at any point equals times its own height — read that off the little slope arrows.

Figure — State-space representation — x' = Ax + Bu, y = Cx + Du

Step 3 — Upgrade: many quantities at once → the vector

WHAT. A real vehicle is not one number. A mass on a spring needs position and velocity; a rocket needs attitude, rates, positions. Stack them into a column of numbers — the state vector (here just means "a list of real numbers").

WHY a matrix. Each entry's speed can depend on all the others. "Speed = rate times size" becomes "speed of the whole list = a table of rates times the whole list." That table is the matrix . So the scalar grows up into — same sentence, bold letters.

PICTURE. Left: the scalar arrow-on-a-line from Step 1. Right: the state now lives in a plane ( horizontal, vertical). At every point the matrix assigns a little arrow — a velocity field. A trajectory is a dot that always follows the arrow under its feet.

Figure — State-space representation — x' = Ax + Bu, y = Cx + Du

Step 4 — What could possibly mean? Build it from the series

WHAT. In the scalar case the answer was . We want the vector answer to be . But you cannot raise to a matrix… unless you decide what that means.

WHY the series. Recall the one honest definition of the ordinary exponential — an infinite sum: Every term is just powers and dividing by counting numbers — and we can take powers of a square matrix (, , …) and divide by numbers. So we simply reuse the same recipe: where is the identity matrix (the "" for matrices — leaves any vector unchanged).

Check it solves the ODE. Differentiate the series term by term (each power drops by one, exactly like ): So really satisfies .

PICTURE. We show the series as a growing stack of contributions: the flat , then the tilt , then the curve , … each bar smaller than the last because in the bottom grows fast. Their sum is the smooth propagator .

Figure — State-space representation — x' = Ax + Bu, y = Cx + Du

Step 5 — Turn the crank: the integrating-factor trick handles the input

WHAT. Add the control. The real equation is , where is the input you apply (thrust, fin angle) and (size ) tells how each input pushes each state.

WHY an integrating factor. We want to "peel off" the term so only the input is left on the right — then plain integration finishes the job. The peeling tool is multiplication by (the inverse slide — undo seconds of dynamics). Watch the two -terms collapse into a single derivative:

\;\;\Longrightarrow\;\; \frac{d}{dt}\big(e^{-At}x\big)=e^{-At}Bu.$$ The left side is now a clean derivative of one thing (product rule, run backward). Integrate from $0$ to $t$, then multiply back by $e^{At}$ to undo the peeling: $$x(t)=e^{At}x(0)+\int_0^t e^{A(t-\tau)}Bu(\tau)\,d\tau.$$ **PICTURE.** The figure splits the answer visually: a **teal curve** = the free response $e^{At}x(0)$ (memory of where we started, no input), and **orange stacked slivers** = the forced response, where each past input kick $Bu(\tau)$ at time $\tau$ is slid forward by the remaining time $(t-\tau)$ via $e^{A(t-\tau)}$ and all such kicks are summed (that is what the integral $\int$ does). ![[deepdives/dd-physics-3.5.29-d2-s05.png]] > [!formula] The complete solution > $$\boxed{\,x(t)=\underbrace{e^{At}x(0)}_{\text{free / zero-input}}+\underbrace{\int_0^t e^{A(t-\tau)}Bu(\tau)\,d\tau}_{\text{forced / zero-state}}\,}$$ > - $e^{At}x(0)$ ::: the past you started with, propagated forward. > - $Bu(\tau)$ ::: an input kick delivered at time $\tau$. > - $e^{A(t-\tau)}$ ::: slides that kick forward the remaining $t-\tau$ seconds. > - $\int_0^t\ldots d\tau$ ::: adds up every kick from start until now. --- ## Step 6 — Reading stability straight off the picture (eigenvalues) **WHAT.** When does the free response die out vs. blow up? Answer lives entirely in $A$, through its **eigenvalues** — special numbers $\lambda$ and directions $v$ with $Av=\lambda v$ (a direction the matrix only *stretches*, never rotates). **WHY eigenvalues.** Along such a special direction $v$, the vector equation *becomes scalar again*: $\dot{x}=Ax$ turns into $\dot{c}=\lambda c$ for the amount $c$ along $v$. And we already solved that in Step 2 — it decays if the rate is negative. For a possibly complex $\lambda=\sigma+i\omega$: - $\sigma=\mathrm{Re}(\lambda)$ ::: sets grow ($\sigma>0$) or decay ($\sigma<0$) — the *envelope*. - $\omega=\mathrm{Im}(\lambda)$ ::: sets how fast it oscillates — the *ringing*. **PICTURE — every case shown.** The complex plane, split by the vertical axis (the $\mathrm{Re}=0$ line). We plot four eigenvalue spots and the tiny motion each produces: teal (left half, decaying spiral — **stable**), plum (on the axis, pure oscillation — **marginal**), orange (right half, growing spiral — **unstable**), and a real negative $\lambda$ (pure decay, no ring). The rule is one sentence: **all dots strictly left of the axis ⇒ stable.** ![[deepdives/dd-physics-3.5.29-d2-s06.png]] > [!definition] Eigenvalue reading > $$Av=\lambda v,\qquad \lambda=\sigma+i\omega.$$ > - $v$ ::: a direction the matrix merely scales. > - $\sigma<0$ for **every** eigenvalue ::: the whole state decays to $0$ → **stable**. See [[Eigenvalues and stability]]. > - $\sigma=0$ ::: rings forever (marginal); $\sigma>0$ ::: at least one direction explodes. --- ## The one-picture summary Everything on one canvas: a **scalar seed** $\dot{x}=ax\to e^{at}$ grows (via the series) into the **matrix propagator** $e^{At}$; the propagator carries the initial state forward (teal) while the integral rakes in input kicks (orange); and the **eigenvalues of $A$** on the complex plane decide, by their left/right position, whether the whole movie fades out or runs away. ![[deepdives/dd-physics-3.5.29-d2-s07.png]] > [!recall]- Feynman: tell it to a 12-year-old > Start with a rabbit-population rule: *how fast it changes equals a number times how big it is now.* > The answer is "$e$ to the power (that number times time)" — $e$ is the one magic number whose growth > curve copies itself when you look at its slope. Now imagine not one population but a **whole team** > of them, each nudging the others. The single number becomes a *box of numbers* (a matrix $A$), and > the magic "$e$-to-a-number" becomes "$e$-to-a-box" — which we make sense of by the same adding-up > recipe, just with the box multiplied by itself over and over. That box, $e^{At}$, is a **time machine**: > feed it where you started, it tells you where you'll be. If you also keep poking the system (your > control $u$), you just add up all the pokes, each slid forward by however long ago you poked. And > whether the team eventually calms down or spins out of control? Look at the special "stretch numbers" > of the box (its eigenvalues): if they all sit on the *left* side of the number-line-with-an-up-axis, > everything fades to calm. That is the entire story of state-space, in one breath. > [!mnemonic] > **Seed → Series → Slide → Sum → Sign.** > ($a x$ Seed; $e$ from the Series; $e^{At}$ Slides the start; the integral Sums the pokes; the > eigenvalue's Sign decides stability.) ## Connections - [[Matrix exponential]] — Steps 4–5 are its full construction. - [[Eigenvalues and stability]] — Step 6, the sign rule. - [[Transfer functions and G(s)]] — same poles via $\det(sI-A)=0$. - [[Controllability and Observability]] — whether $B$'s kicks reach, and $C$ sees, every direction. - [[LQR optimal control]] and [[Kalman filter]] — both run on this exact solution. - [[Linearization of nonlinear systems]] — where a real $A$ comes from.