Professional Documents
Culture Documents
HAR Merged
HAR Merged
HAR Merged
ON
“ECG SIGNAL PROCESSING USING TUNABLE Q FACTOR
WAVELET TRANSFORM”
Submitted to
JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD
In partial fulfillment of the requirement
For the award of the degree of
BACHELOR OF TECHNOLOGY
in
Mrs.P.THANUJA
Associate Professor
1
Department of Electrical and Electronics Engineering
BOLLIKUNTA, WARANGAL-506005
2022-2023
CERTIFICATE
This is to certify that the technical seminar entitled “ECG SIGNAL PROCESSING USING
TUNABLE Q FACTOR WAVELET TRANSFORM” that is being submitted by BOLLABOINA
HARSHAVARDHAN(19641A0227) in partial fulfillment for the award of Bachelor of Technology in
ELECTRICAL AND ELECTRONICS ENGINEERING during the academic year 2022-2023, is a
record of bonafide work carried out by them under our guidance and supervision.
The results embodied in this report have not been submitted to any other University or
Institute for the award of any degree or diploma.
EXTERNAL EXAMINER
1
CANDIDATE DECLARATION
I hereby declare that the work presented in the technical seminar titled “ECG SIGNAL
PROCESSING USING TUNABLE Q FACTOR WAVELET TRANSFORM” submitted
towards completion of major project in IV-II semester of B. Tech (EEE) at the VAAGDEVI
COLLEGE OF ENGINEERING, Bollikunta, Warangal. It is an authentic record of any original
work pursued under the guidance of Mrs.P.THANUJA, Associate Professor, EEE Department.
Place: Warangal
Date:20/06/2023
3
ACKNOWLEDGEMENT
With great pleasure, I want to take this opportunity to express our heartfelt gratitude to
all the people who helped throughout the duration of this technical seminar.
I am highly indebted to Principal Dr. K. Prakash for his support during the period of
this technical seminar.
I would like to thank parents, teaching and non – teaching staff of Department of EEE
for sharing their knowledge.
Submitted by
4
ABSTRACT
V
Table of Contents
Certificate
Declaration………………………………………………… III
Acknowledgement………………………………………… IV
Abstract…………………………………………………… V
Table of contents…………………………………………. VI
List of Figures…………………………………………… IX
CHAPTER 1
CHAPTER 2
CHAPTER 3
VI
3.2 Electrode contract Noise ........................................................................... 11
3.3 Motion Artifact Noise…………………………………….. …...... ... 11
3.4 Muscle Noise…………………………………………………. …… 12
3.5 Baseline drifts with Respiration……………………………………. 13
3.6 Instrumentation noise generated by electronic devices…………….. 13
3.7 Electro surgical Noise……………………………………………… 13
3.8 Electromyographic Noise………………………………………….. 14
CHAPTER 4
4.1 History………………………………………………………….. 15
4.2 Wavelet Families………………………………………………. 17
4.3 Continuous Wavelet Transforms ………………………………… 19
4.4 Discrete Wavelet Transforms…………………………………… 21
4.5 Applications of DWT…………………………………………… 23
4.6 Wavelet Denoising……………………………………………... 25
CHAPTER 5
5.1 Introduction………………………………………..…………… 27
5.2 Parameters………………………………………………………. 28
5.3 Functions……………………………………………………….. 30
CHAPTER 6
DENOISING…………………………………………………………………… 41-43
VII
6.1 Denoising Using TQWT………………………………………. 41
CHAPTER 7
VIII
LIST OF FIGURES
IX
CHAPTER 1
1. INTRODUCTION
The muscle mass of the atria is small compared to that of ventricles, so the electrical
change accompanying the contraction of atria is small. Contraction of the atria
associated with the ECG is called ‘P’. The ventricular mass is large, so there is a large
deflection of ECG when the ventricles are depolarized. This is called the QRS complex.
The ‘T’ wave of ECG is associated with the return of ventricular mass to its resting
repolarization state.
The basic shape of an ECG signal is shown in Fig. 1. The letters P, Q, R, S, and T are
chosen arbitrarily. The P,Q,R,S,T deflections are called the waves and Q,R,S waves
together make up a complex; and the interval between S and T waves is known as ST
segment.
R
6
Amplitude in volts
4
T
2
P
0
ST
Q segment
-2 S
0 0.5 1 1.5
Time in seconds
1
ECG is used to measure the electrical activity of the heart. Inside the heart there is a
specialized electrical conducting system that ensures the heart to expand and contract
this action is produced by sinoatrial node located below the right atrium in the heart.
SA node is called as pacemaker because it has the ability to initiate electrical pulses at
faster rate of 100 per minute.
An impulse sent from SA node starts the heart to beat, and then the electrical
current will flow down to the lower chambers of the heart or atria and produce the P;
electrical activity of the heart. Then the electrical current will flow down to the lower
chambers of the heart or ventricles producing the Q, R and S wave.
As stated earlier, ECG plays an important role in the diagnosis of heart diseases it is
vital for a physician to diagnose properly. For the proper diagnosis the ECG recorded
from the human body must be noise-free.
The morphology of ECG signal has been used for recognizing much variability's of
heart activity, so it is very important to get the parameters of ECG signal clear without
noise. This step gives a full picture and detailed information about the
electrophysiology of the heart diseases and the ischemic changes that may occur like
the myocardial infarction, conduction defects and arrhythmia. In order to support
clinical decision making, reasoning tool to the ECG signal must be clearly represented
and filtered, to remove out all noises and artifacts from the signal. ECG signal is one
of the bio signals that is considered as a non-stationary signal and needs a hard work
to de-noising.
2
1.3 Organization of thesis
The thesis is organized as follows. This chapter provides information regarding ECG
and its importance in diagnosis. Chapter 2 presents basic information regarding the
continuous, discrete wavelet transforms and its applications and denoising procedure.
Chapter 3 discusses the Principle Component Analysis (PCA) and its basic importance
in analysis of ECG signals Processing. Chapter 4 presents the method of combining of
Wavelet transform and PCA, leading to new mathematical formulation known as
Multi scale PCA (MSPCA).
Finally in Chapter 5 discusses the results and discussion to give the importance of
MSPCA in ECG Signal Processing. Conclusion is made in last section.
3
CHAPTER 2
2. ELECTROCARGIOGRAM(ECG)
4
2.2 How does an ECG machine detect the body’s electrical signals?
5
2.3 ECG Characteristics
-The ECG signal consists of low amplitude voltages in the presence of high amplitude
offsets and noise.
-The large offsets present in the system are due to halfcell potential developed at the
electrodes.
-Ag/AgCl (Silver- silverchloride) is the common electrode used in ECG systems and
has a maximum offset voltage of +/- 300 mV.
-The actual desired signal is +/- 0.5 mV superimposed on the electrode offset.
-In addition, the system also picks up the 50/60 Hz noise from the power lines which
forms the common mode signal.
- The amplitude of the power line noise may be very high. So, it has to be filtered.
6
2.4 ECG Acquisition
-Analog front-end processing forms an important part of the ECG system since it needs
to distinguish noise and the desired signal which is of small amplitude.
-The instrumentation amplifiers should have high input impedance since the skin
resistance could be very large.
-Operational amplifiers are needed for signal conditioning for the ECG device.
-The signal chain for the acquisition system consists of instrumentation amplifiers,
filters implemented through op-amps, and ACD s
7
2.5 ECG Filtering
-Signal processing is a huge challenge since the actual signal value will be 0.5 mV in
offset environment of 300 mV.
-Muscle noise (this noise is very difficult to remove as it is in the same region as the
actual signal. It is usually corrected in software).
8
2.6 Preprocessing ECG signals
Helps us remove contaminants from the ECG signals. ECG cantaminants can be
classified as-
-baseline wandering, The baseline wandering and other wideband noises are not easy
to be suppressed by hardware equipments. Instead the software scheme is more
powerful and feasible for offline ECG signal processing. You can use the following
methods to remove baseline wandering and other wideband noises. the most
significant and can strongly affect ECG signal analysis.
9
CHAPTER 3
ECG signals may be corrupted by various kinds of noises. Typical examples are:
10
Fig 3.1.1 Power-line interference noise Processing
11
3.3 Motion Artifacts
Motion artifacts are transient base line changes caused by changes in the electrode-
skin impedance with electrode motion. As this impedance changes, the ECG amplifier
sees different source impedance, which forms voltage divider with the amplifier input
impedance therefore the amplifier input voltage depends upon source impedance
,which changes as the electrode position changes. The usual cause for motion artifacts
will be assumed to be vibrations or moments of the subjects. The peak amplitude and
duration of the artifact are variable. This type of interference represents an abrupt shift
in baseline due to moment of the patient while the ECG is being recorded.
Muscle contractions cause heart factual mill volt level potentials to be generated. The
baseline electromyography is usually in the micro volt range and therefore is usually
insignificant. The maximum noise level is formed by adding random single precision
numbers of 50% of the ECG maximum amplitude to uncorrupted ECG.
12
Fig 3.4.1 Muscle Contraction Noise Processing
13
3.6 Noise Generated by the electronic devices
It completely destroys the ECG and can be represented by a large amplitude sinusoid
with frequencies approximately between 100 KHz to 1MHz.
Decompose the ECG signal using wavelet transform: The ECG signal is decomposed
into multiple frequency components at different scales using wavelet transform.
Identify the muscle noise frequency range: The frequency range of the muscle noise is
identified from the wavelet coefficients.
Reconstruct the ECG signal: The manipulated wavelet coefficients are used to
reconstruct the ECG signal, resulting in a signal with reduced muscle noise.
14
CHAPTER 4
4. WAVELET TRANSFORM
4.1 History
The transform of a signal is just another form of representing the signal. It does
not change the information content present in the signal. The Wavelet Transform
provides a time-frequency representation of the signal. It was developed to overcome
the short coming of the Short Time Fourier Transform (STFT), which can also be used
to analyze non-stationary signals. While STFT gives a constant resolution at all
frequencies, the Wavelet Transform uses multi-resolution technique by which
different frequencies are analyzed with different resolutions.
The wavelet analysis is done similar to the STFT analysis. The signal to be analyzed is
multiplied with a wavelet function just as it is multiplied with a window function in STFT, and
then the transform is computed for each segment generated. However, unlike STFT, in Wavelet
Transform, the width of the wavelet function changes with each spectral component. The
Wavelet Transform, at high frequencies, gives good time resolution and poor frequency
15
resolution, while at low frequencies; the Wavelet Transform gives good frequency resolution
and poor time resolution.
There are a large number of wavelet transforms each suitable for different applications.
• Continuous wavelet transform (CWT)
• Discrete wavelet transform (DWT)
• Fast wavelet transform (FWT)
• Lifting scheme & Generalized Lifting Scheme
• Wavelet packet decomposition (WPD)
• Stationary wavelet transform (SWT)
• Fractional wavelet transform
16
4.2 Wavelet Families
There are a number of basis functions that can be used as the mother wavelet
for Wavelet Transformation. Since the mother wavelet produces all wavelet functions
used in the transformation through translation and scaling, it determines the
characteristics of the resulting Wavelet Transform. Therefore, the details of the
particular application should be taken into account and the appropriate mother
wavelet should be chosen in order to use the Wavelet Transform effectively.
(g)
Fig 4.2.1 Wavelet families (a) Haar (b) Daubechies4 (c) Coiflet1 (d) Symlet2 (e) Meyer (f)
Morlet (g) Mexican Hat
17
Figure 9 illustrates some of the commonly used wavelet functions. Haar wavelet is one
of the oldest and simplest wavelet. Daubechies wavelets are the most popular
wavelets. They represent the foundations of wavelet signal processing and are used in
numerous applications. These are also called Max flat wavelets as their frequency
responses have maximum flatness at frequencies 0 and π. This is a very desirable
property in some applications. The Haar, Daubechies, Symlets and Coiflets are
compactly supported orthogonal wavelets. These wavelets along with Meyer wavelets
are capable of perfect reconstruction. The Meyer, Morlet and Mexican Hat wavelets
are symmetric in shape. The wavelets are chosen based on their shape and their ability
to analyze the signal in a particular application.
Wavelet transforms are classified into discrete wavelet transforms (DWTs) and
continuous wavelet transforms (CWTs). Note that both DWT and CWT are
continuous-time (analog) transforms. They can be used to represent continuous-time
(analog) signals. CWTs operate over every possible scale and translation whereas
DWTs use a specific subset of scale and translation values or representation grid.
Where x(t) is the signal to be analyzed. ψ(t) is the mother wavelet or the basis function.
All the wavelet functions used in the transformation are derived from the mother
wavelet through translation (shifting) and scaling (dilation or compression).
The mother wavelet used to generate all the basis functions is designed based
on some desired characteristics associated with that function. The translation
parameter τ relates to the location of the wavelet function as it is shifted through the
signal. Thus, it corresponds to the time information in the Wavelet Transform. The
scale parameter s is defined as |1/frequency| and corresponds to frequency
19
information. Scaling either dilates (expands) or compresses a signal. Large scales (low
frequencies) dilate the signal and provide detailed information hidden in the signal,
while small scales (high frequencies) compress the signal and provide global
information about the signal. Here the Wavelet Transform merely performs the
convolution operation of the signal and the basis function. The above analysis becomes
very useful as in most practical applications, high frequencies (low scales) do not last
for a long duration, but instead, appear as short bursts, while low frequencies (high
scales) usually last for entire duration of the signal.
with the (normalized) sinc function. The subspace of scale a or frequency band
is generated by the functions (sometimes called child wavelets)
(t) = 1 t − b , (3)
a,b a
a
20
Where a is positive and defines the scale and b is any real number and defines the shift.
The pair (a, b) defines a point in the right half plane R+ R .
The projection of a function x onto the subspace of scale a then has the form
The Wavelet Series is just a sampled version of CWT and its computation may
consume significant amount of time and resources, depending on the resolution
required. The Discrete Wavelet Transform (DWT), which is based on sub-band coding,
is found to yield a fast computation of Wavelet Transform. It is easy to implement and
reduces the computation time and resources required. The foundations of DWT go
back to 1976 when techniques to decompose discrete time signals were devised.
Similar work was done in speech signal coding which was named as sub-band coding.
In 1983, a technique similar to sub-band coding was developed which was named
pyramidal coding. Later many improvements were made to these coding schemes
which resulted in efficient multi-resolution analysis schemes.
In CWT, the signals are analyzed using a set of basis functions which relate to
each other by simple scaling and translation. In the case of DWT, a time-scale
representation of the digital signal is obtained using digital filtering techniques. The
signal to be analyzed is passed through filters with different cut-off frequencies at
different scales.
21
A sufficient condition for the reconstruction of any signal x of finite energy by the
formula
x(t) =
mZ nZ
x,m,n . m,n (t) (7)
is that the functions {m,n :m, nZ 2}form a tight frame of L2 (R).
For practical applications, and for efficiency reasons, one prefers continuously
differentiable functions with compact support as mother (prototype) wavelet
(functions). However, to satisfy analytical requirements (in the continuous WT) and in
general for theoretical reasons, one chooses the wavelet functions from a subspace of
the space L1 (R)L2 (R) This is the space of measurable functions that are absolutely and
square integrable:
and (8)
(t) dt
−
(t) 2 dt
−
Being in this space ensures that one can formulate the conditions of zero mean and
square norm one:
For ψ to be a wavelet for the continuous wavelet transforms the mother wavelet must
satisfy an admissibility criterion in order to get a stable invertible transform.
For the discrete wavelet transform, one needs at least the condition that the
wavelet series is a representation of the identity in the space L2 (R). Most constructions
of discrete WT make use of the multi resolution analysis, which defines the wavelet by
a scaling function. This scaling function itself is solution to a functional equation.
In most situations it is useful to restrict ψ to be a continuous function with a higher
number M of vanishing moments, i.e. for all integer m<M
(9)
t m (t)dt
−
=0
The mother wavelet is scaled (or dilated) by a factor of a, and translated (or shifted) by
a factor of b to give (under Morlet's original formulation):
22
(t) = 1 t − b (10)
a,b a
a
For the continuous WT, the pair (a,b) varies over the full half-plane R+ R ; for the
discrete WT this pair varies over a discrete subset of it, which is also called affine group.
These functions are often incorrectly referred to as the basis functions of the
(continuous) transform. In fact, as in the continuous Fourier transform, there is no basis
in the continuous wavelet transform. Time-frequency interpretation uses a subtly
different formulation (after Delprat).
Wavelets are defined by the wavelet function ψ(t) (i.e. the mother wavelet) and
scaling function φ(t) (also called father wavelet) in the time domain. The wavelet
function is in effect a band-pass filter and scaling it for each level halves its bandwidth.
This creates the problem that in order to cover the entire spectrum, an infinite number
of levels would be required. The scaling function filters the lowest level of the
transform and ensures the entire spectrum is covered. For a wavelet with compact
support, φ(t) can be considered finite in length and is equivalent to the scaling filter g.
Meyer wavelets can be defined by scaling functions
Wavelet transforms are now being adopted for a vast number of applications,
often replacing the conventional Fourier Transform. Many areas of physics have seen
this paradigm shift, including molecular dynamics, ab initio calculations, astrophysics,
density-matrix localization, seismic geophysics, optics, turbulence and quantum
mechanics. This change has also occurred in image processing, blood-pressure, heart-
rate and ECG analyses, DNA analysis, protein analysis, climatology, general signal
processing, speech recognition, computer graphics and multifractal analysis. In
23
computer vision and image processing, the notion of scale-space representation and
Gaussian derivative operators is regarded as a canonical multi-scale representation.
There is a wide range of applications for Wavelet Transforms. They are applied in
different fields ranging from signal processing to biometrics, and the list is still growing. One
of the prominent applications is in the FBI fingerprint compression standard. Wavelet
Transforms are used to compress the fingerprint pictures for storage in their data bank. The
previously chosen Discrete Cosine Transform (DCT) did not perform well at high compression
ratios. It produced severe blocking effects which made it impossible to follow the ridge lines in
the fingerprints after reconstruction. This did not happen with Wavelet Transform due to its
property of retaining the details present in the data.
24
is either stored or transmitted. For most compression applications, processing involves
quantization and entropy coding to yield a compressed image. During this process, all
the wavelet coefficients that are below a chosen threshold are discarded. These
discarded coefficients are replaced with zeros during reconstruction at the other end.
To reconstruct the signal, the entropy coding is decoded, then quantized and then
finally Inverse Wavelet Transformed.
During the last few years wavelet transform has proven to be a valuable tool in
applications areas for analysis of non stationary signals. Wavelet analysis is a tool for
analyzing localized variations of power with in a time series. By decomposing a time
series into time –frequency space, one is able to determine the both dominant-modes
of variability and how those modes vary in time and frequency. Wavelet analysis is a
promising method in signal analysis and because its capability of decomposing a
signal into elementary building blocks, excel in finding and identifying irregular
structures, so it is very useful in filtering tasks.
25
whose absolute values are lower than the threshold, and then shrinking the nonzero
coefficients towards 0.
cA1 cD1
cA2 cD2
cA3 cD3
26
CHAPTER 5
5.1 Introduction
27
5.2 Parameters
The main parameters for the TQWT are the Q-factor, the redundancy, and
the number of stages (or levels), as listed in Table I below
Table I. Parameter Description for TQWT
Parameter Description Note
Q-factor
Redundancy
W{4}
Stage 3
W{3}
Stage 2
x W{2}
Stage 1
W{1}
Fig 5.2.1 : Wavelet transform with three stages (J=3)
Therefore, the parameter r affects the redundancy of the TQWT but it is
not exactly equal to its redundancy.
The number of stages (or levels) of the wavelet transform is denoted by J.
The transform consists of a sequence of two-channel filter banks, with the low-
pass output of each filter bank being used as the input to the successive filter
bank. The parameter J denotes the number of filter banks. Each output signal
constitutes one subband of the wavelet transform. There will be J+1 subbands:
the high-pass filter output signal of each filter bank, and the low-pass filter
29
output signal of the final filter bank. For example, a 3-stage wavelet transform
is illustrated in Fig. 1.
5.3 Functions
The main functions for the TQWT are tqwt_radix2 and itqwt_radix2.
These functions compute the forward and inverse of the radix-2 version of the
TQWT. The radix-2 version of the transform uses FFTs which are powers of 2 in
length. The functions tqwt and itqwt also compute the forward and inverse
TQWT, but use FFTs of various lengths and are therefore less computationally
efficient. In practice, the radix-2 version of the TQWT should be used because
of its relative computationally efficiency. The reconstruction property of TQWT
can be easily verified by taking a simple example.
The function tqwt_radix2 returns a cell array w of wavelet coefficients.
The first subband (the high-frequency subband) is given by w{1}. For example,
eight stages of the TQWT are computed; there are a total of nine subbands. The
last subband, w{9}, being the low-pass subband. The higher redundancy is due
primarily to the use of the radix-2 version of the TQWT here.
Sub-bands: The all individual sub bands J1 through J2 can be displayed. The
parameter Fs refers to the sampling frequency of the signal. Below, sub bands 1
through 9 are displayed for a typical signal x. In the figure, the signal x is shown
at the top.
30
SUBBANDS OF SIGNAL
3
SUBBAND
9
0 50 100 150 200 250
Q = 1.00, r = 3.00, Levels = 8 TIME (SAMPLES)
The function has an option, 'E', that displays the energy in each subband
as a percentage of the total energy. In addition, the subbands can be displayed
with a `stem'-style with the option 'stem'.
SUBBANDS OF SIGNAL
1 2.61%
2 6.26%
3 10.66%
SUBBAND
4 16.55%
5 20.79%
6 23.61%
7 13.41%
8 4.59%
9 1.53%
0 50 100 150 200 250
Q = 1.00, r = 3.00, Levels = 8 TIME (SAMPLES)
Energy: The TQWT satisfies Parseval's theorem, meaning that the total energy
of the wavelet coefficients equals the energy of the signal. It can also be useful
to know how the energy of a signal is distributed across the subbands.
31
DISTRIBUTION OF SIGNAL ENERGY
20
15
10
0
1 2 3 4 5 6 7 8 9
SUBBAND
Wavelets: The wavelets may be displayed for a specified set of subbands using
the function PlotWavelets. The syntax is PlotWavelets(N,Q,r,J1,J2) where N is
the length of the wavelets (in samples), Q and r are the Q-factor and redundancy
parameters, and J1 and J2 are the first and last subbands for which the wavelet
is to be computed. The syntax PlotWavelets(...,'radix2') specifies that the
wavelets should be computed using the radix-2 version of the TQWT.
4
SUBBAND
32
Frequency Responses: The frequency decomposition performed by the TQWT
can be displayed using the function PlotFreqResps.
0.5
0
0 0.1 0.2 0.3 0.4 0.5
NORMALIZED FREQUENCY (HERZ)
The low Q-factor (Q = 1:0) can be recognized in both the shape of the
wavelets and in the plot of the frequency responses: The wavelets have a low-
oscillation behavior and the frequency responses are wide relative to their
center frequencies.
Due to the constant-Q property, the frequency responses have equal
width on a log frequency axis.
0.8
0.6
0.4
0.2
0
0.0156 0.0313 0.0625 0.125 0.25 0.5
NORMALIZED FREQUENCY (HERZ)
33
Effect of parameter r: Increasing r, while keeping Q unchanged, has the effect
of increasing the overlap between adjacent frequency responses. The parameter
r does not affect the general shape of the wavelet of frequency response (they
are controlled by Q). With a larger r, the number of levels J should be increased
in order to cover the same frequency range, because of the increased overlap.
The following figure shows
the frequency responses (on log frequency scale) with an r of 6. This is twice the
r used above, so twice the number of frequency bands are needed to cover the
same frequency range. Comparing the two figures, it can be seen that adjacent
bands overlap more when r is larger.
0.8
0.6
0.4
0.2
0
0.0156 0.0313 0.0625 0.125 0.25 0.5
NORMALIZED FREQUENCY (HERZ)
34
5.4 Sparse signal representation
For the radix-2 TQWT, the synthesis functions (wavelets) do not all have
the same energy (l2-norm squared). Specifically, the energy is different in
different subbands. Therefore, a suitable modification of the above problem is:
j+1
The vector = ( 1 . . . j +1 ) can be used to take into account the fact that the l2 -
35
SPARSE SUBBANDS (BASIS PURSUIT)
1 0.00%
2 7.22%
3 4.14%
SUBBAND
4 21.11%
5 3.99%
6 57.63%
7 3.29%
8 2.47%
9 0.15%
0 50 100 150 200 250
Q = 1.00, r = 3.00, Levels = 8 TIME (SAMPLES)
60
50
40
30
20
10
0
1 2 3 4 5 6 7 8 9
SUBBAND
36
5.5 Higher Q-factor
The TQWT allows the user to specify the Q-factor. By increasing Q, the
wavelets become more oscillatory (due to the higher Q-factor). Note that the
frequency responses are narrower now, compared to above where Q was set to
1.0. With Q increased from 1.0 to 4.0, more stages are needed in order to span
the same frequency range because each frequency response is narrower. Here
we have used 17 stages instead of 8 above.
5
6
7
8
9
SUBBAND
10
11
12
13
14
15
16
17
0.5
0
0 0.1 0.2 0.3 0.4 0.5
NORMALIZED FREQUENCY (HERZ)
37
5.6 Sparse signal approximation
y = x + n.
The problem is to estimate x from the observed signal y. If it is known
that x has a sparse representation with respect to a wavelet transform (or other
transform), then it can be estimated via sparsity-based methods.
One approach is basis pursuit denoising (BPD) [3] which minimizes the sum of
the l1 -norm of the transform coefficients and the energy of the residual:
J +1
arg min y −TQWT −1 ( w) + j wj
2
2 1
w j=1
38
5.7 Dual Q-factor signal decomposition
high Q-factor and low Q-factor wavelet transforms respectively [4]. In this case,
a sparse representation of the signal x using both high Q-factor and low Q-factor
TQWT jointly makes the identification of X1 and X 2 feasible. This approach is
X 1 = TQWT 1−1 ( w1 ) , 2 ( w 2) .
X 2 = TQWT −1
39
As above, we set the subband-dependent regularization parameters
proportional to the l2 -norms of the wavelets.
If the signal under analysis is noisy, then we should not ask for exact
equality as in (4). Just as the basis pursuit denoising (BPD) problem adapts the
basis pursuit (BP) problem to the noisy signal case, we can also apply resonance
decomposition to noisy signals. Suppose y represents the noisy signal, then the
problem can be formulated as the minimization of the following cost function:
J1 +1 J2 +1
argmin y −1w1 −2w2 w1, j 1 + 2, j w2, j
2 1, j
2
1
w1 ,w2 j=1 j=1
where 1 and 2 represent the inverse TQWT having high and low Q-factors
we set
X 1 = TQWT1−1 ( w1 ) , 2 ( w 2)
X 2 = TQWT −1
Note that the residual ( y − X1 − X 2 ) appears noise-like. For the problem
formulated in (6), the residual is the signal component that is sparsely
represented in neither the high Q-factor wavelet transform nor the low Q-factor
wavelet transform. For this reason, this formulation (6) accounts for the
presence of noise in the signal of interest.
5 Some formulas
fc ( j ) 0.25 j−1 (2 − ) fs
for j > 1, where fs is the sampling frequency of the input signal, and
40
CHAPTER 6
6. DENOISING
The following are the general steps involved in using tunable Q factor wavelet transform for
denoising ECG signals:
Decompose the ECG signal using wavelet transform: The ECG signal is decomposed into
multiple frequency components at different scales using wavelet transform.
Identify the noise frequency range: The frequency range of the noise is identified from the
wavelet coefficients.
Manipulate the wavelet coefficients: The wavelet coefficients corresponding to the noise
frequency range are manipulated to adjust the damping factor and, thus, remove the noise
from the ECG signal.
Reconstruct the ECG signal: The manipulated wavelet coefficients are used to reconstruct the
ECG signal, resulting in a signal with reduced noise.
Analyze the ECG signal: The reconstructed ECG signal is analyzed to extract useful
information, such as heart rate, arrhythmia, and ischemia.
By reducing noise in the ECG signal, it is possible to improve the accuracy of ECG analysis
and reduce the risk of misdiagnosis. The tunable Q factor wavelet transform is a powerful
technique for denoising ECG signals, and it has potential applications in diagnosing heart
diseases, monitoring heart conditions, and assessing the effectiveness of treatments.
It is important to note that the use of tunable Q factor wavelet transform for ECG signal
processing is still an active area of research, and further studies are needed to evaluate its
effectiveness and potential clinical applications. Additionally, other signal processing
41
techniques such as adaptive filtering and independent component analysis (ICA) can also be
used to denoise ECG signals.
42