I have data which looks like composition of sine waves. enter image description here

I need to decompose it to fewest possible sine waves that would give me tolerable error.

The picture is of a half-period. Each half-period would be different so I need to analyze each half-period separately as if they arent related (this is empirical limitation).

The data has no physical meaning so the decomposition would not be precise ever, also there is no energy for proper Fourier transform.

Is there a software package (preferably in python) that can find a function that decomposes approximately given wave with error sigma? if not what would you suggest?

  • $\begingroup$ Depending on how you measure error, the FT will be a good candidate for the solution. The meaning of "no energy" is obscure. $\endgroup$
    – whuber
    Commented Nov 29, 2022 at 19:22
  • $\begingroup$ I don't think FT can do approximate decomposition though? Can it? $\endgroup$ Commented Nov 30, 2022 at 12:47
  • $\begingroup$ Pick a subset of the components, such as those with the largest coefficients. That's the same idea as PCA. $\endgroup$
    – whuber
    Commented Nov 30, 2022 at 15:27


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.