124 CHAPTER 3. FUNCTIONAL DESCRIPTION OF Xµ
# Displaying the Hankel singular values shows which
# states are close to unobservable and uncontrollable.
hsv?
hsv (a column vector) =
0.0741834
0.0726887
0.0264105
0.000146401
2.7699e-07
# Compare to the errors from the previous example.
g2 = ctrlplot(sys1g,{logmagplot});
g2 = ctrlplot(sysout3g,g2,{logmagplot,line
style=2});
g2 = ctrlplot(balerr,g2,{logmagplot,line
style=4});
g2 = ctrlplot(residerror,g2,{logmagplot,line
style=5});
g2 = ctrlplot(truncerror,g2,{logmagplot,line
style=6});
g2 = plot(g2,{!grid,legend=["original system";...
"balanced truncation";"error: balmoore";...
"error: sresidualize";"error: truncate"]})?
Frequency
0.1 1 100.01 100
Magnitude
1e-05
0.0001
0.001
0.01
1e-06
0.1
original system
balanced truncation
error: balmoore
error: sresidualize
error: truncate