Home > Health essays > Detection of Cardiac Dysrythmia using DWT

Essay: Detection of Cardiac Dysrythmia using DWT

Essay details and download:

  • Subject area(s): Health essays
  • Reading time: 8 minutes
  • Price: Free download
  • Published: 14 October 2015*
  • Last Modified: 2 September 2024
  • File format: Text
  • Words: 2,238 (approx)
  • Number of pages: 9 (approx)

Text preview of this essay:

This page of the essay has 2,238 words.

Abstract: The paper represents discrete wavelet transform for cardiac dysrhythmia. The main objective is to design the QRS complex in the ECG signal and to identify the time and frequency variations. The results provide whether the patient is suffering from cardiac dysrhythmia or not. For compressing the signal DWT decomposition is used and verified using MATLAB.
Keywords- DWT, ECG, QRS complex, SE.
I. INTRODUCTION
One of the major threats to life is the diseases mainly associated with cardiac. One such case is the dysryhthmia. Cardiac dysrhythmia or arrhythmia or irregular heartbeat is a group of conditions in which the electrical activity of the heart is irregular or is faster or slower than normal. The heartbeat may be too fast (over 100 beats per minute) or too slow (less than 60 beats per minute), and may be regular or irregular. A heart beat that is too fast is called tachycardia and a heart beat that is too slow is called bradycardia. Arrhythmias can occur at any age. Some are rarely found, whereas others can be more dramatic and can even lead to sudden cardiac death. The most common symptom of arrhythmia is an abnormal awareness of heartbeat, called palpitations. These may be infrequent, frequent, or continuous. Some of these arrhythmias are harmless (though distracting for patients) but many of them predispose to adverse outcomes. Some arrhythmias do not cause symptoms, and are not associated with increased mortality. However, some asymptomatic arrhythmias are associated with adverse events.
For this purpose the ElectroCardioGram (ECG) technique is introduced which uses the bio-potentials generated from the electrical activity of the muscles of the heart. The performance of ECG analyzing system depends mainly on the accurate and reliable detection of the QRS complex, as well as T and P waves. Among the noises plaguing the ECG are the power-line interference, electrode contact noise, motion artifacts, respiration causing drift in the baseline, electromagnetic interference and noise coupled from other electronic devices. For accurate detection, steps have to be taken to filter out or discard all these noise sources. For this purpose in this project an algorithm based on mathematical morphological operations is used.
II. MORPHOLOGICAL FILTERING METHOD
Mathematical morphology is a set-theoretic method of image analysis providing a quantitative description of geometrical structures. It provides an effective way to analyze signals using nonlinear signal processing operators, incorporating shape information for extracting image components that are useful for representation and description. A morphological operation is given as interaction of a set or function representing the object or shape of interest with another set or function of simpler shape called the structural element. The geometry information of the signal is obtained by using the structural element to operate on the signal. The shape of the structural element determines the shape of the signal that is extracted under such an operation. Such operators serve two purposes, i.e., extracting the useful signal and removing the artifacts.
A fundamental advantage of mathematical morphology applied to signal processing is that it is important since it works directly on the spatial domain. The concepts of set reflection and translation are used extensively in morphology. Set reflections and translations are employed extensively in morphology method to formulate operations based on structuring elements (SE’s). SE’s are small sets or sub images used to probe an image. The structural elements considered as the ‘basic bricks’ that play the same role as frequencies do in the analysis of the frequently used frequency filters. The fundamental operations to morphological processing are erosion and dilation. With A and B as sets in Z2, the erosion of A and B, denoted A ?? B, is defined as
A ?? B={z|(B)_Z ‘A } ””’. (a)
This equation indicates that the erosion of A by B is the set of all points z such that B, translated by z, is contained in A. If set B is assumed to be a structuring element, then B has to be contained in A is equivalent to B not sharing any common elements with the back ground. It is expressed as
A ‘B={z|(B)_(Z )’A^c=’ ””.. (b)
With A and B as sets in Z2, the dilation of A by B, denoted A ‘ B, is defined as
A ‘B={z|'(B^^)’_Z’A” ””'(c)
The dilation of A by B is the set of all displacements, z, such that B^ and A overlap by at least one element. Based on this interpretation and assuming B as structuring element it can be expressed as
A ‘B={z|'(B^^)’_Z’A’ A ..”’.. (d)
Two other important morphological operations: opening and closing.
Opening generally smoothes the contour of an object, breaks narrow isthmuses and eliminates thin protrusions. The opening of set A by structuring element B, denoted A o B, is defined as
A o B=( A’B)’B ”””.. (e)
The opening A by B is the erosion of A by B, followed by a dilation of the result of B.
Closing tends to smooth sections of contours but, as opposed to opening, it generally fuses narrow breaks and long thin gulfs, eliminates small holes, and fills gaps in the contour. Closing of set A by structuring element B, denoted A o B, is defined as
A o B=(A’B)’B ””” (f)
Closing of set A by B is simply the dilation of A by B, followed by the erosion of the result by B. In this project dilation and erosion are the morphological operations used for QRS extraction. Dilation expands the image and erosion shrinks the image. Unlike the previous processes, in this project the basic morphological operations are alone used and their average is taken. The averaged image is then compared with the original image and the difference is taken. The difference is then converted into binarized image in which the values of the image will be in 0’s and 1’s for further processing.
Fig 1. Binarized image
This gives the QRS signal of the ECG along with some noise signals. These noise signals are eliminated using multiple frame accumulation which is an energy accumulation process.
The matlab results of the morphological filtering method are shown below.
(a)
(b)
(c)
Fig.2 (a) Original and gray scale ECG image, (b) Close and open image (c) Difference and binarized image.
III. DWT DECOMPOSITION
Many transforms are used to obtain the information from the raw signal. But many of the information are hidden in the frequency content of the signal. The time domain ECG signal will be used usually by the doctors. Since the ECG recorders are computerized use only the frequency content of the ECG signal. DWT can be used for a variety of applications such as compression, decomposition, feature extraction etc.
The Wavelet Transform is a time-scale representation that has been used successfully in a broad range of applications, in particular signal compression. In DWT the ECG signal is passed through a series of low and high pass filter. For obtaining the feature, DWT decomposition is used. Multi resolution analysis is one of the advantages of DWT. Wavelet Transform of a signal f (t) is defined as the sum of over all time of the signal multiplied by scaled, shifted versions of the wavelet function ?? and is given by,
W(a,b)=’_(-‘)^(+’)”f(t),??a,b(t)dt’ ‘.. (g)
??a,b(t)=(1/’a ‘ ‘??^(* ) (t-b))/a
MRA provides good time and poor frequency resolution at high frequencies and good frequency, poor time resolutions at lower frequencies.
DWT analyzes the signal into approximation and detailed information at different frequency bands with different resolutions. Using successive high pass and low pass filtering the ECG signal can be decomposed into different frequency bands. The QRS complex feature can be extracted by performing decomposition up to 4 levels.
Fig 3. DWT decomposition
The resolution of the ECG signal can be changed by filtering operations and the scale can be changed by up sampling and down sampling. Sampling rate of the signal increases with up sampling and down sampling removes some samples.
When the signal is passed through low pass and high pass filters they split the frequency content of the signal into half. Down sampling operation is not invertible as it saves only the even numbered components of the filter output and the effect is called aliasing.The ECG signal is decomposed into coefficient vectors using the motherwavelet. The coefficients obtained using the four level decomposition i.e. approximation coefficients of the fourth level and the details of all the four levels are used for analyzing the ECG signal.
The summations of values from the ECG signal provide the feature vector. Some of the applications in which DWT can be used are motion detection and tracking, robot positioning, nonlinear adaptive wavelet controller, encoder quantization decoding, repetitive control, real time feature detection, time varying filters, identification, predictive control, audio applications, speech recognition etc.
Fig 4. Wavelet decomposition
IV. ECG SIGNAL ANALYSIS SYSTEM
Fig 5.Overview of ECG signal analysis system
ECG signal was captured from the MIT-BIH database. Once the signal has been captured, filtering can be done in order to remove any unwanted noise in the captured signal. Basic principle behind the ECG signal analysis was to find the QRS complex. Easier method for detecting the QRS complex was to find out the R peak.
Heart rate is calculated using the peak detection technique. R wave is determined by analyzing the slopes of the ECG samples. The iso-electric baseline of a heart signal can be shifted for various abnormalities. Hence the ECG components may also be shifted. This may be a problem in detecting the R waves. So a threshold level is taken into account. Peaks exceeded the threshold level are counted as R-waves by determining the slopes of the rising and falling edges. At first, we characterize the ECG signal, that is, we detect and locate the different waves and segments of the ECG signal.
The onsets of P-wave, QRS complex, T-wave and the P-R segment, S-T segment, the average duration of QRS complexes are detected. To avoid the problem of baseline shifting of the ECG signal, the signal is de-trended. The baseline shifting is due to a very low frequency signal. This very low frequency component is filtered out by discrete wavelet transform method. To avoid the problem of baseline shifting of the ECG signal, the signal is de-trended. The baseline shifting is due to a very low frequency signal.
The peak signal obtained from the original ECG signal from the DWT decomposition and the obtained peak is shown below.
(a)
(b)
(c)
Fig 6. a)original ECG signal, (b) peak detection, (c) heart rate display.
V. VALIDATION
The validation includes finding: Mean Square Error, Percentage Residual Difference, Peak Signal to Noise Ratio.
Mean Square Error: The mean square error provides the summation of the original and restored images.
MSE=1/MN’_(x=0)^(M-1)”_(y=0)^(N-1)”[f(x,y)-f^^ (x,y)]’^2 ”” (h)
Percentage Residual Difference: The percentage residual difference is used to measure the difference between the original and the restored images
PRD='[‘_(x=0)^(M-1)”_(y=0)^(N-1)”'[f(x,y)-f^^ (x,y)]’^2]”^(1/2)/’_(x=0)^(M-1)”_(y=0)^(N-1)””[[f’^^ (x,y)]’^2*100]’ ””. (i)
Peak Signal to Noise Ratio: If the restored image is considered to be signal and the difference between the image and the original to be noise, the peak signal to noise ratio could be given as
PSNR=10*log10( ‘255’^2/PRD) ”’.. (j)
The values obtained after DWT decomposition are shown below in the table.
MSE
PRD
PSNR HEART RATE
8.85257 11.3706 37.573 237.500
Table 1. Validati
on
VI. CONCLUSION
The main objective of this project is to develop simple and highly accurate ECG signal analysis system. An ECG QRS detection algorithm has been developed using basic mathematical morphological operations. Since DWT is the accurate method for the detection of QRS complex, DWT decomposition. In future it could be implemented in FPGA SPARTAN3 for implementation.
REFERENCES
[1] Gaurav Jaswal, Rajan Parmar and Amit Kaul (2012), ‘QRS Detection Using Wavelet Transform’ International Journal of Engineering and Advanced Technology (IJEAT) ISSN: 2249 ‘ 8958, Volume-1, Issue-6.
[2] Priyanka Mehta, Monika Kumari (2012)., ‘Qrs Complex Detection of Ecg Signal Using Wavelet Transform’, International Journal of Applied Engineering Research, ISSN 0973-4562 Vol.7 No.11.
[3] Yan Lu, Jingyu Yan, and Yeung Yam (2006), ‘Model Based ECG denoising using empirical mode decomposition,’IEEE International Conference on Bioinformatics and Biomedicine, pp. 191-196.
[4] Yun-Chi Yeh, Wen-June Wang (2008), ‘QRS complex detection for ECG signal: The Difference Operation Method’, Computer Methods and Programs in Biomedicine 9 I(2008) 245-254
[5] S. Z. Mahmoodabadi, A. Ahmadian, and M. D. Abolhasani (2005), ‘ECG Feature Extraction using Daubechies Wavelets’, Proceedings of the fifth IASTED International conference on Visualization, Imaging and Image Processing, pp. 343-348.
[6] Mahesh Goparaju, S Mohan (2013), ‘Design & Implementation of DWT ‘ IDWT Algorithm for Image Compression by using FPGA’, International Journal of Scientific and Research Publications, Volume 3, Issue 3, ISSN 2250-3153.
[7] Mehmet Ustindag, Abdulkadir Sengur, Muammer Gokbulut, Fikret ata (2013),’Performance comparison of wavelet thresholding techniques on weak ECG signal denoising’, PRZEGL??D ELEKTROTECHNICZNY, ISSN 0033-2097, R.89 NR5.
[8] Sambhu D, Umesh A. C (2013), ‘Automatic Classification of ECG Signals with Features Extracted Using Wavelet Transform and Support Vector Machines’, International Journal of Advanced Research in Electrical, Electronics and Instrumentation Engineering Vol. 2, Special Issue 1.
[9] Upasana Mishra, Mr. Love Verma (2014), ‘Noise Removal from ECG Signal by Thresholding with Comparing Different Types of Wavelet’ , International Journal of Application or Innovation in Engineering & Management (IJAIEM) Volume 3, Issue 3, ISSN 2319 ‘ 4847.
[10] Mahesh Goparaju, S Mohan (2013), ‘Design & Implementation of DWT ‘ IDWT Algorithm for Image Compression by using FPGA’, International Journal of Scientific and Research Publicatisons, Volume 3, Issue 3, ISSN 2250-3153.

About this essay:

If you use part of this page in your own work, you need to provide a citation, as follows:

Essay Sauce, Detection of Cardiac Dysrythmia using DWT. Available from:<https://www.essaysauce.com/health-essays/essay-detection-of-cardiac-dysrythmia-using-dwt/> [Accessed 21-01-25].

These Health essays have been submitted to us by students in order to help you with your studies.

* This essay may have been previously published on EssaySauce.com and/or Essay.uk.com at an earlier date than indicated.