• 沒有找到結果。

Chapter 3 A Time-Frequency Heart Rate Variability Processor

3.4 Performance and Analysis of the HRV Processor

3.4.1 ECG Beat Detection

To analyze the performance of the RR interval calculation unit, ECG signals from the MIT-BIH Arrhythmia Database were used. The MIT-BIH Arrhythmia Database contains 48 30-minute excerpts of two-channel ambulatory ECG recordings. The recordings were digitized at a sampling rate of 360Hz with an 11-bit ADC. To maintain consistency with our system specification, the ECG signals were re-sampled to 256Hz with 10-bit precision before being used to test the performance of our beat detection unit.

Only channel 1 (Lead II) of the two-channel ECG recording is used in our analysis.

Figure 3.11 shows the output of each stage in our beat detection unit:

differentiation, squaring, and final output pulse. The output pulse can clearly pinpoint the R peak of a clean ECG signal and an ECG signal with motion artefact two within a precision of one sample. For ECG signals with various types of noise, artefacts, and distortion, the designed system is able to identify beats in most cases, as shown in Figure 3.12.

(a)

(b)

Figure 3.11 Resulting output from each stage of the QRS detection algorithm for (a) clean ECG signal and (b) ECG signal with motion artefact. The detected output

3.4.2 Spectral Analysis of HRV

3.4.2.1 Artificial RR Interval Data

To compare spectral analysis performance of different algorithms, an understanding of the underlining oscillations within the signal is required. Since this can rarely be done with real RR tachograms, an artificial signal that closely simulates the characteristics of RR intervals was generated to verify the performance.

Figure 3.12 Beat detection of ECG signals with different types of distortion

short-term RR tachogram can be represented roughly as 0.25 Hz and 0.1Hz corresponding to the HF and LF regions respectively [57]. Thus the artificial RR signal is modelled as the oscillation of these two frequencies around the average heart rate. Assuming an average heart rate of 70 bpm, the artificial heart rate function can be modelled as

HR(t) = HR0 + AL∙ sin(2πfLt + θL) + AH∙ sin(2πfHt + θH) (3.9)

where θL and θH are initially assumed to be 0, HR0 = 70, AL=1, AH=1, fL = 0.095, and fH= 0.275.

The heart rate function is used to iteratively calculate the RR intervals. The RR interval is calculated by dividing one minute by the instantaneous heart rate. Starting with an initial interval, the next interval can be calculated from the heart rate function using this initial interval as the time. The calculated interval is then added to the previous used time to generate the next interval from the heart rate function. In short, the sum of previous intervals is used as the next point in time to calculate the next interval from the heart rate function. The pseudo code for generation of artificial RR intervals is shown below.

The flow chart of the artificial RR interval calculation is shown in Figure 3.13.

Pseudo code for generation of artificial RR intervals RR0 = 60/HR0

current_time = RR0

while(current_time < end_time)

RRi = 60 / Heart_Function (current_time) current_time = current_time + RRi

end

Figure 3.13 Flow chart for artificial generation of RR intervals

The generated artificial RR interval is shown in Figure 3.14. There are 256 points analyzed in our implementation of the Lomb periodogram, so to produce a fair comparison, the results are compared with those that have the same number of points. As we interpolate using a re-sampling rate of 4Hz, to produce 256 points between 0 to 0.5 Hz requires 1024-point FFT. The resulting PSD of the artificial RRI using Lomb periodogram compared with results using 1024 point FFT is shown in Figure 3.15.

Figure 3.14 Generated artificial RR interval time series

Figure 3.15 Power spectral density of artificially generated RRI using 1024 point FFT, Lomb-Scargle periodogram, and our fixed point Lomb method. The RRI time series is

re-sampled at 4 Hz before FFT analysis.

The LF/HF ratio is calculated for each method and the error percentage is compared in Table 3-2.

Table 3-2 LF/HF Ratio Comparison of Artificially Generated RRI (LF/HF = 1)

LF/HF Ratio Value Error

Actual 1 -

FFT 1.095631 9.563104%

Lomb-Scargle 0.983035 1.696541%

This work 1.003755 0.375486%

Artificial Data with Spread Frequencies

To achieve a more realistic signal, the LF and HF frequency components are spread around the central frequencies with the Gaussian distribution

y = 1

The distributions of the frequencies and the resulting RRI time series are shown in Figure 3.16. The PSD of the artificial RRI compared with results using 1024 point FFT and the Lomb-Scargle periodogram is shown in Figure 3.17. The LF/HF ratio is

calculated for each method and the error percentage is compared in Table 3-3Table 3-2.

(a)

(b)

Figure 3.16 (a) Distribution of the HF and LF frequencies (b) Artificial RRI time series with spread frequencies (LF/HF = 1)

Figure 3.17 Power spectral density of artificially generated RRI with spread frequencies using 1024 point FFT, Lomb-Scargle periodogram, and our Lomb method

using fixed point (LF/HF = 1)

Table 3-3 LF/HF Ratio Comparison of Artificially Generated RRI with Spread Frequencies (LF/HF = 1)

LF/HF Ratio Value Error

Actual 1 -

FFT 1.701217 70.121653 %

Lomb-Scargle 1.482163 48.216342%

This work 1.510836 51.083625 %

Artificial Data with Spread Frequencies (LF/HF = 0.5)

Next, the LF/HF is set to be 0.5 with AL=1 and AH=0.5. The generated RR intervals are shown in Figure 3.18. The PSD of the artificial RRI compared with results using 1024 point FFT and the Lomb-Scargle periodogram is shown in Figure 3.19. The LF/HF ratio is calculated for each method and the error percentage is compared in Table 3-4.

Figure 3.18 Artificial RRI time series with spread frequencies (LF/HF = 0.5)

Figure 3.19 Power spectral density of artificially generated RRI with spread frequencies using 1024 point FFT, Lomb-Scargle periodogram, and our Lomb method

using fixed point (LF/HF = 0.5)

Table 3-4 LF/HF Ratio Comparison of Artificially Generated RRI with Spread Frequencies (LF/HF = 0.5)

LF/HF Ratio Value Error

Actual 0.5 -

FFT 0.676603 35.320624 %

Lomb-Scargle 0.530713 12.659493%

This work 0.524123 18.541998 %

Finally, to simulate time-varying properties, the central frequency of the HF is configured to sweep linearly from 95% to 105% of the original value over the course of generation. The resulting time frequency distribution using the Lomb periodogram is shown in Figure 3.20.

Figure 3.20 Time-frequency distribution of artificial RR interval with HF frequency sweep using the Lomb periodogram

3.4.2.1 Data from PhysioBank

In addition to simulation using artificial RRI, data from PhysioBank’s online ECG database has been used to verify the HRV processor design. Databases including the MIT-BIH Arrhythmia Database and the MIT-BIH Normal Sinus Rhythm Database have been used to compare results. Figure 3.21 shows the PSD of a single window compared with results using 1024 point FFT and the Lomb-Scargle periodogram. A time-frequency distribution of HRV is shown in Figure 3.22.

Figure 3.21 Power spectral density of RRI data from the MIT-BIH Arrhythmia Database as calculated using 1024 point FFT, Lomb-Scargle periodogram, and our Lomb

method using fixed point.

Figure 3.22 Time-frequency HRV analysis using Lomb TFD of EKG data from the MIT-BIH arrhythmia database.

相關文件