The original problem:
If $0\le a,b\le 3$ and the equation $$x^2+4+3\cos(ax+b)=2x$$ has at least one real solution, then find the value of $a+b$
At first, on rearranging, I got the following expression: $$x^2-2x+(4+3\cos(ax+b))=0$$ I thought this was a quadratic in $x$, and thus from the quadratic formula(and that at least one real root exists), $D\ge 0$ ie $$4-4(4+\cos(ax+b))\ge 0$$ $$$$
However I'm not really sure about this. I've treated $\cos(ax+b)$ as a constant term even though the argument of the cosine includes $x$: the variable in which the quadratic expression is. $$$$Under these circumstances, is it correct to use $3\cos(ax+b)$ as a constant? If not, how could I use the quadratic formula to find values of $x$ satisfying $$x^2-2x+(4+3\cos(ax+b))=0$$
Many thanks in anticipation!