12. Miscellaneous

12.1 Ordered Schur Decomposition

<< ControlSystems`

m = Table[Random[], {3}, {3}]

{q, t} = SchurDecomposition[m];

t

{qo, to} = SchurDecompositionOrdered[m];

to // Chop

qo . to . Conjugate[Transpose[qo]] - m // Chop

{qo, to} = SchurDecompositionOrdered[m, Re[#] > 0 &];

to // Chop

{qo, to} = 
        SchurDecompositionOrdered[m, Re[#2] < Re[#1] &];

to // Chop

12.2 Lyapunov Equations

a= (({{(1/2), 1}, {-1, -1}}));

c=(({{q1, 0}, {0, q2}}));

DiscreteLyapunovSolve[a, c] // Simplify

a . % . Transpose[a] + c == % // Simplify

a=(({{-3, 2}, {-1, -1}}));

b=(({{1, -1}, {0, 1}}));

p = LyapunovSolve[a, -IdentityMatrix[2]]

bpx = Transpose[b] . p . {x1, x2};

u = -(bpx/(Sqrt[bpx . bpx])) // Simplify

\(\(Plot3D[
        u[[1]], {x1, \(-2\), 
          2}, {x2, \(-2\), 2}, PlotPoints -> 40, Boxed -> False, 
        AxesLabel -> {\*""(Subscript[x, 1])"", \*""(Subscript[x, 2])"", \*""(Subscript[u, 1])""}, ViewPoint -> {3.076, 0.000, 1.080}, 
        PlotLabel -> "Minimum time response control"];\)\)

\(\(Plot3D[
        u[[2]], {x1, \(-2\), 
          2}, {x2, \(-2\), 2}, PlotPoints -> 40, Boxed -> False, 
        AxesLabel -> {\*""(Subscript[x, 1])"", \*""(Subscript[x, 2])"", \*""(Subscript[u, 2])""}, ViewPoint -> {2.141, 2.209, 1.080}, 
        PlotLabel -> "Minimum time response control"];\)\)

12.6 Systems with Random Elements

TransferFunction[s, RandomSystem[]]

StateSpace[RandomSystem[2, 1, 2]]