Real Time Recognition of Heart Attack in a Smart Phone Published online: 25/05/2015

Published print:06/2015

doi: 10.5455/aim.2015.23.151-154 ACTA INFORM MED. 2015 JUN 23(3): 151-154 Received: 11 March 2015 • Accepted: 14 May 2015

© 2015 Mahshid Zomorodi Rad, Saeed Rahati Ghuchani, Kambiz Bahaadinbeigy, Mohammad Mahdi Khalilzadeh This is an Open Access article distributed under the terms of the Creative Commons Attribution Non-Commercial License (http://creativecommons.org/licenses/by-nc/4.0/) which permits unrestricted non-commercial use, distribution, and reproduction in any medium, provided the original work is properly cited.

ORIGINAL PAPER

Real Time Recognition of Heart Attack in a Smart Phone Mahshid Zomorodi Rad1, Saeed Rahati Ghuchani2, Kambiz Bahaadinbeigy3, Mohammad Mahdi Khalilzadeh1 Department of Biomedical Engineering, Islamic Azad University of Mashhad, Mashhad, Iran Department of Electrical Engineering, Islamic Azad University of Mashhad, Mashhad, Iran 3 Medical Informatics Research Center, Institute for Futures Studies in Health, Kerman University of Medical Sciences, Kerman, Iran 1 2

Corresponding author: Kambiz Bahaadinbeigy. Medical Informatics Research Center, Institute for Futures Studies in Health, Kerman University of Medical Sciences, Kerman, Iran

ABSTRACT Background: In many countries, including our own, cardiovascular disease is the most common cause of mortality and morbidity. Myocardial infarction (heart attack) is of particular importance in heart disease as well as time and type of reaction to acute myocardial infarction and these can be a determining factor in patients’ outcome. Methods: In order to reduce physician attendance time and keep patients informed about their condition, the smart phone as a common communication device has been used to process data and determine patients’ ECG signals. For ECG signal analysis, we used time domain methods for extracting the ST-segment as the most important feature of the signal to detect myocardial infarction and the thresholding methods and linear classifiers by LabVIEW Mobile Module were used to determine signal risk. Results: The sensitivity and specificity as criteria to evaluate the algorithm were 98% and 93.3% respectively in real time. Conclusions: This algorithm, because of the low computational load and high speed, makes it possible to run in a smart phone. Using Bluetooth to send the data from a portable monitoring system to a smart phone facilitates the real time applications. By using this program on the patient’s mobile, timely detection of infarction so to inform patients is possible and mobile services such as SMS and calling for a physician’s consultation can be done. Keywords: ECG, R-Detection, Myocardial Infarction, ST elevation.

1. INTRODUCTION

Cardiovascular disease is the most common cause of mortality, morbidity and health costs in our own country Iran and in many other countries. Moreover, according to published reports, with the increase of coronary artery disease, this disease is considered to be the first cause of mortality in developing countries (1). Myocardial infarction (MI) or its serious form acute myocardial infarction (AMI) is the medical term for a heart attack. Early mortality (within 30 days) associated with a heart attack is 30%, and despite improvements in emergency medical services, more than 50% occur before reaching the hospital (2). The initial reaction time for people suffering from AMI is important and can be a determining role in their fate. Evidence shows that the rate of illness and death decreased in patients who experienced AMI and received standard treatment in the first two hours (1). Fortunately, in recent years the treatment of coronary perfusion has developed and so it can reduce damages caused by AMI. By decreasing the interval between the onset of symptoms and administration time of drugs, better results can be achieved (3). An Australian study shows that if treatment is started up to one hour of onset of symptoms, the mortality rate decreases 45%, and if treatment is started after three hours of symptom onset, the mortality decreases 23% (4). Another study in the U.S. shows that only 5% of patients received reperfusion therapy within the first hour after the onset of symptoms, and most delayed coming to the emergency department (3). The classic symptoms of a heart attack include chest dis-

comfort or pain felt in the chest that lasts a few minutes, dizziness, fainting, nausea, sweating, and shortness of breath. The pain may spread to the shoulders, neck and arms. Most people have not experienced heart problems, so they usually do not think that it is the start of a heart disease (1). In response to these symptoms, patients may deny symptoms, consult with relatives, and wait for symptoms to hopefully resolve spontaneously and so go untreated due to lack of knowledge of the nature of symptoms and their importance (4, 5, 3). So, to avoid damages caused by delay, we should seek a way to raise awareness of heart attack victims about their situation. Today the mobile phone has become an integral part of human life, so it can be used as an acceptable means to diagnose patients and thus encourage more patient cooperation. In our project we have attempted to take a step toward early diagnosis of heart attack by sending the heart signal recorded by a portable ECG device to the patient’s smart phone to be processed in real time. If the condition was found to be abnormal, the data was sent to the patient’s physician, so that the doctor could quickly communicate with his/her patient by mobile services if necessary (1). A view of the system can be seen in Figure 1.

Figure 1: Mobile-ECG system Figure 1. Mobile-ECG system

ECG signals include P, QRS and T waves. Various changes in the ECG signal, ECG Signals include P, QRS and T waves. Various changes depending on the place and the development and progression of the disease have been reported. ST segment changes are common symptoms of infarction. According to ST segment ACTA INFORM MED. 2015 JUN 23(3): 151-154 / ORIGINAL PAPER changes, we can divide MI into two categories: ST-elevated myocardial infarction (STEMI) and non ST-elevated myocardial infarction (non STEMI) [6]. In STEMI, the ST-segment elevation is the earliest sign of MI [7]. Thus, we should follow the ST

151

Figure 1: Mobile-ECG system

Real Time Recognition Heart Attack a Smart Phone Various changes in the ECG signal, ECG152 signals include P,ofQRS andin T waves. ending on the place and the development and progression of the disease have been rted. in the ECG signal, depending on the place and the develop- time so conditions associated with a portable data acquisition

system can be provided. ment and progression of the disease have been reported. LabVIEW 8.6 software for designing the program ST segment changes are common symptoms of infarction. segment changes are common symptoms of infarction. According to We STused segment because it is a powerful tool for image processing applications, According to ST segment changes, we can divide MI into two nges, we can divide MI into two categories: ST-elevated myocardial infarction categories: ST-elevated myocardial infarction (STEMI) and digital signal processing (DSP), data analysis, control equipEMI) and nonnon ST-elevated infarction(non (non STEMI) STEMI, the programs, and many other engineering ment, networking ST-elevatedmyocardial myocardial infarction STEMI) (6). [6]. In In egment elevation is the theST-segment earliest sign of MIis [7]. Thus, sign we of should follow the This ST version has 25 toolkits including a mobile STEMI, elevation the earliest MI applications. (7). Thus, we should follow the ST segment to detect myomodule. The mobile module provides an advanced graphical ment to detect myocardial infarction. Fig. 2 shows a normal and ST-elevated ECG cardial infarction. Figure 2 shows a normal and ST-elevated environment from LabVIEW for devices that have Windows al Figure 1: Mobile-ECG system ECG signal mobile for Pocket PC devices. This module provides applications such as remote control systems, monitoring and porECG signals include P, QRS and T waves. Various changes in the ECG signal, table data acquisition systems. To operate the mobile module depending on the place and the development and progression of the disease have been reported. we needed a computer with Windows Vista/XP or Windows 2000 and a mobile with Windows Mobile 5.0, 6.0 or Pocket ST segment changes are common symptoms of infarction. According to ST segment changes, we can divide MI into two categories: ST-elevated myocardial infarction PC 2003. The data can be sent to the phone via USB or Blue(STEMI) and non ST-elevated myocardial infarction (non STEMI) [6]. In STEMI, the tooth. For designing the data transmission system, first the ST-segment elevation is the earliest sign of MI [7]. Thus, we should follow the ST data was converted to real time by using a five second moving segment to detect myocardial infarction. Fig. 2 shows a normal and ST-elevated ECG signal window that was shifted one second in a repeated loop. Then the data was sent in a 1-byte buffer via Bluetooth. Bluetooth Technology, because of having features such as Figure 2. Normal and ST-elevated ECG signal Figure 2: normal and ST-elevated ECG signal being wireless, low-powered, low-cost and capable of 1 Mbps 2. METHODS data transmission rates in the range of at least 10 m, makes Methods In this project, we intended to process data of heart attack it highly desirable for our application. In addition, we used his project, wepatients intended to process of heart attack increaseOmnia their i900 with Windows mobile 6.1 in order to and increase theirdata survival rates by timelypatients diagnosis.andSamsung Figure 2: normal and ST-elevated ECG signal Hence, we designed software to communicate with a mobile provide LabVIEW ival rates by timely diagnosis. Hence, we designed software to communicate with Mobile Module conditions. Finally, the 2. Methods ECG by sending theto recorded signal to apatients mobile phonetheir via data received by the mobile phone via Bluetooth was entered this project, we intended process signal data of heart and phone increase obile ECG byInsending the recorded toattack a mobile via Bluetooth. The survival rates byThe timelyblock diagnosis. Hence, weof designed software to communicate with Bluetooth. diagram the algorithm can be seen into the processing stage. k diagram of in the algorithm can be seen in Fig. 3. a mobile ECG by sending the recorded signal to a mobile phone via Bluetooth. The Figure 3. block diagram of the algorithm can be seen in Fig. 3.

2.3. R-Detection

Since we wanted to detect the ST segment, first we had to

sending the signal

Module conditions. Finally, the dataasreceived by the mobile phone via Bluetooth was mobile phone databasePre-proccesing R-detection ST-segmentation ding the signal2.1.to aThe detect the R-peak a reference. There are via several methods Module conditions. Finally, the data received by the mobile phone Bluetooth was via Bluetooth entered into the processing stage. a mobile phoneThe first phase Pre-proccesing ST-segmentation detecting the R-peak, in this of the work wasR-detection to provide data that was recorded from a patient for project, according to the entered thefor processing stage. Moduleinto conditions. Finally, the data received by the mobile phone via Bluetooth was Bluetooth reference (9), we used the Hilbert transform to detect the R-

whom MI had been reported. In this regard, entered data from European into the the processing stage. ST-T database 2.3. R-Detection Finding STthresholding 2.3. R-Detection peak. In this reference, the first Hilbert transform sugSince we wanted to detect the ST segment, we had to detecthas the been R-peak as a elevation PhysioNet was used [8]. Since we wanted to detect the ST segment, firstR-peak we had in to adetect the monitor R-peak asbea gested in order to detect the Holter 2.3. R-Detection reference. There are several methods for detecting the R-peak, in this project, 3: block diagram of the algorithm reference. There are several methods for hours detecting the R-peak, in this project, data Figure included e0108, e0123, e0124, e0126. Each record is two in cause of short implementation time and lack of computational Figure 3.This Block diagram of the algorithm Since we wanted to detect the ST segment, first we had to detect the R-peak as according to the reference [9], we used the Hilbert transform to detect the R-peak.aIn according toThere the reference [9], we used theforHilbert transform to detect in thethis R-peak. In reference. several methods detecting theinerror R-peak, project, duration and contains twoSTsignals, each sampled 250 samples per second athat 12-the complexity. The results show than 0.005 Finding thresholding this at reference, theare Hilbert transform has with been suggested orderistoless detect the R-peak this reference, the Hilbert transform has been suggested in order to detect the R-peak the reference [9], usedimplementation the Hilbert transform to detect R-peak. In elevation inrange. a Holterto because ofweshort timeand and lack ofthe computational 2.1. resolution The databaseover ataddition, R-peak detection. InMIT-BIH mathematics signal processing, bit a nominal 20 mV inputinaccording Inmonitor we used a Holter monitor becausetransform of short implementation timeinand lack of computational reference, theresults Hilbert has been order detect the R-peakIn complexity. The show that the error issuggested less thanfunction 0.005 attoR-peak detection. - 3 -was to provide data this The first phase of the work that was the Hilbert transform of a real time x (t) is defined complexity. The results show of that the implementation error is less thantime 0.005 at R-peak detection. Inas arrhythmia data as normal data to better assess the algorithm. in a Holter monitor because short and computational mathematics and signal processing, the Hilbert transform of a lack real of time function x (t)

Figure 3: blockfor diagram thehad algorithm recorded from a patient whomofMI been reported. In and when integral the exists: mathematics signalthe processing, Hilbert transform of a real time function x (t) complexity. is defined as:The results show that the error is less than 0.005 at R-peak detection. In this regard, data from the European ST-T database PhysioNet ismathematics defined as: and signal processing, the Hilbert transform of a real time function x (t) 1 ∞ ∞𝑥𝑥(𝜏𝜏) 𝑥𝑥(𝜏𝜏) 2.2. transmission system design: 1 ∫ wasData used (8). 𝑥𝑥 ̂(𝑡𝑡) = 𝐻𝐻[𝑥𝑥(𝑡𝑡)] = 𝑑𝑑𝑑𝑑 is defined as: 𝑥𝑥̂(𝑡𝑡) = 𝐻𝐻[𝑥𝑥(𝑡𝑡)] = 𝜋𝜋 ∫ −∞ 𝑡𝑡 − 𝑑𝑑𝑑𝑑 (1)(1) 𝜏𝜏 ∞𝑡𝑡 − 𝜏𝜏 𝜋𝜋1 −∞ This data included e0123,that e0124, record In this project, it ise0108, assumed thee0126. data Each was sent from a portable data acquisition 𝑥𝑥(𝜏𝜏) whenthe theintegral integralexists. exists. 𝑥𝑥̂(𝑡𝑡) = 𝐻𝐻[𝑥𝑥(𝑡𝑡)] = independent ∫ 𝑑𝑑𝑑𝑑 (1) not changed as when is two hours duration and contains each samIn equation 1 the has 𝜋𝜋 −∞variable 𝑡𝑡 −replace 𝜏𝜏 hasvariable system to theinsmart phone (Fig. 4).two Sosignals, a program must be provided in order to In equation 1 the independent not changed result In aintegral equation 1 of thethis independent variable so hasthe notoutput changedxˆ(t) as as result ofa of thisthis pled at 250 samples per second with a 12-bit resolution over result transformation, time when the transformation, soexists. the outputxˆ(t) xˆ(t)in isalso also a previous time dependent function. Itisnormally isalso normally not the data acquisition system. Therefore, the offline data analyzed the transformation, so the output is a time dependent function. It is 3 -addition, we used MIT-BIH Intoequation 1the theHilbert independent has notnot changed as result of not thisof nominal 20 mV input range.- In dependent function. Itvariable isasnormally possible to calculate possible calculate transform an ordinary improper integral because possible to calculate theoutput Hilbert transform astime an ordinary integral because not of section must beasconverted associated with a also portable data improper transformation, so the xˆ(t) is aas function. It isintegral normally arrhythmia data normal datato to real bettertime assessso theconditions algorithm. the Hilbert transform an dependent ordinary improper bethe possible singularity at τ = t. The integral should be considered as a Cauchy the possible singularity at τ = t. The integral should be considered as a Cauchy possible to calculate transform as an ordinary because of cause the of Hilbert the possible singularity at τimproper = t. Theintegral integral should acquisition system can be provided. principal value. principal value. the possible singularity at τ =ast. aThe integralprincipal should bevalue. considered as a Cauchy 2.2. Data transmission system be considered Cauchy In mathematics, principal value.the certain Cauchy principal value is defined as: design: mathematics,the thecertain certainCauchy Cauchy principal value defined InInmathematics, principal value is is defined as:as: In this project, it is as𝑏𝑏−𝜀𝜀 𝑏𝑏−𝜀𝜀 𝑐𝑐 𝑐𝑐 In mathematics, the certain Cauchy principal value is defined as: sumed that the data was sent [∫𝑥𝑥(𝑡𝑡)𝑑𝑑𝑑𝑑 𝑥𝑥(𝑡𝑡)𝑑𝑑𝑑𝑑++∫𝑐𝑐∫ 𝑥𝑥(𝑡𝑡)𝑑𝑑𝑑𝑑 lim[∫ 𝑥𝑥(𝑡𝑡)𝑑𝑑𝑑𝑑 ] ] (2)(2) lim 𝜀𝜀→0+ 𝑏𝑏−𝜀𝜀 𝜀𝜀→0+ from a portable data acquisi𝑏𝑏+𝜀𝜀 𝑎𝑎 𝑎𝑎 𝑏𝑏+𝜀𝜀 (2) lim [∫ 𝑥𝑥(𝑡𝑡)𝑑𝑑𝑑𝑑 + ∫ 𝑥𝑥(𝑡𝑡)𝑑𝑑𝑑𝑑] 𝜀𝜀→0+ tion system to the smart phone 𝑎𝑎 𝑏𝑏+𝜀𝜀 (Figure 4). So a program must Where b is a point at which the behavior of the function x(t) whereb bisisa apoint pointatatwhich whichthethe behavior function is such where behavior ofof thethe function x(t)x(t) is such thatthat be provided in order to replace is such that 𝑏𝑏 𝑏𝑏 where b is a point at which the behavior of the function x(t) is such that the data acquisition system. ±∞ 𝑓𝑓𝑓𝑓𝑓𝑓 𝑓𝑓𝑓𝑓𝑓𝑓 𝑎𝑎𝑎𝑎𝑎𝑎 𝑥𝑥(𝑡𝑡)𝑑𝑑𝑑𝑑==±∞ 𝑎𝑎𝑎𝑎𝑎𝑎 𝑎𝑎 𝑎𝑎

Real Time Recognition of Heart Attack in a Smart Phone.

In many countries, including our own, cardiovascular disease is the most common cause of mortality and morbidity. Myocardial infarction (heart attack)...
NAN Sizes 1 Downloads 7 Views