LUND INSTITUTE OF TECHNOLOGY Dept. of Electroscience Exam in DIGITAL SIGNAL PROCESSING IN AUDIO/VIDEO (ETI270) 2003-05-27 Hours: 4.00 9.00 Room: MA9B-D Aid Observandum Tables, calculator, the textbook by Mitra. Solutions manual or lecture notes are not allowed. To simplify correction, please: include only one solution per page, write your name on all pages, motivate statements by proper reasoning, equations, or reference(s) to the textbook. Grades (required minimum points): 3 (3.0), 4 (4.0), 5 (5.0).. Provide brief answers to the following questions: a) Why is the DCT used instead of the DFT in JPEG compression? (0.) b) What does frequency masking mean within psychoacoustics? (0.) c) What does perfect reconstruction mean for a filter bank? (0.) d) What does Signal-to-Mask ratio mean in music compression and how is it used to reduce the bit rate? (0.) e) Explain how JPEG compresses an image by using basis functions and weights. (0.2) f) Explain how a filter bank can transform a sequence of 384 samples into 32 sequences, each with 2 samples, without loss of information. (0.2) g) When and why is it acceptable to change positions of an upsampler and a downsampler (no proof is needed)? (0.2) 2. a) Upsample and downsample each of the three spectra shown in Figure by a factor of two and present the result graphically. (0.6) b) For downsampling, in which case(s) is lowpass filtering needed to avoid aliasing? (0.4) 3. Derive the two band polyphase decomposition of the following IIR filter H(z) = 2 + 3.z +.5z 2 + 0.9z + 0.8z 2
2/3 /3 /3 2/3 /2 /2 Figur : Problem 2 and sketch the corresponding block diagram. 4. The input signal to a filter has quantization noise with variance one. Determine the noise variance of the output signal when the input signal is fed through the IIR filter: H(z) = z2.9z +.2 z 2 0.3z + 0.9 5. a) Determine the analog frequency response G(Ω) for a third order Butterworth filter with the cut-off frequency Ω c = rad/s. (0.3) b) Determine the corresponding digital filter, H 0 (z), by using the bilinear transformation. (0.3) c) Rewrite the filter on the form H 0 (z) = 2 (A 0(z 2 ) + z A (z 2 )) where A 0 (z) and A (z) are stable allpass filters. (0.2) d) Show by means of a block diagram how H 0 (z) can be implemented by using one single multiplier. (0.2) 6. a) Determine the two transfer functions for the system in Figure 2 which relate the two output signals to the input signals. (0.7) 2
b) What is the over-all purpose of this particular system? (0.2) c) Is the system time-invariant? (0.) Figur 2: Problem 6 Good Luck!! 3
LUNDS TEKNISKA HÖGSKOLA Inst. för Elektrovetenskap Lösningar till tentamen i DIGITAL SIGNALBEHANDLING I AUDIO/VIDEO (ETT270) 2003-05-27 Tid: 4.00 9.00 Sal: MA9B-D Hjälpmedel Observandum Räkne och transformtabeller, formelsamlingar, räknedosa, kursboken (Mitra). Dock inga skrivna lösningar till övningsuppgifter eller föreläsningsanteckningar. För att underlätta rättningen: -Lös endast en uppgift per blad. -Skriv namn på samtliga blad. Påståenden måste motiveras via resonemang, ekvationer eller lämplig referens till boken. Betygsgränser: 3 (2.0p), 4 (3.0p), 5 (4.0p).. a) DCT basfunktionerna är mjukare för ögat dvs det behövs färre basfunktioner jämfört med DFT för att det ska se hyfsat bra ut. (0.) b) Att frekvenser i närheten av en stark ton maskeras bort dvs inte kan höras. (0.) c) Att filterbanken inte ger amplitud- och fasdistorsion utan har samma fördröjning och förstärkning för alla frekvenser? (0.) d) Hög maskeringsnivå dvs lågt SMR betyder att få bitar ska placeras där eftersom kvantiseringsbruset ändå inte hörs. (0.) e) Ett 8x8 block projiceras på 8x8 olika basfunktioner (bilder). Var och en av dessa bilder får därmed en vikt. Det är dessa vikter som skickas över i JPEG. Kompression åstadkoms bl a genom att bara vikterna för de viktigaste basfunktionerna skickas med. (0.2) f) Varje subband viks vid nedsampling till basbandet (lågpass). (0.2) g) När dessa inte har några gemensamma nämnare (M and L mutually prime)? (0.2) 2. Vikning i och 2 och därför behövs lågpassfiltrering där. Se figur. 3. Följande överföringsfunktion är given H 0 (z) = 2 + 3.z +.5z 2 + 0.9z + 0.8z 2
Uppsampling Nersampling vikning (*2) vikning (*2) 2/3 /3 /3 2/3 2/3 /3 /3 2/3 /2 /2 /2 /2 /2 vilket ger att Då blir Figur : Problem 2 H (z) = H 0 ( z) = 2 3.z +.5z 2 0.9z + 0.8z 2 E 0 (z 2 ) = 2 [H (z) + H ( z)] = 4 + 0.62z 2 + 2.4z 4 + 0.79z 2 + 0.64z 4 och z E (z 2 ) = 2 [H (z) H ( z)] = 2.6z + 2.26z 3 + 0.79z 2 + 0.64z 4 vilket slutligen ger oss den tvåbandiga polyfas uppdelningen av H (z) som ( ) ( 4 + 0.62z 2 + 2.4z 4 H 0 (z) = + z + 0.79z 2 + 0.64z 4 2.6 + 2.26z 2 + 0.79z 2 + 0.64z 4 4. a) Enligt ekvationerna 5.34 och 5.35 i boken så blir en tredje ordningens lågpass Butterworth överföringsfunktion enligt där H a (s) = (s p )(s p 2 )(s p 3 ) p = e j2/3 p 2 = e j = p 3 = e j4/3 = e j2/3 2 )
vilket ger H a (s) = b) Med den bilinjära transformen så får vi (s + )(s 2 + s + ) (0.3) H 0 (z) = H a (s) s= z z+ = (z + ) 3 (z + z + ) ((z ) 2 + (z 2 ) + (z + ) 2 ) (z + )3 = 2z(3z 2 + ) = ( + z ) 3 = + 3z + 3z 2 + z 3 = 6 + 2z 2 6 + 2z 2 2 = ( A0 (z 2 ) + z A (z 2 ) ) 2 ( + 3z 2 + z 3 + z 2 ) c) Vi kan nu bestämma H (z) som A 0 (z) = + 3z 3 + z A (z) = H (z) = H 0 ( z) = ( z ) 3 6 + 2z 2 (0.3). (0.2) d) En realisering, med en multiplikator, av QMF banken enl lösn till 0.39. (0.2) 5. För att beräkna output noise variance, σv 2, så antar vi att σ2 e = (dvs vi beräknar normalized output noise variance: σv,n 2 ). Filtret som vi ska beräkna σv,n 2 för är H(z) = z2.9z +.2.6z + 0.3 = + z 2 0.3z + 0.9 z 2 0.3z + 0.9 För att beräkna σ 2 v,n så använder vi ekvation 9.84 och tabell 9.4 (där alla värden för ekvation 9.88 är beräknade) i boken. Då får vi σ 2 v,n = + (.62 + 0.3 2 )( 0.9 2 ) 2 0.3 (.6) ( 0.3) ( 0.9) ( 0.9 2 ) 2 + 2 0.9 0.3 2 ( + 0.9 2 ) 0.3 2 = + 6.2 = 7.2 6. a) Med u[n] och v[n] enligt figur så blir U(z) = X (z 2 ) + z X 2 (z 2 ) 3
u[n] v[n] Figur 2: Problem 6 g[n] och V (z) = H(z 2 )U(z) G(z) = z V (z) Detta ger Y (z) = 2 Y 2 (z) = 2 k=0 V (z /2 W k 2 ) = 2 [V (z/2 ) + V ( z /2 )] = 2 [H(z)U(z/2 ) + H(z)U( z /2 )] = 2 [H(z)(X (z) + z /2 X 2 (z)) + H(z)(X (z) z /2 X 2 (z))] = H(z)X (z) k=0 G(z /2 W k 2 ) = 2 [G(z/2 ) + G( z /2 )] = 2 [z /2 V (z /2 ) z /2 V ( z /2 )] = 2 [z /2 H(z)U(z /2 ) z /2 H(z)U( z /2 )] = 2 [H(z)(z /2 X (z) + z X 2 (z)) H(z)(z /2 X (z) z X 2 (z))] = H(z)z X 2 (z) b) Med den här metoden kan man skicka två separata datamängder över samma kanal H(z) samtidigt. Man skickar dubbelt så snabbt som samplingsfrekvensen och skickar varannat värde från vardera signalen. c) Ja, förskjuts insignalen ett sampel så sker samma med utsignalen. Uppoch nersamplarna är tidsinvarianta. 4