\(\sin^{-1}\) always gives an angle from \(-\dfrac{\pi}{2}\) to \(\dfrac{\pi}{2}\): an angle on the right half of the unit circle. So \(\sin^{-1}(\sin x) = x\) only when \(x\) itself is in that range. For any other \(x\), the answer is the angle in that range with the same sine. For \(x = 2\) it is \(\pi - 2 \approx 1.14\).
The trap
"\(\sin^{-1}\) undoes \(\sin\), so \(\sin^{-1}(\sin x) = x\) for every \(x\)."
It is true only for \(-\dfrac{\pi}{2} \le x \le \dfrac{\pi}{2}\). Here \(x\) is in radians, and \(2\) is outside that range.
Principal value
\(\sin^{-1} y\) is the one angle \(\theta\) with \(\sin\theta = y\) and \(-\dfrac{\pi}{2} \le \theta \le \dfrac{\pi}{2}\).
On the right half of the circle every height from \(-1\) to \(1\) comes exactly once, so there is exactly one such angle.
Why the answer is \(\pi - 2\)
Take the circle of radius \(1\). The point \(P\) is at an angle of \(2\) radians (about \(115^\circ\)) from the positive \(x\)-axis, and its height is \(\sin 2 \approx 0.909\). Since \(2 > \dfrac{\pi}{2}\), \(P\) is on the left half, so \(2\) cannot be the answer.
A half turn is \(\pi\), so the angle from the radius to \(P\) on to the negative \(x\)-axis is \(\pi - 2\). Take the mirror image in the vertical axis: \(P\) lands on \(Q\), at an angle of \(\pi - 2\) from the positive \(x\)-axis. A mirror image keeps the height, so \(\sin(\pi - 2) = \sin 2\).
\(\pi - 2 \approx 1.14\) lies between \(-\dfrac{\pi}{2}\) and \(\dfrac{\pi}{2}\), so
\[ \sin^{-1}(\sin 2) = {\pi - 2}. \]

The graph of \(y = \sin^{-1}(\sin x)\) is a zigzag
Let \(x\) grow from \(0\). The point \(P\) goes round the circle, and \(Q\) stays on the right half at the same height as \(P\); the angle of \(Q\) is \(y = \sin^{-1}(\sin x)\). From \(0\) to \(\dfrac{\pi}{2}\), \(P\) is on the right half, so \(Q\) is \(P\) and \(y = x\). From \(\dfrac{\pi}{2}\) to \(\dfrac{3\pi}{2}\), \(P\) is on the left half and \(Q\) slides down the right half: \(y = \pi - x\). From \(\dfrac{3\pi}{2}\) to \(\dfrac{5\pi}{2}\), \(P\) is on the right half again, one full turn later: \(y = x - 2\pi\). The pattern repeats for every turn, and for negative \(x\) too.

Every piece crosses the \(x\)-axis at a multiple of \(\pi\), with slope \(1\) or \(-1\). The graph meets the dashed line \(y = x\) only from \(-\dfrac{\pi}{2}\) to \(\dfrac{\pi}{2}\).
Careful
Do not cancel \(\sin^{-1}\) against \(\sin\). The other order is different: \(\sin(\sin^{-1} y) = y\) holds for every \(y\) from \(-1\) to \(1\), but \(\sin^{-1}(\sin x) = x\) holds only for \(x\) from \(-\dfrac{\pi}{2}\) to \(\dfrac{\pi}{2}\). Always check that your answer lies in that range.
Solved example
Find \(\sin^{-1}(\sin 10)\).
Where is \(10\)? \(\dfrac{5\pi}{2} \approx 7.85\) and \(\dfrac{7\pi}{2} \approx 11.0\), so \(10\) lies between \(\dfrac{5\pi}{2}\) and \(\dfrac{7\pi}{2}\).
The piece. There the graph crosses the \(x\)-axis at \(3\pi\) and falls with slope \(-1\): \(y = 3\pi - x\).
Check. \(3\pi - 10 \approx -0.58\), which lies between \(-\dfrac{\pi}{2}\) and \(\dfrac{\pi}{2}\).
\(\sin^{-1}(\sin 10) = 3\pi - 10\)
Key formulas
\(\sin^{-1}(\sin x) = x\) exactly when \(-\dfrac{\pi}{2} \le x \le \dfrac{\pi}{2}\) (both ends included). For any other \(x\), find the piece on which \(x\) lies and use its line:
\[ \sin^{-1}(\sin x) = \begin{cases} -\pi - x, & -\frac{3\pi}{2} \le x \le -\frac{\pi}{2}\\[0pt] x, & -\frac{\pi}{2} \le x \le \frac{\pi}{2}\\[0pt] \pi - x, & \frac{\pi}{2} \le x \le \frac{3\pi}{2}\\[0pt] x - 2\pi, & \frac{3\pi}{2} \le x \le \frac{5\pi}{2}\\[0pt] 3\pi - x, & \frac{5\pi}{2} \le x \le \frac{7\pi}{2} \end{cases} \]
Practice set
Easy to hard. For each, find where \(x\) lies first. Try each one before you open its answer.
Quiz from the Short. What is \(\sin^{-1}(\sin(-2))\)? (A) \(-2\) (B) \(2 - \pi\) (C) \(\pi - 2\).
Show answer
(B) \(2 - \pi\). \(-2\) lies between \(-\dfrac{3\pi}{2}\) and \(-\dfrac{\pi}{2}\), on the piece \(y = -\pi - x\): \(-\pi + 2 = 2 - \pi \approx -1.14\). (A) \(-2\) is the trap: it is outside the range. (C) has the wrong sign: \(\sin(\pi - 2) = \sin 2\), but \(\sin(-2) = -\sin 2\).
Find \(\sin^{-1}(\sin 3)\).
Show answer
\(\pi - 3\). \(3\) lies between \(\dfrac{\pi}{2}\) and \(\dfrac{3\pi}{2}\), on the piece \(y = \pi - x\). \(\pi - 3 \approx 0.14\) is in the range.
Find \(\sin^{-1}\left(\sin \dfrac{5\pi}{6}\right)\).
Show answer
\(\dfrac{\pi}{6}\). \(\dfrac{5\pi}{6}\) lies between \(\dfrac{\pi}{2}\) and \(\dfrac{3\pi}{2}\): \(\pi - \dfrac{5\pi}{6} = \dfrac{\pi}{6}\).
Find \(\sin^{-1}(\sin 5)\).
Show answer
\(5 - 2\pi\). \(5\) lies between \(\dfrac{3\pi}{2} \approx 4.71\) and \(\dfrac{5\pi}{2} \approx 7.85\), on the piece \(y = x - 2\pi\). \(5 - 2\pi \approx -1.28\) is in the range.
Find \(\sin^{-1}(\sin 7)\).
Show answer
\(7 - 2\pi\). \(7\) is on the same piece as \(5\): \(7 - 2\pi \approx 0.72\).
Find all \(x\) from \(0\) to \(2\pi\) for which \(\sin^{-1}(\sin x) = \pi - x\).
Show answer
\(\dfrac{\pi}{2} \le x \le \dfrac{3\pi}{2}\). \(y = \pi - x\) is the piece from \(\dfrac{\pi}{2}\) to \(\dfrac{3\pi}{2}\), both ends included. Below \(\dfrac{\pi}{2}\) the value is \(x\), and above \(\dfrac{3\pi}{2}\) it is \(x - 2\pi\); neither equals \(\pi - x\) there.