Overview
A (simplified) theorem due to van der Waerden
states: for any k there is a sufficiently large n so that if {0, ...,
n-1} is partitioned into two sets, one of those sets must contain a
length-k arithmetic progression. For any k, the lowest such n is
called the van der Waerden number n(2, k) (the two is from the
partition into two sets).
Goal
Color the numbers in such a way that neither the red nor the gray numbers
have an arithmetic progression.
Operations
Enter n (this is the size of the set of numbers you will work with) and
k (this is the length of the progression you're trying to avoid) and
click "Start".
Click a number to change its color from gray to red and vice versa. The applet
will highlight one progession among the red numbers and one among the grays.
Keep changing colors until no numbers are highlighted (and hence there are
no length-k arithmetic progressions of either color).
Impossible tasks
Enter n=9 and k=3. You can't do it! Enter n=35 and k=4 or n=178 and k=5.
You can't do those either!
Links
More information on van der Waerden's Theorem including the original, more general
statement.
version