From my data set, of which I collected myself, I notice that the graph is extremely sinusoidal, except the frequency continually decreases to $0$ as $x\rightarrow\infty$. It strongly resembles
$$y=\left|\cos(f(x))\right|$$
for an unknown $f(x)$. However, I'm quite confident about two things:
$$\lim_{x\to\infty}f(x)=0 \tag 1$$
$$f'(x)<0\,\forall x > 0 \tag 2$$
I have values of $y$ for $\forall x\in\{1,2,3,\dots,1000\}$. I do have the ability to collect data for larger values of $x$, it will just take longer computationally.
The following is not the actual graph of my data, but a highly-resembling example.
If $y=\left|\cos(f(x))\right|$, how can I manipulate my data in a way that I can isolate (with reasonable accuracy) a graph of $f(x)$?
I assume something to do with approximating the derivative may be helpful here.


Let $z=2y^2-1$, which should model $\cos2f$.
In intervals where $z$ is decreasing, let $w =\arccos z$, and where $z$ is increasing, let $w=-\arccos z$.
W will jump down by $2\pi$ when you go from decreasing to increasing, so add $2\pi$ to everything to the right of each jump. This accumulates, so you will add $2\pi$ between the first two jumps, $4\pi$ between jumps 2 and 3, then $6\pi$ and so on.