Document Details

HandyOakland

Uploaded by HandyOakland

Hawassa University

Tags

ECG signal processing biomedical engineering electrocardiography

Summary

This document details the process of ECG signal processing, focusing on acquisition, electrode placement, and waveform recognition techniques. It also describes aspects of signal interpretation, including elements like P-waves, PR-segments, QRS complexes, S-waves, ST segments, and T-waves, for diagnosis purposes. Methods of QRS detection, such as the Pan-Tomkins algorithm, are discussed.

Full Transcript

# Chapter 5: ECG Signal Processing ## 5.1 ECG Signal Acquisition and Pre-processing ### 5.1.1 ECG Signal Acquisition and Electrode Placement * **Right and left arm leads:** should be placed outwardly on the shoulders, preferentially over bone rather than muscle. * **V4:** should be placed in the...

# Chapter 5: ECG Signal Processing ## 5.1 ECG Signal Acquisition and Pre-processing ### 5.1.1 ECG Signal Acquisition and Electrode Placement * **Right and left arm leads:** should be placed outwardly on the shoulders, preferentially over bone rather than muscle. * **V4:** should be placed in the fifth intercostal space on the mid-clavicular line. * **V1 and V2:** are positioned in the fourth intercostal space. * **V3:** lies halfway between V2 and V4. * **V4, V5 and V6:** should be placed along a horizontal line, which does not necessarily follow the intercostal space. ### 5.1.2 Electrode Interpretation **(Diagram)** A diagram depicting the flow of charges during polarization and depolarization of a cell. * **When polarization:** +ve charges may go to the -ve electrode and creates a positive deflection. * **When sell depolarizes:**-ve charges go to negative electrode, this creates positive deflection at the -ve electrode. * **When +ve charges go way from the +ve electrode:** negative deflection will be created at the electrode. * **When +ve charges go across axis of line connecting the +ve and -ve electrode:** it creates +ve deflection for half cycle and -ve deflection, the other half cycle. Thus they will cancel out each other. ### 5.1.3 P-wave The P-wave is the result of the flow of +ve charge to the electrode, from SA-node to the AV-node. It may create depolarization in all directions, but the resultant is as indicated; this is the depolarization of atrium creating a positive deflection at the positive electrode on the left leg. ### 5.1.4 PR-Segment and PR-Interval The AV-node with low conductivity holds the signal for 100ms without any electrical activity, creating the PR-segment. The P-wave with the PR-segment is called the PR-interval. ### 5.1.5 Q-wave Depolarization signal is sent through bundle of HIS and bundle branches. This reaches to the septum and depolarizes it. Since there is more muscle on the left ventricle septum, the resultant depolarization vector direction is to the left, creating a negative deflection on the left leg electrode. This is Q-wave. ### 5.1.6 R-wave After the Q-wave, the depolarization is quickly passed to the Purkinje fibers in both the right and left ventricle. Since, the left ventricle possess more myocardium, the result of the depolarization is to the left, creating a positive deflection on left leg electrode. This is the R-wave, which has maximum intensity. ### 5.1.7 S-wave After the R-wave, the depolarization goes upward. This is through the movement of positive charges away from the +ve electrode, creating a negative deflection on the left leg. This is the S-wave. ### 5.1.8 ST-segment After the S-wave, meaning after finishing the depolarization of the ventricles, it stays that way for a moment, creating the ST-segment. ### 5.1.9 T-wave The last wave, the T-wave is as a result of ventricular repolarization. This is as a result of the movement of -ve charges away from the +ve electrode, creating a positive deflection on the left leg electrode. This indicates the end of one cycle of an ECG signal. ### 5.1.10 ECG Signal Acquisition and Electrode Placement ECG leads: * 10 physical leads: 6-precordial uni-polar leads (v1-v6) and 1-right arm, 1-left arm, 1-left leg and 1-common leads. * 6 Unipolar leads (v1 - v6) * 4 Bipolar leads (I, II, III, aVF) ### 5.1.11 ECG Preprocessing * **High-frequency noise in recording system, pick-up:** The signal illustrated has which may also be considered the ECG signal. * **Motion artifact in the ECG signals by coughing or breathing, in the case of limb-lead ECG:** The signal illustrated has which may also be considered the ECG signal. * **The EGG is a common electrode, which may also cause variations in temperature:** Base-line drift makes analysis cause the positive or negative ## 5.2 ECG waveform recognition ### 5.2.1 ECG QRS Detection Techniques * **Pan-Tomkins algorithm:** This is one of the most widely used algorithms for QRS detection. It involves a series of steps including band-pass filtering, differentiation, squaring, and integration to enhance the QRS complex, followed by a thresholding step to detect the QRS peaks. **Steps:** * Band-Pass Filtering 5-15 Hz * Differentiation * Squaring * Integration (moving integration) * Thresholding (upper and lower) * Peak detection and refinement (200ms) * **Digital filtering based:** It is the same as the Pan-Tomkins but with somehow better and advanced approaches implementing different kinds of filter as well as transform-based feature extraction. **Steps:** * Suitable Filtering 4-40 Hz * Advanced Differentiation * Hilbert or wavelet transform Squaring * Integration (moving integration) * Thresholding (adaptive or not) * Peak detection and refinement (200ms) * **Wavelet based:** wavelet transform-based techniques offer robust and accurate methods for QRS complex detection, leveraging the multi-resolution analysis capabilities of wavelets to enhance signal processing in ECG signals. * **Machine learning and deep learning based:** Machine learning and deep learning techniques have been increasingly applied to detect QRS complexes in electrocardiogram (ECG) signals due to their ability to learn complex patterns and adapt to varying signal conditions. **(Diagram)** A diagram depicting the relationship between artificial intelligence, machine learning, and deep learning. A second diagram showing the process of feature extraction and learning in both machine learning and deep learning. ### 5.2.2 Estimation of R-R Interval * **Using these algorithms:** will be used to estimate the R-R interval and ST segment inclination by simple calculation. * **The R-R interval is finding the time between two consecutive ECG signals** ### 5.2.3 Estimation of ST Segment Inclination **The ST segment inclination can be calculated** * **Mathematical Formulation** * **Inclination Height (H):** H = Amplitude at end of ST segment - Amplitude at J point * **Inclination Angle (β):** β = arctan (H/ Duration of ST segment) * **Maximum Velocity (MVR):** MVR = max (d/dt (ST segment signal)) ### 5.2.4 Arrhythmia Analysis Monitoring * **A heart arrhythmia:** is an irregular heartbeat. Some heart arrhythmias are harmless. Others may cause life-threatening symptoms. * **There are two types of arrhythmias:** * **Tachycardia:** above normal. * **Bradycardia:** below normal. ### 5.2.5 Features of Arrhythmia Detection * **P Wave:** Indicates atrial depolarization; abnormalities suggest atrial arrhythmias. * **QRS Complex:** Reflects ventricular depolarization; widening may indicate ventricular arrhythmias. * **T Wave:** Represents ventricular repolarization; changes suggest ischemia or electrolyte imbalance. * **RR Interval:** Variation helps identify bradycardia, tachycardia, or irregular rhythms. * **QT Interval:** Prolongation or shortening indicates risk for arrhythmias. ### 5.2.6 Types of Arrhythmia Detected in ECG * **Atrial Arrhythmias** * **Ventricular Arrhythmias** * **Conduction Disorders** * **Other Arrhythmias** ### 5.2.7 ECG Analysis * **Manual Interpretation:** Clinicians visually analyze ECG waveforms for abnormalities. * **Automated Analysis:** Algorithms detect arrhythmias by analyzing ECG features. * **Time-domain analysis:** Measures intervals like RR and PR. * **Frequency-domain analysis:** Identifies periodic components of arrhythmias. * **Wavelet transforms:** Captures transient changes in ECG signals. * **Artificial Intelligence:** * **Machine Learning:** Models trained on labeled ECG datasets for arrhythmia classification. * **Deep Learning:** Neural networks (e.g., convolutional neural networks) for end-to-end detection of complex arrhythmias. ### 5.2.8 Challenges and Future Trends * **Challenges:** * **Signal Noise:** Motion artifacts, baseline wander, and interference can obscure signals. * **Data Overload:** Long-term monitoring generates large datasets, requiring efficient processing. * **False Positives/Negatives:** Automated systems may misclassify rhythms, impacting diagnosis. * **Patient Compliance:** Wearable and implantable device usage depends on patient adherence. * **Future Trends:** * **Integration of ECG devices with cloud-based AI for real-time analysis.** * **Development of ultra-portable and affordable monitoring devices.** * **Enhanced precision of automated systems through advanced machine learning.** ### 5.2.9 ECG Data Reduction * **ECG data reduction techniques are essential for efficient storage, transmission, and analysis of electrocardiogram (ECG) signals, particularly in tele-cardiology and e-healthcare systems.** Here are the basics and some common techniques used for ECG data reduction: * **Reasons for ECG Data Reduction:** * **Storage and Transmission Efficiency:** Reducing the amount of data required to store and transmit ECG signals can significantly lower storage costs and improve transmission speeds, especially in real-time monitoring systems * **Data Quality and Noise Reduction:** Some techniques not only reduce data but also help in removing noise and artifacts, enhancing the overall quality of the ECG signal * **Common ECG Data Reduction Techniques:** * **Turning Point Algorithm:** This algorithm identifies and retains only the significant points (turning points) in the ECG signal, discarding the rest. It is simple and effective but may lose some detail. * **Delta Coding:** Delta coding involves storing the differences between consecutive samples rather than the absolute values. This method is efficient when the signal has a low variability between samples * **AZTEC (Arizona Tachycardia and Tachyarrhythmia Electrocardiogram Coder):** AZTEC is a more complex algorithm that uses a combination of amplitude and slope thresholds to select significant points. It provides a good balance between data reduction and signal fidelity * **CORTES (Compressor of Real-Time ECG Signal):** CORTES is another algorithm that uses a combination of techniques to reduce data. It is known for its high compression ratio and good signal quality preservation * **Discrete Cosine Transform (DCT):** DCT is a transform-based method that compresses the ECG signal by representing it in the frequency domain. Only the most significant frequency components are retained, reducing the overall data size * **Empirical Wavelet Transform (EWT):** EWT is a technique that decomposes the ECG signal into different frequency components using wavelets. This allows for the retention of only the most significant components, reducing data size while preserving critical information * **Performance Metrics for compression** * **Compression Ratio (CR):** The ratio of the original data size to the compressed data size. * **Percent Mean Square Difference (PRD):** A measure of the distortion introduced by the compression algorithm. * **Quality Score (QS):** A subjective or objective measure of the signal quality after compression. * **Challenges and Considerations** * **Data Quality:** The choice of technique must balance data reduction with the preservation of clinically relevant information. Lower quality data can significantly impact the performance of machine learning models used for arrhythmia detection * **Noise and Artifacts:** Techniques should also consider the removal of noise and artifacts such as baseline wander, powerline interference, and motion artifacts to ensure reliable ECG analysis * **By selecting the appropriate ECG data reduction technique, healthcare providers can optimize the storage and transmission of ECG data while maintaining the necessary signal quality for accurate diagnosis and monitoring.** ## 5.3 Adaptive Filters for ECG Signal Analysis ### 5.3.1 Adaptive Filters and Noises in ECG * **These filters adjust their parameters dynamically to optimize performance based on the signal and noise characteristics.** They are particularly effective in handling non-stationary noise and interference, which are common in ECG recordings. * **Common noises in ECG:** * **Power Line Interference:** Frequency: 50/60 Hz. Results from electromagnetic interference. * **Baseline Wander:** Low-frequency drift caused by patient movement or respiration. * **Electromyographic (EMG) Noise:** High-frequency noise due to muscle activity. * **Motion Artifacts:** Non-stationary disturbances caused by electrode movement or body motion. ### 5.3.2 Characteristics of Adaptive Filtering * **Dynamic Adjustment:** Automatically update filter coefficients based on signal characteristics. * **Real-Time Operation:** Suitable for continuous ECG monitoring applications. * **Noise-Canceling Capability:** Ideal for removing non-stationary noise without distorting the ECG signal. ### 5.3.3 Adaptive Filter Techniques * **Least Mean Squares (LMS) Algorithm:** Minimizes the mean square error between the desired signal and the filter output. It is simple and computationally efficient, but it may converge slowly for high dynamic range signals. It is applied for removing power line interference and filtering baseline wander. * **Normalized LMS (NLMS):** An extension of LMS with normalization for faster convergence. More robust in handling variations in signal amplitude. * **Recursive Least Squares (RLS) Algorithm:** Minimizes the weighted error over all past samples. It has faster convergence as compared to LMS but with higher computational complexity. Used for high-performance filtering for ECG signals in noisy environments. * **Kalman Filtering:** Bayesian approach to estimate the true signal in the presence of noise. Applied in denoising ECG signals and handling missing or irregularly sampled data. It is highly accurate for dynamic and non-stationary noise however it requires precise noise model parameters. * **Adaptive Noise Cancellation (ANC):** Uses a reference noise signal (e.g., from a separate sensor) to cancel out correlated noise. Commonly used for power line interference and motion artifact reduction. ### 5.3.4 Design of an Optimal Adaptive Filter * **Design an optimal filter to remove a nonstationary interference from a nonstationary signal.** * **An additional channel of information related to the interference is available for use.** The filter should continuously adapt to the changing characteristics of the signal and interference. * **The filter should be adaptive; the tap-weight vector of the filter will then vary with time.** The principles of the adaptive filter, also known as the adaptive noise canceler(ANC) * **The filter should be optimal.** **Mathematical Equation:** $x(n) = v(n) + m(n)$ $z(n) = v(n) + m(n)$ $e(n) = x(n) - y(n)$ $e(n) = z(n) - y(n)$ $E[e²(n)] = E[v²(n)] + E[{(m(n) - y(n))²}] + 2E[v(n){(m(n) - y(n))}]$ $E[v(n){(m(n) - y(n))}] = E[v(n)]E[(m(n) - y(n))] = 0.$ $E[e²(n)] = E[v²(n)] + E[{(m(n) - y(n))²}]$. **(Diagram)** A diagram showing the process of adaptive filtering, including the primary input, reference input, adaptive FIR filter, and output. ### 5.3.5 Applications of Adaptive Filtering in ECG * **Flexibility to handle non-stationary noise.** * **Real-time adaptability for dynamic environments.** * **Preservation of ECG signal integrity during filtering.** ### 5.3.6 Challenges and Future Trends * **Computational complexity for algorithms like RLS and Kalman filters.** * **Convergence issues in scenarios with rapid noise variations.** * **Requirement for appropriate initialization and parameter selection.** ### 5.3.7 Future Directions * **Integration with machine learning to adaptively tune filter parameters.** * **Implementation in hardware for low-power real-time ECG monitoring.** * **Use of multi-channel adaptive filtering for improved noise cancellation.** # Chapter 6: EEG Signal Processing ## 6.1 EEG Signal Acquisition and Characteristics ### 6.1.1 EEG Signal Acquisition * **Electroencephalography (EEG):** is a non-invasive technique to measure electrical activity in the brain. * **Key Aspects of EEG Signal Acquisition:** * **Electrode Placement:** Electrodes are placed on the scalp using standardized systems, such as the 10-20 system. These electrodes detect voltage fluctuations caused by ionic currents in neurons. * **Amplification:** EEG signals are typically weak (in the range of microvolts), requiring high-gain amplifiers to make them measurable. * **Filtering:** * **High-pass filters:** to remove DC drift and slow artifacts). * **Low-pass filters:** to eliminate high-frequency noise). * **Notch filters:** to reduce powerline interference at 50/60 Hz) * **Sampling and Digitization:** Signals are digitized using analog-to-digital converters (ADC) with sampling rates typically between 250 Hz and 1000 Hz to ensure the Nyquist criterion is satisfied. * **Signal Artifacts:** Artifacts such as eye blinks, muscle movements, and electrode motion are often removed through preprocessing techniques like Independent Component Analysis (ICA). ### 6.1.2 EEG Signal Characteristics * **EEG signals exhibit specific characteristics based on their frequency, amplitude, and origin.** These characteristics are categorized into frequency bands: * **Delta Waves (0.5–4 Hz):** Associated with deep sleep and unconscious states. Amplitude: High (20-200 μν). * **Theta Waves (4-8 Hz):** Linked to drowsiness, creativity, and meditation. Amplitude: Moderate (20-100 μν). * **Alpha Waves (8-13 Hz):** Observed during relaxation and calm, awake states, often with closed eyes. Amplitude: Moderate (10-50 μV). * **Beta Waves (13–30 Hz):** Related to active thinking, focus, and problem-solving. Amplitude: Low (5–20 μν). * **Gamma Waves (30–100 Hz):** Associated with high-level cognitive functioning and information processing. Amplitude: Very low (<10 µV). * **Event-Related Potentials (ERPs):** Time-locked responses to specific sensory, cognitive, or motor events. Commonly studied ERPs include P300 and N400 components. ### 6.1.3 Application of EEG * **Medical Diagnosis:** * **Epilepsy, sleep disorders, and brain injuries.** * **Neurofeedback and Rehabilitation:** * **Used in brain-computer interfaces (BCIs) and rehabilitation devices.** * **Research:** * **Studying brain dynamics, cognition, and neuroplasticity.** **(Diagram)** A diagram showing a 10-20 system for electrode placement on the scalp. A second diagram showing a graph of EEG waveforms categorized into frequency bands. ## 6.2 Evoked Potential and Averaging Technique ### 6.2.1 Evoked Potential * **Evoked responses (ERs):** are brain's time-locked electrical responses to specific sensory, cognitive, or motor stimuli. ### 6.2.2 Common Types of Evoked Responses * **Sensory Evoked Potentials (SEPs):** * **Generated by sensory stimuli (e.g., visual, auditory, or somatosensory).** * **Examples:** Visual Evoked Potentials (VEPs), Auditory Evoked Potentials (AEPs), and Somatosensory Evoked Potentials (SSEPs). * **Cognitive Evoked Potentials:** * **Reflect higher-level brain functions.** * **Examples:** P300 (decision-making) and N400 (language processing) ### 6.2.3 Averaging Technique * **Evoked responses are often obscured by background EEG activity and noise.** To enhance the signal-to-noise ratio (SNR), averaging techniques are employed: * **Time-Locked Averaging:** ERs are recorded across multiple trials of the same stimulus. Each trial contains the ER signal and noise. By averaging: * **The consistent signal (evoked response) is preserved.** * **Random noise is canceled out, improving SNR.** * **Key Steps in Averaging:** Align all trials based on the stimulus onset. Compute the point-by-point average across trials. The result is the averaged evoked response. * **Weighted Averaging:** Weights are assigned to trials based on their quality (e.g., lower weight for noisy trials). Improves robustness in the presence of outliers. * **Artifact Rejection:** Trials with excessive noise (e.g., muscle artifacts or electrode movement) are excluded before averaging ## 6.3 Pattern Recognition * **Time-Domain Analysis:** Examining the raw EEG signal visually or computationally to identify waveforms and amplitudes. * **Frequency-Domain Analysis:** Transforming EEG data using Fourier Transform or Wavelet Transform to isolate frequency components. * **Automated Signal Processing:** Using algorithms and machine learning to classify waves based on statistical and spectral features. * **Visualization:** Power spectral density (PSD) plots help distinguish the dominant frequency bands ## 6.4 Applications of EEG * **Medical diagnosis:** * **Epilepsy:** A neurological disorder marked by seizures. * **Sleep disorders:** Abnormalities in sleep patterns, including insomnia, sleep apnea, and narcolepsy. * **Brain injuries:** Damage to the brain caused by trauma, stroke, or infection, such as traumatic brain injury, stroke, or encephalitis. * **Neurofeedback:** a type of biofeedback that uses real-time monitoring of brainwave activity to train individuals to regulate their brain activity. This technique is used to address a variety of neurological and psychological conditions, including ADHD, anxiety, depression, and epilepsy. # Chapter 7: EMG Signal Processing ## 7.1 EMG Signal Acquisition and Description ### 7.1.1 Electromyography (EMG) * **Electromyography (EMG):** measures the electrical activity of muscles during contraction and rest. ### 7.1.2 EMG Signal Acquisition Stages The process of acquiring EMG signals involves several stages: * **Electrode Placement:** Electrodes are placed over the muscle belly, aligned with the muscle fibers to optimize signal capture. * **Types of electrodes:** * **Surface electrodes:** Non-invasive, placed on the skin to measure superficial muscle activity. * **Needle electrodes:** Invasive, inserted into the muscle for detailed, localized measurements. * **Signal Amplification:** EMG signals are typically weak (10 µV to 5 mV) and require amplification. * **Amplifier characteristics:** * **High gain:** amplifies weak muscle signals) * **Differential inputs:** to reduce noise from common sources * **Filtering:** EMG signals contain noise and artifacts that need to be filtered: * **High-pass filter:** Removes low-frequency motion artifacts. * **Low-pass filter:** Eliminates high-frequency noise. * **Notch filter:** Reduces powerline interference at 50/60 Hz. * **Noise and Artifact Removal:** Common artifacts include movement artifacts, cross-talk from adjacent muscles. Techniques like adaptive filtering or wavelet transforms are used to minimize interference. ### 7.1.3 Applications of EMG Signal Acquisition * **Clinical diagnostics:** Detecting neuromuscular disorders like ALS or muscular dystrophy. * **Rehabilitation:** Monitoring muscle function during therapy. * **Ergonomics:** Assessing muscle strain in workplace settings. * **Sports science:** Optimizing performance and preventing injuries. * **Human-Machine Interfaces:** For example, controlling prosthetic limbs. * **Using EMG signals for prosthetics or robotics control.** **(Diagram)** A diagram showing the placement of electrode sensors for EMG signal acquisition, along with an example of an EMG waveform. ## 7.2 EMG Signal Analysis * **Time domain analysis:** This involves examining the raw EMG signal over time to identify changes in muscle activity. This can be done visually or computationally. * **Frequency domain analysis:** This involves transforming the EMG signal into the frequency domain to identify the frequency components of muscle activity. Frequency domain analysis allows for more detailed analysis of muscle activity, allowing for a better understanding of the underlying physiological processes. * **Wavelet domain analysis:** This involves using wavelets, which are mathematical functions, to decompose the EMG signal into different frequency bands. This allows for the extraction of information about the different frequency components of muscle activity. * **ML and DL based analysis:** Machine learning and deep learning algorithms are increasingly used to analyze EMG signals. These algorithms can be trained to identify patterns in EMG data that are associated with specific muscle activity or diseases.

Use Quizgecko on...
Browser
Browser