Play n Tools

Free tools & games for everyone

Free · No sign-up · No accounts

Experimental mathematics lab

Find the rule behind a sequence, hunt for the first counterexample to famous claims, and solve whole-number equations: Pell, sums of two squares, triples.

How to use

  1. Guess the rule: type at least four whole numbers. The lab looks for a known family (squares, primes, Fibonacci ...), then a polynomial (the differences table becomes constant), then a recurrence such as each term = 2 x the last + 1, and gives the next five terms.
  2. Counterexample hunter: pick a claim and a search limit. False claims fail at a specific number, shown with its factors; the unproved ones (Goldbach, Collatz) survive every case you can check.
  3. Whole-number equations: solve a x + b y = c in whole numbers (all solutions), find the smallest answer to Pell's equation, list the ways to write n as a sum of two squares, or the primitive Pythagorean triples.

Keyboard and touch

TabMove between tabs, boxes and buttons
EnterIn a box: work it out

Tips

  • Four numbers fit infinitely many rules. Give more terms to make the lab's answer more convincing.
  • n^2 + n + 41 gives primes for n = 0 to 39: 40 checks, then it fails. Patterns can hold for a long time and still be false.
  • Pell's equation for D = 61 has its smallest answer at x = 1,766,319,049: try it.
  • A whole number is a sum of two squares exactly when each prime of the form 4k + 3 appears an even number of times in it.

About this tool

Polynomials are found with Newton's differences and fitted exactly with fractions; recurrences of order 1 to 4 (with or without a constant) are solved from the first terms and checked on all the others. Counterexamples are searched by trial division, a sieve (Goldbach) and fast powers mod n (the Fermat test, which is fooled first by 341 = 11 x 31).

Pell's equation uses the continued fraction of the square root of D with exact big whole numbers. A rule found by a computer is a conjecture until it is proved: that is the point of experimental mathematics. Everything runs in your browser.

See you tomorrow!

A fresh daily puzzle every morning, and new tools added every month.

Browse every product