I'm supposed to use the derivative to prove that $$f(x)=2\cos ^2\left(\frac{\pi }{4}-\frac{x}{2}\right)-\sin \left(x\right)=1$$
What I have so far is:
$$f'\left(x\right)=D\left(2\left(\cos\left(\frac{\pi}{4}-\frac{x}{2}\right)\right)^2\right)-D\left(\sin\left(x\right)\right)=1$$
$$f\:'\left(x\right)=4\cos\left(\frac{\pi}{4}-\frac{x}{2}\right)\left(-\frac{1}{2}\sin\left(\frac{\pi}{4}-\frac{x}{2}\right)\right)-\cos\left(x\right)=1$$
$$f\:'\left(x\right)=-2\sin\left(\frac{\pi}{4}-\frac{x}{2}\right)\cos\left(\frac{\pi}{4}-\frac{x}{2}\right)-\cos\left(x\right)=1$$
And by continuing this I can get all the way to zero, which would mean that $0=1$ and from there by taking the derivative of $1$ we'd get $0=0$, which is obviously true. But what I'm confused about is that even if the constant was any number, let's say two, the equation would still come out as true. And obviously, the original function doesn't equal two.
I'm assuming that I'm somehow supposed to get $1$ to the left side as well? Honestly, I've gone through the formulas so many times, and yet I can't figure out how to do it.
You have that $f'(x)=0$, so $f(x)=c$. Now substitute a "nice" value into $f$ to get the value of $c$.