OFFSET
1,2
COMMENTS
Players A and B bet in a k-round game. Player A has an initial amount of money n. In each round, player A can wager an integer between 0 and what he has. Player A then gains or loses an amount equal to his wager depending on whether player B lets him win or lose. Player B tries to minimize player A's money at the end. The number of rounds player A can lose is r. a(n) is the maximum amount of money player A can have at the end of the game for k = 5 and r = 4.
LINKS
Charles Jwo-Yue Lien, Dynamic Betting Game, Southeast Asian Bulletin of Mathematics, 2015, Vol. 39 Issue 6, pp. 799-814.
FORMULA
a(n) = floor(n*32/31).
G.f.: t^31/((1-t)*(1-t^31)) + t/(1-t)^2. - Robert Israel, Sep 11 2014
EXAMPLE
In the case of n=31: For the 1st round, player A bets 1. If A loses, A will end up with D(30,4,3)=32 per reference A247160. If A wins, he has 32 and will bet 0 for the remaining rounds. So he will end up 32. If A does not follow the proposed bet, he will have fewer than 32 at the end. So a(31) = 32.
PROG
(PARI)
vector(100, n, floor(32*n/31)) \\ Derek Orr, Sep 11 2014
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Charles Jwo-Yue Lien, Sep 10 2014
STATUS
approved