使用傅立叶变换查找心跳的BPM [英] Finding BPM of a heartbeat using Fourier Transform

查看:106
本文介绍了使用傅立叶变换查找心跳的BPM的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个信号的傅立叶变换图.绘制信号的傅立叶变换及其索引号.给出了采样频率(Fs)和样本总数(N),以及样本中两个最大峰的索引.我正在寻找具有此信息的信号的每分钟节拍数.我的第一个猜测是采样总数除以最大峰值的索引(N/(最大指数).但是,我觉得应该对第二个最大峰值进行处理.索引发挥作用.任何帮助将不胜感激.

I have a plot of the fourier transform of a signal. The fourier transform of the signal is plotted vs. its index numbers. I am given the sampling frequency (Fs) and the total number of samples (N), as well as the indices for the two largest peaks in the sample. I am looking to find the beats per minute of the signal with this information. My first guess would be that it is the total number of samples divided by the index of the largest peak (N/(largest index). However, I feel as though something should be done with the second maximum peak. I am confused on where the indices come into play. Any help would be appreciated.

推荐答案

用于实际输入数据的离散傅立叶变换具有一些对称性:X_{N-k} = X*_{k}.我想你的巅峰服从了这种关系.因此,只有第一个N/2点是相关的,并且您只能检测低于Fs/2的频率,因为如果您以Fs的频率进行采样,而频率为Fs/2的窦,您将看不到窦与常数之间的差异.

The Discrete Fourier Transform for real input data has some symmetry: X_{N-k} = X*_{k}. I assume your peaks obey this relationship. So, only the first N/2 points are relevant and you are only able to detect frequencies lower then Fs/2, because if you sample at a frequency of Fs a sinus with frequency of Fs/2, you can not see the difference between this sinus and a constant.

BPM = (largest_index - 1)/N * Fs * 60

请注意,由于第一个元素的频率为零(即恒定值),因此需要-1.

Note that -1 is need because the first element corresponds with a zero frequency (i.e. constant value).

您始终可以通过手动确定两个心跳之间的峰值来检查代码,方法是使用已知频率的生成信号来验证您的方法.

You can always check your code by manually determining the peak between two heartbeats are by validating your method with a generated signal with known frequency.

这篇关于使用傅立叶变换查找心跳的BPM的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆