📄 dcl_rock.m
字号:
% Sample-data transient responses of the closed_loop rocket
% stabilization system
%
% flight time
t = input ('Enter time t = ');
% open-loop interconnection
sim_rock
%
% response to the reference input
timedata = [0 3 6];
stepdata = [15 -15 15]; % g
tf = 9; % final time value
ref = step_tr(timedata,stepdata,Ts/10,tf);
pert = abv(0,0,0,0,0,0,0);
noise1 = 0;
noise2 = 0;
noise = abv(noise1,noise2);
u = abv(pert,ref,noise);
[y,w,v] = sdtrsp(sim_ic,KD,u,Ts,tf,Ts/10);
%
figure(1)
vplot(ref,'m--',sel(y,10,1),'c-'), grid
title('Response in n_{y}')
xlabel('Time (secs)')
ylabel('n_{y} (g)')
%legend('r','n_{y}',4)
%
figure(2)
vplot(sel(y,9,1),'c-'), grid
title('Response in d\vartheta/dt')
xlabel('Time (secs)')
ylabel('d\vartheta/dt (rads/sec)')
%
figure(3)
vplot(sel(y,11,1),'r-'), grid
title('Fins deflection')
xlabel('Time (secs)')
ylabel('\delta (rads)')
%
figure(4)
vplot(sel(y,12,1),'r-'), grid
title('Closed-loop control')
xlabel('Time (secs)')
ylabel('\delta^o (rads)')
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -