s=%s;
num=s+10;
den=s^3+6*s^2+9*s+10;
cr=syslin('c',num/den);
t=0:0.01:10;
r1=t;
r2=exp(-0.5*t);
subplot(2,1,1);
c1=csim(r1,t,cr);
plot2d(t,c1,2);
plot2d(t,t,3);
xtitle('Response to unit-ramp','t(seg)','Amplitude');
legends(['Input','Output'],[3,2],opt=4)
xgrid;
subplot(2,1,2);
c2=csim(r2,t,cr);
plot2d(t,r2,3);
plot2d(t,c2,2);
xtitle('Response to r(t)=e^(-0.5t)','t(seg)','Amplitude');
legends(['Input','Output'],[3,2],opt=4)
xgrid;