Professional Documents
Culture Documents
s s
(
+
s s
(
+
=
L k
L
L
k L
L
k k
L
k w
2
1 sin 2
sin
2
0 ,
1 sin 2
sin
1
1
(1)
3. Design of Digital Narrow Band
Stop Filter With HAS Window
A Sine window when it is used to weight
symmetrical narrow band stop digital FIR filter for
suppression of powerline noise in ECG may
introduce oscillations due to the fact that it pulls
down the impulse response of the filter to zero at
both extremes of beginning and end. The HAS
window may improve this effect because it pulls up
the two extremes to a value of o not equal to zero.
Recall that o varies between 0 and1. For the narrow
band stop filter targeted at 50Hz powerline noise
filtration in ECG, o is made to be about 0.02 value.
The order of filter here is L =100 which implies that
the number of samples or filter taps is M =L +1 =
101. With this values (1) transforms to (2).
1 o =1 0.02 =0.98
u =sin
-1
(1 o) =Sin
-1
0.98 =78.522
0
( )
100
522 . 78 2
L
1 sin 2
1
=
o
=
0
5704 . 1 =
,
where is the angle covered by the curve AC in fig.
1. Substituting = 1.54704
0
in (1) gives
( ) 50 0 , 5704 . 1 sin 02 . 0
1
s s + = k k k w
( ) ( ) 100 50 , 5704 . 1 100 sin 02 . 0 2 s s + = k k k w
Combining w
1
(k) and w
2
(k) yields
( )
( )
( ) ( )
(
s s +
s s +
=
100 k 50 , 5704 . 1 k 100 sin 02 . 0
50 k 0 , k 5704 . 1 sin 02 . 0
k w
(2)
If the window of (2) is used in designing and
implementing a narrow band stop digital FIR filter
for powerline noise removal in ECG signal, the
impulse, magnitude and phase responses of the filter
are shown in figure 2, 3 and 4, respectively.
Fig. 2: Impulse Response of the Filter
Fig. 3: Magnitude Response of the Filter
0 10 20 30 40 50 60 70 80 90 100
-0.2
0
0.2
0.4
0.6
0.8
1
1.2
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
-25
-20
-15
-10
-5
0
5
D
C
A
B
W(k)
1
0
L
2
L
k
International Journal of Engineering Trends and Technology (IJETT) Volume 4 Issue 10 - Oct 2013
ISSN: 2231-5381 http://www.ijettjournal.org Page 4626
Fig. 4: Phase Response of the Filter
3. Results
A noise-free normal ECG signal of 3.5mV value
generated by matlab is shown in fig 5. The generated
ECG signal is corrupt with 50Hz powerline of 0.1mV
and the resulting signal is recorded in fig 6. The
frequency spectrum of the corrupt ECG is depicted in
fig 7. From fig 7 the average power of the corrupt
ECG signal at 50Hz before the application of the
digital filter is about +4.2dB. The corrupt ECG is
filtered with the designed digital filter and the output
recorded and depicted in fig. 8. The frequency
response of the filtered ECG is presented in Fig 9.
Form fig. 9 the average power of the filtered ECG at
50Hz is brought down to about -19dB, which in
effect means that the implemented narrow band stop
FIR filter has removed the 50Hz powerline noise in
the ECG signal.
The corrupt ECG signal of fig. 6 is applied to an FIR
adaptive notch filter as a way of comparing the
performances of FIR notch filter designed with HAS
window and adaptive notch filter in removing
powerline interference in ECG signals. The
adaptively filtered ECG signal is recorded in fig. 10
while the frequency spectrum is shown in fig. 11.
From fig. 11 the average power of the ECG signal
filtered with adaptive notch filter at 50Hz is further
reduced to -34.2dB. Note that 50Hz here
corresponds to 0.1rad in the normalized frequency
scale.
Fig. 5: Normal Noise-Free ECG Signal
Fig. 6: ECG Corrupt with 50Hz Powerline
Fig. 7: Frequency Response of ECG
Corrupt with 50Hz Powerline
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
-160
-140
-120
-100
-80
-60
-40
-20
0
0 500 1000 1500 2000 2500 3000
-3
-2
-1
0
1
2
3
4
0 500 1000 1500 2000 2500 3000
-3
-2
-1
0
1
2
3
4
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
-100
-80
-60
-40
-20
0
20
Normalized Frequency (trad/sample)
P
o
w
e
r
/
f
r
e
q
u
e
n
c
y
(
d
B
/
r
a
d
/
s
a
m
p
l
e
)
PeriodogramPower Spectral Density Estimate
International Journal of Engineering Trends and Technology (IJETT) Volume 4 Issue 10 - Oct 2013
ISSN: 2231-5381 http://www.ijettjournal.org Page 4627
Fig. 8: Filtered ECG
Fig. 9: Frequency Response of Filtered
ECG
Fig. 10: Adaptively Filtered ECG
Signal
Fig. 11: Frequency Spectrum of
Adaptively Filtered ECG Signal
4. Conclusion
The impulse response is indicating stability of the
filter. The ripples in the magnitude response of the
filter decay quickly which suggests filter stability.
The phase response is linear and as such the filtered
ECG signal will not experience any differential phase
shift due to the filter.
The HAS window-based filter filters off the 50Hz
powerline interference in the corrupt ECG signal of
fig. 6 as shown in fig.8. Comparing the performance
of the HAS filter with that of adaptive filter, as can
be deduced from figures 10 and 11 shows that the
adaptive filter is better in ECG processing with a
view to removing powerline interference.
REFERENCES
[1] Kadam Geeta and Bhaskar P. C., Reduction of
Powerline Interference in ECG Signal Using FIR
Filter, International Journal of Computational
Engineering Research (IJCER), Vol. 2, No. 2,
Pp. 314 319, 2012.
[2] Chavan Manesh S, Agarwala R. A. and Uplane
M. D., Interference Reduction in ECG using
Digital FIR Filters Based on Rectangular
Window, WSEAS Transactions on Signal
Processing, Vol. 4, Issue 5, Pp. 340 349, 2008.
[3] Mbachu C. B, Idigo Victor, Ifeagwu Emmanuel
and Nsionu I. I., Filtration of Artitacts in ECG
Signal Using Rectangular-Based Digital Filters,
International Journal of Computer Science Issues
(IJCSI), Vol. 8, Issue 5, Pp. 279 285, 2011.
0 500 1000 1500 2000 2500 3000
-3
-2
-1
0
1
2
3
4
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
-100
-80
-60
-40
-20
0
20
Normalized Frequency (trad/sample)
P
o
w
e
r
/
f
r
e
q
u
e
n
c
y
(
d
B
/
r
a
d
/
s
a
m
p
l
e
)
PeriodogramPower Spectral Density Estimate
0 500 1000 1500 2000 2500 3000
-4
-3
-2
-1
0
1
2
3
4
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
-100
-80
-60
-40
-20
0
20
Normalized Frequency (trad/sample)
P
o
w
e
r
/
f
r
e
q
u
e
n
c
y
(
d
B
/
r
a
d
/
s
a
m
p
l
e
)
PeriodogramPower Spectral Density Estimate
International Journal of Engineering Trends and Technology (IJETT) Volume 4 Issue 10 - Oct 2013
ISSN: 2231-5381 http://www.ijettjournal.org Page 4628
[4] Chinchkhede K. D., Yadav Govind Sharan,
Hirekhan S. R. and Solanke D. R., On the
Implementation of FIR Filters with various
windows for Enhancement of ECG Signal,
International Journal of Engineering Science and
Technology (IJEST), Vol. 3, No. 3, Pp. 2031
2040, 2011.
[5] Chavan Mahesh S., Agarwala R. A. and Uplane
M. D., Design and Implementation of Digital
FIR Equiripple Notch Filter on ECG Signal for
Removal of Powerline Interference, WSEAS
Transactions on Signal Processing, Vol. 4, No. 4,
Pp. 221 230, 2008
[6] Islam M. K., Haque A. N. M. M., Tangim G.,
Ahammad T. and Khondokar M. R. H., Study
and Analysis of ECG Signal using Matlab
and Labview as Effecctive Tools, International
Journal of Computers and Electrical
Engineering, Vol. 4, No. 3. Pp. 404 408, 2012.
[7] Mbachu C. B., Onoh G. N., Idigo V. E., Ifeagwu
E. N. and Nnebe S. U., Processing ECG Signal
with Kaiser Window-Based FIR Digital Filters,
International Journal of Engineering, Science
and Technology (IJEST), Vol. 3 No. 8, Pp. 6775
6783, 2011.
[8] Chavan Mahesh S., Agarwala R. A. and Uplane
M. D., Use of Kaiser Window for ECG
Processing, Proceedings of the 5
th
WSEAS
International Conference on Signal Processing,
Robotic and Automation, Madrid, Spain, Pp. 1
5, 2008.
[9] Renumadhavi C. H., Kumar S. Madhava, Ananth
A. G. and Srinivasan Nirupama A new
approach for evaluating SNR of ECG Signals
and its implementation, Proceedings of the 6
th
WSEAS International Conference on Simulation,
Modeling and Optimization, Lisbon, Portugal,
Pp. 202 205, 2006.
[10] Van Alste J. A. and Schilder T. S., Removal of
Base-line Wander and Powerline Interference
from the ECG by an Efficient FIR Filter with a
Reduced Number of Taps, IEEE Transactions
on Biomedical Engineering, Vol. 32, No. 12, pp.
1052 1062, 1985.