transfer function plot problem

1 Ansicht (letzte 30 Tage)
fima v
fima v am 4 Sep. 2019
Kommentiert: fima v am 4 Sep. 2019
Hello, I have extracted the poles and zeros of a circuit which have the following response shown in a plot bellow.
the POLES and ZEROS of the circuit are attached.
however when i tried to put them into a transfer function expression as shown in the code bellow it gives me
sys = NaN and an empty plot
Where did i go wrong ?
Thanks.
z=[-1.28811872803795e-09+3.75032438366853e-10i;
-1.28811872803795e-09-3.75032438366853e-10i;
-1.27120508227557e-09+1.46546199782833e-09i;
-1.27120508227557e-09-1.46546199782833e-09i;
-3.32881226000323e-09+9.39321860988066e-11i;
-3.32881226000323e-09-9.39321860988066e-11i;
-1.58271684302383e-09+3.99452158295292e-09i;
-1.58271684302383e-09-3.99452158295292e-09i;
-5.82131957722562e-06+0.00000000000000e+00i;
5.86257744501881e-06+0.00000000000000e+00i;
-3.97879334830376e+02+1.16773714820167e+04i;
-3.97879334830376e+02-1.16773714820167e+04i;
-1.26876548375538e+04+5.92462339644297e+04i;
-1.26876548375538e+04-5.92462339644297e+04i;
-1.22897755043826e+04+1.50129180496307e+05i;
-1.22897755043826e+04-1.50129180496307e+05i;
-2.37898350744872e+10+0.00000000000000e+00i;
2.38692896865366e+10+0.00000000000000e+00i;
-1.83626068795164e+11+1.57681364106391e+11i;
-1.83626068795164e+11-1.57681364106391e+11i;
1.83757221349466e+11+1.57733433284606e+11i;
1.83757221349466e+11-1.57733433284606e+11i;
-3.52043680810489e+11+0.00000000000000e+00i;
3.52133420753001e+11+0.00000000000000e+00i;
-3.43282629853052e+11+3.92816887251620e+11i;
-3.43282629853052e+11-3.92816887251620e+11i;
3.43331696868923e+11+3.92794659000565e+11i;
3.43331696868923e+11-3.92794659000565e+11i;
-6.38933586270784e+11+0.00000000000000e+00i;
6.39013681124312e+11+0.00000000000000e+00i;
-7.41366644869900e+11+0.00000000000000e+00i;
7.41459685162969e+11+0.00000000000000e+00i;
-7.16813058132076e+11+3.17835645085742e+11i;
-7.16813058132076e+11-3.17835645085742e+11i;
7.16937051677754e+11+3.17779565482882e+11i;
7.16937051677754e+11-3.17779565482882e+11]
p=[-1.17526574606346e-08+0.00000000000000e+00i;
-1.45539022282902e-08+0.00000000000000e+00i;
-2.05380336431976e-08+0.00000000000000e+00i;
-2.55828321866515e-08+0.00000000000000e+00i;
-4.56660033199091e-08+0.00000000000000e+00i;
-5.70884825512686e-08+0.00000000000000e+00i;
-1.81058930649108e-07+0.00000000000000e+00i;
-2.26809326278153e-07+0.00000000000000e+00i;
-2.07048762127127e+01+5.79122928914659e+03i;
-2.07048762127127e+01-5.79122928914659e+03i;
-3.83164553845592e+02+1.16216446323155e+04i;
-3.83164553845592e+02-1.16216446323155e+04i;
-1.26711513946503e+04+6.55349709090204e+04i;
-1.26711513946503e+04-6.55349709090204e+04i;
-1.37893284168987e+04+1.38236035864718e+05i;
-1.37893284168987e+04-1.38236035864718e+05i;
-1.21701532452899e+06+0.00000000000000e+00i;
-3.27874730871924e+07+0.00000000000000e+00i;
-2.56974745105871e+10+0.00000000000000e+00i;
2.57902230577189e+10+0.00000000000000e+00i;
-2.00885121575103e+11+0.00000000000000e+00i;
2.00994270339200e+11+0.00000000000000e+00i;
-2.09729105616755e+11+0.00000000000000e+00i;
2.09829607497857e+11+0.00000000000000e+00i;
-3.67183927043333e+11+0.00000000000000e+00i;
3.67280123011875e+11+0.00000000000000e+00i;
-3.93421324148177e+11+0.00000000000000e+00i;
3.93513018627735e+11+0.00000000000000e+00i;
-5.85494774575287e+11+4.93981433401239e+09i;
-5.85494774575287e+11-4.93981433401239e+09i;
5.85599337665681e+11+4.93428043170709e+09i;
5.85599337665681e+11-4.93428043170709e+09i;
-6.86534178758184e+11+0.00000000000000e+00i;
6.86625532723185e+11+0.00000000000000e+00i;
-7.28937758682295e+11+0.00000000000000e+00i;
7.29035537891136e+11+0.00000000000000e+00i;
-8.27479933780269e+11+0.00000000000000e+00i;
8.27565870925879e+11+0.00000000000000e+00i;
-9.10585117712558e+11+1.10238827198810e+11i;
-9.10585117712558e+11-1.10238827198810e+11i;
9.10657754476142e+11+1.10250967050881e+11i;
9.10657754476142e+11-1.10250967050881e+11i;
-9.47150572658139e+11+0.00000000000000e+00i;
9.47241034341615e+11+0.00000000000000e+00i;
-9.80609936035125e+11+0.00000000000000e+00i;
9.80695673294753e+11+0.00000000000000e+00i]
k=1;
[num,den]=zp2tf(z,p,k)
sys=tf(num,den)
bode(sys)

Antworten (1)

Raj
Raj am 4 Sep. 2019
I don't think you need to use 'zp2tf' and then 'tf' to get your transfer function. You can directly use:
sys=zpk(z,p,k)
bode(sys)
  1 Kommentar
fima v
fima v am 4 Sep. 2019
i tried it ,its not the original function plotted.

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu MATLAB finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by