Fermat's little theorem

Home > Mathematics > Number theory > Fermat's little theorem

A theorem that helps simplify modular exponentiation.

Modular arithmetic: The study of arithmetic operations done on remainders of numbers after division by a given integer, referred to as the modulus.
Prime numbers: Positive integers that are only divisible by 1 and themselves.
Euler's totient function: A function that returns the number of positive integers less than or equal to a number and relatively prime to it.
Modular exponentiation: The process of finding the remainder when a number is raised to a power, done in modulo arithmetic.
Congruence: A relation between two numbers, stating that they have the same remainder when divided by a particular modulus.
Divisibility: The property of an integer being exact multiple of another integer.
Carmichael's function: A function that returns the smallest positive integer that satisfies a particular congruence relation.
Fermat's theorem: A theorem that states that if p is a prime number and a is any integer, then a^p≡a (mod p) where "≡" denotes congruence.
Fermat's little theorem: A special case of Fermat's theorem, where p is a prime number and a is any integer coprime to p.
Wilson's theorem: A theorem that provides a necessary and sufficient condition for an integer to be a prime number.
Modular inverse: The multiplicative inverse of a number in modulo arithmetic.
Chinese remainder theorem: An algorithm for solving systems of congruences that differ only in modulus.
Euler's theorem: A generalization of Fermat's little theorem that applies to not only prime numbers but also composite numbers.
Basic Fermat's Little Theorem: This theorem states that if p is a prime number, then ap: A is an integer multiple of p for any integer a.
Euler's Totient Theorem: This theorem states that if a and n are positive integers and a is relatively prime to n, then aᵥⁿ ≡ a^(φ(n)) (mod n), where φ(n) is Euler's totient function.
Lagrange's Theorem: This theorem states that if a and n are relatively prime, then the order of a modulo n divides the value of the Euler's totient function of n, i.e., ordₙ(a) divides φ(n).
Wilson's Theorem: This theorem states that if p is a prime number, then (p-1)! ≡ -1 (mod p).
Generalized Fermat's Little Theorem: This theorem states that if p is a prime number and k is a positive integer, then a^(kp) ≡ (a^k)^p (mod p).
Carmichael's Theorem: This theorem states that if a and n are relatively prime positive integers and λ(n) is Carmichael's function, then a^λ(n) ≡ 1 (mod n).
Lehmer's Theorem: This theorem states that if GCD(a,n) = 1, then the remainder of a^n divided by n can be found by a Euclidean algorithm using a, n, and the remainders of a^(n-1) and a^(n-2) modulo n.
Lucas's Theorem: This theorem is an extension of the basic Fermat's Little Theorem and can be used to calculate binomial coefficients modulo a prime number.
Kummer's Theorem: This theorem is an extension of Lucas's Theorem and can be used to calculate binomial coefficients modulo a prime power.
Hensel's Lemma: This theorem is a tool for lifting modular solutions to solutions modulo a higher power of a prime number.