A739 of 56
0 XP
  1. Hook
  2. Play
  3. Predict
  4. Name it
  5. Check
  6. Explain

A7 · Lesson 39 · The matrix exponential

One formula for every linear system: e^{At}

The scalar equation x′=ax has the solution x=eatx0. The system 𝐮′=A𝐮 has the same solution, 𝐮=eAt𝐮0, once you know what the exponential of a matrix means. Lesson 37 computed it from eigenvectors. Here it gets its own definition, a power series that works for every square matrix, defective ones included, and its properties: what it does to rotations and spirals, why eAeB usually isn't eA+B, and how simulators use it to step linear circuits exactly.

  • The curve is where eAt carries the starting state (1,0), for A=[σ−ωωσ]. The dot is the state at time t.
  • With σ=0 the state goes round a circle: eAt is a rotation by ωt.
  • Make σ negative and the circle becomes a spiral inward, like a ringing LC tank with some resistance. The readouts give the distance from the origin, eσt, and the angle turned, ωt.

Predict

For A=[0−110], what is eAπ?

Name it

The definition

eAt=I+At+(At)22!+(At)33!+⋯

The series converges for every square matrix and every t, because n! eventually beats any power. Differentiating term by term gives ddteAt=AeAt, so 𝐮(t)=eAt𝐮0 solves 𝐮′=A𝐮 with 𝐮(0)=𝐮0.

Properties

  • eA(t+s)=eAteAs and (eAt)−1=e−At: it's never singular.
  • eA+B=eAeB only when AB=BA.
  • If A=XΛX−1, then eAt=XeΛtX−1, and eΛt is diagonal with entries eλit.
  • If Nk=0 (a nilpotent matrix), the series stops: eNt=I+Nt+⋯+(Nt)k−1(k−1)!.

Spirals

For A=[σ−ωωσ]=σI+ωR, the parts commute, and R (the 90° rotation) behaves like j:

eAt=eσt[cos⁡ωt−sin⁡ωtsin⁡ωtcos⁡ωt]

Any real 2 × 2 matrix with eigenvalues σ±jω is similar to this one, which is why a ringing circuit's state traces a spiral.

Stepping exactly

For a linear circuit with a constant input u over a time step T, 𝐱′=A𝐱+𝐛u gives exactly

𝐱k+1=eAT𝐱k+A−1(eAT−I)𝐛u

with no truncation error, however large T is. For an RC circuit, A=−1τ and b=1τ, this is xk+1=e−T/τxk+(1−e−T/τ)u. Ohmwork's own circuit simulator steps linear circuits this way.

Worked example

Find eAt for A=[0100], the matrix of x′=v, v′=0.

Show the solution
  1. Sum the series. A2=0, so the series stops after two terms: eAt=I+At=[1t01]
  2. Apply it. Applied to a starting position x0 and velocity v0, it gives x=x0+v0t and v=v0: motion at constant velocity.
  3. Why eigenvectors won't do. An eigenvector method would fail here, since A has the eigenvalue 0 twice with only one eigenvector.

Answer eAt=[1t01], motion at constant velocity.

Worked example

An LC tank's normalized state obeys 𝐮′=[0−ωω0]𝐮 with ω = 1000 rad/s. Find eAt at t = 1 ms.

Show the solution
  1. The angle. ωt = 1 rad, and eAt is the rotation by that angle: eAt=[cos⁡1−sin⁡1sin⁡1cos⁡1]=[0.5403−0.84150.84150.5403]
  2. Apply it to (1,0). Starting with all the energy in the capacitor, the state after 1 ms is (0.540,0.841).
  3. Energy check. 0.5402+0.8412=1 so the energy is the same, now shared with the inductor.

Answer eAt=[0.5403−0.84150.84150.5403], a rotation by 1 rad.

Worked example

Take A=[0100] and B=[0010]. Compare eAeB with eA+B.

Show the solution
  1. The two exponentials. Both matrices are nilpotent, so eA=I+A=[1101]eB=I+B=[1011]
  2. Their product. eAeB=[2111]
  3. The exponential of the sum. A+B=[0110] has eigenvalues ±1 with eigenvectors (1,±1), giving eA+B=[cosh⁡1sinh⁡1sinh⁡1cosh⁡1]=[1.5431.1751.1751.543]
  4. Why they differ. AB≠BA: AB has a 1 in the top-left corner and BA in the bottom-right.

Answer eAeB=[2111] and eA+B=[1.5431.1751.1751.543]; they differ because A and B don't commute.

Check

For A=[0−220], what is the top-left entry of eAt at t = 0.2?

Check

What is the bottom-right entry of eAt for A=[−100−0.5] at t = 2?

Check

An RC circuit with τ = 1 ms is stepped exactly with T = 0.5 ms. What factor multiplies xk?

Check

For the nilpotent N=[010001000], what is the top-right entry of eNt at t = 3?

Check

A spiral system has A=[−0.1−11−0.1] and starts at (1,0).

(a)

What is u1 at t = 3?

(b)

How far is the state from the origin?

Check

Use eAt=eσt[cos⁡(ωt)I+sin⁡(ωt)A−σIω] for A=[s−wws].

Step 1

What is the top-left entry?

Type it the way you would write it, like 3sin(2πft) or 3*sin(2*pi*f*t). Angles can be in radians or carry a degree sign, like 45°.

Explain why

A simulator steps a linear circuit with eAT instead of Euler's method. Why can it take large steps without losing accuracy or stability?

Practice

Keep practicing

7 kinds of problem on this topic, dealt one at a time with new numbers every time, for as long as you like.