---
title: "About: How the Calculators Work | Prime Orchard"
description: "Prime Orchard is a set of free number theory calculators that show their working. What each one does, the methods behind them and their limits."
url: https://primeorchard.top/about/
---

# About Prime Orchard

Prime Orchard is a small collection of free calculators for the parts of number theory people meet at school, in puzzles and in programming: primes, factors, divisors, the greatest common divisor and the least common multiple. Each one shows its working, because the method is usually the point.

## How it works

Everything runs in your browser. The numbers you type are never uploaded; the calculations use JavaScript's arbitrary-precision BigInt type, so a 500-digit number is handled exactly rather than rounded. Long jobs, such as sieving a billion numbers or factoring a 60-digit number, run in a background Web Worker so the page stays responsive, and you can stop them at any time. Once a page has loaded it keeps working offline.

## The methods

- **Primality:** trial division, then Miller–Rabin with the first 13 prime bases, which is a proof for numbers below 3.317 × 1024. Above that, the Baillie–PSW test plus extra bases: no counterexample is known, but results are labelled "probable prime".
- **Factorization:** trial division by the primes below 100,000, then Pollard's rho (Brent's variant) with a time limit. Parts that cannot be split in time are shown, never hidden.
- **Prime lists and counts:** a segmented sieve of Eratosthenes over odd numbers.
- **GCD and LCM:** Euclid's algorithm and its extended form.

Every page names its sources. The logic is covered by automated tests against published values, such as the counts of primes below powers of ten in the OEIS and the known strong pseudoprimes that fool weaker tests.

## Who runs it

Prime Orchard is an independent site with no accounts, no adverts and no tracking cookies. It is free to use for homework, teaching and curiosity. A wrong answer is the one thing a maths site must never give, which is why each method is checked against published values before anything else.

[Back to the prime checker](https://primeorchard.top/)
