Euler's totient function
Euler's totient function, , determines the number of integers less than a given positive integer that are relatively prime to that integer.
Given the prime factorization of , then one formula for is .
For prime p, , because all numbers less than are relatively prime to it.
For relatively prime , .
For non-relatively prime , we have .
For any , we have where the sum is taken over all divisors d of .