This is a classic problem solving activity that I first saw many years ago in Mathematics: A Human Endeavor. The NCTM has a nice applet to test cases one at a time.
Since I like playing with Excel and trying to extend what it can do, I wrote a spreadsheet to represent the problem. The end result is much better than expected — this representation uses a slider to show many cases in a short period of time, and with it I noticed patterns that I never had before (e.g. if you start at (1,0) on a rectangle whose sides have GCD=2, you get a loop that goes through all squares). Read more >>