Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The MATLAB function below performs the discrete convolution: function y discrete_conv(x, h, N) y- zeros(1, 2N+1); for n- 1: 2 N+1 for m- 1:N if

image text in transcribed
The MATLAB function below performs the discrete convolution: function y discrete_conv(x, h, N) y- zeros(1, 2"N+1); for n- 1: 2 N+1 for m- 1:N if ((n-m)>0 & (n-m)N) y(n)-y(n) +x(m) * h(n-m); end end end 2. Save the function as discrete_conv.m and apply it as shown below to the example of the two pulse example. Record the result. >> xr(11 1 ]; h-[11 1 1], N-length(x); >> y-discrete_conv(x, h, N) y- 3. Apply MATLAB's convolution function as shown below. >y-conv(x, h) 4. Convolve the two pulses indirectly, using MATLAB's fft and ifft functions as shown below >> N-length(x); zzeros(1,N-1);X-fft((x z]); H-fh([hz]); y-ifft(X.* H) 5. Convolve the unequal length pulses below using the discrete_conv function. Record the result Verify using MATLAB's functions, but do not record the results. The MATLAB function below performs the discrete convolution: function y discrete_conv(x, h, N) y- zeros(1, 2"N+1); for n- 1: 2 N+1 for m- 1:N if ((n-m)>0 & (n-m)N) y(n)-y(n) +x(m) * h(n-m); end end end 2. Save the function as discrete_conv.m and apply it as shown below to the example of the two pulse example. Record the result. >> xr(11 1 ]; h-[11 1 1], N-length(x); >> y-discrete_conv(x, h, N) y- 3. Apply MATLAB's convolution function as shown below. >y-conv(x, h) 4. Convolve the two pulses indirectly, using MATLAB's fft and ifft functions as shown below >> N-length(x); zzeros(1,N-1);X-fft((x z]); H-fh([hz]); y-ifft(X.* H) 5. Convolve the unequal length pulses below using the discrete_conv function. Record the result Verify using MATLAB's functions, but do not record the results

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Practical Issues In Database Management A Refernce For The Thinking Practitioner

Authors: Fabian Pascal

1st Edition

0201485559, 978-0201485554

More Books

Students also viewed these Databases questions

Question

Explain the importance of nonverbal messages.

Answered: 1 week ago

Question

Describe the advantages of effective listening.

Answered: 1 week ago

Question

Prepare an employment application.

Answered: 1 week ago