Assumptions:
TeX:
\varphi(n) = \sum_{k=1}^{n} \gcd\!\left(n, k\right) \cos\!\left(\frac{2 \pi k}{n}\right)
n \in \mathbb{Z}_{\ge 0}Definitions:
| Fungrim symbol | Notation | Short description |
|---|---|---|
| Totient | Euler totient function | |
| Sum | Sum | |
| GCD | Greatest common divisor | |
| Cos | Cosine | |
| Pi | The constant pi (3.14...) | |
| ZZGreaterEqual | Integers greater than or equal to n |
Source code for this entry:
Entry(ID("93a877"),
Formula(Equal(Totient(n), Sum(Mul(GCD(n, k), Cos(Div(Mul(Mul(2, Pi), k), n))), For(k, 1, n)))),
Variables(n),
Assumptions(Element(n, ZZGreaterEqual(0))))