📄 fig135.m
字号:
% Generates Fig 13.5 (recurres)% Using the System Identification Toolbox% Computer Controlled Systems (3rd ed)% Author: B. Wittenmark% Last edit: 1997-08-04% Copyright (c) 1996 by K. J. 舠tr鰉, B. Wittenmark and% Department of Automatic Control, Lund Institute of% Technology, Lund, Swedennewplot;clfset(gcf,'PaperUnits','centimeters','PaperPosition',[2 2 13 10])set(gcf,'Units','centimeters','position',get(gcf,'PaperPosition'))lw=0.9;N=500;a1=-0.8;b1=0.5;sig=0.5;P0=10;model=poly2th([1 a1],[0 b1]);u=idinput(600,'prbs',[0 1/5]);u=-u(1:N);randn('seed',217);e=sig*randn(N,1);y=idsim([u e],model);mydata=[y u];[thm,yh,P]=rarx(mydata,[1 1 1],'ff',1,[0 0],P0*eye(2));thm(N,:)Pts=[1:N];subplot(2,1,1)plot(ts,thm(:,1),'k-',ts,thm(:,2),'k-','Linew',lw);hold onplot([0 N],[a1 a1],'k--',[0 N],[b1 b1],'k--','Linew',lw);axis([0 N -1.5 1.5]);set(gca,'Fontsize',9,'Fontname','NewCenturySchlbk');set(gca,'xtick',[0 N],'ytick',[-1 0 1]);text(200,0.9,'\it{b}','Fontsize',9,'Fontname','NewCenturySchlbk')a=hex2dec('d9');text(201,1.1,setstr(a),'fontname','symbol','fontsize',7)text(200,-0.4,'\it{a}','Fontsize',9,'Fontname','NewCenturySchlbk')text(201,-0.26,setstr(a),'fontname','symbol','fontsize',7)ylabel('Parameter estimates','Fontsize',9,'Fontname','NewCenturySchlbk')xlabel('Time','Fontsize',9,'Fontname','NewCenturySchlbk')
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -