3.6. H2AND H∞ANALYSISAND SYNTHE SIS 103
Frequency
0.01 0.1 1 100.001 100
Magnitude
0.001
0.01
0.1
1
0.0001
10
Controllers
Kinf
K2
# Examine sensitivity functions
sensinf = inv(1 + plant*Kinf)
sensinfg = freq(sensinf,omega)
sens2 = inv(1 + plant*K2)
sens2g = freq(sens2,omega)
g2 = ctrlplot(sensinfg,{logmagplot});
g2 = ctrlplot(sens2g,g2,{logmagplot,linestyle=4});
g2 = plot(g2,{title="Sensitivity functions",...
legend=["Kinf","K2"],!grid})?