Category Archives: recursion

Computing optimal play for the greedy coins game, part 4

Last time I explained a method for computing best play for instances of the greedy coins game, which is feasible even for large games. This general approach is known as dynamic programming and is applicable whenever we have some recursively … Continue reading

Posted in computation, games, recursion | Tagged , , , , , , , , , , , | Leave a comment

Computing optimal play for the greedy coins game, part 3

In a previous post we saw how we can organize play sequences in the greedy coins game into a tree. Then in the last post, we saw how to work our way from the bottom of the tree upward and … Continue reading

Posted in computation, games, recursion | Tagged , , , , , , , , , | 2 Comments

Computing optimal play for the greedy coins game, part 2

I want to explain in more detail how we can think about computing the best possible score for Alice in the greedy coins game, assuming best play on the part of both players. I glossed over this too quickly in … Continue reading

Posted in computation, games, recursion | Tagged , , , , , , , , , | 1 Comment

Computing optimal play for the greedy coins game

Recall the greedy coins game, in which two players alternate removing one of the coins from either end of a row, and the player with the highest total at the end is the winner. What if we wanted to play … Continue reading

Posted in computation, games, recursion | Tagged , , , , , , , , , | 2 Comments

The Recamán sequence

I recently learned about a really interesting sequence of integers, called the Recamán sequence (it’s sequence A005132 in the Online Encyclopedia of Integer Sequences). It is very simple to define, but the resulting complexity shows how powerful self-reference is (for … Continue reading

Posted in arithmetic, recursion, sequences | Tagged , , , , | 5 Comments

Apollonian gaskets and Descartes’ Theorem II

In a few previous posts I wrote about “kissing sets” of four mutually tangent circles, and the fact that their signed bends satisfy Descartes’ Theorem, (Remember that the signed bend of a circle is like the curvature , except that … Continue reading

Posted in geometry, pattern, pictures, recursion | Tagged , , , , , , , | 1 Comment

Apollonian gaskets and Descartes’ Theorem

In my previous post, I explained a recursive procedure for drawing Apollonian gaskets. Given any three mutually tangent circles, there are exactly two other circles which are mutually tangent to all three (forming what we called a “kissing set”). This … Continue reading

Posted in geometry, pattern, pictures, recursion | Tagged , , , , , | 2 Comments