I wonder if an efficient method exist to compute how much a signal is periodic, it should be ~1.0 when the signal is totally periodic (like a sinusoïdal signal) and ~0.0 when totally random, like a white noise.
Edit : This question came with a big misunderstanding, it has been modified to fit the answer.
Answer
I suggest using Spectral Flatness, aka Wiener Entropy. It is defined as a ratio of geometric and arithmetic mean of the magnitude spectra X(k):
Ξ=k√∏Kk=0X(k)1K∑Kk=0X(k)
For signals which have flat spectra, its value tends towards 1, whereas for tonal signals it is close to 0. In your particular application, you might want to consider 1−Ξ as a measure of "tonalness" in your signal.
No comments:
Post a Comment