How do I input a signal which is not a standard signal (like step or ramp) to a transfer function?

2 次查看(过去 30 天)
How do I input a signal which is not a standard signal (like step or ramp) to a transfer function? My signal is an error signal from a comparator & I am using a for loop in my program.
for j=1:(t1*100)
xc(j+1,1)=current(j+1,1)*pos_lim/i_lim;
xe(j+1,1)=xc(j+1,1)-xv(j,1);
% transfer function
% output=xe(j+1,1)*transfer function
end

回答(1 个)

Azzi Abdelmalek
Azzi Abdelmalek 2015-7-8
%Example
H=tf(1,[1 2])
time=0:0.1:10
input_s=rand(1,numel(time));
output_s=lsim(H,input_s,time)
plot(time,output_s)

类别

Help CenterFile Exchange 中查找有关 Dynamic System Models 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by