A buttonless calculator for mental maths practice. Type whole numbers separated by spaces in any row and the answer appears as you type.
Type numbers to see the answer
Type numbers to see the answer
Type numbers to see the answer
Type numbers to see the answer
Type numbers to see the answer
Type numbers to see the answer
Type numbers to see the answer
Up to 10 numbers per row, each no greater than 9,007,199,254,740,991. Sum of squares: up to 10,000,000. Difficult factorisations may reach a work limit. Decimal square roots are approximate to 6 places.
Press Enter to jump to the next row. The link keeps what you typed, so you can share it.
How each row works
LCM and HCF
The HCF comes from Euclid's algorithm, gcd(a,b)=gcd(b,amodb), repeated until the remainder is 0. The LCM follows from it:
lcm(a,b)=gcd(a,b)a×b
Prime factors, divisors and square roots
Small prime division, Miller-Rabin primality checks and Pollard-Brent factorisation find prime factors. The divisors are built from the prime powers, and square roots are simplified by taking pairs of equal primes outside the root, so200=102.
Sum of squares
Lagrange proved that every whole number is a sum of at most four squares. Matiks tries one square, then two, then three (Legendre: three are enough unless n=4a(8b+7)), and only then four.
Using it for practice
Work out an LCM or HCF in your head, then type the numbers to check.
Type a run of numbers in the prime row, such as 91 119 143, to spot which ones only look prime.
Use the square root row to learn the common simplified roots: √8 = 2√2, √12 = 2√3, √18 = 3√2.
Frequently asked questions
How does Matiks work without an equals button?
Every row recalculates as you type. Type one or more whole numbers separated by spaces, and the answer appears next to them straight away. Press Enter to jump to the next row.
Can I work with several numbers at once?
Yes. LCM and HCF combine every number you type: 12 15 20 gives an LCM of 60. The other rows answer for each number separately, one line each.
What is the relationship between LCM and GCD?
For two positive whole numbers, a × b = LCM(a, b) × GCD(a, b). Knowing one gives you the other: the LCM of 12 and 18 is 12 × 18 ÷ 6 = 36.
What is Lagrange's four-square theorem?
Every whole number can be written as the sum of at most four squares, such as 7 = 22 + 12 + 12 + 12. Legendre showed exactly which numbers need all four: those of the form 4a(8b + 7). Matiks always finds the fewest squares possible.
How is a square root simplified?
Pull every pair of equal prime factors out of the root. 200 = 23 × 52, so √200 = 2 × 5 × √2 = 10√2. When no pair exists, the root is already in its simplest form.