Compare two Fourier series to depict the signal smoothness

3 views (last 30 days)
Hello
I have several signals, that I am trying to find a metric to compare the signal smoothness. By signal smoothness I mean, the signal that the distance between the peak to trough become smaller (getting close to becoming flat) is smoother, and if this peak-tough distance increases it becomes wavier.
I can fit a Fourier series with eight terms to all of them. it means that I do have a Fourier series equation with eight terms for all of them.
My question is that how I can compare the Fourier series coefficient to each other, in order to evaluate the signal smoothness?
since for a single term Fourier series (i.e f(x)=a0+a1cos(xw)+b1sin (xw)) I can use the "sqrt ((a1^2)+(b1^2))" as an indicator of surface smoothness. but I do not know what I should do when it has eight terms? Thank you

Answers (1)

Swetha Polemoni
Swetha Polemoni on 29 Jul 2021
Hi
You can use findpeaks to find local maxima i.e., all the peaks in the signal. Now invert the siganl and use "findpeaks" to find local minima of the signal. The following answer might help you to understand more about how to use "findpeaks".
Now you can use mean absolute error or mean square error between local maxima and local minima of the siganl to get its smoothness.
  1 Comment
SM
SM on 31 Jul 2021
Hello
Thanks for your response.
That is the alternative approach that I am currently using. However, I was hoping to find a way to compare the Fourier series coefficient since that is a more accurate representor or of the data.
Thanks

Sign in to comment.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!