Heart rate detection method and heart rate detection device
Patent Information
- Application Number
- JP2023544909
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2021-09-02
- Publication Date
- 2025-02-19
- Estimated Expiration
- 2041-09-02
AI Technical Summary
【0016】 本発明によれば、計測すべき心拍数の上限値HRmaxに対してスキップ幅を60000/HRmaxよりも短い値に設定することにより、R波を取りこぼすことなく検出することができ、心拍数を的確に計測することができる。
Smart Images

Figure 0007632659000001 
Figure 0007632659000002 
Figure 0007632659000003
Abstract
Description
[Technical field]
[0001] The present invention relates to a heartbeat detection method and a heartbeat detection device for detecting a heart rate from an electrocardiogram waveform. [Background technology]
[0002] An ECG (Electrocardiogram) waveform is a measurement of the electrical activity of the heart, and is made up of a series of heartbeat waveforms. A single heartbeat waveform is made up of components such as P waves, Q waves, R waves, S waves, and T waves, which reflect the activity of the atria and ventricles. Of these, the R wave is associated with ventricular contraction and has a large amplitude, so heartbeats are often detected based on the peaks derived from the R waves.
[0003] A conventional heartbeat detection method is disclosed in Patent Document 1. The method disclosed in Patent Document 1 uses an index value that focuses on the relationship between the peak of the time difference value of the ECG waveform and the values in a certain time domain before and after the peak, and detects R waves using a judgment logic based on a threshold. This method has the advantage that it is sensitive not only to the amplitude of the ECG waveform but also to the shape (time width of the peak), and can emphasize peaks that are likely to be R waves.
[0004] On the other hand, when detecting R-waves using a judgment logic based on a threshold, even after the index value exceeds the threshold once, it is normal for the threshold to continue to be exceeded for a while. Also, since there is an upper limit to the human heart rate, it is reasonable to assume that the next R-wave will not arrive immediately after an R-wave. Therefore, a process of stopping the R-wave detection operation for a certain period of time after detecting an R-wave is routinely performed.
[0005] Also, if the RR interval (RRI), which is the time interval between the detected R wave and the previous R wave, is too short than the standard, it is reasonable to determine that noise other than an R wave has been mistakenly detected and reject the R wave detection. Also, in R wave detection, the instantaneous heart rate (=60000 / RRI) value may deviate from the normal value due to errors such as noise mixed into the ECG waveform. Therefore, it is common to output a stabilized average heart rate by performing a time averaging process on the instantaneous heart rate.
[0006] However, ECG waveforms vary from person to person, and depending on the shapes of the Q, R, and S waves, the peak of the index value as described above may be gentle or the index value may have multiple peaks. For this reason, the timing at which the index value is determined to have exceeded the threshold may fluctuate back and forth by up to about 20 ms. This fluctuation in timing, the setting of the lower limit of the RRI, and the skipping process of R wave detection may cause errors in detecting R waves and measuring the heart rate.
[0007] The reasons for the errors in R-wave detection and heart rate measurement will be described below. Figs. 8 and 9 are diagrams showing examples of index values calculated by a conventional heart rate detection method. However, only index values near a threshold value TH are shown. Here, a case is considered in which the upper limit of the heart rate to be measured is 300 bpm, and the heart rate obtained from the observed ECG waveform is also 300 bpm. Two consecutive peaks P1 and P2 appear in the index value. The centers of the peaks P1 and P2 are separated by RRI=200 ms, which corresponds to a heart rate of 300 bpm. The tips of the peaks P1 and P2 are not sharp, but gently wavy.
[0008] In the example of Fig. 8, the index value exceeds the threshold value TH at time T1, and so time T1 is detected as the time of an R wave. The index value next exceeds the threshold value TH at time T2, and the interval between times T1 and T2 is 186 ms. However, the skip width tskip after R wave detection is set to 200 ms, and R wave detection is temporarily halted during the period up to 200 ms after time T1, so time T2 cannot be detected as the time of an R wave.
[0009] In the example of Fig. 9, the skip width tskip is changed to 180 ms. As in the example of Fig. 8, the index value exceeds the threshold TH at time T1, so time T1 is detected as the time of an R wave. Furthermore, after the elapsed time from time T1 exceeds tskip = 180 ms, the index value exceeds the threshold TH at time T2, so time T2 is detected as the time of an R wave. However, the lower limit of the RRI RRI LOW is set to 200 ms, and the interval between times T1 and T2 is 186 ms, so 186 ms is not adopted as the RRI and is excluded from the calculation of the instantaneous heart rate. In addition, the next time the index value exceeds the threshold TH is time T3, but since R-wave detection is temporarily suspended during the period from time T2 until 180 ms has elapsed, time T3 passes without being detected as the time of an R wave.
[0010] Even if there is fluctuation in the timing at which the index value exceeds the threshold value TH as in the examples of Figures 8 and 9, if each peak is detected without missing it, the RRI can be averaged to obtain a constant value even if the instantaneous value of the RRI fluctuates, and an appropriate average heart rate can be obtained. However, if the lower limit of the RRI is set without any leeway to match the upper limit of the heart rate to be measured, as in the example of Figure 9, cases where the RRI fluctuates on the short side will be excluded, and the average heart rate calculated will be biased toward the lower side than the actual one. [Prior art documents] [Patent documents]
[0011] [Patent Document 1] Patent No. 6527286 Summary of the Invention [Problem to be solved by the invention]
[0012] The present invention has been made to solve the above-mentioned problems, and has an object to provide a heartbeat detection method and a heartbeat detection device that can accurately measure the heart rate. [Means for solving the problem]
[0013] The heartbeat detection method of the present invention includes a first step of detecting an R wave from an electrocardiogram waveform of a living body, a second step of calculating an R-R interval, which is a time interval between the R wave detected in the first step and the immediately preceding R wave, and a third step of calculating a heart rate based on the R-R interval. 1 The steps are , most The method includes a step of stopping R-wave detection during a period in which the elapsed time from the time of the latest R-wave is equal to or less than a skip width, and the skip width is set to a value shorter than 60000 / HRmax, where HRmax is the upper limit of the heart rate to be measured. 、 The second step includes a step of not adopting the calculated time as the RR interval when the time of the latest R wave detected in the first step minus the time of the immediately preceding R wave is shorter than a lower limit value, and the lower limit value is set to a value shorter than 60000 / HRmax when the upper limit value of the heart rate to be measured is HRmax.
[0014] In one configuration example of the heart rate detection method of the present invention, the skip width is set to a value shorter than (60000 / HRmax)-20. In one configuration example of the heart rate detection method of the present invention, the lower limit is set to a value shorter than (60000 / HRmax)-20. In one configuration example of the heartbeat detection method of the present invention, the skip width is equal to or smaller than the lower limit value.
[0015] A heartbeat detection device according to the present invention includes an R-wave detection unit configured to detect an R-wave from an electrocardiogram waveform of a living body, an R-R interval calculation unit configured to calculate an R-R interval, which is a time interval between an R-wave detected by the R-wave detection unit and the immediately preceding R-wave, and a heartbeat calculation unit configured to calculate a heartbeat based on the R-R interval. The R wave detection unit is R wave detection is stopped during a period in which the elapsed time from the time of the latest R wave is equal to or less than the skip width, and the skip width is set to a value shorter than 60000 / HRmax, where HRmax is the upper limit of the heart rate to be measured. 、 When the time obtained by subtracting the time of the immediately preceding R wave from the time of the latest R wave detected by the R wave detection unit is shorter than a lower limit value, the RR interval calculation unit does not adopt the calculated time as the RR interval, and the lower limit value is set to a value shorter than 60000 / HRmax, where HRmax is an upper limit value for the heart rate to be measured. Effect of the Invention
[0016] According to the present invention, by setting the skip width to a value shorter than 60000 / HRmax for the upper limit value HRmax of the heart rate to be measured, it is possible to detect R waves without missing any, and to measure the heart rate accurately. [Brief description of the drawings]
[0017] [Figure 1] FIG. 1 is a block diagram showing a configuration of a heart rate detection device according to an embodiment of the present invention. [Diagram 2] FIG. 2 is a flowchart illustrating the operation of the heart rate detection device according to the embodiment of the present invention. [Diagram 3] FIG. 3 is a block diagram showing a configuration of an R wave detection unit of a heart rate detection device according to an embodiment of the present invention. [Figure 4] FIG. 4 is a flowchart illustrating the operation of the R wave detection unit of the heart rate detection device according to the embodiment of the present invention. [Diagram 5] FIG. 5 is a diagram illustrating an example of the operation of the heartbeat detection device according to the embodiment of the present invention. [Figure 6] FIG. 6 is a diagram illustrating an example of the operation of the heartbeat detection device according to the embodiment of the present invention. [Figure 7] FIG. 7 is a block diagram showing an example of the configuration of a computer that realizes a heartbeat detection device according to an embodiment of the present invention. [Figure 8] FIG. 8 is a diagram illustrating a conventional heartbeat detection method. [Figure 9] FIG. 9 is a diagram illustrating a conventional heartbeat detection method. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0018] Hereinafter, an embodiment of the present invention will be described with reference to the drawings. Fig. 1 is a block diagram showing the configuration of a heartbeat detection device according to an embodiment of the present invention. The heartbeat detection device includes an electrocardiograph 1 that outputs a sampling data string of an ECG waveform, a storage unit 2 that stores the sampling data string of the ECG waveform and information on the sampling time, an R-wave detection unit 3 that detects R-waves from the sampling data string of the ECG waveform, an R-R interval calculation unit 4 that calculates an R-R interval from time series data of the R-wave time, and a heartbeat calculation unit 5 that calculates the heartbeat based on the R-R interval.
[0019] Next, the operation of the heartbeat detection device of this embodiment will be described with reference to Fig. 2. In this embodiment, a data string obtained by sampling an ECG waveform is designated as D(i). i (i = 1, 2, ...) is a number given to one sample of data. It goes without saying that the larger the number i, the later the sampling time.
[0020] The electrocardiograph 1 measures the ECG waveform of a living body (human body) (not shown) and outputs a sampling data string D(i) of the ECG waveform (step S1 in FIG. 2). At this time, the electrocardiograph 1 outputs each sampling data with information of the sampling time added thereto. Since the specific method of measuring the ECG waveform is a well-known technique, a detailed description will be omitted. The memory unit 2 stores the sampling data string D(i) of the ECG waveform output from the electrocardiograph 1 and the information of the sampling time.
[0021] The R wave detection unit 3 detects R waves from the sampling data string D(i) of the ECG waveform stored in the storage unit 2 (step S2 in FIG. 2).
[0022] 3 is a block diagram showing the configuration of the R-wave detection unit 3. The R-wave detection unit 3 includes a positive / negative inversion value calculation unit 30 that calculates a positive / negative inversion value of the time difference of sampling data from a sampling data string of an ECG waveform for each sampling time, a maximum value detection unit 31 that detects for each sampling time the maximum value of the positive / negative inversion value of the time difference in a time range A before the sampling time to be processed and the positive / negative inversion value of the time difference in a time range B after the sampling time to be processed, an index value calculation unit 32 that calculates for each sampling time an index value obtained by subtracting the maximum value from the positive / negative inversion value of the sampling time to be processed, and a time determination unit 33 that sets the sampling time to be processed as the time of the R wave when the index value exceeds a predetermined threshold value.
[0023] The maximum value detection unit 31 is composed of a FIFO buffer (First In, First Out) 310 which receives as input the time difference positive / negative inverted value calculated by the positive / negative inverted value calculation unit 30, a FIFO buffer 311 which receives as input the output value of the FIFO buffer 310, a FIFO buffer 312 which receives as input the output value of the FIFO buffer 311, and a detection processing unit 313 which detects the maximum value M of the time difference positive / negative inverted value stored in the FIFO buffer 310 and the time difference positive / negative inverted value stored in the FIFO buffer 312 for each sampling time.
[0024] The index value calculation unit 32 is composed of a FIFO buffer 320 that receives the time difference positive / negative inverted value calculated by the positive / negative inverted value calculation unit 30 as an input, and a subtraction processing unit 321 that calculates an index value x for each sampling time by subtracting the maximum value M detected by the maximum value detection unit 31 from the output value of the FIFO buffer 320.
[0025] The operation of the R wave detection unit 3 of this embodiment will be described below with reference to Fig. 4. In order to calculate the time difference positive / negative inversion value Y(i) of the sampling data D(i), the positive / negative inversion value calculation unit 30 acquires data D(i+1) after one sampling of the sampling data D(i) and data D(i-1) before one sampling from the storage unit 2 (step S100 in Fig. 4). Then, the positive / negative inversion value calculation unit 30 calculates the time difference positive / negative inversion value Y(i) of the sampling data D(i) for each sampling time as follows (step S101 in Fig. 4). Y(i)=-{D(i+1)-D(i-1)} ···(1)
[0026] The positive / negative inverted value calculation unit 30 inputs the calculated positive / negative inverted time difference value Y(i) to the FIFO buffer 320 for each sampling time (Step S102 in FIG. 4).
[0027] Moreover, positive / negative inversion value calculation unit 30 inputs the calculated time difference positive / negative inversion value Y(i) to FIFO buffer 310 for each sampling time (step S103 in FIG. 4). The output of FIFO buffer 310 is input to FIFO buffer 311 (step S104 in FIG. 4), and the output of FIFO buffer 311 is input to FIFO buffer 312 (step S105 in FIG. 4). FIFO buffers 310 to 312 are used to find the maximum value M of the time difference positive / negative inversion value in time ranges A and B.
[0028] Time interval L3 (the delay time from when the time difference positive / negative inverted value is input to FIFO buffer 311 until it is output) corresponding to the length of FIFO buffer 311 needs to be sufficiently wide with respect to the width of the peak derived from the R-wave (approximately 10 ms), and is preferably about 50 ms. This interval L3 becomes the interval between time ranges A and B. Also, time interval L2 (the delay time from when the time difference positive / negative inverted value is input to FIFO buffer 310 until it is output) corresponding to the length of FIFO buffer 310 and time interval L4 (the delay time from when the time difference positive / negative inverted value is input to FIFO buffer 312 until it is output, L2=L4) corresponding to the length of FIFO buffer 312 are each appropriately about 100 ms.
[0029] Furthermore, the time interval L1 corresponding to the length of the FIFO buffer 320 may be set as L1=L2+L3 / 2. In the above numerical example, L1 is 125 ms. By setting L1=L2+L3 / 2 and L2=L4, it is possible to obtain the maximum value M in the ranges of -(L2+L3 / 2) to -(L3 / 2) and (L3 / 2) to (L2+L3 / 2) for the time of the output value a of the FIFO buffer 320 (the sampling time to be processed), and it becomes possible to subtract the maximum value M from the output value a.
[0030] The detection processing unit 313 detects a maximum value M of the positive / negative inverted time difference values stored in the FIFO buffer 310 and the positive / negative inverted time difference values stored in the FIFO buffer 312 for each sampling time (step S106 in FIG. 4). The subtraction processing unit 321 calculates an index value x(i)=aM by subtracting the maximum value M from the output value a of the FIFO buffer 320 for each sampling time (Step S107 in FIG. 4).
[0031] When the index value x(i) exceeds a predetermined threshold TH (YES in step S108 in FIG. 4), the time determination unit 33 judges whether the sampling time of the index value x(i) is appropriate as the time of the R wave, and determines the time of the R wave. Specifically, the time determination unit 33 judges whether the time difference ΔT between the sampling time of the index value x(i) that exceeds the threshold TH and the time of the R wave determined immediately before is longer than a preset skip width tskip (step S109 in FIG. 4), and if the time difference ΔT is equal to or less than the skip width tskip (NO in step S109), the sampling time of the index value x(i) that exceeds the threshold TH is not adopted as the time of the R wave. By the process of step S109, it is possible to realize the skip process of the R wave detection. If the sampling time of the index value x(i) is not adopted as the time of the R wave, the process moves to the sampling data D(i) of the next sampling time, and the process from step S100 onwards is performed again.
[0032] Furthermore, if the time difference ΔT is longer than the skip width tskip (YES in step S109), the time determining unit 33 determines the sampling time of the index value x(i) that exceeds the threshold value TH as the time of the R wave (step S110 in FIG. 4).
[0033] As described above, the time difference positive / negative inverted value Y(i) is calculated from the sampling data D(i), and the index value x(i) is calculated from the time difference positive / negative inverted value Y(i). Therefore, the sampling time of the index value x(i) is the sampling time of the time difference positive / negative inverted value Y(i) (the sampling time of the data D(i)), and can be acquired from the storage unit 2.
[0034] In this manner, the processing of steps S100 to S110 is repeatedly executed for each sampling period, thereby obtaining time series data of the time of the R wave. The time series data of the time of the detected R wave is stored in the storage unit 2. The above-mentioned method for detecting R waves is just one example, and R waves may be detected by other methods.
[0035] In this embodiment, the skip width tskip is set to be equal to or smaller than the lower limit of the RR interval (RRI). When the upper limit of the instantaneous heart rate to be measured is HRmax [bpm], the lower limit of the RRI RRI LOW is greater than 0 and less than (60000 / HRmax) [ms]. More specifically, the lower limit of RRI, RRI LOW is set to a value greater than 0 and less than ((60000 / HRmax)-20) [ms]. The expected upper limit value HRmax of the instantaneous heart rate is, for example, 300 bpm.
[0036] Therefore, the skip width tskip is greater than 0 and less than (60000 / HRmax) [ms]. More specifically, the skip width tskip is set to a value greater than 0 and less than ((60000 / HRmax)-20) [ms].
[0037] Next, the RR interval calculation unit 4 calculates a time d by subtracting the time of the previous R wave from the time of the latest R wave detected by the R wave detection unit 3 (FIG. 2, step S3). The RR interval calculation unit 4 calculates the time d by subtracting the time of the latest R wave from the time of the previous R wave (FIG. 2, step S3). LOW If the time d is shorter than the lower limit RRI (NO in step S4 in FIG. 2), the time d is discarded without being adopted as the RRI. LOW In the above case (YES in step S4), the time d is determined as RRI [ms] (step S5 in FIG. 2).
[0038] The heart rate calculation unit 5 calculates an instantaneous heart rate HR(i) [bpm] for each RRI based on the RRI [ms] calculated by the RR interval calculation unit 4 (step S6 in FIG. 2). HR(i) = 60000 / RRI (2)
[0039] The heart rate calculation unit 5 also calculates the average heart rate HRave(i) [bpm] for each RRI (step S7 in FIG. 2). As described above, the instantaneous heart rate calculated from the i-th RRI(i) before averaging is HR(i), the average value of the instantaneous heart rates up to the i-1th is HRave(i-1), and a predetermined averaging coefficient is r. Then, the average value of the instantaneous heart rates up to the i-th, HRave(i), can be calculated by Equation (3). HRave(i)=r×HR(i)+(1-r)×HRave(i-1) (3)
[0040] In this manner, by repeating the processes in steps S1 to S7, time series data of the instantaneous heart rate HR(i) and the average heart rate HRave(i) is obtained. The calculated time series data is stored in the storage unit 2.
[0041] FIG. 5 shows an example in which the heartbeat detection method according to the present embodiment is applied to the example in FIG. 8. Here, the skip width tskip is set to 180 ms. In the example in FIG. 5, the index value x exceeds the threshold value TH at time T1, so that the R-wave detection unit 3 detects time T1 as the time of an R-wave. The R-wave detection unit 3 suspends R-wave detection during the period from time T1 until tskip=180 ms, but detects time T2 as the time of an R-wave because the index value x exceeds the threshold value TH 186 ms after time T1. In this way, in this embodiment, it is possible to appropriately detect time T2 at which the index value x exceeds the threshold value TH.
[0042] 6 shows an example in which the heartbeat detection method according to the present embodiment is applied to the example of FIG. 9. Here, the skip width tskip and the lower limit value RRI LOW 5, the index value exceeds the threshold TH at time T1, so that the R-wave detection unit 3 detects time T1 as the time of an R-wave. Furthermore, after the elapsed time from time T1 exceeds tskip=180 ms, the index value exceeds the threshold TH at time T2, so that the R-wave detection unit 3 detects time T2 as the time of an R-wave.
[0043] The time d = 186 ms obtained by subtracting time T1 from time T2 is the lower limit of RRI. LOW = 180 ms or more, the RR interval calculation unit 4 adopts the time d as the RRI. In this way, in this embodiment, the RRI can be properly detected. In addition, since the peak of the index value x can be detected without missing, the average heart rate can also be properly calculated.
[0044] The memory unit 2, the R wave detector 3, the RR interval calculator 4, and the heart rate calculator 5 of the heart rate detector described in this embodiment can be realized by a computer equipped with a CPU (Central Processing Unit), a storage device, and an interface, and a program that controls these hardware resources. An example of the configuration of this computer is shown in FIG.
[0045] The computer includes a CPU 100, a storage device 101, and an interface device (I / F) 102. An electrocardiograph 1 and the like are connected to the I / F 102. A program for implementing the heartbeat detection method of the present invention is stored in the storage device 101. The CPU 100 executes the processes described in this embodiment in accordance with the program stored in the storage device 101. [Industrial Applicability]
[0046] The present invention can be applied to a technique for detecting the heartbeat of a living body. [Explanation of symbols]
[0047] 1...electrocardiograph, 2...memory unit, 3...R wave detection unit, 4...RR interval calculation unit, 5...heart rate calculation unit, 30...positive / negative inversion value calculation unit, 31...maximum value detection unit, 32...index value calculation unit, 33...time determination unit, 310-312, 320...FIFO buffer, 313...detection processing unit, 321...subtraction processing unit.
Claims
1. A first step of detecting an R wave from an electrocardiogram waveform of a living body; A second step of calculating an R-R interval, which is a time interval between the R wave detected in the first step and the immediately preceding R wave; and a third step of calculating a heart rate based on the R-R interval. the first step includes a step of stopping R-wave detection during a period in which an elapsed time from a time of the latest R-wave is equal to or less than a skip width; The skip width is set to a value shorter than 60000 / HRmax, where HRmax is the upper limit of the heart rate to be measured. the second step includes a step of not adopting the calculated time as the R-R interval when the time obtained by subtracting the time of the immediately preceding R wave from the time of the latest R wave detected in the first step is shorter than a lower limit value; The heart rate detection method according to the present invention is characterized in that the lower limit is set to a value shorter than 60,000 / HRmax, where HRmax is an upper limit value of the heart rate to be measured.
2. 2. The method for detecting a heartbeat according to claim 1, A heartbeat detection method, characterized in that the skip width is set to a value shorter than (60000 / HRmax)-20.
3. 2. The method for detecting a heartbeat according to claim 1, The heart rate detection method according to the present invention, wherein the lower limit is set to a value shorter than (60000 / HRmax)-20.
4. 4. The heartbeat detection method according to claim 1, further comprising: A heartbeat detection method, wherein the skip width is equal to or smaller than the lower limit value.
5. An R wave detection unit configured to detect an R wave from an electrocardiogram waveform of a living body; an R-R interval calculation unit configured to calculate an R-R interval, which is a time interval between an R wave detected by the R wave detection unit and the immediately preceding R wave; a heart rate calculation unit configured to calculate a heart rate based on the R-R interval, The R wave detection unit stops R wave detection during a period in which an elapsed time from the time of the latest R wave is equal to or less than a skip width, The skip width is set to a value shorter than 60000 / HRmax, where HRmax is the upper limit of the heart rate to be measured. the R-R interval calculation unit does not adopt the calculated time as the R-R interval when the time obtained by subtracting the time of the immediately previous R wave from the time of the latest R wave detected by the R wave detection unit is shorter than a lower limit value, A heart rate detection device according to claim 1, wherein the lower limit is set to a value shorter than 60,000 / HRmax, where HRmax is an upper limit value of the heart rate to be measured.
6. 6. The heartbeat detection device according to claim 5, A heart rate detection device, wherein the skip width is equal to or smaller than the lower limit value.
Citation Information
Patent Citations
Vehicle seat
JP2013220322A
Estimation device, learning device, estimation method and computer program
JP2020130344A
Heartbeat detection method and heartbeat detection device
JP6527286B2