3.5.29Guidance, Navigation & Control (GNC)

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

1,765 words8 min readdifficulty · medium6 backlinks

WHY do we need state-space?


WHAT is the state?


HOW to derive it from a physical ODE (from scratch)

The trick: any nn-th order linear ODE becomes nn coupled first-order equations by naming derivatives as new states.

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

The solution (derived, not dumped)


Common mistakes (Steel-man them)


Forecast-then-Verify

Recall Forecast before checking

Q: For the mass–spring–damper with m=1,k=1,c=0m=1, k=1, c=0 (no damping), predict the eigenvalues of AA and the motion. Forecast: A=[0110]A=\begin{bmatrix}0&1\\-1&0\end{bmatrix}, det(λIA)=λ2+1=0λ=±i\det(\lambda I-A)=\lambda^2+1=0\Rightarrow\lambda=\pm i. Purely imaginary → undamped oscillation at ω=1\omega=1 rad/s. ✅ Matches physics: no damping ⇒ it rings forever.


Flashcards

What are the two state-space equations?
x˙=Ax+Bu\dot{x}=Ax+Bu (state/dynamics) and y=Cx+Duy=Cx+Du (output).
What is the "state" of a system?
The minimal set of variables needed with future inputs to fully predict future behavior.
What does the AA matrix represent physically?
The internal dynamics — how the state feeds back on itself; its eigenvalues set stability.
What does BB do?
Maps control inputs uu into rates of change of the state.
What does CC do?
Selects/combines states into measured outputs yy.
When is DD nonzero?
When an input instantly (algebraically) affects an output — direct feedthrough.
How do you convert an nn-th order ODE to state-space?
Define states as the function and its first n1n-1 derivatives, giving nn coupled first-order equations.
What is the full solution of x˙=Ax+Bu\dot{x}=Ax+Bu?
x(t)=eAtx(0)+0teA(tτ)Bu(τ)dτx(t)=e^{At}x(0)+\int_0^t e^{A(t-\tau)}Bu(\tau)d\tau.
Condition for stability in state-space?
All eigenvalues of AA have negative real part.
Transfer function from state-space?
G(s)=C(sIA)1B+DG(s)=C(sI-A)^{-1}B+D.
Why is state-space not unique?
A coordinate change x~=Tx\tilde x=Tx gives (TAT1,TB,CT1,D)(TAT^{-1},TB,CT^{-1},D) describing the same system.
What determines the system order nn?
The dimension of the state vector = number of independent energy-storing / memory elements.

Recall Feynman: explain to a 12-year-old

Imagine a toy car with a spring. To know where it'll go next, you only need two things right now: where it is and how fast it's moving. That's its "state." A push is your input. The rule "position and speed + push → how they change in a tiny moment" is the whole physics. We just write that rule as boxes of numbers (matrices) so a computer can play the movie forward. The CC box says which of those two things the car's little sensor can actually read out.

Connections

  • Transfer functions and G(s)G(s)=C(sIA)1B+DG(s)=C(sI-A)^{-1}B+D links the two worlds.
  • Eigenvalues and stability — poles = eigenvalues of AA.
  • Matrix exponential — engine of the solution eAte^{At}.
  • Controllability and Observability — do BB and CC actually reach every state?
  • LQR optimal control — designs feedback u=Kxu=-Kx directly on (A,B)(A,B).
  • Kalman filter — estimates unmeasured states from y=Cxy=Cx.
  • Linearization of nonlinear systems — where A,BA,B come from as Jacobians.

Concept Map

name derivatives as states

minimal memory of

drive

defines size n

assembled into

assembled into

dynamics matrix

input matrix

output matrix

feedthrough

handles MIMO and initial conditions

limited to SISO at rest

nth-order linear ODE

State vector x

System future

Inputs u

System order n

State-space form

A: state feedback

B: controls push state

C: measured combos

D: direct input to output

Output y

Kalman filter and LQR

Transfer function G of s

Hinglish (regional understanding)

Intuition Hinglish mein samjho

Dekho, state-space ka basic idea ekdum simple hai: kisi bhi system ka future sirf do cheezon pe depend karta hai — uska abhi ka state (yaani uski memory) aur aap jo input de rahe ho. Jaise ek spring pe laga mass — usse predict karna ho to bas position aur velocity chahiye. Yahi do variable "state" ban jaate hain, aur inhe hum ek vector xx me daal dete hain.

Ab magic yeh hai: koi bhi bada ODE (jaise mq¨+cq˙+kq=Fm\ddot q + c\dot q + kq = F) ko hum kaat kar chhote-chhote first-order equations me tod dete hain. Har derivative ko naya state naam de do, aur sab kuch matrix form me aa jaata hai: x˙=Ax+Bu\dot x = Ax + Bu. Yahan AA system ka apna behaviour (andar ka dynamics) batata hai, BB batata hai input kaise push karta hai, CC batata hai sensor kya measure karta hai, aur DD direct shortcut hai (mostly zero).

GNC me yeh isliye important hai kyunki rocket ya aircraft me bahut saare inputs (thrust, fins, gimbal) aur bahut saare outputs (attitude, position) hote hain — transfer function ek-ek karke handle nahi kar sakta, par state-space sab ek saath matrices me pakadta hai. Aur sabse mast baat: stability ka pura raaz AA matrix ke eigenvalues me chhupa hai. Agar sab eigenvalues ka real part negative hai, system stable hai; warna wobble ya blow-up. Isi foundation pe LQR aur Kalman filter jaise sabhi advanced controllers khade hote hain, isliye ise achhe se samajhna 80/20 wala kaam hai.

Go deeper — visual, from zero

Test yourself — Guidance, Navigation & Control (GNC)

Connections