# About proof: $\cot^{-1}\left(\frac{\sqrt{1+\sin x}+\sqrt{1-\sin x}}{\sqrt{1+\sin x}-\sqrt{1-\sin x}}\right)=\frac x2$

I have the following question:

Prove that: $$\cot^{-1}\Biggl(\frac{\sqrt{1+\sin x} + \sqrt{1-\sin x}}{\sqrt{1+\sin x} - \sqrt{1-\sin x}}\Biggl) = \frac x2, \ x \in \biggl(0, \frac \pi4\biggl)$$

The solution: My question is about the second step (i.e., highlighted). We know that it has came from the following resolution: $$\sqrt{1\pm \sin x} = \sqrt{\sin^2\frac x 2 + \cos^2\frac x 2 \pm2\sin\frac x 2\cos\frac x 2} = \pm \biggl( \cos\frac x 2 \pm \sin\frac x 2 \ \biggl)$$

I've included the $$\pm$$ symbol in accordance with the standard definition of square root. The above solution uses the positive resolution (i.e., $$\cos\frac x 2 - \sin\frac x 2$$) for $$\sqrt{1- \sin x}$$. But, if I use the negative one, then the result changes. The sixth step changes to: $$\cot^{-1}\biggl(\tan\frac x 2\biggl) = \cot^{-1}\Biggl(\cot\left(\frac \pi 2 - \frac x 2\right)\Biggl)$$

which yield the result: $$\frac \pi 2 - \frac x 2$$

Mathematically, this result is different from that provided in the RHS of question.

Is the question statement wrong or I've been hacked up?

• @Winther Ok, I edited the question. Dec 1, 2018 at 13:42
• The range $x\in(0,\pi/4)$ has to be kept in mind while removing the square root. Dec 1, 2018 at 13:55
• It’s already given x belong to 0 to pi/4. That means x is positive. Which also means sinx + cos is positive Dec 2, 2018 at 5:17
• The authors use a specific range to get positive numbers. They don't spell it out but they DO mean PRINCIPAL ROOTS (square root values are positive). They also imply real numbers in this problem. And no, the result doesn’t change if “standard” square roots are extracted: You just get two values. Yet nonsense may still arise: $\sqrt{1}=1;\;\sqrt{1}=-1$. Hence, $-1=+1$. Non-principal square root values should be combined properly! Jan 21, 2019 at 7:44
• Note that Arccot may have infinite number of values since $cot$ is periodic. So we need to restrict its range to avoid dragging around infinite number of values. Hence, we define $\cot^{-1}$ range from $0$ to $\pi$ for convenience (to make $\cot^{-1}$ continuous). Hope you can figure out everything checks out for negative values too if root values are combined properly! And the range of $\cot^{-1}$ can also be defined –pi/2 to +pi/2 to deal with negative values (not needed here). +1 for figuring out roots aren’t principal roots and confusion is possible if a student is not a rote-learner. Jan 21, 2019 at 7:47

Rationalize the numerator to find

$$f(x)=\dfrac{1+|\cos x|}{\sin x}$$

Now if $$\cos x\ge0,$$ $$f(x)=\cot\dfrac x2$$

$$\cot^{-1}f(x)=?$$

Else $$f(x)=\dfrac{1-\cos x}{\sin x}=\tan\dfrac x2$$

Now $$\cot^{-1}f(x)=\dfrac\pi2-\tan^{-1}f(x)=?$$

As StubbornAtom mentioned in comment, for $$x \in \biggl(0, \frac \pi4\biggl)$$, the square root is: $$\sqrt{1-\sin x}=\cos \frac x2-\sin \frac x2,$$ because: $$\cos \frac x2-\sin \frac x2>0.$$ If, for example, $$x \in \biggl(\frac \pi2, \pi\biggl)$$, the square root would be: $$\sqrt{1-\sin x}=\sin\frac x2-\cos \frac x2,$$ because: $$\sin \frac x2-\cos \frac x2>0.$$

Addendum. Note that $$\pm$$ is placed to make the number positive and it does not imply one gets positive and negative values for the square root. Here is another way to write the same equality: $$\sqrt{1-\sin x}=\left|\cos \frac x2-\sin \frac x2\right|=\begin{cases}+\left(\cos \frac x2-\sin \frac x2\right), \cos \frac x2-\sin \frac x2\ge 0 \\ -\left(\cos \frac x2-\sin \frac x2\right), \cos \frac x2-\sin \frac x2< 0 \\ \end{cases}.$$

• Why not $\sqrt{1-\sin x}= - \bigl( \cos \frac x2-\sin \frac x2 \bigl)$? Because $\sqrt9 = \pm3$ Dec 2, 2018 at 2:28
• Firstly, $0\le 1-\sin x\le 2<9$. Secondly, $\sqrt{9}=3$ and $\pm \sqrt{9}=\pm 3$. Thirdly, $0<x<\pi/4$. For example, when $x=\pi/6$, $\sqrt{1-\sin (\pi/6)}=1/\sqrt{2}=\cos (\pi/12)-\sin (\pi/12)=\frac{1+\sqrt{3}}{2\sqrt{2}}-\frac{\sqrt{3}-1}{2\sqrt{2}}$. Fourthly, for $x=5\pi/6>\pi/2>\pi/4$, we get what you are saying: $\sqrt{1-\sin (5\pi/6)}=1/\sqrt{2}=\sin (5\pi/12)-\cos (5\pi/12)=\frac{1+\sqrt{3}}{2\sqrt{2}}-\frac{\sqrt{3}-1}{2\sqrt{2}}$. Dec 2, 2018 at 4:20

Note that for $$x\in (0,{\pi \over 4})$$ we have $$\sqrt{1-{\sqrt 2\over 2}}<\sqrt{1-\sin x}<1\\\sqrt{1-{\sqrt 2\over 2}}=\cos {\pi \over 8}-\sin {\pi \over 8}<\cos {x\over 2}-\sin{x\over 2}<1\\-1<\sin {x \over 2}-\cos {x \over 2}<-\sqrt{1-{\sqrt 2\over 2}}$$comparing the range for all $$x\in (0,{\pi \over 4})$$ we obtain$$\sqrt{1-\sin x}=\cos {x\over 2}-\sin{x\over 2}$$and$$\sqrt{1-\sin x}\ne \sin {x\over 2}-\cos{x\over 2}$$

We see that $$\frac{\sqrt{1+\sin x} + \sqrt{1-\sin x}}{\sqrt{1+\sin x} - \sqrt{1-\sin x}}$$ $$= \sqrt{(\frac{\sqrt{1+\sin x} + \sqrt{1-\sin x}}{\sqrt{1+\sin x} - \sqrt{1-\sin x}})^2}$$ $$= \sqrt{\frac{1+\sin x +1-\sin x + 2\cdot\sqrt{1-\sin^2 x}}{1+\sin x +1-\sin x -2\cdot\sqrt{1-\sin^2 x}}}$$ $$= \sqrt{\frac{1+\cos x}{1-\cos x}}$$ $$= \sqrt{\frac{2\cdot\cos^2\frac{x}{2}}{2\cdot\sin^2\frac{x}{2}}}$$ $$= \cot \frac{x}{2}$$

And hence, $$\cot^{-1} (\frac{\sqrt{1+\sin x} + \sqrt{1-\sin x}}{\sqrt{1+\sin x} - \sqrt{1-\sin x}})$$ $$= \cot^{-1} (\cot \frac{x}{2})$$ $$= \frac{x}{2}$$

Note: as $$x\in [0,\frac{\pi}{4}]$$, $$\sqrt{1-\sin x} \le \sqrt{1+\sin x}$$. And hence $$0\le\frac{\sqrt{1+\sin x} + \sqrt{1-\sin x}}{\sqrt{1+\sin x} - \sqrt{1-\sin x}}$$

• Yet another way of solving the problem. But, you forgot to mention $\pm$ in sixth line before cot x/2 Jan 21, 2019 at 15:10