# 3

**3** (three) is the smallest odd prime number and the second prime overall, and it is the only prime that is one more than another prime, namely 2.<sup>[1](https://oeis.org/wiki/3)</sup> Because 2 and 3 are the only consecutive primes, 3 anchors several distinctive facts in elementary number theory: it is the smaller member of the first two twin-prime pairs, (3, 5) and (5, 7), and the only value of n for which the triple (n, n + 2, n + 4) consists entirely of primes.<sup>[2](https://alozano.clas.uconn.edu/wp-content/uploads/sites/490/2022/12/amstext35.pdf)</sup>

| Key fact | Detail |
|---|---|
| Primality | Smallest odd prime; the only prime one more than another prime (2)<sup>[1](https://oeis.org/wiki/3)</sup> |
| Consecutive primes | 2 and 3 are the only consecutive primes; every other pair of primes differs by at least 2<sup>[2](https://alozano.clas.uconn.edu/wp-content/uploads/sites/490/2022/12/amstext35.pdf)</sup> |
| Divisibility test | An integer is divisible by 3 if and only if its digit sum is<sup>[3](https://www.open.edu/openlearn/ocw/pluginfile.php/1044022/mod_resource/content/1/17mst125u3-extract.pdf)</sup> |
| Sequence membership | Appears among the odd numbers, primes, Fibonacci numbers, Lucas numbers, and triangular numbers<sup>[1](https://oeis.org/wiki/3)</sup> |
| Partitions | Exactly three partitions of 3: {1, 1, 1}, {1, 2}, and {3}<sup>[1](https://oeis.org/wiki/3)</sup> |
| Approximate values | \( \sqrt{3} \approx 1.73205080 \); \( \log_{2} 3 \approx 1.58496250 \)<sup>[1](https://oeis.org/wiki/3)</sup> |
| Representations | 11 in binary, 10 in ternary, 111 in negabinary<sup>[1](https://oeis.org/wiki/3)</sup> |

## Arithmetic character

As a prime, 3 has exactly two positive divisors, 1 and itself, and it is the building block of the smallest odd numbers in the prime sequence 2, 3, 5, 7, 11, 13, ...<sup>[1](https://oeis.org/wiki/3)</sup><sup> • </sup><sup>[4](https://mathworld.wolfram.com/PrimeNumber.html)</sup> Its primality interacts with parity in a way no other prime shares: since 2 and 3 are consecutive, every prime after 3 differs from every other prime by at least 2, and the twin-prime pairs (3, 5) and (5, 7) are the only overlapping twin pairs.<sup>[2](https://alozano.clas.uconn.edu/wp-content/uploads/sites/490/2022/12/amstext35.pdf)</sup> The same divisibility-by-3 obstruction explains why the prime triple (n, n + 2, n + 4) exists only for n = 3, giving (3, 5, 7): among any three numbers spaced by 2, one is divisible by 3.<sup>[2](https://alozano.clas.uconn.edu/wp-content/uploads/sites/490/2022/12/amstext35.pdf)</sup>

The number 3 also appears in the classical sequences: it is the third odd number, the second prime, the fourth [Fibonacci](https://www.edgepedia.org/fibonacci) number, the third [Lucas number](https://www.edgepedia.org/lucas-number), and the second triangular number.<sup>[1](https://oeis.org/wiki/3)</sup> In Pascal's triangle it occurs twice, and in Lozanić's triangle four times.<sup>[1](https://oeis.org/wiki/3)</sup>

## The digit-sum divisibility test

The best-known practical fact about 3 is its divisibility test: an integer is divisible by 3 if and only if the sum of its digits is divisible by 3.<sup>[3](https://www.open.edu/openlearn/ocw/pluginfile.php/1044022/mod_resource/content/1/17mst125u3-extract.pdf)</sup> The reason is that 10 is congruent to 1 modulo 3, so each power of 10 in a decimal expansion contributes only its digit:

\[ n = \sum_{i=0}^{k} d_{i} \cdot 10^{i} \equiv \sum_{i=0}^{k} d_{i} \pmod{3}. \]

The same argument works for 9, since 10 ≡ 1 (mod 9) as well, and the test can be iterated when the digit sum itself is large; for 8,675,038,695 the digit sum is 57, whose digit sum is 12, so the original number is divisible by 3.<sup>[3](https://www.open.edu/openlearn/ocw/pluginfile.php/1044022/mod_resource/content/1/17mst125u3-extract.pdf)</sup> The rule is a special case of modular arithmetic, the system of congruences published by [Carl Friedrich Gauss](https://www.edgepedia.org/carl-friedrich-gauss) in 1801, in which two integers are congruent modulo n when they leave the same remainder on division by n.<sup>[5](https://www.sw.it.aoyama.ac.jp/2024/Math1/lecture13.html)</sup>

## Powers, roots, and logarithms

The powers of 3 begin 3, 9, 27, 81, 243, 729, 2187, 6561, 19683, 59049, forming the sequence of powers of three.<sup>[1](https://oeis.org/wiki/3)</sup> Its square root is \( \sqrt{3} \approx 1.73205080 \), and the base-2 logarithm \( \log_{2} 3 \approx 1.58496250 \) measures how many bits are needed to distinguish three states, a quantity that appears in information theory and computer science.<sup>[1](https://oeis.org/wiki/3)</sup>

## Behavior in other number systems

In ordinary base-10 notation 3 is a single digit, but its representation varies with the base: it is 11 in binary, 10 in ternary (the base it generates), and 111 in [negabinary](https://www.edgepedia.org/negabinary), since \( (-2)^{2} + (-2)^{1} + (-2)^{0} = 4 - 2 + 1 = 3 \).<sup>[1](https://oeis.org/wiki/3)</sup>

In algebraic number theory, 3 is prime in the ordinary integers \( \mathbb{Z} \) but composite in some quadratic integer rings. In \( \mathbb{Z}[\sqrt{3}] \) it factors as \( (\sqrt{3})^{2} \), and in the Eisenstein integers \( \mathbb{Z}[\omega] \), where \( \omega = -\tfrac{1}{2} + \tfrac{\sqrt{-3}}{2} \) is a complex cube root of unity, it factors as \( (-1)(1 + 2\omega)^{2} \).<sup>[1](https://oeis.org/wiki/3)</sup> The ring \( \mathbb{Z}[\omega] \) has six units, more than any other imaginary quadratic integer ring, a distinction that traces directly back to the role of 3 in defining \( \omega \).<sup>[1](https://oeis.org/wiki/3)</sup>

Primality testing modulo 3 is not foolproof: composite numbers called Fermat pseudoprimes to base 3, beginning 91, 121, 286, 671, and 703, satisfy the base-3 Fermat condition without being prime.<sup>[1](https://oeis.org/wiki/3)</sup>

## Sums of three triangular numbers

The triangular numbers 1, 3, 6, 10, 15, ... are the sums 1 + 2 + ... + n, and 3 is the second of them.<sup>[1](https://oeis.org/wiki/3)</sup><sup> • </sup><sup>[6](https://mathworld.wolfram.com/TriangularNumber.html)</sup> Fermat's polygonal number theorem states that every positive integer is a sum of at most three triangular numbers; Carl Friedrich Gauss proved this triangular case and recorded it in his diary on July 10, 1796 with the notation "ΕΥΡΗΚΑ! num = Δ + Δ + Δ".<sup>[6](https://mathworld.wolfram.com/TriangularNumber.html)</sup> The number 3 itself has two such representations, {3, 0, 0} and {1, 1, 1}.<sup>[7](https://oeis.org/wiki/Triangular_numbers)</sup>

## Historical and cultural notes

The digit 3 reached its modern European form through the Hindu-[Arabic numerals](https://www.edgepedia.org/arabic-numerals), whose transmission from India through the Arabic world and into Europe took centuries; the numerals appear in the Codex Vigilanus, copied by a monk in Spain in 976, and were popularized in Europe by Fibonacci's *Liber abaci* of 1202.<sup>[8](https://mathshistory.st-andrews.ac.uk/HistTopics/Arabic_numerals/)</sup> In the eastern Arabic empire the numerals were known as Gubar ("dust") numerals, from the dust board used for calculation.<sup>[8](https://mathshistory.st-andrews.ac.uk/HistTopics/Arabic_numerals/)</sup>

The number three carries heavy symbolic weight across traditions. In ancient [Egyptian temple](https://www.edgepedia.org/egyptian-temple) theology, divine triads such as Osiris, Isis, and Horus organized local religion, and the triangle represented harmony and balance in [Egyptian mythology](https://www.edgepedia.org/egyptian-mythology).<sup>[9](https://codexnumerica.com/number/3.html)</sup><sup> • </sup><sup>[10](https://reference-global.com/download/article/10.2478/zireb-2023-0010.pdf)</sup> In Christian doctrine, the Trinity defines one God existing in three co-equal, coeternal, and consubstantial divine persons: [God the Father](https://www.edgepedia.org/god-the-father), God the Son, and God the Holy Spirit.<sup>[10](https://reference-global.com/download/article/10.2478/zireb-2023-0010.pdf)</sup>

## References

1. [3, OeisWiki](https://oeis.org/wiki/3)
2. [The Prime Numbers (chapter from an AMS preliminary textbook, L. Alloza et al.)](https://alozano.clas.uconn.edu/wp-content/uploads/sites/490/2022/12/amstext35.pdf)
3. [Divisibility tests, MST124 Book 3 Unit 17 extract, The Open University](https://www.open.edu/openlearn/ocw/pluginfile.php/1044022/mod_resource/content/1/17mst125u3-extract.pdf)
4. [Prime Number, Wolfram MathWorld](https://mathworld.wolfram.com/PrimeNumber.html)
5. [Modular Arithmetic, Discrete Mathematics I, Martin J. Dürst, Aoyama Gakuin University](https://www.sw.it.aoyama.ac.jp/2024/Math1/lecture13.html)
6. [Triangular Number, Wolfram MathWorld](https://mathworld.wolfram.com/TriangularNumber.html)
7. [Triangular numbers, OeisWiki](https://oeis.org/wiki/Triangular_numbers)
8. [The Arabic numeral system, MacTutor History of Mathematics](https://mathshistory.st-andrews.ac.uk/HistTopics/Arabic_numerals/)
9. [The Number 3 in Sacred Traditions, Codex Numerica](https://codexnumerica.com/number/3.html)
10. [Numeral 3 in symbolism and religion, Zeitschrift für Interkulturelle Erziehungswissenschaft (2023)](https://reference-global.com/download/article/10.2478/zireb-2023-0010.pdf)

---
*Topic: Encyclopedia › Physical world and mathematics › Mathematics and statistics › Numbers and algebra › Arithmetic and number systems › Integer sequences and partitions › Special and named integers › Named individual integers*

*Initially written Sep 17, 2026 · Reviewed: Oct 15, 2026 · Edited: Oct 15, 2026 · Last review: Oct 15, 2026*

*Copyright 2026 EdgeChat AI, a subsidiary of Biostate AI.*

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license
