# An automated tool for localization of heart sound components S1, S2, S3 and S4 in pulmonary sounds using Hilbert transform and Heron’s formula

- Ashok Mondal
^{1}Email author, - Parthasarathi Bhattacharya
^{2}and - Goutam Saha
^{1}

**2**:512

https://doi.org/10.1186/2193-1801-2-512

© Mondal et al.; licensee Springer. 2013

**Received: **17 July 2013

**Accepted: **27 September 2013

**Published: **5 October 2013

## Abstract

The primary problem with lung sound (LS) analysis is the interference of heart sound (HS) which tends to mask important LS features. The effect of heart sound is more at medium and high flow rate than that of low flow rate. Moreover, pathological HS obscures LS in a higher degree than normal HS. To get over this problem, several HS reduction techniques have been developed. An important preprocessing step in HS reduction is localization of HS components. In this paper, a new HS localization algorithm is proposed which is based on Hilbert transform (HT) and Heron’s formula. In the proposed method, the HS included segment is differentiated from the HS excluded segment by comparing their area with an adaptive threshold. The area of a HS component is calculated from the Hilbert envelope using Heron’s triangular formula. The method is tested on real recorded and simulated HS corrupted LS signals. All the experiments are conducted under low, medium and high breathing flow rates. The proposed method shows a better performance than the comparative Singular Spectrum Analysis (SSA) based method in terms of accuracy (ACC), detection error rate (DER), false negative rate (FNR), and execution time (ET).

### Keywords

Filtering; Heart sound localization; Hilbert transform; Heron’s formula; Lung sound## Introduction

The conventional stethoscope based auscultation technique is a cost-effective and non-invasive diagnostic procedure. This technique is very popular among the physicians and commonly used by them since 1816 (Laennec1962). However, the performance of this diagnostic technique degrades due to the presence of noise in lung sound signals. Modern electronic stethoscope can reduce the ambient noises from lung sounds, but they are inefficient to avoid heart sound noise.

During the recording of lung sound, heart sound interferes and changes the temporal and spectral contents of the respiratory sound. This may lead to misinterpretation of the underlying lung diseases. Heart sounds comprise of two primary sounds S1 and S2. In addition, it may have components like S3, S4 and murmurs associated with pathological conditions. The first heart sound, S1 and second heart sound, S2 are produced by the openings of the atrioventricular valves and closures of semilunar valves, respectively and vice versa (Pourazad2004). The third (S3) HS occurs at the end of S2 due to the vibration of blood inside the ventricles and the fourth (S4) HS is appeared just before the S1 due to the contraction of atria (Webster1998; Balasubramaniam and Nedumaran2010). These components carry important information regarding the cardiac system and are segmented to diagnose the valvular heart diseases (Schmidt et al.2010; Tang et al.2012; Sanei et al.2011; Patidar and Pachori2013). However, lung sounds are produced by stochastic and disruptive flow of air within lung airways (Blake1986). Most of the heart sound information lies in the frequency range of 20-150 Hz (Arnott et al.1984; Lu et al.1988; Cromwell et al.2002) but murmur sounds have a higher frequency range of 600 Hz (Patidar and Pachori2013). On the other hand, lung sound information spread out over a wide range of frequency approximately 20-1600 Hz (Gavriely et al.1981). However, a major part of the lung sound information is confined to a frequency less than 200 Hz (Sovijarvi et al.2000).

With the advances in modern technologies, computer science, and statistical signal processing, a lot of research work has been conducted to overcome the problem of HS removal to highlight the LS (Iyer et al.1986; Lu et al.1988; Kompis and Russi1992; Hadjileontiadis and Panas1997; Gnitecki et al.2003; Gnitecki and Moussavi2003; Ahlstrom et al.2005; Yadollahi and Moussavi2006; Pourazad et al.2006; Flores-Tapia et al.2007; Ghaderi et al.2011). This is an important preprocessing step in lung sound analysis. A common approach of heart sound reduction is high pass filtering of lung sounds. However, this approach attenuates the lung sound components that resemble to heart sound in spectral domain (Donoho1995). Except the wavelet de-noising technique, the performance of all the other heart sound cancellation methods depends on a properly defined heart sound location. Many research groups have developed methods to detect the heart sounds locations in LS signals. These methods are based on adaptive filtering (Iyer et al.1986; Lu et al.1988; Kompis and Russi1992; Hadjileontiadis and Panas1997; Gnitecki et al.2003), time-frequency filtering (Pourazad et al.2006), multiscale product based (Flores-Tapia et al.2007), and statistical signal analysis (Gnitecki and Moussavi2003; Ahlstrom et al.2005; Yadollahi and Moussavi2006; Ghaderi et al.2011) approaches. Adaptive filtering techniques need a reference heart sound signal which is produced either by the noisy lung sound signal itself or by an external source, e.g., electrocardiogram (ECG) signal. A combined theory of spectrogram and wavelet transform analysis is proposed to detect the HS components in (Pourazad et al.2006). A multiscale product based method is implemented in (Flores-Tapia et al.2007) to localize the HS segments. Several statistical methods are used to find out the heart sound locations, such as variance fractal dimension trajectory (Gnitecki and Moussavi2003), recurrence time statistics (Ahlstrom et al.2005), entropy (Yadollahi and Moussavi2006), and singular spectrum analysis (SSA) (Ghaderi et al.2011). Entropy (ENT) and SSA based algorithms give comparatively better results than other techniques. However, SSA method gives better results than that of ENT method in terms of false negative rate, error in localization and correlation coefficient. Moreover, SSA method is much faster than ENT method. Gadheri et al. has shown the superiority of SSA method over ENT technique in (Ghaderi et al.2011).

All these techniques highlight their performances for normal lung sound signals at low and medium flow rate but not at high flow rate.

The objective of this work is to develop an effective and efficient algorithm to localize primary heart sounds (S1 and S2) and pathological heart sounds (S3 and S4) components that is applicable to both normal as well as abnormal cases of lung sounds for three different breathing flow rates: low, medium and high. In this paper, a novel heart sounds (S1, S2, S3 and S4) localization algorithm is proposed by using Hilbert transform (Johansson1999; Mertins1999) and Heron’s formula (Stanojevié1997) and the proposed method is referred to as Hilbert Heron Algorithm (HHA). The HS and non HS segments are discriminated by investigating the morphological characteristics of the cardiac sounds. It has been taken under consideration that each HS component extends for a certain duration (Khandpur2003; Schlant and Alexander1994) and defined by two global minima and one maximum points. The minima points are correspond to the starting and ending of the HS component and the maximum point is correspond to the highest energy peak of the HS component. By connecting the global extrema points some scalene triangles can be drawn and their areas will be used to identify the HS and non HS segments. The area of the triangle can be computed from the envelope signal using Heron’s formula. The envelope signal is estimated from the filtered mixed LS signal using HT. The decision regarding the heart sound included segment or heart sound excluded segment is taken by comparing the area with an adaptive threshold value. The threshold value is calculated from the variance of the area vector as discussed in Section "Methodology". The performance of the proposed method is compared with the SSA method by evaluating the results for both cases of simulated mixed lung sound signals (normal and pathological) and real recorded lung sound signals. The method gives better performance than the SSA method in terms of false negative rate, accuracy, detection error rate, and execution time.

The remaining part of this paper is organized as follows. Section "Theoretical background on Hilbert transform and Heron’s formula" provides theoretical background on the Hilbert transform and Heron’s formula and Section "Methodology" describes in detail the methodology. The experimental database and certain implementation issues are described in Section "Experimental data sets and implementation issues" and Section "Results and discussion" presents the experimental results and discusses the efficiency of the method. The conclusion is given in section "Conclusion".

## Theoretical background on Hilbert transform and Heron’s formula

### The Hilbert transform

*j*is an imaginary unit, i.e.,$j=\sqrt{-1}$. The Hilbert transform of a real valued continuous time domain signal,

*y*(

*t*) is defined by

*s*is real and

*H*{·} is the Hilbert operator. Here, the integration has to be carried out according to the Cauchy principle value, that is,

*y*[

*n*] is estimated by the discrete Hilbert transform denoted by

*H*

_{ d }{·}. The discrete Hilbert transform

*H*

_{ d }{·} of a sequence

*y*[

*n*] having a finite period

*R*can be computed using its Discrete Fourier transform (DFT). The DFT of

*y*[

*n*] is denoted by

*Y*[

*m*] is calculated by

*m*is the discrete frequency and

*n*is the discrete time. The DFT

*Y*[

*m*] of the discrete time domain signal

*y*[

*n*] can be expressed as a combination of a real and an imaginary component, i.e.,

*y*[

*n*] is calculated as

The equation (5) is applicable when *R* is even and equation (6) for odd *R*.

### Heron’s formula

Heron was a Greek mathematician and engineer in 10-70 AD (Stanojevié1997). He contributed much in the field of optics, mathematics and enginering. But Heron is popular for deriving the formula for computing the area of the triangle. The formula consists of two steps:

The detail of the formula is given in proposition 1.8 of his book, Metrica. The proof of Heron’s formula has been done by Roger Boscovich and stated in (Stanojevié1997).

## Methodology

### Amplitude normalization

*y*(

*n*) be the signal value at

*nth*sample, and

*M*be the absolute maxima in the sample space. The normalized signal

*y*

_{ norm }(

*n*) is given by

Here *n* = 1,2,3,…, *K* and *K* is the total number of samples in the signal.

#### Filtering

*t*

*h*order Butterworth finite impulse response (FIR) filter with a cutoff frequency of 150 Hz. The filtering operation enhances the HS components by attenuating the higher frequency LS and murmur components as shown in Figure2. The filtered sound is used as input to the next step to detect the HS segments.

#### Hilbert Envelope Extraction

*x*

_{ nf }(

*n*) be the normalized, filtered mixed signal. The complex analytic signal

*A*[

*x*

_{ nf }(

*n*)] of the given signal

*x*

_{ nf }(

*n*) is expressed as

*E*

_{ H }(

*n*) of the given signal

*x*

_{ nf }(

*n*) can be computed from the magnitude of the analytic signal

*A*[

*x*

_{ nf }(

*n*)], and is expressed as

*ϕ*(

*n*) information of the analytic signal

*A*[

*x*

_{ nf }(

*n*)] is determined by the following equation

#### Peak Detection in the Envelope

The Hilbert envelope curve *E*
_{
H
}(*n*) is estimated from the filtered mixed signal using equation (12) and is shown in Figure1(c). The envelope signal consists of many peaks which are originated from the HS components and from the low frequency LS components of the filtered mixed signal as shown in Figure1(b). Each peak of the envelope curve *E*
_{
H
}(*n*) has a rising and a falling edges, respectively. The rising edge gives the positive gradient values and falling edge gives negative gradient values at each point over the envelope. These peaks are detected through the following steps:

Step 1: Smoothening of the envelope: The Hilbert envelope *E*
_{
H
}(*n*) of the signal is not smooth because of the presence of lung sound components. Hence, it is required to smoothen for more accurate peak detection which is associated with HS. To accomplish this, a filtering operation is done using a 5*t* *h* order Butterworth FIR filter with a cutoff frequency varying in a range of 7-25 Hz. We discuss the effect of variation in cut-off frequency in Section "Results and discussion".

Step 2: Identification of local maxima and minima: The extreme points of the envelope signal can be calculated by considering the sign changes across the first derivative of the envelope. A sample value *E*
_{
H
}(*i*) of the smoothed envelope curve will be a minimum valued point for$\frac{d({E}_{H}(n))}{\mathit{\text{dn}}}{\mid}_{n=i}=0\parallel \frac{d({E}_{H}(n-1))}{\mathit{\text{dn}}}{\mid}_{n=i}<0\parallel \frac{d({E}_{H}(n+1))}{\mathit{\text{dn}}}{\mid}_{n=i}>0$ and will be a maximum valued point for$\frac{d({E}_{H}(n))}{\mathit{\text{dn}}}{\mid}_{n=i}=0\parallel \frac{d({E}_{H}(n-1))}{\mathit{\text{dn}}}{\mid}_{n=i}>0\parallel \frac{d({E}_{H}(n+1))}{\mathit{\text{dn}}}{\mid}_{n=i}<0$.

Step 3: Estimation of peaks: A peak consists of three consecutive extrema points which include two minima and one maximum. Each peak has a finite extension from one minimum point to another as shown in Figure1(d). The duration of the individual peak varies according to its source characteristics. The peak locations are identified by calculating their extreme points and marked with a white arrow head in Figure1(d).

#### Picking up the S1, S2, S3 and S4 peaks

The peaks detected using the above described peak detection framework do not always correspond to heart sound components. Some peaks occur due to the presence of artifacts and unfiltered lung sound components. The non-heart sound peaks are rejected and the heart sound peaks are selected using a geometrical formula derived by Greek mathematician Heron.

*ith*peak are${L}_{\mathit{\text{min}}1}^{i}$,${L}_{\mathit{\text{min}}2}^{i}$, and${L}_{\mathit{\text{max}}}^{i}$, respectively. The length of each side of the triangle associated with

*ith*peak are calculated as follows:

*c*

^{ i }is the base,

*a*

^{ i }is the left lateral side and

*b*

^{ i }is the right lateral side of the triangle. The three angles of the triangle are defined by the following equation

*α*

^{ i },

*β*

^{ i }and

*γ*

^{ i }are the angles between the three sides. The lengths of the three sides of the triangle are unequal in magnitude and the angles in between them are also unequal in degree. Hence this triangle satisfies the criterion of scalene triangle. The area △

^{ i }of the

*ith*triangle is calculated as

where *i* indicates the number of triangle and lies in the range defined by 1 ≦ *i* ≦ Γ-2 × *Q*, *P* and *Q* are the total number of minima and maximum points in the envelope, respectively. The area of heart sound components is higher than that of the artifacts or low frequency lung sound components because heart sound components have a high peak amplitudes as shown in Figure1(b). The heart sound components S1, S2, S3 and S4 are identified by comparing the area of the peak with an adaptive threshold value that is calculated from the variance *σ* of the area vector **A** = [*A*
_{1}, *A*
_{2}, *A*
_{3},…, *A*
_{
Q
}]^{
T
}, where *A*
_{
r
}(*r* = 1,2,…, *Q*) indicates the area of individual peak in corrupted LS. The heart sound peaks *P*
_{
HS
} are selected using the Algorithm 1.

#### Boundary estimation of S1, S2, S3 and S4 peaks

The primary HS components (S1 and S2) extend on both sides of its peak position as shown in Figure1(e) for a finite length due to the time gap between the closures and openings of the heart valves (Pourazad2004) but the third (S3) and fourth (S4) HS components extend due to the relaxation of the ventricle and atrium heart chambers (Webster1998; Balasubramaniam and Nedumaran2010). To estimate the HS boundary, peak location identification is needed. The peak locations are detected using Algorithm 1, and after that their boundary *B*
_{
HP
} are calculated by using Algorithm 2.

## Experimental data sets and implementation issues

### Subjects and data acquisition

The lung sound signals are recorded from the normal as well as abnormal male and female subjects using a single channel stethoscope based data acquisition system as described in (Mondal et al.2011). The data acquisition system has been constructed by making a circuit using active devices (Transistors. Operational Amplifiers) and passive elements (Resistors, Capacitors and Inductors) fitted to a stethoscope to capture the LS using the diaphragm mode. The LS data are recorded from different auscultation locations over the body surface (e.g., left mid clavicular area, 2nd intercostal and third intercostal spaces) of the patients in the sitting position and under relaxing mood conditions. The recordings are not associated with any particular age group. The recorded data are arranged in 16 bit, PCM, Mono audio format and stored as *.wav files at sampling frequency of 8 kHz. The pathological LS are recorded from 8 female and 20 male subjects with different types of pulmonary dysfunctions: Chronic Obstructive Pulmonary Diseases (COPDs), Interstitial Lung Disease (ILD) and asthma. The pathological HS are recorded from 10 female and 22 male subjects with various valvular heart diseases. On the other hand, the normal LS are recorded from 5 male healthy subjects and normal HS from 3 female and 5 male subjects. The pulmonary sound records are collected from various resources: Institute of Pulmocare and Research, Kolkata, Audio & Biosignal Processing laboratory, IIT Kharagpur, India and also from R.A.L.E. dataset available at:http://www.rate.cal. The cardiac sound data are collected from the two institutes mentioned above and also from the Maulana Azad Medical Institute, Delhi, India. The abnormal lung sounds include wheezes, crackles and squawks sounds and abnormal heart sounds include late systolic murmur, pulmonary stenosis, early systolic murmur, ejection click, aortic insufficiency, pan systolic murmur, etc.

#### Synthetic data

*F*

*S*

_{ HS }(

*t*) onto the filtered lung sound components

*F*

*S*

_{ LS }(

*t*) as given next.

where *a*
_{
p
} and *b*
_{
q
} are the vectors of lung sound and heart sound filter coefficients, respectively. These are four dimensional vectors, i.e., **a**
_{
p
} = [*a*
_{
p 0}, *a*
_{
p 1}, *a*
_{
p 2}, *a*
_{
p 3}]^{
T
} and **b**
_{
q
} = [*b*
_{
q 0}, *b*
_{
q 1}, *b*
_{
q 2}, *b*
_{
q 3}]^{
T
}. The heart sound filter coefficient vector **b**
_{
q
} is normalized to one, i.e., ∥**b**
_{
q
}∥ = 1. These filter coefficients are generated randomly.

**a**

_{ p }corresponding to different flow rates for various types of mixtures are given in Table1. The classifications of flow rates have been done empirically by a pulmonologist.

**The values of norms for different flow rates**

TLS | THS | TM | Range of Norm | TF |
---|---|---|---|---|

of a
| ||||

> 3.10 | High | |||

Normal | Normal | Normal | 0.81-3.10 | Medium |

0.10-0.80 | Low | |||

> 3.30 | High | |||

Normal | Abnormal | Abnormal | 0.91-3.30 | Medium |

0.10-0.90 | Low | |||

>3.28 | High | |||

Abnormal | Normal | Abnormal | 1.59-3.28 | Medium |

0.10-1.58 | Low | |||

> 3.35 | High | |||

Abnormal | Abnormal | Abnormal | 1.97-3.35 | Medium |

0.10-1.96 | Low |

#### Implementation platform

The whole analysis is implemented on an ACER-PC with 3.29 GHz Intel core 2 quad CPU and 3.49 GB of RAM. The MATLAB (R2008a, The Mathworks, Inc., Natick, MA) tool is used for conducting the all experiments.

## Results and discussion

False negative (FN) occurs when HS segment is missed and false positive (FP) occurs due to misidentification of non HS as HS. On the other hand, true negative (TN) and true positive (TP) occur when HS segment and LS segment are correctly detected. All the experiments are conducted on the same database mentioned in Section "Experimental data sets and implementation issues" with the proposed and SSA method.

### Graphical interpretation of the results

### Quantitative evaluation of the results

*n*

*d*pair and (2) the threshold value and cutoff frequency of high pass filter mentioned in (Ghaderi et al.2011) are reduced.

**Performance of the different HS localization methods, HHA and SSA for the synthetic mixtures of normal HS and normal LS at three different flow rates**

TF | Method | Error (%) | ACC | DER | ET | |
---|---|---|---|---|---|---|

FNR | FPR | (%) | (%) | (Sec) | ||

L | HHA | 0.0 ± 0.0 | 1.05 ± 0.04 | 99.15 ± 0.03 | 0.83 ± 0.03 | 0.38 ± 0.01 |

L | SSA | 24.63 ± 0.18 | 0.0 ± 0.0 | 96.05 ± 0.02 | 3.94 ± 0.02 | 1.39 ± 0.01 |

M | HHA | 0.00 ± 0.0 | 2.42 ± 0.34 | 98.00 ± 0.27 | 1.99 ± 0.27 | 0.38 ± 0.01 |

M | SSA | 28.10 ± 0.18 | 0.0 ± 0.0 | 95.49 ± 0.03 | 4.49 ± 0.03 | 1.39 ± 0.01 |

H | HHA | 0.0 ± 0.0 | 5.46 ± 0.31 | 95.63 ± 0.23 | 4.35 ± 0.23 | 0.38 ± 0.01 |

H | SSA | 34.90 ± 0.14 | 0.0 ± 0.0 | 94.40 ± 0.05 | 5.59 ± 0.05 | 1.39 ± 0.01 |

**Performance of the different HS localization methods, HHA and SSA for the synthetic mixtures of normal HS and abnormal LS at three different flow rates**

TF | Method | Error (%) | ACC | DER | ET | |
---|---|---|---|---|---|---|

FNR | FPR | (%) | (%) | (Sec) | ||

L | HHA | 0.0 ± 0.0 | 1.85 ± 0.30 | 98.46 ± 0.25 | 1.53 ± 0.25 | 0.38 ± 0.01 |

L | SSA | 25.80 ± 0.49 | 0.0 ± 0.0 | 95.86 ± 0.08 | 4.13 ± 0.08 | 1.39 ± 0.01 |

M | HHA | 0.00 ± 0.0 | 2.86 ± 0.31 | 97.49 ± 0.14 | 2.49 ± 0.14 | 0.38 ± 0.01 |

M | SSA | 31.85 ± 0.07 | 0.0 ± 0.0 | 94.88 ± 0.15 | 5.10 ± 0.15 | 1.39 ± 0.01 |

H | HHA | 0.0 ± 0.0 | 7.11 ± 0.08 | 94.41 ± 0.26 | 5.57 ± 0.26 | 0.38 ± 0.01 |

H | SSA | 37.09 ± 1.94 | 2.27 ± 1.66 | 92.11 ± 2.74 | 7.88 ± 2.74 | 1.39 ± 0.01 |

**Performance of the different HS localization methods, HHA and SSA for the synthetic mixtures of abnormal HS and normal LS at three different flow rates**

TF | Method | Error (%) | ACC | DER | ET | |
---|---|---|---|---|---|---|

FNR | FPR | (%) | (%) | (Sec) | ||

L | HHA | 0.0 ± 0.0 | 3.05 ± 0.32 | 97.92 ± 0.21 | 2.06 ± 0.21 | 0.38 ± 0.01 |

L | SSA | 25.92 ± 0.59 | 0.0 ± 0.0 | 91.06 ± 0.20 | 8.92 ± 0.20 | 1.39 ± 0.01 |

M | HHA | 0.00 ± 0.0 | 4.94 ± 0.47 | 96.73 ± 0.30 | 3.25 ± 0.30 | 0.38 ± 0.01 |

M | SSA | 32.98 ± 1.76 | 0.0 ± 0.0 | 88.63 ± 0.60 | 11.36 ± 0.60 | 1.39 ± 0.01 |

H | HHA | 0.0 ± 0.0 | 14.07 ± 1.25 | 91.57 ± 0.65 | 8.41 ± 0.65 | 0.38 ± 0.01 |

H | SSA | 44.27 ± 3.30 | 2.64 ± 1.84 | 81.38 ± 0.92 | 18.59 ± 0.92 | 1.39 ± 0.01 |

**Performance of the different HS localization methods, HHA and SSA for the synthetic mixtures of abnormal HS and abnormal LS at three different flow rates**

TF | Method | Error (%) | ACC | DER | ET | |
---|---|---|---|---|---|---|

FNR | FPR | (%) | (%) | (Sec) | ||

L | HHA | 0.0 ± 0.0 | 4.43 ± 0.60 | 97.01 ± 0.30 | 2.97 ± 0.30 | 0.38 ± 0.01 |

L | SSA | 27.15 ± 1.26 | 0.0 ± 0.0 | 90.42 ± 0.47 | 9.56 ± 0.47 | 1.39 ± 0.01 |

M | HHA | 0.00 ± 0.0 | 6.81 ± 0.39 | 95.59 ± 0.23 | 4.39 ± 0.23 | 0.38 ± 0.01 |

M | SSA | 34.83 ± 0.95 | 0.83 ± 0.20 | 87.44 ± 0.25 | 12.54 ± 0.25 | 1.39 ± 0.01 |

H | HHA | 0.0 ± 0.0 | 16.37 ± 0.72 | 90.40 ± 0.35 | 9.58 ± 0.35 | 0.38 ± 0.01 |

H | SSA | 45.34 ± 0.64 | 3.97 ± 0.76 | 79.25 ± 1.69 | 20.73 ± 1.69 | 1.39 ± 0.01 |

**Performance of the different HS localization methods, HHA and SSA for the real time recorded lung sounds at three different flow rates**

TF | Method | Error (%) | ACC | DER | ET | |
---|---|---|---|---|---|---|

FNR | FPR | (%) | (%) | (Sec) | ||

L | HHA | 0.0 ± 0.0 | 2.50 ± 0.33 | 98.15 ± 0.21 | 1.83 ± 0.21 | 0.23 ± 0.01 |

L | SSA | 25.84 ± 0.99 | 0.69 ± 0.47 | 95.42 ± 0.78 | 4.56 ± 0.78 | 1.45 ± 0.01 |

M | HHA | 0.0 ± 0.0 | 5.83 ± 0.10 | 95.59 ± 0.33 | 4.40 ± 0.33 | 0.23 ± 0.01 |

M | SSA | 29.19 ± 0.52 | 1.24 ± 0.97 | 92.96 ± 0.87 | 7.03 ± 0.89 | 1.45 ± 0.01 |

H | HHA | 0.0 ± 0.0 | 11.66 ± 0.80 | 93.05 ± 0.59 | 6.94 ± 0.59 | 0.23 ± 0.01 |

H | SSA | 36.25 ± 0.61 | 1.53 ± 1.44 | 90.40 ± 1.68 | 9.59 ± 1.68 | 1.45 ± 0.01 |

### Effect of cut off frequency (*f*
_{
c
}) on the performance of the proposed method

*f*

_{ c }of LPF used for the smoothing of the envelope signal, is set in the range of 7–25 Hz. In fact the performance of the method is directly influenced by

*f*

_{ c }. The FNR increases and FPR decrease with increasing

*f*

_{ c }as shown in Figure6. The reason for increment of FNR and decrement of FPR for high

*f*

_{ c }is the shifting of minima points toward the maximum points. This occurs because of the presence of high frequency components in the filtered envelope signal as shown in Figure7. In other words the estimated HS boundary is smaller than the actual HS boundary. The actual HS boundary is validated through several tests: auditory, visual inspection, spectrogram analysis, and WaveSurfer toolkit. The efficiency of the proposed method may be improved to a higher degree by deriving an optimum

*f*

_{ c }value based on an adaptive filter. This issue may be addressed in a future work. The analysis of the results shows that the performance of HS localization algorithms is affected by flow rates and by pathological states. In spite of these shortcomings, the proposed method is superior than other technique in all aspects except FPR.

## Conclusion

A new HS localization algorithm is proposed in this work. This method is developed by using the Hilbert transform for envelope detection and Heron’s formula for area calculation. Here, HS segments are estimated by comparing their area with an adaptive threshold value. The performance of the method is compared with the SSA method described in (Ghaderi et al.2011). The results are obtained by implementing the proposed and SSA method on simulated and real recorded LS data. In this study, different flow rate and various pathological conditions are considered. The results for simulated and real data show that the proposed method superior in terms of FNR, ACC, DER, and ET. However, the SSA method is better in term of FPR. The proposed technique gives a false negative rate of zero for all cases under all conditions and is faster. Hence, it is expected to have a high impact in real-life applications that interpret lung sounds.

## Declarations

## Authors’ Affiliations

## References

- Ahlstrom C, Liljefeldt O, Hult P, Ask P: Heart sound cancellation from lung sound recordings using recurrence time statistics and nonlinear prediction.
*Signal Process Lett, IEEE*2005, 12(12):812-815.View ArticleGoogle Scholar - Ari S, Saha G: On a robust algorithm for heart sound segmentation.
*JMMB*2007, 7(2):129-150. 10.1142/S0219519407002200View ArticleGoogle Scholar - Arnott P, Pfeiffer G, Tavel M: Spectral analysis of heart sounds: relationships between some physical characteristics and frequency spectra of first and second heart sounds in normals and hypertensives.
*J Biomed Eng*1984, 6(2):121-128. 10.1016/0141-5425(84)90054-2View ArticleGoogle Scholar - Balasubramaniam D, Nedumaran D: Efficient computation of phonocardiographic signal analysis in digital signal processor based system.
*IJCTE*2010, 2(4):660-664.View ArticleGoogle Scholar - Blake WK:
*Mechanics of flow-induced sound and vibration*. FL: Academic Press, Orlando; 1986.Google Scholar - Choi S, Jiang Z: Comparison of envelope extraction algorithms for cardiac sound signal segmentation.
*Expert Syst Appli*2008, 34(2):1056-1069. 10.1016/j.eswa.2006.12.015View ArticleGoogle Scholar - Cromwell L, Weibell FJ, Pfeiffer EA (Eds):
*Biomedical instrumentation and measurements*. New Delhi, India: PHI Publication; 2002.Google Scholar - Donoho DL: De-noising by soft-thresholding.
*IEEE Trans Inf Theory*1995, 41(3):613-627. 10.1109/18.382009View ArticleGoogle Scholar - Flores-Tapia D, Moussavi Z, Thomas G: Heart sound cancellation based on multiscale products and linear prediction.
*IEEE Trans Biomed Eng*2007, 54(2):234-243.View ArticleGoogle Scholar - Gavriely N, Palti Y, Alroy G: Spectral characteristics of normal breath sounds.
*J Appl Physiol*1981, 50(2):307-314.Google Scholar - Ghaderi F, Mohseni H, Sanei S: Localizing heart sounds in respiratory signals using singular spectrum analysis.
*IEEE Trans Biomed Eng*2011, 58(12):3360-3367.View ArticleGoogle Scholar - Gnitecki J, Moussavi Z, Pasterkamp H: Recursive least squares adaptive noise cancellation filtering for heart sound reduction in lung sounds recordings. Engineering in medicine and biology society, Proceedings of the 25th annual international conference of the IEEE, Cancun, Mexico 2416–2419. 2003.Google Scholar
- Gnitecki J, Moussavi Z: Variance fractal dimension trajectory as a tool for heart sound localization in lung sounds recordings. Engineering in medicine and biology society, Proceedings of the 25th annual international conference of the IEEE, Cancun, Mexico 2420–2423. 2003.Google Scholar
- Hadjileontiadis L, Panas S: Adaptive reduction of heart sounds from lung sounds using fourth-order statistics.
*IEEE Trans Biomed Eng*1997, 44(7):642-648. 10.1109/10.594906View ArticleGoogle Scholar - Iyer VK, Ramamoorthy PA, Fan H, Ploysongsang Y: Reduction of heart sounds from lung sounds by adaptive filtering.
*IEEE Trans Biomed Eng*1986, 33(12):1141-1148.View ArticleGoogle Scholar - Johansson M: The Hilbert transform. Master thesis, Växjö University. 1999.Google Scholar
- Khandpur RS (Ed):
*Handbook of biomedical instrumentation*. New Delhi, India: Tata McGraw Hill; 2003.Google Scholar - Kompis M, Russi E:
*Adaptive heart-noise reduction of lung sounds recorded by a single microphone. Engineering in medicine and biology society, Proceedings of the 14th annual international conference of the IEEE.*Paris, France; 1992:691-692.View ArticleGoogle Scholar - Laennec RTH:
*Invention of the stethoscope. Acoustic historical and philosophical development*. Stroudsburg, PA: Dowden: Hutchinson and Ross Inc; 1962.Google Scholar - Lu YS, Liu WH, Qin GX:
*Removal of the heart sound noise from the breath sound. Engineering in medicine and biology society, Proceedings of the 25th annual international conference of the IEEE.*New Orleans, LA, USA; 1988:175-176.Google Scholar - Mertins A:
*Signal analysis; wavelets, filter banks*. England: Wiley; 1999.Google Scholar - Mondal A, Bhattacharya PS, Saha G: Reduction of heart sound interference from lung sound signals using empirical mode decomposition technique.
*JMET*2011, 35(6):344-353.View ArticleGoogle Scholar - Patidar S, Pachori RB: Segmentation of cardiac sound signals by removing murmurs using constrained tunable-q wavelet transform.
*Biomed Signal Proc Control*2013, 8(6):559-567. 10.1016/j.bspc.2013.05.004View ArticleGoogle Scholar - Pourazad M: Heart sounds reduction from lung sounds recordings applying signal and image processing techniques in time-frequency domain. Master thesis,. 2004.Google Scholar
- Pourazad M, Moussavi Z, Thomas G: Heart sound cancellation from lung sound recordings using time-frequency filtering.
*MBEC*2006, 44(3):216-225.Google Scholar - Sanei S, Ghodsi M, Hassani H: An adaptive singular spectrum analysis approach to murmur detection from heart sounds.
*Med Eng & Physics*2011, 33(3):362-367. 10.1016/j.medengphy.2010.11.004View ArticleGoogle Scholar - Schlant RC, Alexander RW (Eds):
*The heart arteries and veins*. Ch. 11 New York, USA: McGraw Hill Inc.; 1994.Google Scholar - Schmidt S, Holst-Hansen C, Graff C, Toft E, Struijk JJ: Segmentation of heart sound recordings by a duration-dependent hidden markov model.
*Physiol Meas*2010, 31(4):513-529. 10.1088/0967-3334/31/4/004View ArticleGoogle Scholar - Sovijarvi A, Malmberg L, Charbonneau G, Vanderschoot J, Dalmasso F, Sacco C, Rossi M, Earis J: Characteristics of breath sounds and adventitious respiratory sounds.
*Eur Respir Rev*2000, 10(77):591-596.Google Scholar - Stanojevié M: Proof of the Hero’s formula according to R.
*Boscovich. Math Commun*1997, 2(1):83-88.Google Scholar - Tang H, Li T, Qiu T, Park Y: Segmentation of heart sounds based on dynamic clustering.
*Biomed Signal Proc Control*2012, 7(5):509-516. 10.1016/j.bspc.2011.09.002View ArticleGoogle Scholar - Webster J:
*Medical instrumentation: Application and design*. New York: John Wiley & Sons; 1998.Google Scholar - Yadollahi A, Moussavi Z: A robust method for heart sounds localization using lung sounds entropy.
*IEEE Trans Biomed Eng*2006, 53(3):497-502. 10.1109/TBME.2005.869789View ArticleGoogle Scholar

## Copyright

This article is published under license to BioMed Central Ltd. This is an Open Access article distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/by/2.0), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.