diff options
Diffstat (limited to 'lab5/RTDSP/Matlab')
-rw-r--r-- | lab5/RTDSP/Matlab/elliptical.m | 10 | ||||
-rw-r--r-- | lab5/RTDSP/Matlab/filter_coeff_ell.txt | 2 | ||||
-rw-r--r-- | lab5/RTDSP/Matlab/filter_coeff_ell_a.txt | 1 | ||||
-rw-r--r-- | lab5/RTDSP/Matlab/filter_coeff_ell_b.txt | 1 | ||||
-rw-r--r-- | lab5/RTDSP/Matlab/gen_filter.m | 7 |
5 files changed, 3 insertions, 18 deletions
diff --git a/lab5/RTDSP/Matlab/elliptical.m b/lab5/RTDSP/Matlab/elliptical.m deleted file mode 100644 index 7b603c7..0000000 --- a/lab5/RTDSP/Matlab/elliptical.m +++ /dev/null @@ -1,10 +0,0 @@ -function [b,a] = elliptical (Fs)
-
-order = 4; % Order of the bandpass filter
-startband = 270*2/Fs; % Normalised startband frequency
-stopband = 450*2/Fs; % Normalised stopband frequency
-ripple = 0.3; % The passband ripple (in dB)
-stopband_atten = 20; % The stopband attenuation (in dB)
-
-% Call the eliptical filter function
-[b,a] = ellip(order/2,ripple,stopband_atten,[startband, stopband]);
diff --git a/lab5/RTDSP/Matlab/filter_coeff_ell.txt b/lab5/RTDSP/Matlab/filter_coeff_ell.txt deleted file mode 100644 index dc7ef6f..0000000 --- a/lab5/RTDSP/Matlab/filter_coeff_ell.txt +++ /dev/null @@ -1,2 +0,0 @@ - 9.6683656064376025e-02 -3.7417971508180198e-01 5.5502519309909670e-01 -3.7417971508180270e-01 9.6683656064376386e-02
- 1.0000000000000000e+00 -3.8475581971606738e+00 5.5906851263228337e+00 -3.6360361044752754e+00 8.9323992595555990e-01
diff --git a/lab5/RTDSP/Matlab/filter_coeff_ell_a.txt b/lab5/RTDSP/Matlab/filter_coeff_ell_a.txt deleted file mode 100644 index bbb695e..0000000 --- a/lab5/RTDSP/Matlab/filter_coeff_ell_a.txt +++ /dev/null @@ -1 +0,0 @@ -double a[] = { 1.0000000000000000, -3.8475581971606738, 5.5906851263228337, -3.6360361044752754, 0.89323992595555990 };
diff --git a/lab5/RTDSP/Matlab/filter_coeff_ell_b.txt b/lab5/RTDSP/Matlab/filter_coeff_ell_b.txt deleted file mode 100644 index c750218..0000000 --- a/lab5/RTDSP/Matlab/filter_coeff_ell_b.txt +++ /dev/null @@ -1 +0,0 @@ -double b[] = { 9.6683656064376025e-02, -3.7417971508180198e-01, 5.5502519309909670e-01, -3.7417971508180270e-01, 9.6683656064376386e-02 };
diff --git a/lab5/RTDSP/Matlab/gen_filter.m b/lab5/RTDSP/Matlab/gen_filter.m index d6b5304..625aba1 100644 --- a/lab5/RTDSP/Matlab/gen_filter.m +++ b/lab5/RTDSP/Matlab/gen_filter.m @@ -1,6 +1,5 @@ Fs = 8000; -[b,a] = elliptical (Fs); -freqz(b, a); +b = m_filter; +freqz(b, 1, 1024, Fs); -%save filter_coeff_ell_b.txt b -ASCII -DOUBLE -TABS -%save filter_coeff_ell_a.txt a -ASCII -DOUBLE -TABS
\ No newline at end of file +save filter_coeff_correct.txt b -ASCII -DOUBLE -TABS
\ No newline at end of file |