MLP Based Tan-Sigmoid Activation Function for Cardiac Activity Monitoring

Cardiac abnormalities can occur to everyone, irrespective of race, age or gender. However, family history gives a clear signal of the probable probability of heart failure in the heart. Cardiac abnormalities rarely show early symptoms, thereby contributing to sudden deaths in patients. In general, heartbeat is an irregular electric boost or heart activity. In this paper, an early monitoring system for detecting cardiac abnormalities was conducted using the Multilayer Perceptron (MLP) network. The cardiac abnormalities dataset is taken from the MIT-BIH database used to train the MLP network by using multiple training algorithms with Tan-Sigmoid as an activation function.


Introduction
Cardiac abnormal activity in human heart that usually results in irregularities or disorders in the heartbeat is known as arrhythmias (or dysrhythmias). These disorders include fibrillation, re-entry or activity triggered. Abnormality level rates are classified to normal, bradycardia and tachycardia. These problems can interfere with the heart's electric system and induce arrhythmia which could be the symptom of heart disease (coronary). Cardiac abnormalities occur since the blood clots formed in the bloodstream and blocked the blood to travel to the heart. These clotted bloods cause the arteries to become narrow and causes the disruption of the blood circulation in the body. It will cause the oxygenated blood pumped across the body to be inadequate and cause the cells to have a small percent of oxygen in turn can cause a heart attack.
Electrocardiogram (ECG) is a commonly used method of detecting cardiac abnormality. ECG is a test performed to identify heart electrical activity as a result of contraction and expansion of heart muscles. In order to get ECG output, some electrodes are placed in a particular place at the body. This electrode can detect any small changes of the electrical signal in the heart. Electrocardiography is measured heart activity by differentiate the potential of electrical in a pair of electrode, thus recording electrical current associated with cardiac activity will be recorded. This work will be used computerized techniques in predicting cardiac abnormalities by using MLP networks. The MLP network consist of numbers of layers, and each layer is connected to layer by using nodes. Both duration and amplitude of P, QRS, T waves of ECG signal usually used as the input parameter to the MLP network.

Literature Review
This chapter will explain more about heart function as well as the process of producing electric pulses in the heart. Then, the explanation will be continued on the use of ECG in identifying cardiac abnormalities. Some parameters from ECG will be used as inputs to the Artificial Neural Network (ANN). The ANN is widely used with the numbers of type and application. One of the commonly used is Multilayer Perceptron (MLP) network. This MLP network can offer useful properties and capabilities, which are not linear, input-output mapping and neurobiological analogy. The MLP network has also been successfully applied in various fields including engineering, mathematics, finance and others [1][2][3]. In this study, MLP networks have been used for patterns identification system and subsequently classifying data. In addition, the MLP network is pairing with selected training algorithms to train then optimize the network and the Tan-Sigmoid function to activate the MLP network.

Human Heart
The heart plays a big role in the human body, 24 hours a day without fail. The heart works to pump blood throughout the body throughout blood circulatory system to supply nutrients and oxygen to tissue [4]. The heart muscle is thicker on the left side compared to the right side. The left muscles will pump blood throughout the body while the right muscles only receive nonoxygenated blood from the body [5]. In addition, carbon dioxide and others waste also be removed from blood circulation system. Blood circulation system in the human body takes place in two channels; heart and lung channels. In the heart channel, the oxygenated blood transmitted from pulmonary vein to rest of body via aorta. This oxygenated blood enters the arteries and capillaries to supply oxygen to tissue bodies. In the lungs, deoxygenated blood transmitted from vena cava to the right ventricle via the pulmonary artery to enter the lungs. In the lungs, deoxygenated blood will be supplied with the oxygen then move to the left atrium through the pulmonary venous blood vessels. The changes in electrical system of the heart may lead to cardiac abnormalities or Arrhythmias which interfere with the heartbeat rhythm [7]. There are several categories of arrhythmia, bradycardia, normal and tachycardia [8]. Table 1 shows the types of heart defects and symptoms. Table 1. Heart Abnormality and its symptom.

Heart Abnormality Symptom
Bradycardia Heart beat too slow, < 60 beats/min Normal Heart beat at rest time, within 60 to 100 beats/min Tachycardia Heart beat too fast, >100 beats/min

Electrocardiogram (ECG)
ECG is an electrical signal in the heart which always be recorded, associated with the electrical signal in the heart. Numbers of electrode are located at limbs and chest, simultaneously the electrical signal will be recorded and monitored the generated electrical impulses as atrial and ventricular are contract and rest. Any changes of the current and voltage of any two electrodes is displayed as a wave on the screen or paper [9]. ECG consists of waves P, QRS and T. However, sometimes additional waves can be seen on the ECG called U waves. This type of wave represents the electrical activity of the heart as shown in Table 2. The waveform generated by the ECG monitor illustrates the electrical changes occurring in the heart. Depolarization occurs when the heart receives an electrical boost while repolarization occurs when the heart recharges itself.

Artificial Neural Network and Activation Function
Artificial Neural Network (ANN) is designed perform similar with the biological system in human brain. ANN are including with artificial neurons (network, also known as "nodes"). These nodes are designed to be connected of each other. The ANN is fall under Artificial Intelligence (AI) cluster seem to be involving with human brain ability. An algorithm is designed and optimised to be function as human brain [1][2].
The MLP is one of AI algorithm, consist of layers connected between the input and output layers. The input parameter is fed into single directional, from input to output layer. Inputs of neurons are assigned nodes which are not targeted at any connection while output neurons are nodes that do not have any source connection. MLP is not restricted to an output neuron alone but the number of output neurons depends on the number of targets (the desired value) of the training pattern described. The nodes between input neurons and output neurons are known as hidden neurons. The network is designed with one layer of input, single or more layers as hidden layer and one layer of output. The nodes in MLP at the input-output layers is depend on variables of input-output be required. Hashim et. al. in their work shown of a single hidden layer is adequate to approximation the continuous function until reach to acceptable accuracy [11]. The prediction output of the designed MLP network as given by: where ni and nh are the number of input nodes hidden nodes, respectively. The ∂(•) is the chosen Tan-Sigmoid activation function which to activate the MLP network. The weights 1 , 2 , and 0 1 are unknown variables. So all the weights are required to converge until the optimum is reached in order to minimize the cost function (prediction error) defined as: with ( ) is the output given or taken from database (actual output) and ̂( ) is the predicted given or calculated by the algorithm. The transfer function is constructed to be used for mapping input-output signals.
In this work, the MLP network is activated by Tan-Sigmoid function.
This Tan-Sigmoid transfer function is related to a bipolar sigmoid. The output of Tan-Sigmoid activation function is ranging from of -1 to +1.

Methodology
In the work, rectangular pulse signal is generated and superimposed with ECG signal. Each intersection between rectangular pulse and ECG signal will be taken as the input of the MLP network. From the work, rectangular pulse is generated from one to ten pulse to overlapped with a complex ECG signal. Intersections are generated using factor of 2n-1; which n is the number of pulses of rectangular pulse. From the simulation, the four pulse (seven intersections) sufficient to give best results. Clinically, most ECG measurement is undergo during subject or patient in rest or walking with a constant velocity. Most ECG signal rates are extracted based on R to R peak interval (RRI) morphology. However, the heartbeat will be different if the subject performs healthy activities such as walking or climbing stairs. Therefore, to overcome this problem, the extraction based on P to T peak interval (PTI) morphology. PTI has been recognized where the reading is taken from the peak P to the T peak at each complex. Datasets of RRI and PTI morphologies are generated from ECG signals; which contains numbers of complexes. Rectangular pulse is generated then overlapped with RRI and PTI morphology complexes. The amplitude and duration of each intersection between ECG and pulse is noted to be the input vector for the neural network.

Results and Discussion
From the table, the use of four rectangular pulses (seven intersections) is sufficient to produce good classification results. The network of MLP networks requires sufficient RRI and PTI dataset to produce high accuracy prediction however, too much dataset makes the network more complex and networks unable to be classified properly. A dataset with 1000 data has been used to train MLP networks with 800 for training and the rest for testing. ANN such as Feed-Forward Backpropagation (FFBP), Multilayer Perceptron and Cascade-Forward Reinforcement (CFBP) have been selected as the training algorithm for MLP network. Both network structure is activated by Tan-Sigmoid activation function for RRI and PTI morphologies [12].   Table 3 shows that MLP networks have yielded better results compared to CFBP and FFBP networks for both RRI and PTI morphology. The MLP network provided the lowest MSE with 0.0008 and 0.0015 for RRI and PTI morphology. The MLP network also showed the highest regression score among others with 0.9972 for RRI 0.9969 for PTI morphology, with both MSE and regression bases on RPE training algorithms. The MLP network trained by RLS training algorithm also shows high accuracy prediction results but unable to overcome with MLP network trained by RPE training algorithm performance. Both the CFBP and FFBP networks (AI techniques) are able to perform good accuracy results but unable to outperform MLP network performance.

Conclusion
The ANN is capable to monitor the activity of cardiac abnormalities in the human body. The combination of the suitable structures, training algorithms and activation functions that are appropriate for current use can provide high precision performance in predicting.
From work papers, it shows that MLP networks with RPE training algorithms capable to give the highest regression and the lowest MSE performance than other networks.