# Exact values of $\cos(2\pi/7)$ and $\sin(2\pi/7)$

What are the exact values of $\cos(2\pi/7)$ and $\sin(2\pi/7)$ and how do I work it out?

I know that $\cos(2\pi/7)$ and $\sin(2\pi/7)$ are the real and imaginary parts of $e^{2\pi i/7}$ but I am not sure if that helps me...

There are various ways of construing and attacking your question.

At the most basic level: it's no problem to write down a cubic polynomial satisfied by $\alpha = \cos(2 \pi/7)$ and hit it with Cardano's cubic formula. For instance, if we put $z = \zeta_7 = e^{2 \pi i/7}$, then $2\alpha = z + \overline{z} = z + \frac{1}{z}$. A little algebra leads to the polynomial $P(t) = t^3 + \frac{1}{2} t^2 - \frac{1}{2}t - \frac{1}{8}$ which is irreducible with $P(\alpha) = 0$. (Note that the noninteger coefficients of $P(t)$ imply that $\alpha$ is not an algebraic integer. In this respect, the quantity $2 \alpha$ is much better behaved, and it is often a good idea to work with $2 \alpha$ instead of $\alpha$.) To see what you get when you apply Cardano's formula, consult the other answers or just google for it: for instance I quickly found this page, among many others (including wikipedia) which does it.

The expression is kind of a mess, which gives you the idea that having these explicit radical expressions for roots of unity (and related quantities like the values of the sine and cosine) may not actually be so useful: if I wanted to compute with $\alpha$ (and it has come up in my work!) I wouldn't get anything out of this formula that I didn't get from $2 \alpha = \zeta_7 + \zeta_7^{-1}$ or the minimal polynomial $P(t)$.

On the other hand, if you know some Galois theory, you know that the Galois group of every cyclotomic polynomial is abelian, so there must exist a radical expression for $\zeta_n$ for any $n \in \mathbb{Z}^+$. (We will usually not be able to get away with only repeatedly extracting square roots; that could only be sufficient when Euler's totient function $\varphi(n)$ is a power of $2$, for instance, so not even when $n = 7$.) From this perspective, applying the cubic formula is a big copout, since there is no analogous formula in degree $d > 4$: the general polynomial of such a degree cannot be solved by radicals...but cyclotomic polynomials can.

So what do you do in general? The answer was known to Gauss, and involves some classical algebra -- resolvents, Gaussian periods, etc. -- that is not very well remembered nowadays. In fact I have never gone through the details myself. But I cast around on the web for a while looking for a nice treatment, and I eventually found this writeup by Paul Garrett. I recommend it to those who want to learn more about this (not so useful, as far as I know, but interesting) classical problem: his notes are consistently excellent, and have the virtue of concision (which I admire especially for lack of ability to produce it myself).

• May I also point out this paper (I've forgotten if I learned of it from here or MO); it's quite nice! – J. M. isn't a mathematician May 11 '11 at 9:15
• @J.M. How do you manage posting the link to "this paper" here? In similar situations I have tried but failed. – Américo Tavares May 11 '11 at 11:01
• @Américo: The syntax isn't too hard; in this case [this paper](http://www.jstor.org/pss/27643106) produces the required result. – J. M. isn't a mathematician May 11 '11 at 11:08
• Thanks! It turns out the the problem was originally to find the exact values of the cos and sin of $2\pi/5$, but was changed at the last minute. They have since realised that this problem is too hard for us 1st semester maths students, and told us if we can find the polynomial P(t) (as above), it will be enough. – Hannesh May 12 '11 at 19:58
• @Hannesh: Ah, that is certainly easier. If you are familiar with the usual ruler-compass construction for the regular pentagon, it's a nice exercise to figure out via coordinate geometry the values of $\cos 72^\circ$ and $\sin 72^\circ$... – J. M. isn't a mathematician May 14 '11 at 3:26

case = {7},

first, set $\zeta^k_7$ as seventh roots of unity, using both Euler and De Moiver Formula, $\zeta^{k}_{7}=\text{e}^{\frac{2ki\pi}{7}}=\cos\frac{2k\pi}{7} \pm i\sin\frac{2k\pi}{7}$ hence $\zeta^{-k}_{7}=\text{e}^{\frac{2ki\pi}{7}}=\cos\frac{2k\pi}{7} \mp i\sin\frac{2k\pi}{7}$ hence $$\zeta^{k}_{7}+\zeta^{-k}_{7}=2\cos\frac{2k\pi}{7}$$ $$\zeta^{k}_{7}-\zeta^{-k}_{7}=2i\sin\frac{2k\pi}{7}$$ $$\zeta^{2k}_{7}-2+\zeta^{-2k}_{7}=-4\sin\frac{2k\pi}{7}$$ $$-4\sin\frac{2k\pi}{7}=2\cos\frac{4k\pi}{7}-2$$ $$2i\sin\frac{2k\pi}{7}=\sqrt{2\cos\frac{4k\pi}{7}-2}$$ and some certain properties of $7^{th}$ roots of unity, $$\zeta^{7}_{7}=1$$ $$\zeta^{k}_{7}=\zeta^{k\text{mod}7}_{7}$$ $$\zeta^{-k}_{7}=\zeta^{7-k}_{7}$$ and sum of all $n^{th}$ (where $n$ is more than $1$) roots of unity is $0$, so we can write $$\zeta^{1}_{7}+\zeta^{2}_{7}+\zeta^{3}_{7}+\zeta^{4}_{7}+\zeta^{5}_{7}+\zeta^{6}_{7}+1=0$$ move 1 $$\zeta^{1}_{7}+\zeta^{2}_{7}+\zeta^{3}_{7}+\zeta^{4}_{7}+\zeta^{5}_{7}+\zeta^{6}_{7}=-1$$ hence $$\zeta^{1}_{7}+\zeta^{2}_{7}+\zeta^{3}_{7}+\zeta^{-3}_{7}+\zeta^{-2}_{7}+\zeta^{-1}_{7}=-1$$ set $$t_{k}=\zeta^{k}_{7}+\zeta^{-k}_{7}=2\cos\frac{2k\pi}{7}$$ this simplifies $$t_1+t_2+t_3=-1$$ multiply $t_1$ with $t_2$ , remember $\zeta^{k}_{7}=\zeta^{k\text{mod}7}_{7}$ $$t_{1}=\left(\zeta^{1}_{7}+\zeta^{6}_{7}\right)$$ $$t_{2}=\left(\zeta^{2}_{7}+\zeta^{5}_{7}\right)$$ $$t_{1} t_{2}=\zeta^{3}_{7}+\zeta^{6}_{7}+\zeta^{1}_{7}+\zeta^{4}_{7}$$ $$t_{1} t_{2}=t_{1}+t_{3}$$ similarly $$t_{1} t_{3}=t_{3}+t_{2}$$ $$t_{2} t_{3}=t_{2}+t_{1}$$ so $$t_{1} t_{2}+t_{1} t_{3}+t_{2} t_{3}=-2$$ then, find $t_{1} t_{2} t_{3}$ $$t_{1} t_{2}=t_{1}+t_{3}$$ since $t_1+t_2+t_3=-1$ $$t_{1} t_{2}=-1-t_{2}$$ $$t_{1} t_{2} t_{3}=\left(-1-t_{2}\right)t_{3}$$ $$t_{1} t_{2} t_{3}=-t_{3}-t_{2}t_{3}$$ $$t_{1} t_{2} t_{3}=-t_{3}-t_{2}-t_{1}$$ $$t_{1} t_{2} t_{3}=1$$ then, $$t_1 + t_2 + t_3 = -1$$ $$t_2 + t_3 = -1 -t_1$$ $$t_1 t_2 t_3 = 1$$ $$t_2 t_3 = \frac {1}{t_1} = t^{-1}_1$$ $$t_1 t_2 + t_1 t_3 + t_2 t_3 +2 = 0$$ $$t_1 ( t_2 + t_3 ) + t_2 t_3 +2 = 0$$ $$t_1 ( -1 -t_1 ) + t^{-1}_1 +2 = 0$$ $$-t^2_1 -t_1 + 2 + t^{-1}_1 = 0$$ $$t^3_1 + t^2_1 -2t_1 -1 = 0$$ this statement also applies for other $t_k$ $$t^3+t^2-2-1=0$$ back to the statement that we've set $$t_{k}=2\cos\frac{2k\pi}{7}$$ the roots of the cubic polynomial $$t^3+t^2-2-1=0$$ have the roots cosine, applying Lagrange Resolvent ( if you want a hard way ) or Tartaglia Formula,

$$2\cos\frac{2\pi}{7}=\frac{-1+\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}}{3}$$ $$2\cos\frac{4\pi}{7}=\frac{-1+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}}{3}$$ $$2\cos\frac{6\pi}{7}=\frac{-1+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}}{3}$$ and, notice $t_{k}=\zeta^{k}_{7}+\zeta^{-k}_{7}$ $t_{-k}=\zeta^{-k}_{7}+\zeta^{k}_{7}$ so $t_{1}=t_{1} t_{2}=t_{2} t_{3}=t_{3} t_{4}=t_{3} t_{5}=t_{2} t_{6}=t_{1}$ $$\zeta^{2k}_{7}-2+\zeta^{-2k}_{7}=-4\sin\frac{2k\pi}{7}$$ so $$t_{2k}-2=-4\sin\frac{2k\pi}{7}$$

## $$\sqrt{t_{2k}-2}=2i\sin\frac{2k\pi}{7}$$

$$\sqrt{t_{2}-2}=2i\sin\frac{2\pi}{7}$$ $$\sqrt{t_{3}-2}=2i\sin\frac{4\pi}{7}$$ $$\sqrt{t_{1}-2}=2i\sin\frac{6\pi}{7}$$ substitute each $t_{k}$ $$\sqrt{t_{2}-2}=\sqrt{\frac{-1+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}}{3}-2}$$ $$\sqrt{t_{2}-2}=\sqrt{\frac{-7+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}}{3}}$$ $$\sqrt{t_{2}-2}=\sqrt{\frac{3\left(-7+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}{9}}$$ $$\sqrt{t_{2}-2}=\frac{\sqrt{3\left(-7+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}}{3}$$ $$2i\sin\frac{2\pi}{7}=\frac{\sqrt{3\left(-7+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}}{3}$$ so $$2\sin\frac{2\pi}{7}=\frac{\sqrt{-3\left(-7+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}}{3}$$ $$2\sin\frac{4\pi}{7}=\frac{\sqrt{-3\left(-7+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}}{3}$$ $$2\sin\frac{6\pi}{7}=\frac{\sqrt{-3\left(-7+\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}}{3}$$ now, we are done with

$$\cos\frac{2\pi}{7}=\frac{-1+\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}}{6}$$ $$\cos\frac{4\pi}{7}=\frac{-1+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}}{6}$$ $$\cos\frac{6\pi}{7}=\frac{-1+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}}{6}$$ $$\sin\frac{2\pi}{7}=\frac{\sqrt{-3\left(-7+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}}{6}$$ $$\sin\frac{4\pi}{7}=\frac{\sqrt{-3\left(-7+\frac{-1+\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\frac{-1-\sqrt{-3}}{2}\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}}{6}$$ $$\sin\frac{6\pi}{7}=\frac{\sqrt{-3\left(-7+\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}+\sqrt[3]{\frac{7}{2}\left(1+3\sqrt{-3}\right)}\right)}}{6}$$

$\cos2\pi/7$ is a root of a cubic equation with integer coefficients. You can find that cubic by using $\cos\theta=(1/2)(e^{i\theta}+e^{-i\theta})$, computing the square and the cube, and looking for linear relations, bearing in mind that the $7$ $7$th roots of unity add up to zero. Then you can use Cardano's formula to solve the cubic. I don't know if I recommend actually doing all this - I'm sure you get a mess, although the discriminant will be a perfect square, so you'll get some simplification there.

• Cardano's formula will involve taking the cube root of a complex number, and I am not sure that is any easier than $\left(e^{2\pi i/7} + e^{-2\pi i/7} \right)/2$ – Henry May 11 '11 at 7:47
• Cardano's formula will tell you that the answer is... $\cos \frac{2\pi}{7}$. The existence of the cubic formula does not tell you anything about expressing the root of a cubic in terms of radicals of positive rationals: see en.wikipedia.org/wiki/Casus_irreducibilis . – Qiaochu Yuan May 11 '11 at 7:56

There is a little problem if you want to express $\cos(2\pi/7)$ in terms of radicals. As Gerry Myerson wrote, it is a root of a degree $3$ polynomial ($e^{2\pi i /7}$ is a root of $x^6+x^5+\dots+1=0$, $\cos(2\pi/7)=y=(x+x^{-1})/2$, which gives $8 y^3+4 y^2-4 y-1 = 0$). That polynomial ($8 y^3+4 y^2-4 y-1$) is irreducible (over $\mathbb{Q}$) and has real roots (namely $\cos(2\pi/7),\cos(4\pi/7),\cos(6\pi/7)$). There is a famous theorem (casus irreducibilis) saying that the roots of the polynomial cannot be expressed using real radicals. So you will need complex numbers in your formula for $\cos(2\pi/7)$.

(Cardano's formula gives $$y= -1/6+7^{2/3}/(3\times 2^{2/3} (1+3 i \sqrt{3})^{1/3})+ (7/2\times (1+3 i \sqrt{3}))^{1/3}/6$$ - computed by Wolfram Alpha)

Are you sure there is an "exact" value? Well, it depends on what you mean by exact. My point is that I don't think heptagons are constructible with ruler and compass, which means, if I remember correctly, that the sine and cosine cannot be expressed as sum of fractions and square roots of fractions.

I know $\cos\dfrac{2\pi}{17}$ is a known value, maybe that's what you meant.

• Heptagons are not constructible with ruler and compass. (This is because the Galois group of $\mathbb{Q}(\cos \frac{2\pi}{7})$ has order $3$.) – Qiaochu Yuan May 11 '11 at 7:16
• That's why I was confused, but the question states exactly that "Calculate the exact values of $cos(2\pi/7)$ and $sin(2\pi/7)$". Is it possible to represent as a real power of e? – Hannesh May 11 '11 at 7:23
• while I agree that the exact meaning here is a bit up for grabs, construing "having an exact value" to mean "constructible in the sense of ancient Greek geometry" seems like a fairly, um, old-fashioned way of looking at things. Surely $\sqrt[3]{2}$ is "just as exact" as $\sqrt{2}$, no? None of the people who are serious about "constructive mathematics" have any issues with algebraic numbers, i.e., numbers given as the root of a polynomial with rational coefficients. – Pete L. Clark May 11 '11 at 8:44
• @Pete L. Clark: fair enough. I'm a few thousands years late, which is another way of saying I'm not fit to answer this question. My apology. – Sebastien May 11 '11 at 11:12
• $\sqrt[3]{2}$ is not constructible either, but itself is considered an "exact" value.... – N. S. Jan 19 '12 at 19:21

I arrived at an equation (third degree polynomial below):

$$\binom71 x^3 - \binom73 x^2 + \binom75 x - \binom77 = 0\;.$$

The zeroes are $x_1= \cot (\pi/7)^2, x2= \cot (2\pi/7)^2$ and $x_3=\cot(3\pi/7)^2$.

I hope this will help. I arrived at an answer to this problem after solving the above cubic polynomial. This took some time, but the answer was not very messy.

• That cubic has solutions in terms of radicals, doesn't it? – Stefan Smith Jun 9 '12 at 16:38

I recently figured a different way of getting to the cubic polynomial. You can see that the three roots $A$, $B$, and $C$ of the cubic must correspond to \begin{align*} w^1 + w^6 &= A\\ w^2 + w^5 &= B\\ w^4 + w^3 &= C \end{align*} where $w$ is the seventh root of unity...no, to just "the" seventh root of unity, but any non-trivial seventh root of unity. You can also see that that the group of automorphisms of the splitting field is the cyclic group on three elements. How? because if you adjoin any one of $A$, $B$, or $C$ to the rationals, you get a group of order three which contains all of $A$, $B$, and $C$. In particular it is easy to see that: \begin{align*} A^2 - 2 &= B\\ B^2 - 2 &= C\\ C^2 - 2 &= A \end{align*} If we substitute for $A$ recursively in these three equations, we get the eight-degree equation: $$A^8 - 8A^6 + 20A^4 - 16A^2 + 2 = A$$

Why eighth degree? Because we have perhaps forgotten that the recursive relation is also satisfied if we allow $A^ -2 = A$. So we use synthetic division to divide out these "trivial" solutions and we then get the unlikely sixth-degree equation: $$A^6 + A^5 - 5A^4 - 3A^3 + 7A^2 + A - 1 = 0$$

This sixth degree equation factors into two third degree equations. One of those third degree equations contains the three cosines of interest as its solution. The other has a different set of cosine solutions, namely $2\cos(2\pi m/9)$ where $m = 1$, $2$, or $4$. If, for instance, we select $A = 2\cos(2\pi/9)$, then using the double angle formula for cosine and the above definitions we get $B = 2\cos(4\pi/9)$, then $C = 2\cos(8\pi/9)$, then $A = 2\cos(16\pi/9) = 2\cos(2\pi/9)$ because $$\frac{16\pi}{9} + \frac{2\pi}9 = 2\pi.$$