<s>[INST] Find the Maximum and Minimum Values of $f(x) = \cos\sqrt{x+1} - \cos\sqrt{x}$ I saw today in a fb forum the following excersice:
Find the range of values of 
$f(x)=\cos\sqrt{x+1}-\cos\sqrt{x}$
I have tried to find the mix and max of the function but failed. Any ideas?
 [/INST] To do an analytic check of the range, and possibly other properties, note you can combine the $2 \cos$ terms into a multiple of one $\sin$ term using several identities from List of trigonometric identities. First, note that $\cos(\theta) = \sin(\frac{\pi}{2} - \theta)$, so you get
$$f(x) = \cos\sqrt{x+1}-\cos\sqrt{x} = \sin\left(\frac{\pi}{2} - \sqrt{x+1}\right) - \sin\left(\frac{\pi}{2} - \sqrt{x}\right) \tag{1}\label{eq1}$$
Next, you can use the Arbitrary phase shift formula for a linear sum of $2$ $\sin$ values which gives
$$a\sin y+b\sin(y+\theta )=c\sin(y+\varphi ) \tag{2}\label{eq2}$$
where
$$c={\sqrt {a^{2}+b^{2}+2ab\cos \theta }} \tag{3}\label{eq3}$$
and
$$\varphi =\operatorname {atan2} \left(b\,\sin \theta ,a+b\cos \theta \right) \tag{4}\label{eq4}$$
where $\operatorname {atan2}$ is the principal arc-tangent angle in $(-\pi,\pi]$ (more details are at atan2)). For the case of \eqref{eq1}, you have $a = 1$, $b = -1$, $y = \frac{\pi}{2} - \sqrt{x+1}$ and $\theta = \sqrt{x+1} - \sqrt{x}$. As such, \eqref{eq3} gives
$$c = \sqrt{2 - 2\cos\left(\sqrt{x+1} - \sqrt{x}\right)} \tag{5}\label{eq5}$$
Since $\sqrt{x+1} - \sqrt{x}$ is a strictly decreasing function, from $1$ towards $0$, for $x \ge 0$ and $\cos$ is also a decreasing function in $(0,1]$, this means that at $x = 0$ you have $c = \sqrt{2 - 2\cos(1)}$ is it's maximum and, since $\cos(0) = 1$, its infimum is $0$ since $c \to 0$ as $x \to \infty$.
You can do similar appropriate checks for the range of $\varphi$ values in \eqref{eq4} and then determine, overall, the range of possible values for \eqref{eq1}.
</s>