In the following Matlab command H freqzb a 3 pi6 pi10003pi

In the following Matlab command: H = freqz(b, a, -3* pi:6* pi/1000:3*pi), explain what are the meaning of the three input parameter? What is the dimension of the output vector H? Explain how can you plot the magnitude and phase response in Matlab given a system transfer function.

Solution

Ans)

[h,w] = freqz(b,a,n) returns the n-point frequency response vector, h, and the corresponding angular frequency vector, w, for the digital filter with numerator and denominator polynomial coefficients stored in b and a, respectively.

in your case instead of n ,you have given -3pi:6pi/1000:3pi

From this length or dimension of output vector H=length of n which is 1000 in this case,as you can see that there are 1000 points in between -3pi and 3pi

so Dimension of H=1 X 1000

-------------------------------------------------------------

To plot the magnitude and phase response from transfer function ,take the coefficeints of numerator and denominator of transfer function into vectors b and a respectively

then use the following command

[h,w] = freqz(b,a,n)

where \'h\' has frequency response and \'w\' has angular frequency values

To plot magnitude response use command

plot(w,abs(h))

abs(h) gives magnitude response

similarly

angle(h) gives phase reponse

plot(w,angle(h))

 In the following Matlab command: H = freqz(b, a, -3* pi:6* pi/1000:3*pi), explain what are the meaning of the three input parameter? What is the dimension of t

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site