0
$\begingroup$

Does anyone have a reference handy on how to convert poles and zeros of a system to differential/difference equations.

Here is a quick draft of math, but I am not sure if it's at all correct. First, solving the characteristic equation gives the eigen values (equal to poles). Applying rudimentary knowledge of differential equations, the solution regarding only the poles should be:

$$\text {Poles Diffrential}: p(t)= \sum_{i=1}^{n_1} c_ie^{t\times \text{p}_i} $$

$$\text {Poles Difference}:p[n]= \sum_{i=1}^{n_1} c_i\text{p}_i^n $$

Where the $p_i$ is the value of ith pole and C is some constant, possibly scaled to the inverse value of the number of poles, the index runs from 1 to $n_1$, the number of poles. I denote the solution that considers only poles/characteristic equation as $p(t)$. (To be exact, c is the input/initial value at time zero so we still have the denominator of characteristic equation as cz^0=c).

Next, zeros should be solved in respect to time/samples. This should be an easy task, considering that the input equation which zeros are solved from, directly outputs the signal. First solve the Y(z) (equivalent to the numerator of the transfer function):

$$Y[z]=\prod_{i=1}^{n_2}(z-q_i)$$

Where $q_i$ is the value of ith zero and $n_2$ the number of zeros. The function needs to still be converted to time doimain by converting each individual elements $az^{x}$ into $z[n(-x)]=a$. Things get more complicated when both elements are considered simultaneously. Unless my interpretation is incorrect, the input equation (used for zeros) acts as a signal that is fed into the recursive filter(poles portion). Thus the final interpretation can be had by simply convolving the equations (with $c_i=1$):

$$ \text {Zeros, Poles}: y[n] = p[n] * z[n] $$

Where the $p[n]$ and $z[n]$ from the preceding equations and $*$ is the convolution operator. To solve the differential equation variation, simply substitute $t$ in place of $n$ for zeros and the output.

$\endgroup$
  • 2
    $\begingroup$ if i were you, i would adopt a semantic that is recognizable to electrical engineers. your "$p(t)$" should be (dirac) impulse response $h(t)$. "$p(n)$" should be discrete-time (kronecker) impulse response $h[n]$. better not use "$n$" as the top limit of your summation to avoid confusion with the other $n$. you should express your poles and zeros (i would use the semantic $p_i$ and $q_i$) in terms of your transfer function $H(s)$ or $H(z)$. such as $$ H(z) = H_0 \frac{(z-q_1)(z-q_2)...(z-q_M)}{(z-p_1)(z-p_2)...(z-p_N)} $$ where $M \le N$. $\endgroup$ – robert bristow-johnson Jun 28 '16 at 18:38
  • $\begingroup$ to add what @robertbristow-johnson said: it's really bad style to use $words$ as variable names, because things get ambiguous ($words\overset?= w\cdot o\cdot r\cdot d\cdot s$). Also, avoid $*$, because that operator is commonly used for convolution. Simply use nothing or the multiplication dot $\cdot$. Same goes for $\times$ - that commonly is used to mark multi-dimensional spaces (as in $\mathbb R^{N\times N}$), but never to denote multiplication! $\endgroup$ – Marcus Müller Jun 28 '16 at 21:45
  • $\begingroup$ @MarcusMüller Thanks for the feedback, I will try to tidy things a bit. The * is the convolution operator! (not multiplication). $\endgroup$ – Dole Jun 29 '16 at 0:38
  • $\begingroup$ i still can't recognize the mathematics as anything i am familiar with regarding poles and zeros in linear, time-invariant systems. (particularly the $z(t)$ equation; where is "$t$" in the right-hand side of that equation?) $\endgroup$ – robert bristow-johnson Jun 29 '16 at 2:44
  • $\begingroup$ @robertbristow-johnson I made some more edits. The idea behind that equation is to convert the zeros back into the transfer function input representation (that is the equation $Y[z]$). Then convert that into the time domain by using the exponent of z (in reverse order) as the time index and the preceding coefficient of z as the amplitudes for each respective time index. I also changed this to the discrete manifestation, because I am not sure how this would work with continuous signals. By the way, why is M<=N? $\endgroup$ – Dole Jun 29 '16 at 3:08
3
$\begingroup$

Okay, I'm gonna attempt an answer to this while I am still convinced the question is ill-formed. I am answering the title of the question without really referring to the text of the question, which I don't understand.

First, for discrete-time: A general IIR (or even FIR in which all of the poles are at the origin, where $z=0$) transfer function is:

$$\begin{align} H(z) \triangleq \frac{Y(z)}{X(z)} & = H_0 \frac{(z-q_1)(z-q_2)(z-q_3)...(z-q_M)}{(z-p_1)(z-p_2)(z-p_3)...(z-p_N)} \\ \\ & = H_0 \frac{z^M (1-q_1 z^{-1})(1-q_2 z^{-1})(1-q_3 z^{-1})...(1-q_M z^{-1})}{z^N (1-p_1 z^{-1})(1-p_2 z^{-1})(1-p_3 z^{-1})...(1-p_N z^{-1})} \\ \\ & = z^{M-N} \ \frac{H_0 \ (1-q_1 z^{-1})(1-q_2 z^{-1})(1-q_3 z^{-1})...(1-q_M z^{-1})}{(1-p_1 z^{-1})(1-p_2 z^{-1})(1-p_3 z^{-1})...(1-p_N z^{-1})} \\ \\ & = z^{M-N} \ \frac{b_0 + b_1 z^{-1} + b_2 z^{-2} + b_3 z^{-3} + ... + b_M z^{-M} }{ 1 + a_1 z^{-1} + a_2 z^{-2} + a_3 z^{-3} + ... + + a_N z^{-N} } \end{align}$$

$N$ is the number of poles, $p_i$, and $M$ is the number of zeros, $q_i$.

The difference equation comes from moving a few of the above things around.

$$\begin{align} Y(z) & \left( 1 + a_1 z^{-1} + a_2 z^{-2} + ... + a_N z^{-N} \right) \\ & \quad = X(z) z^{M-N} \left( b_0 + b_1 z^{-1} + b_2 z^{-2} + ... + b_M z^{-M} \right) \end{align}$$

$$\begin{align} Y(z) = \ & b_0 z^{M-N} X(z) + b_1 z^{M-N-1} X(z) + b_2 z^{M-N-2} X(z) + ... \\ & \quad ... + b_M z^{-N} X(z) - a_1 z^{-1}Y(z) - a_2 z^{-2}Y(z) - ... - a_N z^{-N}Y(z) \end{align}$$

Inverting the Z Transform, this becomes

$$\begin{align} y[n] = \ & b_0 \ x[n+M-N] + b_1 \ x[n+M-N-1] + b_2 \ x[n+M-N-2] + ... \\ & \quad ... + b_M \ x[n-N] - a_1 \ y[n-1] - a_2 \ y[n-2] - ... - a_N \ y[n-N] \end{align}$$

For a causal system or filter, we cannot look into the future for any input sample $x[n]$. That means $M \le N$ so that there is no negative delays on the $x[n+M-N]$ term.

Often $M=N$ (the numbers of poles and zeros are the same) and you get the more familiar

$$\begin{align} y[n] = \ & b_0 \ x[n] + b_1 \ x[n-1] + b_2 \ x[n-2] + ... + b_N \ x[n-N] \\ & \quad - a_1 \ y[n-1] - a_2 \ y[n-2] - ... - a_N \ y[n-N] \end{align}$$

and the more familiar transfer function

$$\begin{align} H(z) & = H_0 \frac{(z-q_1)(z-q_2)(z-q_3)...(z-q_N)}{(z-p_1)(z-p_2)(z-p_3)...(z-p_N)} \\ \\ & = \frac{H_0 \ (1-q_1 z^{-1})(1-q_2 z^{-1})(1-q_3 z^{-1})...(1-q_N z^{-1})}{(1-p_1 z^{-1})(1-p_2 z^{-1})(1-p_3 z^{-1})...(1-p_N z^{-1})} \\ \\ & = \frac{b_0 + b_1 z^{-1} + b_2 z^{-2} + b_3 z^{-3} + ... + b_N z^{-N} }{ 1 + a_1 z^{-1} + a_2 z^{-2} + a_3 z^{-3} + ... + + a_N z^{-N} } \end{align}$$

That demonstrates where the difference equation (and the feedforward, $b_i$, and feedback, $-a_i$, coefficients) come from the poles, $p_i$, and zeros, $q_i$.

The problem remaining, which is the hard problem, is that I didn't bother to multiply it out. So you have to blast this out:

$$\begin{align} H_0 \ & (1-q_1 z^{-1})(1-q_2 z^{-1})(1-q_3 z^{-1})...(1-q_M z^{-1}) \\ & \quad = b_0 + b_1 z^{-1} + b_2 z^{-2} + b_3 z^{-3} + ... + b_M z^{-M} \end{align}$$

and

$$\begin{align} & (1-p_1 z^{-1})(1-p_2 z^{-1})(1-p_3 z^{-1})...(1-p_N z^{-1}) \\ & \quad = 1 + a_1 z^{-1} + a_2 z^{-2} + a_3 z^{-3} + ... + a_N z^{-N} \end{align}$$

You can see right away that $b_0 = H_0$ and that $a_0=1$ (I never really had an "$a_0$" term anyway), but you have to blast out the multiplication of the binomials to get the polynomials. You can also see that $b_M = (-1)^M H_0 q_1 q_2 q_3 ... q_M$ and $a_N = (-1)^N p_1 p_2 p_3 ... p_N$ That's not a simple expression, but I hope you understand what you must do here.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.