Question

Remove noise from the signal below and plot the original signal less noise. y=[2.75428, 5.71513, 4.74625,...

Remove noise from the signal below and plot the original signal less noise.

y=[2.75428, 5.71513, 4.74625, 4.0357, 3.58133, 4.29361, 3.17913,3.96698, 4.947, 2.50101, 5.18169, 2.42088, 4.19325, 5.36498, 3.02793,5.3784, 2.79834, 5.13506, 5.43307, 5.70375, 4.02817, 3.45414,3.15312, 3.77185, 3.1477, 3.61882, 4.29079, 1.62228, 5.45282,5.21009, 2.99312, 3.5315, 2.37493, 4.56933, 3.66105, 2.94791,4.00497, 5.01201, 2.42359, 3.34126, 2.95821, 1.60697, 2.69763,3.32045, 4.58761, 3.78392, 1.14806, 1.12364, 2.98555, 1.68054,2.34178, 0.954301, 2.95354, 1.85866, 0.70389, 2.74476, 1.86708,2.5442, 2.26406, 0.984498, 3.01632, 2.65318, 0.928562, 2.69881,1.08165, 2.03826, 3.19213, 4.30941, 1.39572, 3.1275, 2.88962,4.00469, 3.20351, 2.21581, 1.29336, 3.77378, 0.952478, 1.04008,1.25416, 1.67683, 3.71773, 3.11416, 3.59578, 1.28689, 1.28631,1.03774, 3.23732, 3.15302, 4.76595, 3.5586, 4.6036, 3.40278, 3.93159,0.996068, 2.28392, 3.97436, 1.31199, 3.37306, 1.59347, 4.81479,4.98611, 2.97305, 4.99383, 3.80786, 1.95455, 4.56209, 2.11904,3.26038, 1.42664, 4.30224, 3.67952, 4.92539, 1.49919, 1.60278,3.95577, 2.42314, 2.48873, 1.54822, 2.63348, 3.43014, 2.17739,3.19454, 2.07749, 3.67022, 2.26272, 1.30863, 2.18551, 4.97789,1.43625, 1.88595, 1.21594, 2.87569, 1.17509, 2.75502, 2.71201,3.12858, 4.85521, 2.33088, 3.93246, 1.87746, 3.53247, 1.94075,2.44728, 3.5839, 2.47802, 3.85354, 1.45955, 0.983903, 1.264, 3.57013,0.273807, 0.978381, 0.770786, 2.59596, -0.0634878, 2.94635, 0.40255,0.609216, 1.95247, 0.503754, 0.189706, 2.87551, 2.57051, 3.12867,1.11012, 1.33686, 0.473327, -0.158264, 2.87489, 1.67097, -0.85459,-1.06732, 1.62827, 2.06016, -1.22761, 1.79616, 0.640145, -0.812508,-1.50028, -1.54575, -0.217228, 2.06445, -0.0252311, 1.31984,-1.09519, -1.55624, 0.602962, 1.33464, 0.883919, 0.142988, -0.886204,0.426426, 0.893315, 1.30856, -1.24124, 0.239628, 1.96819, 1.91064,-1.39036, 1.02973, -0.120615, 1.24169, -1.40214, 1.03507, -1.46984,1.58711, 1.01167, 2.08498, 1.97875, 1.48291, -1.26303, -0.930141,-0.59183, -0.350317, 1.93194, 0.953808, 0.829422, 0.662458, 1.50385,-0.943274, 1.21817, 1.12564, 1.28737, 0.4419, -0.222186, 2.34941,1.18368, 1.9319, -0.194216, 3.35556, 2.80241, 2.51639, 0.537432,0.625744, 2.86291, 2.28998, 4.0202, 3.9159, 3.92103, 0.377672,2.28483, 2.40107, 1.61928, 0.578327, 4.38002, 0.645356, 3.7589,3.62083, 4.1443, 1.89589, 2.23305, 1.4046, 4.11185, 2.37104, 3.31836,2.83245];

Homework Answers

Answer #1

Here is the python code. Run it in anypython compiler by copy and pasting this code. Play with N and Wn to find the desired result.

import scipy.signal as signal

# Design the Buterworth filter
N = 3 # This is the Filter order
Wn = 0.1 # This says about Cutoff frequency
B, A = signal.butter(N, Wn, output='ba')
smooth_data = signal.filtfilt(B,A, y)
plt.plot(y,'r-')
plt.plot(smooth_data,'b-', label = 'Filter order= 3 and cutoff freqency = 0.1')
plt.legend()
plt.show()

if needed some further details of writing the code ask in the comment section.

Know the answer?
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
Similar Questions
Design a filter circuit to remove the noise signals while selectively amplifying the high-frequency signals by...
Design a filter circuit to remove the noise signals while selectively amplifying the high-frequency signals by at least a factor of 100. The low-frequency noise signal has its peak energy in the vicinity of 20 Hz, and has fallen to less than 1 % of its maximum by 1 kHz. The engine failure signals begin in the vicinity of 25 kHz.
A voltage signal is created by adding the output from a white noise generator and from...
A voltage signal is created by adding the output from a white noise generator and from a sinewave generator. The white noise is band limited in the range 30 to 80 Hz and has a root mean square value (rms) of 1.5 V. The sine wave has a frequency of 50 Hz and an amplitude of 1.0 V. The signal is digitized at 200 samples per second and a spectral density is obtained by the Fast Fourier Transfer (FFT) algorithm,...
Generate a Matlab Code for amplitude modulated signal by multiplying a message signal (a low frequency...
Generate a Matlab Code for amplitude modulated signal by multiplying a message signal (a low frequency cosine signal) with a carrier signal (a high frequency cosine signal). Sketch the Fourier transform of the modulated signal. Demodulate the modulated signal (with no noise) by again multiplying it with the same carrier signal. Sketch the Fourier transform of the signal obtained in c). Your task is to recover the message signal from the signal in c). Determine the type of filter you...
Assignments Generate and plot the signal x1(t) = 1+ sin (4pt), for t ranging from -1...
Assignments Generate and plot the signal x1(t) = 1+ sin (4pt), for t ranging from -1 to 1 in 0.001 increments. Use proper axes labels with title. Generate and plot the function x2(t) = sin (30pt), for t ranging from -1 to 1 in 0.001 increments. Use proper axes labels with title. Generate and plot the combination function x3(t) = x1(t)*x2(t) as above. Use proper axes labels with title. Generate and plot the sum of two cosine waves   v1(t) =...
For this homework, you will be filtering noise from a sound recording. The assignment is broken...
For this homework, you will be filtering noise from a sound recording. The assignment is broken into simple steps you can follow. Please follow instructions carefully and remember that you will only upload one workspace (*.mat) file. Make sure to name the clean_speech variable correctly. 1) Download the Matlab workspace from the link provided in Canvas. Move the downloaded file to the same folder as your script to make things simpler. 2) Load the downloaded workspace into Matlab. You can...
A signal described by y(t) = .25*sin(6000*t) + cos(3500*t) was sampled with fs = 1 kHz....
A signal described by y(t) = .25*sin(6000*t) + cos(3500*t) was sampled with fs = 1 kHz. Determined: a) Whether this signal was aliased. Provide the spectral plot (magnitude versus frequency) b) If the signal proved to be aliased, find the right sampling rate c) Provide the spectral plot indicating the right frequencies of the signal
Question : Design the low and high pass filter for the signal, x(t) = 10 sin...
Question : Design the low and high pass filter for the signal, x(t) = 10 sin (10 t) + 1 sin (1000 t) by MATLAB Is below answer right? at ?High pass , 5row shouldn't this change from sin(100*t) ? sin(1000*t) x = 10*sin(10*t) + 1*sin(100*t); ?   x = 10*sin(10*t) + 1*sin(1000*t); ??? ..................................................................................................................................................... ?Low pass clc; rng default Fs=2000; t=linspace(0,1,Fs); x=10*sin(10*t)+sin(1000*t)%given signal n=0.5*randn(size(t));%noise x1=x+n; fc=150; Wn=(2/Fs)*fc; b=fir1(20,Wn,'low',kaiser(21,3)); %fvtool(b,1,’Fs’,Fs) y=filter(b,1,x1); plot(t,x1,t,y) xlim([0 0.1]) xlabel('Time (s) ') ylabel('Amplitude') legend('Original Signal','Filtered Data')...
Plot the voltage of the cell using the original parameters for Na, K and Cl, and...
Plot the voltage of the cell using the original parameters for Na, K and Cl, and changing sodium permeability from 1 to 10, 100, 1000 and up to 9999. Will the voltage keep increasing positively as the permeability to sodium is increasing? Why? Plot the voltage of the cell using the original parameters for Na, K and Cl, and changing potassium permeability from 1 to 10, 100, 1000 and up to 9999. Will the voltage keep increasing negatively as the...
Analyze the residual plot below and identify? which, if? any, of the conditions for an adequate...
Analyze the residual plot below and identify? which, if? any, of the conditions for an adequate linear model is not met. 5 15 25 2 -2 0 Explanatory Residuals A residual plot has a horizontal axis labeled Explanatory from less than 5 to 25 plus in increments of 10 and a vertical axis labeled residuals from less than negative 2 to 2 plus in increments of 1. A horizontal dashed line intersects the vertical axis at 0. A series of...
For each of the random quantities X,Y, and Z, defined below (a) Plot the probability mass...
For each of the random quantities X,Y, and Z, defined below (a) Plot the probability mass function PMS (in the discrete case) , or the probability density function PDF (in the continuous case) (b) Calculate and plot the cumulative distribution function CDF (c) Calculate the mean and variance, and the moment function m(n), and plot the latter. The random quantities are as follows: X is a discrete r.q. taking values k=0,1,2,3,... with probabilities p(1-p)^k, where p is a parameter with...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT