National Instruments 370760B-01 Calculator User Manual


 
308 Chapter 6. Function Reference
# Look at the worst case perturbations for each of
# the Kinf and Kmu controllers. Compare also a
# random perturbation for each controller. In all cases the
# perturbation is of size 0.5 and we choose a perturbation
# which is bad at 1Hz.
mupert = mkpert(Delta2,blk,rpbnds2,{fselect=1,pnorm=0.5,Hertz})
mupert = mupert(1,1) # select part to close around top
infpert = mkpert(Delta1,blk,rpbnds1,{fselect=1,pnorm=0.5,Hertz})
infpert = infpert(1,1) # select part to close around top
# set up an LFT for the reference tracking problem
M = daug(W,1,1)*consys([0,0,1;1,0,1;-1,1,-1])*daug(1,1,P)
mupertic = starp(mupert,M)
mupertclp = starp(mupertic,Kmu)
munomclp = starp(starp(0,M),Kmu)
infpertic = starp(infpert,M)
infpertclp = starp(infpertic,Kinf)
infnomclp = starp(starp(0,M),Kinf)
rpert = randpert(blk,{pnorm=0.5})
rpert = rpert(1,1)
rpertic = starp(rpert,M)
murpert = starp(rpertic,Kmu)
infrpert = starp(rpertic,Kinf)
# Look at step responses
time = [0:0.05:4]
step = gstep(time,0,1)
yinfnom = infnomclp*step
yinfpert = infpertclp*step
ymunom = munomclp*step
ymupert = mupertclp*step
gph4 = ctrlplot([step,yinfnom(1,1),yinfpert(1,1),...