How to solve using matlab The purpose of this problem is to use MATLAB to perform discrete-time conv

How to solve using matlab


The purpose of this problem is to use MATLAB to perform discrete-time convolution and to solve a linear difference equation. Consider an LTI system described by the difference equation y[n] 0.8y[n-1]-2x[n] under the assumption of initial rest. We want to use MATLAB to compute the output y[n] for the following three inputs x[n]: (i) u[n] - u[n-2], (ii) u[n] 2u[u-2]+ u[n-6], and (ii) (0.7)*n u[n]. This should be done for each input using the three methods given below. For each method, turn in a listing of the code used to compute y[n], along with plots of x[n] and y[n] on the same axes (using an appropriate range 5. 3 5 9 of n to adequately illustrate the solution). a) (10 pts) Design a program to implement this equation directly in MATLAB. That is, your program should perform the recursion similar to that in Example 2.15. b) (10 pts) Design a program to implement the convolution sum directly. This should be written for arbitrary x[n] and h[n]. Note that to do this, you will have to determine the impulse response h[n] of this system, either analytically or using the results of part a) c) (5 pts) Use the convO function to compute the convolution. The convO function is a built-in function of MATLAB. Compare the results that you obtain to those in parts a) and b). The purpose of this problem is to use MATLAB to perform discrete-time convolution and to solve a linear difference equation. Consider an LTI system described by the difference equation y[n] 0.8y[n-1]-2x[n] under the assumption of initial rest. We want to use MATLAB to compute the output y[n] for the following three inputs x[n]: (i) u[n] – u[n-2], (ii) u[n] 2u[u-2]+ u[n-6], and (ii) (0.7)*n u[n]. This should be done for each input using the three methods given below. For each method, turn in a listing of the code used to compute y[n], along with plots of x[n] and y[n] on the same axes (using an appropriate range 5. 3 5 9 of n to adequately illustrate the solution). a) (10 pts) Design a program to implement this equation directly in MATLAB. That is, your program should perform the recursion similar to that in Example 2.15. b) (10 pts) Design a program to implement the convolution sum directly. This should be written for arbitrary x[n] and h[n]. Note that to do this, you will have to determine the impulse response h[n] of this system, either analytically or using the results of part a) c) (5 pts) Use the convO function to compute the convolution. The convO function is a built-in function of MATLAB. Compare the results that you obtain to those in parts a) and b).

You don't know how to answer this question. We can help you find the right answer.

We assure you an A+ quality paper that is free from plagiarism. Order now for an Amazing Discount! Use Discount Code "save15" for a 15% Discount!

Get Started

No need to wonder who can do my homework. You can always reach our team of professionals to do your homework at a low price.