Question

In: Electrical Engineering

Pass the signal x5 through the filter h using the command: x6 = filter(h,1,x5); In your...

Pass the signal x5 through the filter h using the command: x6 = filter(h,1,x5); In your report, include a plot of the amplitude spectrum of x6 (use the normalized frequency axis as you did for previous parts of this project).

Solutions

Expert Solution

clc
clear all
close all
fs = 600; %Sampling frequency
t = 0:1/fs:.5;
N=10;
%Input Signal
x = sin(2*pi*50*t)+sin(2*pi*150*t)+sin(2*pi*250*t);
%Band Pass filter design
d=fdesign.bandpass('N,F3dB1,F3dB2',N,100,200,fs);
Hd=design(d,'butter');
%Filtering input signal with Bandpass filter
y=filter(Hd,x);
subplot(2,1,1)
plot(t,x)
title('Input signal')
xlabel('time')
ylabel('Amplitude')
subplot(2,1,2)
plot(t,y,'-r')
title('Band Pass Filtered signal')
xlabel('time')
ylabel('Amplitude')

figure;
freq=0:(2*pi)/length(x):pi;
X=fft(x);
Y=fft(y);
subplot(2,1,1)
plot(freq,abs(X(1:length(x)/2+1)))
xlabel('Normalized Frequency (\times\pi rad/sample)')
ylabel('Magnitude')
title(['Frequency Response of input signal for order N=',num2str(N)])
subplot(2,1,2)
plot(freq,abs(Y(1:length(x)/2+1)),'-r')
xlabel('Normalized Frequency (\times\pi rad/sample)')
ylabel('Magnitude')
title(['Frequency Response of filtered signal for order N=',num2str(N)])

We can also design any type of filter using relevant filter model in the same way. Order of filter N can be changed to our requirement.


Related Solutions

Listen to the audio signal x6 using the soundsc command. In your report, describe the perceived...
Listen to the audio signal x6 using the soundsc command. In your report, describe the perceived sound and explain your results.
In matlab using a RC low pass filter Create a 1 Hz input signal (with amplitude...
In matlab using a RC low pass filter Create a 1 Hz input signal (with amplitude of one). Corrupt the input signal with signals greater than or equal to 100 Hz and/or random noise. Use randn(length(v_in,1)) to test filter
Designa low-pass filter that reduces magnitude of H(jw) to 0.4 for the signal with 10(X+4)Hz. a)Use...
Designa low-pass filter that reduces magnitude of H(jw) to 0.4 for the signal with 10(X+4)Hz. a)Use 10 Ω resistor and calculate the value of the inductance of the filter. Calculate the cutoff frequency of the filter .b)Design another filter for the same purpose by using the same resistorcombined with a capacitor.Find the value of the capacitance.Find the magnitudes of H(jw) for 2Hz and 200 Hz frequencies and sketch the frequency response graph of the filter c)(20+Y)Ωresistive loadis connected across the...
1. Design 3rd order ideal low pass filter H(s). Two poles are complex conjugates, and one...
1. Design 3rd order ideal low pass filter H(s). Two poles are complex conjugates, and one pole is on the real axis. 2. transform H(s) to H(z). (Use impulse invariance criterion) 1%criterion
Reconstruct the original signal with a higher order low pass filter. Which Sampling method (Natural, Flat-top,...
Reconstruct the original signal with a higher order low pass filter. Which Sampling method (Natural, Flat-top, Sample-and-hold) can be easy to reconstruct the signal? Explain your observations.
How can you use your circuit to obtain a low-pass or a high-pass filter? What is...
How can you use your circuit to obtain a low-pass or a high-pass filter? What is a low-pass filter used for?
Case Y X1 X2 X3 X4 X5 X6 1 43 45 92 61 39 30 51...
Case Y X1 X2 X3 X4 X5 X6 1 43 45 92 61 39 30 51 2 63 47 73 63 54 51 64 3 71 48 88 76 69 68 70 4 61 35 86 54 47 45 63 5 81 47 85 71 66 56 78 6 43 34 51 54 44 49 55 7 58 35 70 66 56 42 67 8 71 41 64 70 57 50 75 9 72 31 81 71 69 72 82...
I need to obtain an approximate implementation of a Butterworth low pass first order filter using...
I need to obtain an approximate implementation of a Butterworth low pass first order filter using P-spice. It suppose to have a cutoff frequency of 1000Hz and the attenuation cutoff frequencies fixed at 3db.
Design a second-order band-pass filter using resistors and capacitors for a microphone for a hearing aid,...
Design a second-order band-pass filter using resistors and capacitors for a microphone for a hearing aid, which allows signals in the range of 1 to 16 kHz to pass through. For the component values that you chose, at what frequency is the transfer function at a maximum?
Show that h(n) is a Lowpass filter, given that g(n) = (-1)nh(n) is a Highpass filter
Show that h(n) is a Lowpass filter, given that g(n) = (-1)nh(n) is a Highpass filter
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT