📄 reinf5_1.m
字号:
%%%%%%%%%%% Reinforcement Problem 5.1 %%%%%%%%%%%
% Discrete-Time Control Problems using %
% MATLAB and the Control System Toolbox %
% by J.H. Chow, D.K. Frederick, & N.W. Chbat %
% Brooks/Cole Publishing Company %
% September 2002 %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% ---- Exponential signal ----
%
clear
disp('Reinforcement Problem 5.1')
Ts = 0.05;
kT = [0:Ts:1]'; % sampling at 20 Hz
t = [0:0.02:1]'; % continuous time
e_k = exp(-3*kT) + kT.*exp(-2*kT) +3*exp(-10*kT); % sampled signal e(k)
e_t = exp(-3*t) + t.*exp(-2*t) +3*exp(-10*t); % continuous signal e(t)
figure
dplot(kT,e_k);grid % plot sampled signal
hold on
plot(t,e_t,'--') % plot continuous signal with dashes
hold off
xlabel('Time (s)')
title('Reinforcement Problem 5.1: Sampled signal e^*(k) and continuous signal e_(t)')
%%%%%%%%%%
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -