I am trying to find a strictly mathematical (i.e., not manual graphing or plugging) method to solve for the absolute (global) maximum value of an irregular sinusoid.
Given a rational function $f(x)$, i.e., $$f(x) = \frac{8480128-33x}{100x+63}$$ and a sinusoid transformed by the above function, i.e., $$r(x) = \cos(\pi f(x)) \cos(\pi x)$$ I am trying to numerically solve for the absolute maximum of $r(x)$. Right now, I have plotted the function on Desmos and manually checked for an intersection with the line $y=1$. I am also aware that I can iterate $x = 0, 1, ...$ at the peaks of $r(x)$ and checking $r(x)=1$ but both of these methods are unsatisfactory for $f(x)$ with large coefficients.
Setting $\cos\left(\pi \frac{8480128-33x}{100x+63}\right) \cos(\pi x)=1$, I do not know how to proceed algebraically or with calculus. I am looking for a way to deterministically find whether or not this function $r(x)$ will ever reach $y=1$ without doing too much manual work.
One way to proceed can be find for $x$ real such that
$$8480128-33x=0 \implies x\approx 256973.6$$
therefore for $x=256974$ we obtain a value very close at $1$, that is
$$\cos\left(\pi \frac{8480128-33x}{100x+63}\right) \cos(\pi x)\approx 0.9999999999985...$$
Another strategy is look at integer solution for
$$f(x) = \frac{8480128-33x}{100x+63}$$
and, in this special case for example, we can find that $x=139$ is a solution with $f(139) = 607$ therefore
$$\cos(607\pi ) \cos(139\pi )=(-1)\cdot (-1)=1$$
Idea for a general method
Following the idea used in the particular example, more in general we can proceed as follows.
1. Look for solutions in $\mathbb Z$ of the rational equation $f(x)=n$ and we have three cases:
To determine/check for an integer solution, we can refer, for example, to the general methods discussed here.
2. When no integer solutions exist, we can search for real solutions of $r(x_0)=0$ and then:
3. The previous method can be generalized searching for real solutions of $r(x_0)=2k$ and of $r(x_0)=2k+1$ with $k\in\mathbb Z$.