Prove that: \[ \tan x \tan \left(x+\frac{\pi}{3}\right) +\tan x \tan \left(x-\frac{\pi}{3}\right) +\tan \left(x+\frac{\pi}{3}\right) \tan \left(x-\frac{\pi}{3}\right) =-3 \]
Solution
Let
\[
\tan x = t
\]
Using the formula
\[
\tan(A\pm B)
=
\frac{\tan A \pm \tan B}{1 \mp \tan A \tan B}
\]
and
\[
\tan \frac{\pi}{3}=\sqrt{3}
\]
we get
\[
\tan\left(x+\frac{\pi}{3}\right)
=
\frac{t+\sqrt{3}}{1-\sqrt{3}t}
\]
\[
\tan\left(x-\frac{\pi}{3}\right)
=
\frac{t-\sqrt{3}}{1+\sqrt{3}t}
\]
Now consider
\[
S=
t\cdot\frac{t+\sqrt{3}}{1-\sqrt{3}t}
+t\cdot\frac{t-\sqrt{3}}{1+\sqrt{3}t}
+\frac{t+\sqrt{3}}{1-\sqrt{3}t}
\cdot
\frac{t-\sqrt{3}}{1+\sqrt{3}t}
\]
Take the common denominator:
\[
(1-\sqrt{3}t)(1+\sqrt{3}t)
=
1-3t^2
\]
Then
\[
S=
\frac{
t(t+\sqrt{3})(1+\sqrt{3}t)
+t(t-\sqrt{3})(1-\sqrt{3}t)
+(t+\sqrt{3})(t-\sqrt{3})
}
{1-3t^2}
\]
Expand each term:
\[
t(t+\sqrt{3})(1+\sqrt{3}t)
=
3t^3+\sqrt{3}t^2+t^2+\sqrt{3}t
\]
\[
t(t-\sqrt{3})(1-\sqrt{3}t)
=
3t^3-\sqrt{3}t^2+t^2-\sqrt{3}t
\]
\[
(t+\sqrt{3})(t-\sqrt{3})
=
t^2-3
\]
Adding,
\[
=6t^3+3t^2-3
\]
\[
=3(2t^3+t^2-1)
\]
Using factorization,
\[
6t^3+3t^2-3
=
-3(1-3t^2)
\]
Therefore,
\[
S=
\frac{-3(1-3t^2)}{1-3t^2}
\]
\[
S=-3
\]
Hence proved.