Measure of how oscillatory a function is

80 Views Asked by At

In the image below I have the plots of two different functions (the exact functions are't completely relevant, but just in case anyone wants a little bit of visual context).

Two example plots

I will have many functions behaving more or less like these two examples, and I need an automated way to distinguish them. As one of my ideas, I was wondering if there is any sort of measure of how oscillatory a function is so I could distinguish these. My thought process is that the one on the left has an extended region over which the function is slightly decreasing, whereas in the one on the right the function is highly oscillatory in the same region. Of course there could be multiple ways to achieve this, I was just wondering what is out there.

I don't want to rely on something that counts local maxima/minima because there are some examples of functions similar to the one on the left that have some oscillatory behavior before and after the nearly constant region (this is somewhat visible here, although I have functions where this behavior is more pronounced.