Fermat's Little Theorem
For prime p, a^{p-1} ≡ 1 (mod p) when p ∤ a.
Fermat's Little Theorem: Let be a prime and let . Then
Equivalently, if (i.e., ), then
Here means that divides .
Remarks
This is a standard application of Lagrange's theorem to the group of units , a finite group of order . It is also the prime-modulus special case of Euler's theorem (since ).
Examples
- , : , so .
- , : both and are divisible by , so (this is the "" form).
- If , then is a multiplicative inverse of modulo (since ). For instance, with , : , so because .