E48 Digital Signal Processing Exam date: Tuesday 242 Final Exam Solutions Dan Ellis <dpwe@ee.columbia.edu>. The only twist here is to notice that the elliptical filter is actually high-pass, since it has zeros on the unit circle close to ω =, and poles in the left-hand half-plane (i.e. with more influence on the high frequencies).. (a) The roots, magnitude, and frequency response of the filter are shown below:.8.6.4.2 -.2 -.4 -.6 -.8-4.2.4.6.8.5 -.5 -.8 -.6 -.4 -.2.2.4.6.8.2.4.6.8 Having seen where the zeros are, we figure it must be HPF. We know the passband ripple is db and the stopband ceiling at db, we know that the gain goes to zero at the two zeros on the unit circle, and we know to expect two maxima in the passband ripples, corresponding to the two poles. Hence the sketch (note, you were not asked for the phase function; I include it only for reference). (b) To get from an analog LPF prototype to a discrete-time HPF, we first convert the LPF to an Ω analog-domain HPF by substituting s p Ωˆ p = -------------- where Ω p and its hatted version are the pivot ŝ frequencies. The analog HPF is then converted to discrete time via the bilinear transform. To get a passband edge at ω =.5π in the discrete domain, we need the high-pass band-edge in the analog domain prior to the bilinear transform to be at Ω = tan(ω/2) = tan(π/4) =. Since the prototype elliptical low-pass filter also has a band edge at Ω =, the LP-to-HP transformation is simply substituting s /s. To get the pole-zero diagram of the analog HPF filter, we have to undo the mapping of the s- plane to the z-plane. The unit circle (and the zeros) map to the imaginary axis, of course, and the unit circle interior to the left-hand half plane. Getting the location of the poles exactly right is tricky, but we just wanted them in roughly the right space. Here are the pole-zero E48 - Final Exam Solutions 242 - page /5
diagram and magnitude and phase responses for the analog HP filter whose bilinear transform gives us our final DT filter: 3 2-4 Im{s} 2 3 4 5.5 2 3 Re{s} -.5 2 rad / s 3 4 5 Naturally, the ripples are still at db and db, and the passband edge is at, which is also the imaginary value close to the first pole. The low-pass prototype simply reciprocates the s-plane and the frequency axis, giving: 3 2-4 Im{s} 2 3 4 5.5 2 3 Re{s} 2 3 4 5 rad / s We were looking for true reciprocal positions of the poles (i.e. same angle relative to the origin on the s-plane, but reciprocal distance) and the frequencies of the zeros (i.e. here we have HPF zeros at about.4 and.8, and LPF zeros at about.25 = /.8 and 2.7 /.4. The frequencies of the zeros in the spectrum are of course just the imaginary values for the zeros on the s-plane. And of course the ripples are still db in passband and db in the stopband, with a passband edge at Ω =. -.5 E48 - Final Exam Solutions 242 - page 2/5
2. (a) We have two pole pairs, one inside the unit circle (A), and one at reciprocal positions outside the unit circle (B). Since initially each pair can be either poles or zeros, that appears to give us four choices. However, if we have poles at B, we have an unstable filter with an illdefined Fourier transform, so we don t consider those two; the roots at B (outside the unit circle) must be zeros. This leaves in fact only two possible filters. If the roots at A are zeros, we have a constellation of four conjugate-symmetric-reciprocal zeros, indicating a 5-point type-i FIR, which is basically going to have a smooth frequency response with a single dip in it (near to the zeros). The phase will be strictly linear, with a slope of.5 samples. If the interior roots are poles, we have the root configuration of an all-pass filter with a constant gain at all frequencies, but a phase response with greatest slope near to the roots. The figure below shows the actual frequency responses of examples of both filters, for r =.7 and ω = π/3:.5.5.5 -.5.5 -.5.5.5 2 2 5 5 5 5.2.4.6.8.2.4.6.8.5.5 -.5 -.5.2.4.6.8.2.4.6.8 (b) With only two filters, there are two possibilities to consider: filtering the allpass output to look like the linear-phase output, and vice-versa. In general, neither filter is perfectly invertible because the zeros outside the unit circle would require unstable poles to cancel. But to convert one to the other, we need only change the interior roots from poles to zeros and vice versa. Thus, a filter consisting only of the two interior poles would, applied once, remove the interior zeros of the linear phase filter, and, applied a second time, reconstruct the net effect of the allpass filter (and a similar filter consisting of only the two interior zeros does the same for the allpass filter). This shows how a non-minimum-phase system can be magnitude-corrected even if it cannot be perfectly inverted. E48 - Final Exam Solutions 242 - page 3/5
3. This question is a little weird because we only defined the transpose operation for single input, single output systems, and it s not entirely clear that you can extend it to multiple-input, multiple-output systems of this kind. However, the obvious thing to do, i.e. to interchange x[] with X[], works in this case, and is what I was looking for. (a) The left panel below shows the 4-point DIT FFT flowgraph. This is the fully-optimized version, with the twiddle factors shifted prior to the splits; note that I ve explicitly put in the sign flips as multiplies, so they don t get lost in the transposition. Closed circles are splitoff nodes, and open circles are summation nodes. I ve also simplified the twiddle factor, though that doesn t matter: x[] x[2] x[] x[3] W 4 = e -j2π/4 = -j X[] X[] X[2] X[3] (b) The pane on the right is the transpose: all summation nodes and splitoff nodes are interchanged, all signal flow directions are reversed, and the input and output labels have been interchanged (as described above). I have mirror-imaged the graph, so the signal flow is still left-to-right. Actually, this is just the same algorithm as the original. If we swapped the middle two rows (the ones starting with x[] and x[2]) while preserving the topology, we end up with the graph on the left again. This argument, coherently made, was sufficient to answer the question. But let s just check that it really does calculate the 4 point DFT: If we assign names to the outputs of the first four summers, as shown on the figure, we get: a = x[] + x[2] b = x[] + x[3] c = x[] x[2] d = x[] x[3] Working through the final stage, we get: X[] = a + b = x[] + x[] + x[2] + x[3] X[2] = a b = x[] x[] + x[2] x[3] X[] = c j d = x[] j x[] x[2] + j x[3] X[3] = c + j d = x[] + j x[] x[2] j x[3].. which is indeed the correct definition of the 4 values of the 4 point DFT, so it works. x[] x[] x[2] x[3] a b c d -j X[] X[2] X[] X[3] 4. The simple bandpass filter is the one we covered in class, so my hope was you should not be too disoriented by the transfer function. The only difference is that I wrote β directly as cos ω c to avoid unnecessary notation. In fact, you don t need to do anything with the transfer function, it s just about reading the right values from the graphs presented. (a) We want a filter with a center frequency of π/4 and a Q of 8, so its bandwidth will be (π/4)/8 or.325 π. Assuming it is symmetric around ω c, it would be from about.234π to.266π. To E48 - Final Exam Solutions 242 - page 4/5
achieve an attenuation of 3dB relative to the peak at those frequencies puts us pretty much exactly midway between the second and third most narrow curves in the zoomed-in magnitude response plot, which would give us an estimate of α of.9. In fact, slide 4 of lecture 6 gave us a closed-form equation relating bandwidth B to α: 2α B = acos-------------- + α 2 cos( B)α 2 2α + cos( B) = The solution to this quadratic gives the precise value of α as.963. To achieve the same 3dB bandwidth with a cascade of two identical filters, we would want the attenuation of each one to be.5db at these frequencies, so the net effect of the two stages is 3dB. From the zoomed-in magnitude graph, this puts us midway between the 3rd and 4th broadest curves, for an α of about.85. The plots below show the actual responses of these two filters: α =.963-4 two stages α =.85-4 -6 π.5π phase / rad.5π phase / rad -.5π -π.2π.4π.6π.8π π -.5π.23π.24π.25π.26π.27π Naturally, they are approximately the same in the region of the peak response; it is elsewhere in frequency that they differ more. Away from the peak frequency, the 4th order filter has greater attenuation in the stop band, as well as a larger maximum phase shift at the extreme frequencies. This reflects the fact that varying alpha has relatively little effect on the responses outside of the region of the peak (at least compared to absolute size of the response), but cascading the filters doubles the gain and phase effects in these regions. (b) This question is about group delay: the narrowband modulator will be shifted in time by the group delay, to first order. We see both filters have a local slope of about -π/.4π around the center frequency, so the group delay should be about 25 samples. The carrier phase shift is zero, so the output y[n] m[n 25] cos.25πn. In fact, the slope of the 2nd order filter is a little less, and its group delay is closer to 2 samples. E48 - Final Exam Solutions 242 - page 5/5