Euler's Totient Function

Euler's Totient Function ϕ(n)\phi(n) counts the numbers less than nn that are co-prime with nn. For a prime number pp, ϕ(p)=p1\phi(p) = p-1, for the product of two primes pp and qq, ϕ(pq)=(p1)(q1)\phi(pq) = (p-1)(q-1). For example: ϕ(14)=ϕ(2×7)=(21)(71)=6\phi(14) = \phi(2 × 7) = (2-1)(7-1) = 6

Use in the RSA calculation, as part of the private key calculation.