Generating function for the Josephus Problem?

223 Views Asked by At

According to the Wikpedia article on the Josephus problem, the general solution is by dynamic programming. However, since there seems to be an explicit recurrence rule for the problem, should there not be a generating function in terms of n and k, where n is the number of people and k is the decimation interval, that gives a solution by direct calculation?