Prime Number Calculator
A prime number has exactly two factors: 1 and itself. This prime number calculator checks whether a whole number is prime by testing divisors up to its square root. If it is not prime, you get its prime factorisation. It also finds the next prime number after the one you enter.
How to use the prime number calculator
- Enter a whole number, such as 97.
- Press Calculate.
- See whether it is prime, its prime factors and the next prime.
Formula
Worked example: 97
- Whole number: 97
✓ Answer checked
97 is a prime number
- Next prime
- 101
Step-by-step working (3 steps)
Set the search limit
Only divisors up to √97 ≈ 9 need testing; any larger factor would pair with a smaller one.
Test the divisors
No whole number from 2 to 9 divides 97 exactly.
Conclusion
97 has exactly two factors, 1 and 97, so it is prime.
How this was checked
- ✓ Multiplying the prime factors gives 97.
- ✓ Every factor in the factorisation is itself prime.
Frequently asked questions
Is 1 a prime number?
No. A prime must have exactly two different factors, and 1 has only one.
Why only test divisors up to the square root?
If a number has a factor bigger than its square root, it must also have one smaller than it, so checking up to the square root is enough.
Is 2 a prime number?
Yes. 2 is the smallest prime and the only even prime.
People also search for
prime number calculatoris it primeprime checkerprime factorisationprime number calculator with stepsfree prime number calculator online
