Consider $\sin^{-1}(\sin(x))$ for $x\in[\pi/2 , 3\pi/2]$ . Clearly,
$$\pi/2 \le x \le 3\pi/2\tag{1}$$
Subtracting $\pi$, we get:
$$-\pi/2 \le x - \pi \le \pi/2$$
Now, the term $(x-\pi)$ had come in the range of $\sin^{-1}(x)$. Hence,
$\sin^{-1}(\sin(x))=x-\pi$ for all $x\in[\pi/2,3\pi/2]\tag{2}$
Once more consider the inequation (1): $$\pi/2 \le x \le 3\pi/2$$
Multiplying this by $(-1)$, we get;
$$-\pi/2 \ge -x \ge -3\pi/2$$
Adding $\pi$ in this gives:
$$\pi/2 \ge \pi-x \ge -\pi/2;$$ which can be re-written as;
$$-\pi/2 \le \pi-x \le π/2$$
Now, the term $(\pi -x)$ has come within range of $\sin^{-1}(\sin(x))$. Hence,
$\sin^{-1}(\sin(x)) = \pi -x$ for all $x\in[\pi/2,3\pi/2]\tag{3}$
But (2) and (3) are contradictory. Can anyone tell whether $\sin^{-1}(\sin(x)) = x-\pi$ or $\pi-x$ and also explain why.
With the first method we have
$$\frac \pi 2 \le x \le \frac 3 2 \pi \implies -\frac \pi 2 \le x-\pi \le \frac \pi 2 $$
then we can conclude that
$$\sin^{-1}(\sin (x-\pi))=x-\pi$$
but not $$\color{red}{\sin^{-1}(\sin(x))=x-\pi}$$
To proceed by this way, we can observe that $$\sin (x-\pi) = -\sin (\pi-x)= -\sin x$$
and since $\forall \theta \in \mathbb R$ we have $$\sin^{-1}(-\sin \theta)= -\sin^{-1}(\sin \theta)$$ we can conclude that
$$\sin^{-1}(-\sin x)=x-\pi \implies \sin^{-1}(\sin x)=\pi-x$$