<s>[INST] Trig identities analogous to $\tan(\pi/5)+4\sin(\pi/5)=\sqrt{5+2\sqrt{5}}$ The following trig identities have shown up in various questions on MSE:
$$-\tan\frac{\pi}{5}+4\sin\frac{2\pi}{5}=\tan\frac{\pi}{5}+4\sin\frac{\pi}{5}=\sqrt{5+2\sqrt{5}}$$
$$-\tan\frac{2\pi}{7}+4\sin\frac{3\pi}{7}=-\tan\frac{\pi}{7}+4\sin\frac{2\pi}{7}=\sqrt{7}$$
$$\tan\frac{\pi}{11}+4\sin\frac{3\pi}{11}=\tan\frac{3\pi}{11}+4\sin\frac{2\pi}{11}=\sqrt{11}$$
$$\tan\frac{6\pi}{13}-4\sin\frac{5\pi}{13}=\tan\frac{2\pi}{13}+4\sin\frac{6\pi}{13}=\sqrt{13+2\sqrt{13}}$$
Does anyone know of any analogous identities for larger primes? I have not been able to find anything similar for $p=17$ or $p=19$.
(I am not asking for proofs of the above equations.)
 [/INST] The case of multiples of $\pi/11$ actually involves five "symmetrically equivalent" forms:
$4\sin(5\pi/11)-\tan(2\pi/11)=\sqrt{11}$
$4\sin(\pi/11)+\tan(4\pi/11)=\sqrt{11}$
$4\sin(4\pi/11)-\tan(5\pi/11)=-\sqrt{11}$
$4\sin(2\pi/11)+\tan(3\pi/11)=\sqrt{11}$
$4\sin(3\pi/11)+\tan(\pi/11)=\sqrt{11}$
All are derivable from the quadratic Gauss sum corresponding to the prime number $11$.
These are manifestations of the more compact, "symmetric" relation
$\color{blue}{4\sin(3\theta)-\tan(\theta)=(k|11)\sqrt{11}}$
where $\theta=(2k\pi/11)$ and $(k|11)$ is the Legendre symbol of residue $k$ modulo $11$, with the specific equations quoted above representing $k=1,2,3,4,5$ respectively.
There is a hidden feature in the equation rendered in blue above.  In addition to multiples of $\pi/11$ we get one more value of $\theta$ between $0$ and $\pi$ where the function on the left evaluates to $+\sqrt{11}$.  Correspondingly there is an additional value of $\theta$ between $\pi$ and $2\pi$, having the same cosine, for which the function value is $-\sqrt{11}$.  Now, suppose we plug in $x=2\cos\theta$.  Squaring the blue equation, expressing the quantities in terms of $x$ and clearing fractions yields an eighth-degree polynomial equation, which factors as follows:
$(x^5+x^4-4x^3-3x^2+3x+1)(x^3-x^2-x-1)=0$
The quintic factor is just the minimal polynomial for $2\cos(2k\pi/11)$ for $k\in\{1,2,3,4,5\}$.  The cubic factor, containing the "extra" roots for $\theta$, has been coupled into the quintic one through the Gauss sum and the "sine-tangent relations" derived from it.
In 2014 the regular hendecagon was discovered to be neusis constructible.  The authors "miraculously" found that the neusis construction, which requires finding the roots of the quintic factor given above, can be rendered in terms of cubic roots for which a neusis construction is guaranteed.  It turns out that in the construction found by the authors, the distance from the pole of the neusis (a fixed point through which the marked ruler passes) to the straight line that includes one of the marks satisfies the equation
$a^3+a^2+a-1=0.$
This corresponds exactly to the reciprocal of the root of $x^3-x^2-x-1=0$, the latter equation being the coupled cubic factor emerging above from the Gauss sum.  The construction is still a bit of a miracle, but we see that its cubic roots do not just appear out of nowhere.  They are derived from the Gauss sum!
</s>