Frequency Analysis Of EMG Signals With Matlab Sptool

Similar documents
Introduction to Digital Filters

Author: Dr. Society of Electrophysio. Reference: Electrodes. should include: electrode shape size use. direction.

ANALYZER BASICS WHAT IS AN FFT SPECTRUM ANALYZER? 2-1

A DESIGN OF DSPIC BASED SIGNAL MONITORING AND PROCESSING SYSTEM

Transition Bandwidth Analysis of Infinite Impulse Response Filters

The Effective Number of Bits (ENOB) of my R&S Digital Oscilloscope Technical Paper

RF Measurements Using a Modular Digitizer

Convolution. The Delta Function and Impulse Response

ECG SIGNAL PROCESSING AND HEART RATE FREQUENCY DETECTION METHODS

Time series analysis Matlab tutorial. Joachim Gross

Department of Electrical and Computer Engineering Ben-Gurion University of the Negev. LAB 1 - Introduction to USRP

SUMMARY. Additional Digital/Software filters are included in Chart and filter the data after it has been sampled and recorded by the PowerLab.

Filter Comparison. Match #1: Analog vs. Digital Filters

The Calculation of G rms

The front end of the receiver performs the frequency translation, channel selection and amplification of the signal.

This document is downloaded from DR-NTU, Nanyang Technological University Library, Singapore.

T = 1 f. Phase. Measure of relative position in time within a single period of a signal For a periodic signal f(t), phase is fractional part t p

Sampling Theorem Notes. Recall: That a time sampled signal is like taking a snap shot or picture of signal periodically.

Lecture 1-6: Noise and Filters

How to Design 10 khz filter. (Using Butterworth filter design) Application notes. By Vadim Kim

Implementation of Digital Signal Processing: Some Background on GFSK Modulation

AN Application Note: FCC Regulations for ISM Band Devices: MHz. FCC Regulations for ISM Band Devices: MHz

Laboratory Guide. Anatomy and Physiology

Lock - in Amplifier and Applications

TCOM 370 NOTES 99-4 BANDWIDTH, FREQUENCY RESPONSE, AND CAPACITY OF COMMUNICATION LINKS

DIGITAL-TO-ANALOGUE AND ANALOGUE-TO-DIGITAL CONVERSION

Non-Data Aided Carrier Offset Compensation for SDR Implementation

Design of Efficient Digital Interpolation Filters for Integer Upsampling. Daniel B. Turek

Computer Networks and Internets, 5e Chapter 6 Information Sources and Signals. Introduction

MATRIX TECHNICAL NOTES

RANDOM VIBRATION AN OVERVIEW by Barry Controls, Hopkinton, MA

VCO Phase noise. Characterizing Phase Noise

Signal to Noise Instrumental Excel Assignment

Experiment 3: Double Sideband Modulation (DSB)

chapter Introduction to Digital Signal Processing and Digital Filtering 1.1 Introduction 1.2 Historical Perspective

Short-time FFT, Multi-taper analysis & Filtering in SPM12

Matlab GUI for WFB spectral analysis

SIGNAL GENERATORS and OSCILLOSCOPE CALIBRATION

AN-837 APPLICATION NOTE

Introduction to acoustic imaging

Analog and Digital Signals, Time and Frequency Representation of Signals

Voice---is analog in character and moves in the form of waves. 3-important wave-characteristics:

ANIMA: Non-Conventional Interfaces in Robot Control Through Electroencephalography and Electrooculography: Motor Module

Hands On ECG. Sean Hubber and Crystal Lu

PCM Encoding and Decoding:

See Horenstein 4.3 and 4.4

FAST Fourier Transform (FFT) and Digital Filtering Using LabVIEW

Harmonics and Noise in Photovoltaic (PV) Inverter and the Mitigation Strategies

Introduction to FM-Stereo-RDS Modulation

Introduction to IQ-demodulation of RF-data

Frequency Response of Filters

DIGITAL SIGNAL PROCESSING - APPLICATIONS IN MEDICINE

Electronic Communications Committee (ECC) within the European Conference of Postal and Telecommunications Administrations (CEPT)

Convolution, Correlation, & Fourier Transforms. James R. Graham 10/25/2005

Impedance 50 (75 connectors via adapters)

PIEZO FILTERS INTRODUCTION

Optical Fibres. Introduction. Safety precautions. For your safety. For the safety of the apparatus

SECTION 6 DIGITAL FILTERS

Time Series Analysis: Introduction to Signal Processing Concepts. Liam Kilmartin Discipline of Electrical & Electronic Engineering, NUI, Galway

Building a Simulink model for real-time analysis V Copyright g.tec medical engineering GmbH

Em bedded DSP : I ntroduction to Digital Filters

Aircraft cabin noise synthesis for noise subjective analysis

POWER SYSTEM HARMONICS. A Reference Guide to Causes, Effects and Corrective Measures AN ALLEN-BRADLEY SERIES OF ISSUES AND ANSWERS

Digital Signal Processing IIR Filter Design via Impulse Invariance

L9: Cepstral analysis

SAMPLE CHAPTERS UNESCO EOLSS DIGITAL INSTRUMENTS. García J. and García D.F. University of Oviedo, Spain

Hideo Okawara s Mixed Signal Lecture Series. DSP-Based Testing Fundamentals 46 Per-pin Signal Generator

Laboratory 4: Feedback and Compensation

Clock Recovery in Serial-Data Systems Ransom Stephens, Ph.D.

Spectrum Level and Band Level

A Sound Analysis and Synthesis System for Generating an Instrumental Piri Song

GETTING STARTED WITH LABVIEW POINT-BY-POINT VIS

BSEE Degree Plan Bachelor of Science in Electrical Engineering:

HD Radio FM Transmission System Specifications Rev. F August 24, 2011

USB 3.0 CDR Model White Paper Revision 0.5

PHASE ESTIMATION ALGORITHM FOR FREQUENCY HOPPED BINARY PSK AND DPSK WAVEFORMS WITH SMALL NUMBER OF REFERENCE SYMBOLS

Evaluating a motor unit potential train using cluster validation methods

Spectrum analyzer with USRP, GNU Radio and MATLAB

PRACTICAL GUIDE TO DATA SMOOTHING AND FILTERING

Time series analysis of data from stress ECG

Loop Bandwidth and Clock Data Recovery (CDR) in Oscilloscope Measurements. Application Note

Frequency response. Chapter Introduction

Analysis/resynthesis with the short time Fourier transform

Laboratory #5: RF Filter Design

Jeff Thomas Tom Holmes Terri Hightower. Learn RF Spectrum Analysis Basics

1995 Mixed-Signal Products SLAA013

DESIGN AND SIMULATION OF TWO CHANNEL QMF FILTER BANK FOR ALMOST PERFECT RECONSTRUCTION

Step Response of RC Circuits

Analog and Digital Filters Anthony Garvert November 13, 2015

SOFTWARE FOR GENERATION OF SPECTRUM COMPATIBLE TIME HISTORY

Timing Errors and Jitter

Design of FIR Filters

Log-Likelihood Ratio-based Relay Selection Algorithm in Wireless Network

AC : MEASUREMENT OF OP-AMP PARAMETERS USING VEC- TOR SIGNAL ANALYZERS IN UNDERGRADUATE LINEAR CIRCUITS LABORATORY

NRZ Bandwidth - HF Cutoff vs. SNR

RF Network Analyzer Basics

2.161 Signal Processing: Continuous and Discrete Fall 2008

PeakVue Analysis for Antifriction Bearing Fault Detection

Structural Health Monitoring Tools (SHMTools)

CHAPTER 6 Frequency Response, Bode Plots, and Resonance

Transcription:

Frequency Analysis Of EMG Signals With Matlab Sptool Ufuk OZKAYA Department of Electronics and Communication Engineering Suleyman Demirel University Faculty of Engineering & Architecture TURKIYE uozkaya@mmf.sdu.edu.tr Ozlem COSKUN Department of Biomedical Device Technology Suleyman Demirel University Vocational School TURKIYE oulukut@mmf.sdu.edu.tr Selcuk COMLEKCI Department of Electronics and Communication Engineering Suleyman Demirel University Faculty of Engineering & Architecture TURKIYE scom@mmf.sdu.edu.tr Abstract: - In the area of biomedical digital signal processing (DSP), wavelet analysis, neural networks and pattern recognition methods are being developed for analysis of EMG signals (generated by the muscles) in neuromuscular disease and CTG (the cardiotocogram) signals during labor. These are traditionally very difficult signals to quantify and innovative approaches to analysis are required for clinical quantification. Software and hardware DSP systems are being designed for real time clinical applications. In this paper, the aim is identification of EMG signals by computing the median and average frequencies and investigating frequency domain behavior of EMG signals. To determine these parameters, fast Fourier transform and digital filters have been very important factors at getting the result. Key-Words: EMG, MATLAB, SP Tool, FFT 1 Introduction EMG stands for electromyography. It is the study of muscle electrical signals. Electromyography (EMG) is the recording and analysis of the electrical activity of a contracting muscle. It is used in the diagnosis of neuromuscular diseases - those that affect the muscle tissue itself (myopathic disorders) and those that affect the nerves that activate the muscle (neurogenic disorders). EMG is sometimes referred to as myoelectric activity. EMG is measured using similar techniques to that used for measuring EKG, EEG or other electrophysiological signals. Electrodes are placed on the skin overlying the muscle. Alternatively, wire or needle electrodes are used and these can be placed directly in the muscle. Similar to other electrophysiological signals, EMG signals are small and need to be amplified by an amplifier designed to measure physiological signals. These amplifiers include a differential amplifier circuit, and frequently include some filtering and other signal processing features [1]. ISSN: 179-5117 83 ISBN: 978-954-926-4-5

When EMG is acquired from electrodes mounted directly on the skin, the signal is a composite of all the muscle fiber action potentials occurring in the muscle(s) underlying the skin. These action potentials occur at somewhat random intervals so at any one moment, the EMG signal may be either positive or negative voltage. Individual muscle fiber action potentials are sometimes acquired using wire or needle electrodes placed directly in the muscle. The signal can be displayed directly on an oscilloscope, stored on a device like a computer hard disk. If the signal is stored digitally, software is needed to retrieve it and display it on a monitor or in hardcopy format. There are many, many applications for the use of EMG. EMG is used clinically for the diagnosis of neurological and neuromuscular problems. It is used diagnostically by gait laboratories and by clinicians trained in the use of biofeedback or ergonomic assessment. EMG is also used in many types of research laboratories, including those involved in biomechanics, motor control, neuromuscular physiology, movement disorders, postural control, physical therapy, and many others [3]. First, the signal is picked up at the electrode and amplified. Typically, a differential amplifier is used as a first stage amplifier. Additional amplification stages may follow. Before being displayed or stored, the signal can be processed to eliminate lowfrequency or high-frequency noise, or other possible artifacts. Frequently, the user is interested in the amplitude of the signal. Consequently, the signal is frequently rectified and averaged in some format to indicate EMG amplitude. However, there are many types of EMG analysis schemes. The EMG signal is typically described using a variable related to the size or amplitude of the signal. Rectified, averaged EMG, integrated EMG, and linear envelope displays are all ways to display the amplitude of the EMG signal. Frequency analysis comprises the second category of analysis for the EMG signal, and there are many ways to conduct frequency analysis, including analysis of zero crossings, spectral analysis, numerous time-frequency algorithms, and many other techniques [3,5]. 2 Fast Fourier Transform (FFT) Frequency spectrum of EMG signals must be obtained in order to investigate the frequency domain behaviour and characterize the frequency components of EMG signals. For this reason, using advanced digital signal processing methods should be beneficial. Because, the aim of this paper is to show how can EMG signal be decomposed. So, Fast Fourier Transform (FFT) method was used to obtain the frequency spectrum of EMG signal. Also, digital filters were used to take the several frequency components. In order to extract the desired components and parameters from frequency domain behaviour, a qualified FFT process should be applied to the EMG signal. FFT is another method for Discrete Fourier Transform. While it produces same result as the other approaches, in addition FFT becomes more effective reducing the computation time by hundreds [2,4]. In complex notation, the time and frequency domains each contain one signal made up of N complex points. Each of these complex points is composed of two numbers, the real part and the imaginary part. In other words, each complex variable holds two numbers. Two complex variables are multiplied; the four individual components must be combined to form the two components of the product. Assuming that N is an even integer, x(n) array can be divided into two arrays have N/2 length. X k = neven x ) nk ( n W N + nodd x ( n) (1) nk W N For n = 2r and n = 2r+1 separation process can be realized. ( N/2) X k = 1 x (2r) r= 2rk W N ( N / 2) + 1 (2r+ 1) k x (2r+ 1) (2) r= W N The FFT operates by decomposing an N point time domain signal into N time domain signals each composed of a single point. The second step is to calculate the N frequency spectra corresponding to these N time domain signals. Lastly, the N spectra are synthesized into a single frequency spectrum. ISSN: 179-5117 84 ISBN: 978-954-926-4-5

The first stage breaks the 16-point signal into two signals each consisting of 8 points. The second stage decomposes the data into four signals of 4 points. This pattern continues until there are N signals composed of a single point. An interlaced decomposition is used each time a signal is broken in two, that is, the signal is separated into its even and odd numbered samples. The best way to understand this is by inspecting Figure 1 until you grasp the pattern. There are stages required in this decomposition, i.e., Log2N a 16 point signal (24) requires 4 stages, a 512 point signal (27) requires 7 stages, a 496 point signal (212) requires 12 stages, etc. Fig 1. The FFT decomposition The decomposition is nothing more than a reordering of the samples in the signal. Figure 2 shows the rearrangement pattern required. On the left, the sample numbers of the original signal are listed along with their binary equivalents. On the right, the rearranged sample numbers are listed, also along with their binary equivalents. The important idea is that the binary numbers are the reversals of each other. For example, sample 3 (11) is exchanged with sample number 12 (11). Likewise, sample number 14 (111) is swapped with sample number 7 (111), and so forth. A bit reversal-sorting algorithm usually carries out the FFT time domain decomposition. This involves rearranging the order of the N time domain samples by counting in binary with the bits flipped left-forright. The next step in the FFT algorithm is to find the frequency spectra of the 1-point time domain signals. The next step in the FFT algorithm is to find the frequency spectra of the 1-point time domain signals. Nothing could be easier; the frequency spectrum of a 1-point signal is equal to itself. This means that nothing is required to do this step. Although there is no work involved, each of the 1- point signals is now a frequency spectrum, and not a time domain signal. The last step in the FFT is to combine the N frequency spectra in the exact reverse order that the time domain decomposition took place. This is where the algorithm gets messy. Unfortunately, the bit reversal shortcut is not applicable, and we must go back one stage at a time. In the first stage, 16 frequency spectra (1 point each) are synthesized into 8 frequency spectra (2 points each). In the second stage, the 8 frequency spectra (2 points each) are synthesized into 4 frequency spectra (4 points each), and so on. The last stage results in the output of the FFT, a 16-point frequency spectrum [2,4]. 3 Filter Design A filter is a device designed to attenuate specific ranges of frequencies, while allowing others to pass, and in so doing limit in some fashion the frequency spectrum of a signal. The frequency range(s), which is attenuated, is called the stopband, and the range, which is transmitted, is called the passband. The behavior of filters can be characterized by one of four functions depicted in Figure 3: low-pass, highpass, band-bass and band-stop. The depictions of Figure 2 are representations of ideal filter characteristics, typically referred to as brick-wall responses that imply the following behavior: 1. The passband amplitude response is continuously flat at a value of 1. The frequencies, which are allowed to pass through the filter, do so completely undistorted. 2. The stopband amplitude response is continuously flat at a value of. The undesirable frequencies are completely suppressed. 3. The transition between the passband and the stopband happens instantaneously. Fig 2. Ideal Filter Types ISSN: 179-5117 85 ISBN: 978-954-926-4-5

4 Digital Filters The digitization of electric signals into sequences of numbers permits the complete manipulation of these signals to occur mathematically. Voltage signals that are expressed as numbers can easily be scaled through scalar multiplication or offset by adding constants; they can be rectified by using the absolute value operator or modulated with other signals through multiplication. The digital realm provides unbounded opportunities for condition and processing of the signal. This branch of science is known as digital signal processing. The digital implementation of the filters described in the previous sections is typically accomplished through various schemes of weighted averaging. It begins with an analog voltage signal, which is digitized with an ADC after it is appropriately conditioned. Once sampled, the signal is defined by a sequence of numbers representing the voltage amplitude at specific instances in time. A window of n input taps is created, each tap consecutively holding one value of the sampled data (xn to xi). Individual tap values are then multiplied by a specific weighting factor (hn to hi). The current filter output, yi, is then calculated by summing all the weighted input tap values: 1 y i = h x (3) k k k= i n where k is the summation index, i is sample value index, n is the number filter taps, x is the filter input value, h is tap weight and y is the filter output value. 5 Analysis Of EMG Signals With In Frequency Domain Analysis of EMG signals in frequency domain is made with measuring and computing the parameters that define the characteristics of these signals. In order to determine the power spectrum densities of the signals oftenly fast Fourier transform is used. The relation between median and average frequency is: fmed 1 Sm( f ) df = Sm ( f ) df = 2 Sm ( f ) df (4) fmed Where, Sm(f) is power spectrum density of signal. Median and average frequency are most reliable parameters in EMG analysis. Median frequency is less sensitive to noise compared to average frequency. This condition occurs in low-levelled contraction with low valued signal to noise ratio. Bandwidth characterizes the spectrum and defines time and variation with force. Also, it gives important informations about filtering processes on EMG signals. It s not useful for real-time trainings because it can be only computed with power spectrum. Mod frequency, is the frequency of spectrum s peak point. It has some variation behaviour as median and average frequencies. Zero crossing technique, which is used in time domain analysis, it can also be used in frequency domain analysis. Zf = 2 σ 2 - (fav) 2 2 1 = 2 σ 2 - (k.fm) 2 2 1 (5) With equation 5, it can be shown that Zf (Zero Crossing Rate), depends on average frequency and variance of EMG signal. Fm gives the median frequency and k is constant. 6 Analysis Of EMG Signals With Sptoll Matlab Signal Processing Tool (sptool) enables to view waveforms and spectrums of several signals and make a qualified filter design. Therefore, characteristic properties and desired parameters of signals should be estimated. In order to use a signal under these processes the signal must be imported as a vector. Sptool has 3 main sections. Signal, filters and spectra in figure as shown above. EMG signal, a matrix of 212x1and with a sample frequency, is the electrical reaction of Biceps Femoris muscle. The waveform and frequency spectrum at decibel and linear scale of EMG signal as shown in figure 4 and 5. ISSN: 179-5117 86 ISBN: 978-954-926-4-5

Magnitude response, phase response, group phase delay and many properties of the filter can be observed. After filtering, new signal is ready to make a new observation. The waveform and spectrum of the signal is shown below. Fig 3. Main Menu of Sptool Fig 6. Filter Design Fig 4. Waveform of EMG signal Fig 7. The waveform of filtered signal Fig 5. Spectrum of EMG signal (db) As shown in figure 5, the dominant frequency range of the signal is between -5 Hz. A low-pass filter can be designed to extract components of the signal in this frequency range. With sptool this filter can be designed with several windowing methods as Equiripple FIR, Least Squares FIR, Kaiser Window FIR, Butterworth IIR, and Chebyshev Type I-II IIR. Fig 8. Spectrum of filtered signal (db) ISSN: 179-5117 87 ISBN: 978-954-926-4-5

7 Discussion According to the determined power density spectrums, firstly it is briefly shown that the filtering process eliminated noise successfully as shown both power spectrum densities of pre-filtering and after filtering. As said before the aim is to identify the frequency domain behaviour of EMG signal and so to determine median, average and mod frequency parameters from the power density spectrum. With theoretical explanations and figure 8, these parameters were determined easily. As shown figure 8, median frequency of the EMG signal is 52 Hz, mod frequency is 48 Hz, and the average frequency is 43 Hz. 8 Conclusions With using the most important parameters that EMG signals have, it is possible to reach a lot of information about behaviour of muscle fibers, many diseases and their treatment methods, behaviour of normal and diseased muscles. In many researches, thanks to Motor Unit Action Potentials, muscle fibers and EMG signal characteristics, information repertory about EMG signals is being expanded. Many approaches such as behaviour of muscle fibers and motor unit action potentials (MUAP), classification of muscle fibers and MUAP s can be achieved with these parameters (as frequency spectrum, power density spectrum, important frequency components) that are determined with our research. In future works, with new evaluation criterions to be set on these parameters, it will be possible to gain clear informations about EMG signals and so diseases and their treatments. So that. the parameters, which are examined with this research become vital parameters to achieve more successful works about EMG signals. [3] Abel EW., Arikidis NA., Forster A., Inter-scale local maxima-a new technique for wavelet analysis of EMG signals. 2th Annual Conference of the IEEE Engineering in Medicine and Biology Society, Hong Kong, October 29-November, 1998. [4] Forster A., Arikidis NA., Abel EW., Wavelet analysis of the interference pattern. Annual Conference of the British Society of Clinical Neurophysiology, Nottingham, 1998. [5] Abel EW., Zacharia PC., Forster A., Farrow TL., Neural network analysis of the EMG interference pattern, Med. Eng. Phys, 18, 12-17, 1996. References: [1] Meng H., Abel EW., Forster A., Singularity analysis of the EMG interference pattern, 2nd European Medical&Biological Engineering Conference, Vienna, Austria, December 4-8, 22. [2] Abel EW., Arikidis NA., Forster A., Inter-scale wavelet maximum-a fine to coarse algorithm for wavelet analysis of the EMG interference pattern. IEEE Transactions on Biomedical Engineering, 49:337-344, 22. ISSN: 179-5117 88 ISBN: 978-954-926-4-5