repeated roots in residue fn, how to read/ display??

18 Ansichten (letzte 30 Tage)
Aidan Macdougall
Aidan Macdougall am 29 Sep. 2019
my code is as follows
clc ;
clear;
n1=[5 20 6];
d1=[1 2 1 0];
tf1=tf(n1,d1)
[r,p,k]= residue(n1,d1)
% r values are the numeratior of the tf
% p values are the poles,
%NOTE
%THEY ARE oposite
%VALUE AKA p = -5 is ACT (s+5)
Id really like to be able to get some repeated root values from this but i dont know what to do code wise to get there..
Btw this is from the tf bellow
( 5s^2 + 20s + 6 ) / ( s^3+ 2s^2 + s )
this should yeild 6/s - 1/(s+1) + 9(s+1)^2
but i get
r =
-1
9
6
p =
-1
-1
0
which is great, but doesnt show that the (s+1) of the 9/(s+1) should be ^2 ... can i edit my code some how to show that i needs to be squared?

Antworten (1)

Mahesh Taparia
Mahesh Taparia am 3 Okt. 2019
Hi,
It is possible to know if the fraction contains multiple roots. As per your given code, ‘r’ contains the residue, ‘p’ contains the poles and ‘k’ contains the direct terms of your transfer function. If ‘p’ contains any duplicate element entry, then it means there are multiple roots at the same location. As per your case, p= [-1 –1 0] it means there are two roots at –1.
For more information on residue function, you can refer to the documentation link given below:
  3 Kommentare
Mahesh Taparia
Mahesh Taparia am 4 Okt. 2019
Hi,
If multiple roots are present at same location, then residue are arranged as per the pole multiplicity. In your case, '-1' residue corresponds to (s+1), '9' residue is for (s+1)^2. In general, for a pole of multiplicity m, you can refer to the following link for residue arrangement:
Hope it will help.
Aidan Macdougall
Aidan Macdougall am 5 Okt. 2019
Okay, i understand from this that it is purely a matter of knowing that the repeated values in the p array are going to be of second or higher power, this is helpful thank you both, i was hopeful i could get it to display this simply but ill just to add a note to those lines, regarless thanks for your time :)

Melden Sie sich an, um zu kommentieren.

Produkte


Version

R2019a

Community Treasure Hunt

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

Start Hunting!

Translated by