-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating

GNU Octave Beginner's Guide
By :

1. Continuing from Commands 39-46, let us apply a tenth order Butterworth filter with ωc = 0.1 to smooth the "trend-less" data set stored in curr2, see Command 42:
octave:47> b_order = 10; w_c = 0.1;
2. The Butterworth function is simply given as:
octave:48> w = sqrt(1./(1 + (freq./wc).^(2*b_order)));
3. We can choose to rearrange either the Butterworth window function or the data before multiplying them together —we will rearrange the window function:
octave:49> w = fftshift(w);
4. In order to apply the filter to the Fourier transform of curr2
and then perform the inverse Fourier transform, we use:
octave:50> plot(m_index, ifft(fft(curr2).*w), 'r', \ > m_index, curr2, 'b')
5. The result is given below, where the smoothed data is given by the red curve:
![]() |
In Command 47, we specified the critical frequency and the Butterworth order parameter. There is no recipe on how to choose the particular parameters, but it is always...
Change the font size
Change margin width
Change background colour