Please show work and answers Create your own audio file that is at least 4 secon
ID: 2844735 • Letter: P
Question
Please show work and answers
Create your own audio file that is at least 4 seconds long (the exact time duration is not really important, but do not make the file too long). Use the wavrecord command in MATLAB and a sampling frequency of 10000 Hz. You can also try to find a wav file online. Use the sound command in MATLAB to play the sound. Make sure the recording is fine. Using the wavread command, read the signal into a vector called x. Also read the sampling frequency in to a variable called Fs. Make sure you understand what this sampling frequency means. Plot the received signal as a function of time. Your time axis must have units in seconds. Even though the audio signal is originally a continuous-time signal, we cannot represent such signals on a digitial computer directly. In this example, you have sampled the continuous time signal and you are representing it as a discrete-time signal. Create the signal x[2n] and play the signal. See that it sound shriller. Make sure you use the same sampling frequency from before. Think about why this should be the case. Simulate a room with echo. Suppose this speech signal is played in a large room which results in significant echo. Let us model the echo as being composed of a direct path which has no delay and two reflected paths. one corresponding to a delay of tau seconds and another corresponding to a delay of 2 tau seconds. Let the reflection coefficient forthese two paths be 0.9 and 0.81 respectively. Simulate the received signal y[n] and play it using the sound command. Play around with different values of tau and in your opinion, what is the smallest value of tau for which you can clearly start to hear some distortion in the signal?Explanation / Answer
Use $(a, b) to represent integral from a to b.
a) g(-7) = $(-3, -7) f(x) dx = $(-3, -7) 0 dx = 0
g(0) = $(-3, 0) f(x) dx = $(-3, 0) 3 dx = 3*(0 - (-3)) = 9
g(3) = $(-3, 3) f(x) dx = $(-3, 3) 3 dx = 3*(3 - (-3)) = 18
g(6) = $(-3, 6) f(x) dx = $(-3, 3) 3 dx + $(3, 6) (6 - x) dx = 18 + 4.5 = 22.5
g(7) = $(-3, 7) f(x) dx = $(-3, 3) 3 dx + $(3, 7) (6 - x) dx = 18 + 4 = 22
g(9) = $(-3, 9) f(x) dx = $(-3, 3) 3 dx + $(3, 7) (6 - x) dx + $(7, 9) (-1) dx = 18 + 4 - 2 = 20