필터 지우기
필터 지우기

Convert s in j*ω in a transfer function

조회 수: 7 (최근 30일)
FEDERICO CIOL
FEDERICO CIOL 2021년 3월 20일
댓글: Paul 2021년 3월 22일
Hi, in this code I want to replace the variable s with the complex j*ω
syms s;
m=100;
k=20;
c=0;
A=[m*s^2+c*s+k -s*c-k 0; -k-s*c m*s^2+s*2*c+2*k -s*c-k;0 -s*c-k m*s^2+s*c+k]
det=det(A);
AI=inv(A)
for i = 1:3
for j = 1:3
[nf,df] = numden(AI(i,j));
tfn = sym2poly(nf);
tfd = sym2poly(df);
sys(i,j) = tf(tfn,tfd);
end
end
AI is the stiffness matrix of a MDOF system in mechanics of vibration and I want to plot the displacement behaviour of the masses.
Thanks
  댓글 수: 2
Paul
Paul 2021년 3월 22일
Replace s with j*w at what part of the process? It's straightforward to do that substitution in AI, but then sys will be incorrect? Or do you want to just evaluate sys at s = j*w? Or perhaps you want to do something else?
FEDERICO CIOL
FEDERICO CIOL 2021년 3월 22일
I want to evaluate sys(i,j) at s=j*w, but I don't know how to change s in a tf.

댓글을 달려면 로그인하십시오.

채택된 답변

Paul
Paul 2021년 3월 22일
No need to change anything in sys. It is a tf object and either freqresp() or bode() can evaluate sys at s = j*w
doc freqresp
doc bode
  댓글 수: 2
FEDERICO CIOL
FEDERICO CIOL 2021년 3월 22일
Thanks. But how can I plot my freqresp?
Paul
Paul 2021년 3월 22일
bode without output arguments will make the plots for you. The magnitude and/or phase of the output of freqresp can be plotted vs w, typically using semilog
doc abs
doc angle
doc semilog

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Time and Frequency Domain Analysis에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by