zplane - don't the zeros and poles need to be complex?

I'm just getting my head around the zplane function. I'm not how the values of z and p are mapped onto the pole-zero plot. I thought zeros and poles were supposed to have both real and imaginary parts - as these are the axes of the pole-zero plot. But in the examples of zplane code given in the help documentation the z and p values are just single real values. Also, for a 4 pole/zero filter there are 5 values for z and also for p. Shouldn't this be four?

1 Comment

I'm just getting my head around the zplane function. I'm not how the values of z and p are mapped onto the pole-zero plot. I thought zeros and poles were supposed to have both real and imaginary parts - as these are the axes of the pole-zero plot. But in the examples of zplane code given in the help documentation the z and p values are just single real values. Also, for a 4 pole/zero filter there are 5 values for z and also for p. Shouldn't this be four?

Sign in to comment.

 Accepted Answer

zplane is a little subtle. When B and A are rows, they represent transfer functions. However, if B and A are columns, they are zeros and poles.
Compare
[b,a] = ellip(4,.5,20,.6);
zplane(b,a)
zplane(roots(b),roots(a))

6 Comments

Thanks - they look the same is that the way it's supposed to be? Surely roots(b) is just z and roots (a) is just p. I'm still confused I'm afraid. Do you have another example?
What I mean is that if you put in z and p as rows, they are treated as polynomial coefficients, not zeros and poles. If you want the input to be treated as zeros and poles, then they must be in columns. I hope this clarifies the syntax.
Thanks for that. I can't work out how to change my array into a column vector now. I thought it was just putting ' after it, but that's not working. If I had A=[1,2,3,4] how would I make that into a column?
You can do A(:), but A' should work if all elements in the row vector are real
great thanks :)
Hi Tom, in your code, b and a are coefficients. So if you want to use zplane, you need to keep them in the row form and zplane will automatically calculate zeros and poles for you and display in the figure.
On the other hand, if you want to pass in column vectors, then zplane treat them as just zeros and poles. In this case, you need to compute zeros and poles yourself before passing it into the function. So you need to do zplane(roots(b),roots(a)).
HTH

Sign in to comment.

More Answers (0)

Products

Tags

Asked:

Tom
on 22 May 2012

Community Treasure Hunt

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

Start Hunting!