Isn't the book wrongly taking $\sin^{-1}$ on both sides here? Question:
If $\sin(\pi\cos\theta)=\cos(\pi\sin\theta)$, then show that $\theta=\pm\frac{1}{2}\sin^{-1}\frac{3}{4}$.
My book's solution:
$$\sin(\pi\cos\theta)=\cos(\pi\sin\theta)$$
$$\sin(\pi\cos\theta)=\sin(\frac{\pi}{2}\pm\pi\sin\theta)\ [\text{Formula:}\cos\theta=\sin(\frac{\pi}{2}\pm\theta)]$$
$$\sin^{-1}(\sin(\pi\cos\theta))=\sin^{-1}(\sin(\frac{\pi}{2}\pm\pi\sin\theta))...(i)$$
$$\pi\cos\theta=\frac{\pi}{2}\pm\pi\sin\theta...(ii)$$
$$\cos\theta=\frac{1}{2}\pm\sin\theta$$
$$\cos\theta\pm\sin\theta=\frac{1}{2}$$
$$\cos^{2}\theta\pm2\sin\theta\cos\theta+\sin^{2}\theta=\frac{1}{4}$$
$$1\pm\sin2\theta=\frac{1}{4}$$
$$\sin2\theta=\pm\frac{3}{4}$$
$$\sin^{-1}(\sin2\theta)=\sin^{-1}(\pm\frac{3}{4})$$
$$2\theta=\pm\sin^{-1}(\frac{3}{4})$$
$$\theta=\pm\frac{1}{2}\sin^{-1}(\frac{3}{4})\ \text{(showed)}$$
This solution is good and all, but if we input the value of $\theta$ in line (i) we will see something interesting:-
$$\sin^{-1}(\sin(\pi\cos\theta))=\sin^{-1}(\sin(\frac{\pi}{2}\pm\pi\sin\theta))$$
$$[\text{Let's input $\theta=\frac{1}{2}\sin^{-1}(\frac{3}{4})$}]$$
$$\sin^{-1}(\sin(164.058809^{\circ}))=\sin^{-1}(\sin(164.058809^{\circ})$$
$$164.058809^{\circ}=164.058809^{\circ}$$
This is what my book did essentially. However, isn't $164.058809^{\circ}$ outside the restricted range of $\sin^{-1}(x)$: $[\frac{\pi}{2},-\frac{\pi}{2}]$? So, is the line (ii) in the solution of the book valid?
 A: *

*Even though the spirit of the exercise is really asking you to
solve the given
equation (in other words, for the final line to be equivalent to
the first line), it technically presents an if-then statement, so
let's not quibble about the author squaring both sides of the
equation without justification, thereby potentially creating
extraneous solutions. Let's also not quibble about them needlessly
applying $\cos\theta=\sin\left(\frac{\pi}{2}\pm\theta\right)$
instead of simply
$\cos\theta=\sin\left(\frac{\pi}{2}-\theta\right).$
However, your book is blithely discarding solutions in the the
fourth and eleventh lines, so those steps are invalid; for example

*

*$$\arcsin(\sin(\pi\cos\theta)) \not\equiv \pi\cos\theta$$
(counterexample: $\frac\pi6)$
and

*

*$$\arcsin(\sin2\theta)  \not\equiv 2\theta$$
(counterexample: $\frac\pi3).$




*As for your main question: the first three lines of the given solution are equivalent to one another, and $\arcsin\left(\sin\left(\pi\cos\theta\right)\right)$ accepts all real values of $\theta.$

This is the general solution:
$$\sin(\pi\cos\theta)=\cos(\pi\sin\theta)\\
\cos\left(\frac\pi2-\pi\cos\theta\right)=\cos(\pi\sin\theta)\\
\frac\pi2-\pi\cos\theta=2n\pi\pm\pi\sin\theta\\
\cos\theta\pm\sin\theta=\frac12-2n\\
\sqrt2\cos\left(\theta\mp\frac\pi4\right)=\frac12-2n\\
\cos\left(\theta\mp\frac\pi4\right)=\frac1{2\sqrt2}-\sqrt2n\\
=\frac1{2\sqrt2}\\
\theta\mp\frac\pi4=2k\pi\pm\arccos\left(\frac1{2\sqrt2}\right)\\
\theta=\left(8k\pm1\right)\frac\pi4\pm\arccos\left(\frac1{2\sqrt2}\right).$$
N.B. The two $\pm$ signs above are independent and not to be combined; in other words, there are four—not two—independent general solutions. To be clear: \begin{align}\theta=&\left(8k\pm1\right)\frac\pi4+\arccos\left(\frac1{2\sqrt2}\right)\\&\text{or}\:\: \left(8k\pm1\right)\frac\pi4-\arccos\left(\frac1{2\sqrt2}\right).\end{align}
A: The reasoning shown in the book is incorrect. Indeed, were it correct, then we could make the following deduction.
$$\sin(\pi\cos\theta)=\cos(\pi\sin\theta)$$
$$\sin(\pi\cos\theta)=\sin(\frac{\pi}{2}+\pi\sin\theta)$$
This is exactly the same as your step (i), but with a $+$, rather than a $\pm$. That's perfectly fine, since $\cos\theta=\sin(\frac{\pi}{2}+\theta)$ is a correct identity for any $\theta$.
$$\sin^{-1}(\sin(\pi\cos\theta))=\sin^{-1}(\sin(\frac{\pi}{2}+\pi\sin\theta))$$
$$\pi\cos\theta=\frac{\pi}{2}+\pi\sin\theta$$
This is the dodgy step. In your example, it works out for the author, but now the statement is genuinely incorrect.
$$\cos\theta=\frac{1}{2}+\sin\theta$$
$$\cos\theta-\sin\theta=\frac{1}{2}$$
$$\cos^{2}\theta-2\sin\theta\cos\theta+\sin^{2}\theta=\frac{1}{4}$$
$$1-\sin2\theta=\frac{1}{4}$$
$$\sin2\theta=\frac{3}{4}$$
$$\sin^{-1}(\sin2\theta)=\sin^{-1}(\frac{3}{4})$$
(assuming that $\theta$ lies in $[-\pi,\pi]$)
$$2\theta=\sin^{-1}(\frac{3}{4})$$
$$\theta=\frac{1}{2}\sin^{-1}(\frac{3}{4})\ \Box$$
But this is now incorrect, since $\theta = -\frac12\sin^{-1}\frac34$ is also a solution.
