Show that $f(x)=\cos x-\sin x$ is bounded Show that $$f(x)=\cos x-\sin x$$ is bounded.
We know that $$-1\le\cos x\le1\\{-1}\le\sin x\le1,$$ so I tried to subtract these two inequalities, but it seems that it doesn't work as we get: $$0\le\cos x-\sin x\le0$$
I also noticed: $f(x)=\cos x-\sin x\ge\cos x-(-1)=\cos x+2$ and $f(x)=\cos x-\sin x\ge\cos x - 1$.
 A: Just apply the triangle inequality:
$$\lvert \cos x-\sin x\rvert\leq\lvert \cos x\rvert +\lvert \sin x\rvert\leq 2.$$
A: In this way you can find "exact bound" (least upper bound)
$$\cos(x)-\sin(x)=a$$
$$\frac{\cos(x)}{\sqrt{2}}-\frac{\sin(x)}{\sqrt{2}}=\frac{a}{\sqrt{2}}$$
$$\cos\left(\frac{\pi}{4}\right)\cos(x)-\sin\left(\frac{\pi}{4}\right)\sin(x)=\frac{a}{\sqrt{2}}$$
$$\cos\left(\frac{\pi}{4}+x\right)=\frac{a}{\sqrt{2}}$$
$$a=\sqrt{2}\cos\left(\frac{\pi}{4}+x\right)$$
$$-\sqrt{2} \leq a \leq\sqrt{2} $$
A: You can write
$$\begin{cases}-1\le\cos x\le1\\{-1}\le\sin x\le1\end{cases}\\
\implies \begin{cases}-1\le\cos x\le1\\{1}\ge-\sin x\ge -1\end{cases}
$$
We see that it is not possible to sum these inequalities directly from side by side.
We can try the following way to subtract the two inequalities.
Let $a≥x≥b \wedge c≥y≥d$, then we have
\begin{align*}&\begin{cases} a≥x≥b\\ c≥y≥d \end{cases}\\
\implies &\max x-\min y ≥x-y≥ \min x-\max y \\
\implies & a-d≥x-y≥b-c \end{align*}
Hence you get,
$$-2\le \cos x-\sin x\le 2$$
However, you can also write
$${1}\ge-\sin x\ge -1\\
\implies
2\ge1+\cos x\ge\cos x-\sin x\ge \cos x-1\ge-2\\
\implies -2\le \cos x-\sin x\le 2$$
But, more rigorous way is:
$$-\sqrt {a^2+b^2}≤a\cos x+b\sin x≤\sqrt {a^2+b^2}$$
Because, $\cos x-\sin x=-2$ and $\cos x-\sin x=2$ is not possible.
A: Never subtract two inequalities which are in the same direction
It some time you get right result and wrong other time. So subtraction of inequalities is a spurious exercise as the subtraction is non-commutative. Instead one can add two inequalities which are in the same direction to get correct statement all the times.
As $-1 \le \sin x \le 1, -1 \le \cos x\le 1$, we can write
$\sin x \le 1$ and $-1\le \cos x$ you can add these two to get
$$\sin x -1 \le 1+\cos x \implies \sin x-\cos x \le 2.....(1)$$
Similarly, we have $\sin x \ge -1 $ and $1 \ge \cos x$ adding these two. we get
$$\sin x+1 \ge \cos x-1 \implies \sin x-\cos x \ge -2.....(2)$$
