Prime Number Checker
Check if a number is prime. Shows the prime factorization, the previous prime and the next prime. Instant result.
Prime factorization
Previous prime
Next prime
What is a prime number?
We call a number prime when it's a natural number greater than 1 that admits only two divisors: 1 and itself. The sequence opens with 2, 3, 5, 7, 11, 13, 17, 19, 23 and keeps going from there. By definition, 1 stays out of this list.
Prime numbers: definition and primality testing
A prime number is a natural number greater than 1 with exactly two divisors: 1 and itself. By convention, 1 is not prime (the modern definition was settled in the early 20th century; before that, it was debated). The naive primality test is trial division: to check whether n is prime, test divisibility by every integer from 2 up to √n — no factor can exceed √n without pairing with a smaller one. Small primes: 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31. The Prime Number Theorem states that primes thin out with density roughly 1/ln(n). The Sieve of Eratosthenes (≈260 BC) remains the most efficient way to list all primes up to a bound. Mersenne primes have the form Mₚ = 2^p − 1; the distributed project GIMPS found the latest known prime in 2024 — M82589933, with more than 24 million digits.
Applications: cryptography and probabilistic tests
Primes power RSA: security relies on the difficulty of factoring n = p·q when p and q are primes of ~1024 bits each. They are used in hash function design and in probabilistic primality tests like Miller-Rabin and Solovay-Strassen, shipped in libraries such as OpenSSL, Pari/GP and SageMath.
FAQ
Is 1 prime? No. Modern mathematics excludes 1 so that the Fundamental Theorem of Arithmetic (unique prime factorization) holds.
Is 2 the only even prime? Yes. Every other even number is divisible by 2 and therefore composite.
How many primes are there? Infinitely many — Euclid proved this around 300 BC by contradiction.
What is the largest known prime? M82589933 = 2^82589933 − 1, a Mersenne prime with 24,862,048 digits, discovered by GIMPS in 2024.
Related Tools
Prime Factorization
Decompose any number into its prime factors. Instant result with the complete factorization.
Perfect Number Checker
Check if n is a perfect number; list its divisors.
Stacking Frames Tracking Photo
Estimates number of frames needed to stack for a desired SNR gain in astrophoto.
Karlovitz Number
Computes the Karlovitz number of a turbulent premixed flame, Ka = (u'/S_L)^1.5 · (ℓ_t/δ_L)^−0.5, comparing the chemical time of the flame front with the turnover time of the smallest eddies (Kolmogorov scale). Ka below 1 means the laminar flame structure survives the turbulence (wrinkled and corrugated regimes); between 1 and 100 eddies penetrate the preheat zone and thicken the flame; above 100 the reaction zone itself is broken. Together with the Damköhler number it forms the axes of the Borghi diagram, used to pick combustion models in CFD. Peters' form is adopted; integral scale and flame thickness must share the same unit. Enter the velocity fluctuation, the laminar flame speed, the integral length scale and the laminar flame thickness.
Lifetime Breaths
Estimates how many breaths a person takes during life based on age and average rate.
F-Stop Time ISO EV
Computes Exposure Value (EV) from aperture, shutter and ISO.
The results provided by this tool are for general informational and educational purposes only and do not constitute professional, financial, medical, legal, tax or accounting advice. Always confirm important decisions with a qualified professional and official sources.