Let x=cosθ,so that cos−1x=θ
Now, tan−1(√1+x−√1−x√1+x+√1−x)
=tan−1(√1+cosθ−√1−cosθ√1+cosθ+√1−cosθ)
=tan−1(√2cosθ2−√2sinθ2√2cosθ2+√2sinθ2)
=tan−1(cosθ2−sinθ2cosθ2+sinθ2)
, =tan−1(1−tanθ21+tanθ2)
=tan−1(tanπ4−θ2)=π4−θ2
(∵−1√2≤x≤1⇒−1√2≤cos θ≤1⇒ cos 3π4≤cos θ≤cos 0⇒3π4≤θ≤0⇒0≤θ≤3π4⇒−3π8≤−θ2≤0⇒π4+−3π8≤π4+−θ2≤π4⇒−π4≤π4−θ2≤π4)
=π4−12cos−1x