# Prime Number

**Type:** Concept  
**Domain:** Number Theory  
**Codex URL:** /mathematics/number-theory/prime-number/  
**Entry status:** Live — v1.0 (2026-05-27)

---

## Definition

A **prime number** is a natural number p > 1 whose only positive divisors are 1 and p.

First few primes: 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, …

Note: 1 is not prime (by convention, to preserve uniqueness of factorisation).

---

## Fundamental Theorem of Arithmetic

Every integer n > 1 is a product of primes in exactly one way (up to order). Primes are the "atoms" of arithmetic.

---

## Infinitely many primes (Euclid, c. 300 BCE)

Assume finitely many primes p₁…pₙ. Let N = p₁p₂…pₙ + 1. N is not divisible by any pᵢ. So N is prime or has a new prime factor. Contradiction. ∎

---

## Prime Number Theorem

π(n) ~ n / ln(n) — the number of primes up to n. Proved by Hadamard and de la Vallée-Poussin (1896).

---

## Open problems

- **Riemann Hypothesis** — zeros of ζ(s) lie on Re(s) = 1/2; controls prime distribution. Unsolved since 1859.
- **Twin Prime Conjecture** — infinitely many pairs (p, p+2). Zhang (2013): infinitely many primes within 246 of each other.
- **Goldbach's Conjecture (1742)** — every even n > 2 is the sum of two primes. Verified to 4 × 10¹⁸. Unproved.

---

## Sources

### Tier 1
- Hardy, G.H. and Wright, E.M. (2008). *An Introduction to the Theory of Numbers*. 6th ed. Oxford University Press. [Chs 1–3]
- Davenport, H. (2000). *Multiplicative Number Theory*. 3rd ed. Springer.

### Tier 2
- Crandall, R. and Pomerance, C. (2005). *Prime Numbers: A Computational Perspective*. 2nd ed. Springer.

### Tier 3
- Derbyshire, J. (2003). *Prime Obsession*. Joseph Henry Press.

---

*Mathematics Codex entry v1.0 — added 2026-05-27 — thecodex.expert/mathematics/*
