Euler’s Totient Function 𝜑(n)

Learn Euler's totient function and its role in number theory in this lesson.

Euler’s totient function plays a vital role in number theory. It counts all the positive integers up to a given number nn that are coprime to nn.

We’ll make use of it when we want to determine the number of generators in cyclic groups and when we want to describe the order of the multiplicative group of integers modulo nn.

Definition

The number of positive integers a<na < n that are relatively prime to nNn \in \mathbb{N} is called Euler’s totient function 𝜑(n), defined by the rule

φ(n)={aN0a<n:gcd(a,n)=1}.\varphi (n) = \left | \left \{ a \in \mathbb{N} \mid 0 \le a < n : gcd(a , n) = 1 \right \} \right |.

Get hands-on with 1200+ tech skills courses.