A355659 Martingale win/loss triangle, read by rows: T(n,k) = total number of dollars won (or lost) using the martingale method on all possible n trials that have exactly k losses and n-k wins, for 0 <= k <= n.
0, 1, -1, 2, 1, -3, 3, 5, -1, -7, 4, 11, 7, -7, -15, 5, 19, 24, 4, -21, -31, 6, 29, 53, 38, -12, -51, -63, 7, 41, 97, 111, 41, -57, -113, -127, 8, 55, 159, 243, 187, 5, -163, -239, -255, 9, 71, 242, 458, 500, 248, -130, -394, -493, -511, 10, 89, 349, 784, 1084, 874, 202, -488, -878, -1003, -1023
Offset: 0
Examples
Triangle T(n,k) begins: n\k| 0 1 2 3 4 5 6 7 8 9 ---+------------------------------------------- 0| 0 1| 1 -1 2| 2 1 -3 3| 3 5 -1 -7 4| 4 11 7 -7 -15 5| 5 19 24 4 -21 -31 6| 6 29 53 38 -12 -51 -63 7| 7 41 97 111 41 -57 -113 -127 8| 8 55 159 243 187 5 -163 -239 -255 9| 9 71 242 458 500 248 -130 -394 -493 -511 Examples from triangle: T(4,3) = -7: In this example, we consider all possibilities with 4 trials that result in 3 losses and one win. There are binomial(4,3) = 4 different combinations to consider (lllw, llwl, lwll, and wlll), which have net earnings of +1, 0, -2, -6 respectively when using the martingale method, giving a total of -7. T(6,2) = 53: In this example, we have 6 trials and we consider the results with 2 losses and 4 wins. There are binomial(6,2) = 15 such combinations to consider (wwwwll, wwwlwl, wwwllw, wwlwwl, wwlwlw, wwllww, wlwwwl, wlwwlw, wlwlww, wllwww, lwwwwl, lwwwlw, lwwlww, lwlwww, llwwww), and summing over all 15 earnings gives us a total of 53. T(2,0) = 2: In this example, we have 2 trials, with 0 losses and 2 wins. In this one single case, the martingale method gives us earnings of +1 and +1 with a total of 2.
Formula
T(n,k) = T(n-1,k) + T(n-1,k-1) + binomial(n-1,k) for 0 < k < n.
Sum_{k=0..n} T(n,k) = 0 (the sum of each row equals 0).
The following six formulas describe the three leftmost columns and the three rightmost diagonals of the triangle drawn below.
T(n,0) = n (this is the scenario with n trials, 0 losses; since the martingale method has us bet 1 after each win, we end up with total earnings equal to n).
T(n,1) = n^2 - n - 1 (this scenario is when there are n trials with just 1 loss; calculations show that this equals n^2 - n - 1 = A165900(n)).
T(n,2) = (n^3 - 3n^2 - 2)/2.
T(n,n) = 1 - 2^n = A000225(n).
T(n,n-1)= 1 + 2*n - 2^n = A070313(n).
T(n,n-2) = (3*n^2 - n)/2 + 1 - 2^n.
G.f.: x*(1-y)*(1-x*y) / ((1 - x*(1+y))^2 * (1-2*x*y)). - Kevin Ryde, Aug 30 2022
Comments