1 / 41

Tutorials 11,12,13 discrete signals and systems

Tutorials 11,12,13 discrete signals and systems. Technion, CS department, SIPC 236327 Winter 2012-2013. 1. Discrete LSI system. Linear Space invariant. 2. Discrete LSI system. Linear Space invariant. 3. E xample.

sanne
Download Presentation

Tutorials 11,12,13 discrete signals and systems

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Tutorials 11,12,13discrete signals and systems Technion, CS department, SIPC 236327 Winter 2012-2013 1

  2. Discrete LSI system • Linear • Space invariant 2

  3. Discrete LSI system • Linear • Space invariant 3

  4. Example • For compression, a rule to predict the pixel value is used:Is the system linear? Space invariant? 4

  5. Discrete LSI system • System is defined with its impulse response 5

  6. Cyclic convolution Convolution • Infinite support • DTFT • Finite support • DFT • Efficient implementation 6

  7. Exercise Q: How can we use this system to calculate a linear convolution? A: Zero padding, and truncation of the result. H Q: If both signals are of length N, how many zeros will we add? A: N-1 zeros 7

  8. Exercise Q: How can we use this system to calculate a cyclic convolution? A: Duplicate one signal, and truncation of the result. H Q: If both signals are of length N, how much should we duplicate A: N-1 cells 8

  9. Discrete Fourier Transform (DFT, FFT) Infinite support infinite support Continiuous continuous Finite support Finite support Discrete Discrete 9

  10. DFT • התמרות הDFT וDFT-1מתבצעות בדרך הרגילה • המקדמים מחזוריים: • לכן במקום להתייחס לתחום [0,N-1] בד"כ מסתכלים על התחום [-N/2,N/2-1]. 10

  11. הפעלת DFT 11

  12. דוגמאות DFT 12

  13. Summary – Fourier Transforms • Fourier transform • Time domain – non-periodic infinite signals • Continuous time (t) • Continuous frequency (f) • Formulas

  14. Summary – Fourier Transforms • DTFT: Discrete Time Fourier Transform • Time domain – non-periodic infinite signals • Discrete time (n) • Continuous frequency (f) • Formulas לא נלמד בקורס

  15. Summary – Fourier Transforms • Fourier series • Time domain – periodic infinite signals • Continuous time (t) • Discrete frequency (f) • Formulas

  16. Summary – Fourier Transforms • DFTor Discrete Time Fourier Series • Time domain – periodic infinite signals • Discrete time (n) • Discrete frequency (f) • Formulas

  17. DFT ומערכת LSI 17

  18. Exercise • We have an N-length filter with impulse response h[n].We create a new filter as follows: Express F[k] with H[k], where H[k]=DFT{h[n]},F[k]=DFT{f[n]} • Instructions: calculate 18

  19. Example – discrete frequency filtration • Noisy image of size 256X256 Im_out[m,n]=Im_in[m,n]+noise[m,n] • Harmonic noise: • f= 1/(8 pixels) • Amplitude A and phase φ are random and independent for each line.

  20. Example – added noise in line 100

  21. Example – discrete frequency filtration

  22. Example – discrete frequency filtration - smoothing

  23. Example – discrete frequency filtration– smoothing vs median (8 pixels) No noisebut image is blurred

  24. Example – discrete frequency filtration • DFT of the noise in line i

  25. Example – discrete frequency filtration • Design an LSI filter • Such filter multiplies each frequency with a complex number • Can handle each frequency separately • In this example, we want to handle frequencies 32 and -32. • Notch filter – attenuates specific frequency

  26. Example – discrete frequency filtration Original signal in frequency domain Filtered signal in frequency domain

  27. Example – discrete frequency filtration • Noise removed completely • Original image not fully restored • We cannot restore the attenuated frequencies

  28. Example – discrete frequency filtration Smoothing filter of 8 pixels Notch filter

  29. Filter in freq. domain: Filter=ones(1,256); Filter(32+1)=0; Filter(224+1)=0; Filtration: For k=1:size(I,1), Y=fft(I(k,:)).*Filter; I(k,:)=ifft(Y); end Example –frequency filtration - implementation Notch filter in freq. domain

  30. Tutorials 11,12,13discrete signals and systemsPart II: 2D Technion, CS department, SIPC 236327 Winter 2012-2013 30

  31. 2D - definitions 2Dconvolution: 31

  32. 2D - definitions • Cyclic 2D-convolution: • 2D DFT: 32

  33. 2D - notes • DFT is linear, we have an operation matrix: • 2D-DFT can be implemented as: • If the input is separable: 33

  34. Example • Noisy image 512X512 • The noise:Add 100 gray levels for all 16i lines 34

  35. Example Noisy image Average filter 35

  36. Example Noisy image Average filter 36

  37. Example • How does the noise look like in the frequency domain? 37

  38. Example After freq. filtration • Filter implementation in the freq. domain: H=ones(512,512); for n=1:32:512 H(n,1) = H(1,n) = 0; end H(1,1) = 1; • Image filtration: out = ifft( fft(img).*H ); 38

  39. לפני סינון תדר 39

  40. לפני סינון תדר (הגדלה של מרכז) 40

  41. אחרי סינון תדר (הגדלה של מרכז) 41

More Related