Why does $\sin^{-1}(\sin(\pi))$ not equal $\pi$

The sine function lacks the property of injectivity, which means that it sometimes happens that $\sin x= \sin y$ even though $x\ne y$; for example $\sin 0 = \sin \pi$ even though $0\ne \pi$. To have a full inverse, a function $f$ must be injective: it must have $f(x)=f(y)$ only when $x=y$. Otherwise it is ambiguous, for each case where $f(x) = f(y)$ but $x\ne y$, whether the inverse function $f^{-1}$ at $f(x)$ should yield $x$ or $y$. There are usually many possible choices for $f^{-1}$.

Consider a simpler example, where $f(x) = x^2$. This function is not injective, since for example $f(7) = f(-7)$. If we want an inverse for $f$, we need to choose whether $f^{-1}(49)$ will be $7$ or $-7$, and similarly for almost every other value of $f$. Usually in this case we adopt the rule that whenever there is a choice, $f^{-1}(x)$ is always positive. When we do this we get exactly the square root function $\sqrt x$. But note that $\sqrt x$ is not a full inverse for $x^2$: We do have $f(f^{-1}(x)) = x$ whenever this is defined, but not $f^{-1}(f(x)) = x$, because for example $f^{-1}(f(-7)) = \sqrt{(-7)^2} = \sqrt{49} = 7$. Here we have $f^{-1}(f(x)) = x$ only for $x\ge 0$.

We could chose a different partial inverse for $f$. Say $f^{-1}(x) = -\sqrt x$. This is a perfectly good partial inverse for $f$. Again we have $f(f^{-1}(x)) = \left(-\sqrt x\right)^2 = x$ for all $x$ for which the expression is well defined, but this time we have $f^{-1}(f(x)) = x$ only for $x\le 0$; for example $f(f^{-1}(49)) = f(-7) = 49$ and $f^{-1}(f(-7)) = f^{-1}(49) = -7,$ but $f^{-1}(f(7)) = f^{-1}(49) = -7\ne 7.$

Or we could choose a still more unusual inverse for $f(x)$. Say that $f^{-1}(x)$ is $\sqrt x$ when the integer part of $x$ is even, and $-\sqrt x$ when the integer part of $x$ is odd. Then we have $f^{-1}(f(x)) = x$ whenever $x\ge 0$ and its integer part is even, or whenever $x\lt 0$ and its integer part is odd, but not otherwise. So for example $f^{-1}(f(8.5)) = 8.5$, but $f^{-1}(f(7.5)) = -7.5 \ne 7.5$.

So the set of values $x$ for which $f^{-1}(f(x)) = x$ will depend on how we choose to define the inverse function; when $f$ is not injective, there may be many reasonable ways to define the inverse.

With $\sin$ we have the question of how to define the inverse. We can't simply say that $\sin^{-1} y$ is "the" value $x$ for which $\sin x = y$, because there are many such $x$ for each $y$. We usually choose the definition that says that $\sin^{-1} y$ is the value $x$ for which $\sin x = y$ and $-\frac\pi2 \le x \le \frac\pi2$; this definition does select a unique $x$, because the sine function is injective for $x$ between $-\frac\pi2$ and $\frac\pi2$.

For this definition of $\sin^{-1}$, we have the property that $\sin(\sin^{-1}(x)) = x$ everywhere the left-hand side is defined, and $\sin^{-1}(\sin x) = x$ exactly when $-\frac\pi2 \le x \le \frac\pi2$.


Since, for any $y \in [-1,1]$, several different $x$ have $\sin(x)=y$, either $\sin^{-1}(y)$ is multivalued and so not a function, or you need to restrict its range by taking a principal value. Usually the later choice is made, with $-\pi/2 \le \sin^{-1}(y) \le \pi/2$.

So in answer to your title question: $ \sin^{-1} (\sin (\pi)) \not = \pi$ because $\pi \gt \pi/2$ and in fact $\sin^{-1} (\sin (\pi)) = \sin^{-1} (0) = 0$.

$\sin^{-1} (\sin (x)) = x $ when $-\pi/2 \le x \le \pi/2$.