This app is designed to demonstrate the fundamental properties of prime numbers using a physical metaphor - the arranging of pebbles into rows. A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself. In terms of pebbles, a prime number of pebbles can only be arranged into one row or in a single column, not in a rectangular grid of two or more rows and columns.
The Euclid's theorem states that there are infinitely many primes. This app aims to illustrate this by continuously generating new prime numbers. You start by entering an initial list of prime numbers. These prime numbers are then used to generate a "product-plus-one" number, which is the product of the entered prime numbers plus one. This "product-plus-one" number of pebbles is then arranged in different ways, where the number of pebbles in a row corresponds to the next prime number.
If the pebbles can be arranged in a way such that each row contains the same number of pebbles, then the "product-plus-one" number is not a prime, and the process continues with a new "product-plus-one" number. If it is impossible to arrange the pebbles into equal rows (excluding a single row or column), then the "product-plus-one" number is a prime, and it is added to the list of prime numbers.
Through this process, the app illustrates the continuous existence of prime numbers, and how each new prime number can be used to generate another potential prime.
This app was constructed by ChatGPT 4 (July 20 2023 Version) by Ken Kahn (toontalk@gmail.com). The conversation where this app was created can be found here.