What is MATLAB doing when adding multiple ZPK transfer functions together?

조회 수: 9 (최근 30일)
Austin Kwon
Austin Kwon 2024년 6월 14일
편집: Aquatris 2024년 6월 17일
I am trying to add multiple zpk transfer functions by directly accessing the zeros, poles, and gains without the use of the "parallel" or "+" operations (for runtime reduction), and I was wondering what "+" does:
zero1 = [1, 2];
pole1 = [3, 4];
gain1 = 2;
tf1 = zpk(zero1, pole1, gain1)
% tf1 =
%
% 2 (s-1) (s-2)
% -------------
% (s-3) (s-4)
zero2 = [-1, -2];
pole2 = [-3, -4];
gain2 = -2;
tf2 = zpk(zero2, pole2, gain2)
% tf2 =
%
% -2 (s+1) (s+2)
% --------------
% (s+3) (s+4)
tf = tf1 + tf2
% tf =
%
% 16 s (s-2.345) (s+2.345)
% ------------------------
% (s-3) (s-4) (s+3) (s+4)
I googled how to add two ZPK transfer functions and it said that it's simply linearly adding them together but Matlab is definitely doing something different (as "tf" has a zero at +/- 2.345 when neither "tf1" nor "tf2" have those zeros)

답변 (1개)

Aquatris
Aquatris 2024년 6월 14일
편집: Aquatris 2024년 6월 17일
Yes but you are doing a fractional algebra. To refresh your memory:
a/b + c/d = (a*d + c*b)/(b*d)
Since numerator stays b*d, you maintain the same poles. However your denominator is changed significanty, meaning you do not necessarily maintain the same zeros after the addition.
In transfer function terms
(s-2)/(s-5) + (s-1)/(s-3) = [(s-2)*(s-3) + (s-1)*(s-5)] / [(s-5)(s-3)]
So your numerator is the same, poles of your tf1 and tf 2. However your denominator that defines your zeros is now
(s-2)*(s-3) + (s-1)*(s-5) = 2*s^2 - 11*s +11
So zeros of your tf1 and tf2 are no longer the zeros when you add them together

카테고리

Help CenterFile Exchange에서 Pole and Zero Locations에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by