%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%2345678901234567890123456789012345678901234567890123456789012345678901234567890
% 1 2 3 4 5 6 7 8
\documentclass[a4paper, 10 pt, conference]{ieeeconf} % Comment this line out
% if you need a4paper
%\documentclass[a4paper, 10pt, conference]{ieeeconf} % Use this line for a4
% paper
\IEEEoverridecommandlockouts % This command is only
% needed if you want to
% use the \thanks command
\overrideIEEEmargins
% See the \addtolength command later in the file to balance the column lengths
% on the last page of the document
\usepackage{graphicx}
\usepackage{amsmath,amsfonts,amssymb}
% The following packages can be found on http:\\www.ctan.org
%\usepackage{graphics} % for pdf, bitmapped graphics files
%\usepackage{epsfig} % for postscript graphics files
%\usepackage{mathptmx} % assumes new font selection scheme installed
%\usepackage{times} % assumes new font selection scheme installed
%\usepackage{amsmath} % assumes amsmath package installed
%\usepackage{amssymb} % assumes amsmath package installed
\title{\LARGE \bf
ECG Project
}
%\author{ \parbox{3 in}{\centering Huibert Kwakernaak*
% \thanks{*Use the $\backslash$thanks command to put information here}\\
% Faculty of Electrical Engineering, Mathematics and Computer Science\\
% University of Twente\\
% 7500 AE Enschede, The Netherlands\\
% {\tt\small h.kwakernaak@autsubmit.com}}
% \hspace*{ 0.5 in}
% \parbox{3 in}{ \centering Pradeep Misra**
% \thanks{**The footnote marks may be inserted manually}\\
% Department of Electrical Engineering \\
% Wright State University\\
% Dayton, OH 45435, USA\\
% {\tt\small pmisra@cs.wright.edu}}
%}
\author{Raphaël Blanchet, Axel Boland, Thomas Donnay, Mario Jose Teles Varandas, \ \small{\textit{University of Liege}}}
\begin{document}
\maketitle
\thispagestyle{empty}
\pagestyle{empty}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{abstract}
We were asked to design our own Electrocardiogram. Obviously, recording heart beats without any noise is a real challenge. Seeing the prices of those kinds of devices, we could already imagine that reaching great performances with our means would be difficult. However, the real goal of this project was to be able to analyze the different problems we encountered and to think about possible improvements we could have provided to overcome them.
%Go On with a summary of the next chapters
\end{abstract}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{INTRODUCTION}
Electrocardiograms are a fundamental components of today's medicine. They have many functions, as the monitoring of the heart condition of a patient under surgery, or the possible detection of heart diseases. However, their use is not limited to the heart. Indeed, electrocardiograms can be used to detect other problems, such as pulmonary embolism.\\
In Section II we will briefly talk about ECG's market and opportunities while in Section III we will discuss about ECG's electrode working principles to briefly understand how we can detect and record biological electric signals.
Then, since the required measurements are very low in magnitude, noise can have a great impact on measurements. Hence we will describe possible noise sources in section IV.\\
In section V we are going to answer to some specific questions we had to think about before starting our ECG design.\\
Afterwards, in section VI and VII we will show our ECG design and prototype but also emphasize their results and problems.
Finally in section VIII we will describe some possible improvements which could be made in the future.
%% Donner le résumé des chapitres
\section{ECG equipment market}
Based on a report from Grand View Research regarding the ECG equipment market \cite{ecgmarket}, it has been predicted that this market is going to reach almost \$6,3 billion by 2022 when it was valued at \$3,683 million in 2013.
This growth can be considered as the result of cardiovascular disorder increase and the initiatives from governments to intensify check-ups of their population.
According to the World Health Organization (WHO) \cite{ecgoms}, cardiovascular disease makes 17.5 million deaths which represent around 31\% of global death and twice the number from cancers. This is the results of a lack of early symptoms or late diagnosis from the patient or the medical corps.
The American Heart Association (AHA), reports that in 2012, the percentage of women death due to heart disease had reached 56\% while it was 30\% in 1997.
The ECG market is divided in 3 main segments:
\begin{itemize}
\item ECG monitoring equipment (Equipment most commonly used in hospital that monitors the heart beats during medical diagnosis and represent the main segment of the market)
\item ECG stress testing system (Measures of heart's ability to respond to external stress in a controlled clinical environment)
\item Holter monitoring system (Equipment hold by the patient that record heart activity for observing occasional cardiac disorder which would be difficult to identify in short medical diagnosis)
\end{itemize}
The main actors of ECG market are:
\begin{itemize}
\item (U.K.) GE Healthcare
\item (Netherlands) Philips Healthcare
\item (China) Mindray Medical,
\item (U.S.) Mortara Instrument Inc., Spacelabs Healthcare, Cardionet, Compumed Inc. and Welch Allyn,
\item (Switzerland) Schiller AG,
\item (Japan)Nihon Kohden Corporation,
\end{itemize}
Also, ECG industries are constantly re-thinking the ECG by implementing new technologies. For exemple, CardioComm Solutions Inc. (U.S.) launched in May 2015 a HeartCheck PEN which works through thumbs measurements and integrate a Bluetooth wireless connectivity that could be connected for data acquisition with Android or Apple smartphones.
\section{Electrode working principle}
In their article \cite{electrode}, Stephen Lee and John Kruse, explain that electrode used in electrocardiography (ECG), electromyography (EMG), and electroencephalography (EEG) are biopotential electrodes that are able to measure heart, muscle or brain activity. This type of electrode measures the electric potential on the surface of living tissue by detecting the ionic current flow. The biopotential electrode then converts the ion current to electron current.
To enhance the ion detection, an electrolyte solution is added between the electrode and the living tissue, on the other side, a conductive metal is attached to a lead wire connected to the instrument. Then a chemical reaction appears among the electrolyte and the electrode that allows to receive a signal.
Silver/silver chloride (Ag/AgCl) electrodes are very common due to their very low half-cell potential of approximately 220 mV and their ease of manufacturability. The half-cell potential is a voltage that is established at the interface of the electrolyte and the electrode due to an uneven distribution of anions and cations and is seen as a DC offset by the measurement instrument.
There exist also Ag/AgCl electrodes which are nonpolarized electrodes. It means that they allow current to pass across the interface between the electrolyte and the electrode, when polarized electrodes act more like a capacitor and current is displaced but does not move freely across the electrolytic interface. Then, nonpolarized electrodes are considered as better than polarized electrodes regarding their rejection of motion artifacts and their response to defibrilation currents.
\section{Noise}
ECG measurements can be corrupted by several sort of noise. The main causes of noise are the following ones\cite{noise},\cite{noise2}:
\begin{itemize}
\item Power line interference;
\item Electrode contact noise;
\item Motion artifacts;
\item EMG noise;
\item Instrumentation noise.
\end{itemize}
A block diagram of each of these noise sources is shown in figure \ref{oxidation}.\\
\begin{figure}[!h]
\begin{center}
\includegraphics[scale = 0.6]{Noise.png}
\caption{\label{oxidation}noise}
\end{center}
\end{figure}
\subsection{Power line interference}
The power line interferences are the 50Hz (60 Hz in the United States) -and multiples- coming from all the devices connected to the network. Power line interferences occur through two mechanisms: capacitive and inductive coupling. Capacitive coupling is the coupling capacitance between two circuits having a voltage difference and the inductive coupling is due to the mutual inductance betwwen two conductors.\\
Typically, capacitive coupling is responsible for high frequency noise while inductive coupling introduces low frequency noise. For this reason inductive coupling is the dominant mechanism of power line interference. Ensuring the electrodes are applied properly, that there are no loose wires, and that all components have adequate shielding should help limit the amount of power line interference.
In addition, one could use a notch filter at 50 Hz or a comb filter at all multiples of 50 Hz.\\
\subsection{Electrode Contact Noise and Motion Artifacts}
Electrode contact noise is caused by variations in the position of the heart with respect to the electrodes and changes in the propagation medium between the heart and the electrodes. This causes sudden changes in the amplitude of the ECG signal. In addition, poor conductivity between the electrodes and the skin both reduce the amplitude of the ECG signal and increase the probability of disturbance.
Motion artifacts are transient (but not step) baseline changes caused by electrode motion. The usual causes of motion artifacts are vibrations, movement, or respiration of the subject.
The solution consists of a high pass filter with a cut-off frequency $\sim$ 0.5 Hz. Another solution for the motion artifacts interference is to make some recurrent adaptive filtering.\\
\subsection{EMG noise}
EMG noise is caused by the contraction of other muscles besides the heart. When other muscles contract, they generate depolarization and repolarization waves that can also be picked up by the ECG. In general the amplitude of these signals are about 10$\%$ of the ECG amplitude with a bandwidth between 20 and 1000 Hz.
It can be reduced by using a low pass filter with a cut off frequency $>$ 20 Hz.\\
\subsection{Instrumentation Noise}
The electrical equipment used in ECG measurements also contributes to noise. The major sources of this form of noise are the electrode probes, cables, signal processor/amplifier, and the Analog-to-Digital converter.
Unfortunately instrumentation noise cannot be eliminated as it is inherent in electronic components, but it can be reduced through higher quality equipment and careful circuit design.
\section{Problems : before starting}
This section is about the problems we needed to think about before beginning to work on the project itself.
\subsection{What are the frequencies that you want to record?}
An average of 70 heartbeats/minute is a good approximation for the heart rate of human beings. This corresponds to a frequency of $\frac{70}{60}\approx 1.2Hz$. However to be able to reconstruct the whole electrocardiogram we consider that we have to have a bandwidth including at least the range $[0.05;150]Hz$.
\subsection{Which amplification gain do you need?}
The electric signals produced by the heart are of the order of magnitude of milliVolts. We thus decided to use an amplification gain of 1000 in order to measure and/or display signals of the order of magnitude of Volts.
\subsection{Propose a solution to Common mode parasite.}
We used the right-leg feedback, or right-leg drive amplifier, to try to diminish as much as possible common-mode parasitic signals.
\subsection{Which devices will you use? Regarding the datasheet, comment in 5 lines your op-amp choice.}
We first used two LTC1050 op amps. By having a quick look at the datasheet, it's easily understandable why we chose this model. Indeed, it has a \textbf{minimal} CMR of 120dB, a low noise and its input common mode range includes ground, which can be useful since we are dealing with very small signals. Besides the supply voltages we needed to power it were matching the power supply needed for our instrumentation amplifier and it consumed a small input current.
We also used an AD623 op amp. Is has also goof CMR (even if smaller than that of LTC1050, it is a "rail-to-rail" op amp, which was useful to make sure that our output would not saturate.
\section{Problems : ECG Design}
We decided to use Einthoven's triangle principle to measure electrical activity of the heart over a period of time using electrodes placed on a patient's body.
Hence we had to use 2 or 3 electrodes.
\begin{itemize}
\item Right arm: RA
\item Left arm: LA
\item Right leg: RL
\end{itemize}
First we decided to use only 2 electrodes (RA and LA). Afterwards we added RL derivation.
\subsection{Electronic circuit}
\begin{itemize}
\item First stage \\
Knowing that the ECG bandwidth is equal to [0.05-150]Hz, we used two pass-band filters within that range.(i.e: one for each arm).
\item Second stage\\
We needed to amplify the signal since its order of magnitude was around mV.
Hence we decided to use an instrumentation amplifier, since it has a very good Common-mode rejection ratio. Using R$_G$=50 $\Omega$ we had a gain greater than 1000.
\end{itemize}
\subsection{LTspice Simulation}
In order to test if our designed circuit had a good response we made an equivalent model on LTspice. We used an ECG signal as input for the RA and for the LA the same signal but reversed. The LTSpice model is shown in Figure \ref{spice}.
\begin{figure}[!h]
\centering
\includegraphics[scale=0.35]{1stmodel.png}
\caption{ECG circuit on LTspice}
\label{spice}
\end{figure}
\begin{figure}[!h]
\centering
\includegraphics[scale = 0.25]{ECG_simulation_Vin.png}
\caption{V$_{in}$}
\label{vin}
\end{figure}
\begin{figure}[!h]
\centering
\includegraphics[scale=0.25]{vout_1ermodel.png}
\caption{V$_{out}$}
\label{vout}
\end{figure}
As we could observe in Figure \ref{vin} the input signal had a correct shape and amplitude for an ECG signal. The output signal, as we could see in Figure \ref{vout} was well amplified (peak about 4.8V compared to 1mV for Vin) and we could also see that the periodicity was respected since it remained around 1 second.
Therefore based on such results we decided to validate our circuit and move up to a real prototype.\\\\
\textbf{Bandwidth and gain}
\begin{figure}[!h]
\centering
\includegraphics[scale=0.13]{fre.jpg}
\caption{Bode diagram}
\label{bode}
\end{figure}
In Figure \ref{bode} we showed the Bode diagram corresponding to our Spice simulation.
We saw that the bandwidth was respected ([0.05-150]Hz), but we had a negative gain of -96dB. Which did not seem logical since in the temporal analysis we clearly saw an amplified signal at the output. Hence we thought that we could have done some errors when doing AC analysis in LTspice.
\section{ECG Prototype}
\subsection{First Model}
Our first model did not have any RL derivation. Figure \ref{card1} shows how it looked like on our card and Figure \ref{osci} shows what we obtained at the oscilloscope at the output.
\begin{itemize}
\item Green Wires on the left: Power supply: +5V
\item Green and orange wire on bottom: RA and LA respectively
\item Yellow wire: Signal output
\end{itemize}
\begin{figure}[!h]
\centering
\includegraphics[angle=90,scale=0.05]{1stModel.jpg}
\caption{ECG Prototype}
\label{card1}
\end{figure}
\begin{figure}[!h]
\centering
\includegraphics[scale=0.05]{RA_LA.jpg}
\caption{Output Signal}
\label{osci}
\end{figure}
we first thought the output signal in Figure \ref{osci} looked similar to an ECG signal but, once we looked closer, we noticed that the period of the signal was equal to 20ms $\Rightarrow$ 50Hz. All we were looking at was 50Hz interference.
Hence we deduced that our output signal was drowned into noise.
\subsection{Second Model}
Unfortunately, the patient's body can also act as an antenna picking up electromagnetic interference, especially 50/60 Hz noise from electrical power lines. Right Leg Driver circuitry is used to eliminate interference noise.
Therefore in our second model we included a RL derivation.
\begin{figure}[!h]
\centering
\includegraphics[scale=0.3]{2ndmodel.png}
\caption{ECG circuit with RL derivation}
\label{spice2}
\end{figure}
As we can see in Figure \ref{spice2}, we replaced $R_{G}$ by two resistors of 25 $\Omega$. The potential between these two resistors is the common mode potential (V$_+$ + V$_-$)/2 which could impose the shield potential. We added a 390k$\Omega$ resistor to protect the patient.
\begin{figure}[!h]
\centering
\includegraphics[scale=0.05]{10mswithRL.jpg}
\caption{$V_{out}$ - Timescale = 10ms}
\label{os2}
\end{figure}
Unfortunately our signal was still drowned by the 50Hz interference, as we can see in Figure \ref{os2}.
\subsection{Third Model}
Since our problems always came from 50Hz interference, why couldn't we reduce the bandwidth to frequencies lower than 50Hz?\\
We thought that a heart will never beat at a frequency higher than 50Hz.
Hence we decided to reduce the bandwidth to 25Hz. Therefore we changed the low pass filter resistor from 10k$\Omega$ to 60k$\Omega$.
Furthermore we had the chance to use the shield of group\footnote{Florent Bourghelle, Fanny de Decker, Eva Hansenne, Maxime Javaux} for our circuit.
We set the shield potential to V$_{CM}$ (as said above). Instead of placing the electrodes on the arms we thought it would be better to place them on our chest.
Finally in order to reduce picked external flux, we twisted the RA\&LA wires.
\begin{figure}[!h]
\centering
\includegraphics[scale=0.05]{box.jpg}
\caption{Final prototype within an opened shield}
\end{figure}
\begin{figure}[!h]
\centering
\includegraphics[scale=0.25]{3thmodel.png}
\caption{3th model circuit}
\end{figure}
\begin{figure}[!h]
\centering
\includegraphics[scale=0.05]{ecg.jpg}
\caption{Results from final prototype}
\label{final}
\end{figure}
As we can see in Figure \ref{final}, we finally achieved to have a "correct" ECG, even if we did not cover all the desired range.
\section{Possible improvements}
Here are some possible improvements for our ECG prototype.
\begin{itemize}
\item Notch Filter at 50 Hz if we let the bandwidth as [0.05-150]Hz\\
The problem with the notch filter is that since our useful signal's frequency is around 50 Hz if the filter has not a very good quality factor it will attenuate it.(Need to be tuned)
\item Conductive gel for electrodes
\item Coaxial connection cables
\item Better placement of electrodes
\end{itemize}
\addtolength{\textheight}{-12cm} % This command serves to balance the column
\begin{thebibliography}{99}
\bibitem{ecgmarket} \textit{ECG Equipment Market Size | ECG Device Industry Report, 2022}, http://www.grandviewresearch.com/industry-analysis/ecg-equipment-market
\bibitem{ecgoms} \textit{Global status report on noncommunicable diseases 2014}, http://www.who.int/nmh/publications/ncd-status-report-2014/en/
\bibitem{electrode}\textit{Biopotential Electrode Sensors in ECG/EEG/EMG Systems}, http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.175.4192
\bibitem{noise}\textit{Noise in ECG and how to deal with it}, http://www-classes.usc.edu/engr/bme/620/LectureECGNoise.pdf
\bibitem{noise2}\textit{Characterization of ECG Noise Sources}, http://www.ecf.utoronto.ca/~sdavies/sysbioldir/papers2005/Characterization of ECG Noise Sources.doc
\end{thebibliography}
\end{document}