310SE – ADVANCED DIGITAL SYSTEM ASSIGNMENT – APR 2019

profileSelva

 310SE – ADVANCED DIGITAL SYSTEM ASSIGNMENT – APR 2019 

1. You are given an image file “Q1_256gray.bmp” for image processing. Write a MATLAB program to implement the algorithm for histogram equalization. Apply this algorithm to the given image file, and plot the images and their histograms before and after the equalization. Write comments in your program to explain the algorithm clearly. Do not use the standard built-in function such as histeq() to process the image. (15 marks)  


2. a. Find and simplify the mathematical expression for the convolution of   = ℎ ⨂ , given that  =     ; ℎ =      . (5 marks) b. Write a MATLAB program to implement convolution function given by  = ℎ ⊗  = ∑ ℎ  −    . Write comments to explain the algorithm clearly. For  and ℎ as given in part (a), use your convolution function to compute ℎ ⊗  over the range 0 ≤  ≤ 20 and plot the result. Compare the result obtained in (a) and (b). Do not use built-in function conv(). (15 marks)   


3. In this Problem you are to perform spectral analysis on the audio signals provided. You are given a short piano piece “piano_sequence.wav” of duration 3 measures. The second musical note and first chord (combination of notes) are given separately in “piano_single_note.wav” and “piano_chord.wav” respectively. Write a MATLAB program to perform the followings: a. Read “piano_single_note.wav” into a vector x. b. Determine the sampling rate and number of samples in x. (2 marks) c. Use MATLAB built-in function to perform DFT on x, and save the result in X. (2 marks) d. Create an array freq (in Hz) that represents the a b. Design an IIR, 


Chebyshev type 2 filter for the same specifications in (a). What is the order of the filter? What are the filter coefficients? Plot the magnitude response and the phase response for this filter. Show the pole-zero plot for the filter. (8 marks) 

c. Compare the results of part (a) with the results of part (b). (4 marks) 


5. Exporting your filter designs in 4(a) and 4(b) to SIMULINK. In SIMULINK, create two discrete-time signals ,  supposition with a band limited white noise as follow:  = 0.000021 "#$ noise power: 0.0000021  = sin(2)*  + + noise, * = 3012  = sin(2)*  + + noise, * = 12012 Submit the circuit diagrams that show the connections of the discretised signal source, band limited white noise source, digital filters, and the scope capturing the input and output signals. Plot the input and output signals in the time-domain before and after the filters, for all 4 cases (2 signals x 2 filters). From the filter design frequency response, estimate the attenuation expect at 3kHz and 12kHz. Comment on the waveforms.  


 6. Write a VHDL code to implement the circuit function described below. The circuit is to display the last four digits of your student ID number on a 7-segment display, one digit at a time, triggered by the falling edge of the clock signal. DIR: Direction of the display sequence, ‘1’ = forward, ‘0’ = reverse. CLK: clock pulse for the display sequence. RST: reset the display counter. For example, if your ID number is 1234567, the last four digits are ‘4’, ‘5’, ‘6’, ‘7’, and the circuit is to display ‘4’, ‘5’, ‘6’, ‘7’,’4’, ‘5’,’6’,’7’…when DIR = ‘1’ and display ‘4’,’7’,’6’,’5’,’4’,’7’,’6’,’5’,’4’…when DIR = ‘0’. Code must be well-organized and clearly explained. Write a small test bench code to perform the simulation and verification. Submit your VHDL code, test bench code and the simulation waveforms. (15 marks) 

    • 7 years ago
    • 20
    Answer(1)

    Purchase the answer to view it

    blurred-text
    NOT RATED
    • attachment
      mat1.docx