Question

(a) Does it have to be this way? Briefly explain, is it possible to have an online FIR filter without a window function? (b)

Please do both questions! thank you very much!

0 0
Add a comment Improve this question Transcribed image text
Answer #1

a)Yes .This is possible with Parks-McClellan optimal FIR filter design using FIRPM command and Least-squares linear-phase FIR filter design using firls.

EX: Uisng FIRPM

f = [0 0.5 0.6 1];

a = [ 1 1 0 0];

b = firpm(17,f,a);

freqz(b,1,512);

20 0 ︶-20 g 40 60 -80 -100 0.2 0.4 0.6 0.8 Normalized Frequency (×π rad/sample) 0 -500 -1000 a) -1500 -2000 2500 0.2 0.6 0.8

__________________________________________________________________________________

b)Using HAmming window:

(i)

MATLAB:

clc;clear all;close all;


N=100;wc=0.3004;
n=0:1:N-1
hLP=wc*(sinc(wc.*(n-((N-1)/2))))
WHAM=hamming(N)'
hWLP=hLP.*WHAM

%Magnitude response
w=0:0.01*pi:pi
[H,w]=freqz(hWLP,[1],w)


figure(1)
subplot(221)
stem(n,WHAM,'r')
title('Hamming window ')
xlabel('n')
ylabel('wh(n)')

subplot(222)
stem(n,hWLP,'m')
title('Impulse response h(n)')
xlabel('n')
ylabel('h(n)')

subplot(223)
plot(w/pi,abs(H),'b')
title('Magnitude response ')
xlabel('w/pi')
ylabel('|H(exp(jw)|')

subplot(224)
plot(w/pi,angle(H),'b')
title('Phase response ')
xlabel('w/pi')
ylabel('<H(exp(jw)>')


figure(2)
freqz(hWLP,[1])

Hamming window Impulse response h(n) 0.3 0.8 0.6 30.4 0.2 S 0.1 0.2 0.1 40 60 80 20 40 60 20 80 100 100 Magnitude response Ph

100 Ф-100 -200 -300 400 0.6 0.8 0.2 0.4 Normalized Frequency (×π rad/sample) 500 3 -1000 -1500 g -2000 Q -2500 -3000 3500 0.6

ii)MATLAB:

N=100;wc=0.3004;
h=fir1(N,wc)
freqz(h,1)

50 2-50 2 -100 150 0.6 0.8 0.2 0.4 Normalized Frequency (xt rad/sample) 500 3 -1000 -1500 g -2000 Q -2500 -3000 3500 0.6 0.8


The response produced by FIR1 command and the response produced by using Hamming window without using FIR1 command- both are same why because the the command FIR1 uses hamming window for its windowing process.

Add a comment
Know the answer?
Add Answer to:
Please do both questions! thank you very much! (a) Does it have to be this way? Briefly explain, is it possible to have an online FIR filter without a window function? (b) Low-Pass Filter Consider...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • a) The transfer function of an ideal low-pass filter is and its impulse response is where...

    a) The transfer function of an ideal low-pass filter is and its impulse response is where oc is the cut-off frequency i) Is hLP[n] a finite impulse response (FIR) filter or an infinite impulse response filter (IIR)? Explain your answer ii Is hLP[n] a causal or a non-causal filter? Explain your answer iii) If ae-0. IT, plot the magnitude responses for the following impulse responses b) i) Let the five impulse response samples of a causal FIR filter be given...

  • b) When designing a FIR filters, the impulse response of the ideal low-pass filter is usually modified by multiplying i...

    b) When designing a FIR filters, the impulse response of the ideal low-pass filter is usually modified by multiplying it by a windowing function such as the Hamming window which is defined, for an odd number N of samples, by: (2n)-(N-I)-ns(N-1) N-12 wlnl 0.54 + 0.46 cos i What are the advantages of windowing with this function compared 2 with a standard rectangular window? ii) Design a 10th Order Hamming windowed FIR low-pass filter with cut- off frequency at 1000...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT