Fundamental theorem of arithmetic

The fundamental theorem of arithmetic states that every integer greater than 1 is prime or can be expressed as a product of prime numbers in exactly one way, apart from the order of the factors. It underlies prime factorization, divisibility, greatest common divisors and least common multiples, and has connections to number theory and public-key cryptography.

Last updated
30 October 2026
Confidence
High (98%)
Sources
5
Versions
1
This article was researched and drafted with AI assistance and checked by an automated review pass. It is not guaranteed to be accurate — verify important facts against the references below.

Statement

Every integer n > 1 can be written as a product of primes, and that factorization is unique except for the order of its factors. Equivalently, each such integer has one prime-power representation n = p₁^a₁ p₂^a₂ ⋯ pₖ^aₖ, where the pᵢ are distinct primes and each exponent aᵢ is a positive integer. For example, 360 = 2³ × 3² × 5. Rearranging the factors does not give a different factorization.

Existence of a prime factorization

If n > 1 is prime, it is already a product consisting of one prime. If it is composite, write n = ab with integers a and b strictly between 1 and n. Each factor is smaller than n. Repeating this process, or using induction, eventually expresses n as a product of primes: each split replaces a composite integer with smaller positive factors, so the process terminates.

Why the factorization is unique

A key ingredient is Euclid's lemma: if a prime p divides a product ab, it must divide a or b. More generally, if p divides a product of several integers, it divides at least one factor. Suppose an integer has two prime factorizations. The first prime in one factorization divides the product in the other, so Euclid's lemma implies it equals one of the primes there. Cancel this common prime from both sides and repeat. All prime factors, including their multiplicities, must match; only their order can differ. Euclid's Elements presents the prime-divisor result in Book VII, Proposition 30, and results about decomposition appear in adjacent propositions.

Examples and consequences

The factorization of 360 can be written 360 = 2 × 2 × 2 × 3 × 3 × 5 or, in prime-power form, 2³ × 3² × 5. The theorem makes prime factorizations a reliable way to compare integers: a greatest common divisor is obtained by taking the smaller exponent of each prime shared by the numbers, while a least common multiple uses the larger exponent. It also explains why 1 is not classified as prime: if it were, factors of 1 could be inserted indefinitely, contradicting uniqueness.

Scope and significance

The theorem concerns ordinary integers; unique factorization does not automatically hold in every number system or algebraic structure. In modern number theory, studying which broader systems have unique factorization is a major topic. Prime factorization also appears in cryptography: RSA public keys include a composite modulus formed from two large primes, and factoring such moduli is related to the security of RSA when it is correctly implemented. The theorem guarantees a unique factorization exists; it does not say that finding the factors of a large number is computationally easy.

Key facts

Domain
The statement applies to integers greater than 1.
Existence
Every such integer can be expressed as a product of primes.
Uniqueness
The primes and their multiplicities are fixed; only their order may vary.
Proof ingredient
Euclid's lemma says that a prime dividing a product divides at least one factor.
Example
360 = 2³ × 3² × 5.
Important limitation
Unique factorization in the integers does not imply easy factorization of very large integers or unique factorization in every number system.

Ask about this article

Answers use only “Fundamental theorem of arithmetic” and its references, with citations.

References

  1. 1.
    Euclid's Elements, Book VII, Proposition 30

    David E. Joyce, Clark University · other · reliability: unverified · retrieved 30 October 2026

    Supports: Provides a translation and explanation of Euclid's proposition that a prime dividing a product divides one of the original factors.

  2. 2.
    2.3: The Fundamental Theorem of Arithmetic

    Mathematics LibreTexts; chapter by Wissam Raji, American University of Beirut · other · reliability: unverified · retrieved 30 October 2026

    Supports: States and proves existence and uniqueness of prime factorizations, explains Euclid's lemma, and illustrates consequences for divisibility and greatest common divisors.

  3. 3.
    The Fundamental Theorem of Arithmetic

    University of Houston, Department of Mathematics (course handout by Min Ru, dated 14 June 2008) · other · reliability: unverified · retrieved 30 October 2026

    Supports: Presents the theorem, a proof using Euclid's lemma, and examples of prime-power decompositions and least common multiples.

  4. 4.
    Prime Numbers and Factorizations

    UCLA Math Circle (handout by Yan Tao) · other · reliability: unverified · retrieved 30 October 2026

    Supports: States the theorem and discusses its proof, Euclid's lemma, and how unique factorization behaves in other number systems.

  5. 5.
    The Role Of Prime Numbers in RSA Cryptosystems

    Georgia College & State University (Henry Rowland, 2016) · other · reliability: unverified · retrieved 30 October 2026

    Supports: Explains that RSA key generation uses two large primes and that factoring their product is central to the cryptosystem's security assumptions.

References are suggested by the research engine and may be incomplete. Unverified URLs are omitted rather than guessed.

Article history

  1. Version 130 October 2026 · EditorCreated by Zapia