login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A119610 Number of cases in which the first player gets killed in a Russian roulette game when 5-player use a gun with n-chambers and the number of the bullets can be from 1 to n. In the game they do not rotate the cylinder after the game starts. 1
1, 2, 4, 8, 16, 33, 66, 132, 264, 528, 1057, 2114, 4228, 8456, 16912, 33825, 67650, 135300, 270600, 541200, 1082401, 2164802, 4329604, 8659208, 17318416, 34636833, 69273666, 138547332, 277094664, 554189328, 1108378657, 2216757314 (list; graph; refs; listen; history; internal format)
OFFSET

1,2

COMMENTS

Here we let p = 5 to produce the above sequence, but p can be an arbitrary natural number. By letting p = 2, 3, 4, 6, 7 we can produce A000975, A033138, A083593, A195904 and A117302 in the On-Line Encyclopedia of Integer Sequences. We denote by U[p,n,m] the number of the cases that the first player gets killed in a Russian roulette game when p players use a gun with n-chambers and m-bullets. They never rotate the cylinder after the game starts. The chambers can be represented by the list {1,2,...,n}.

We are going to calculate the following (0), (1),...(t) separately. (0) The first player gets killed when one bullet is in the first chamber and the remaining (m-1)- bullets are in {2,3,...,n}. We have binomial[n-1,m-1]-cases for this. (1) The first gets killed when one bullet is in the (p+1)th chamber and the rest of the bullets are in {p+2,..,n}. We have binomial[n-p-1,m-1]-cases for this. We continue to calculate and the last is (t), where t = Floor[(n-m)/ p]. (t) The first gets killed when one bullet is in (pt+1)-th chamber and the remaining bullets are in {pt+2,...,n}. We have binomial[n-pt- 1,m-1]-cases for this. Therefore U[p,n,m] = Sum[binomial[n-pz-1,m-1], for z = 0 to t, where t = Floor[(n-m)/p]. Let A[p,n] be the number of the cases that the first player gets killed when p-player use a gun with n-chambers and the number of the bullets can be from 1 to n. Then A[p,n] = Sum[U[p,n,m], m = 1 to n].

REFERENCES

Miyadera, R. "General Theory of Russian Roulette." Mathematica source.

Miyadera, R. Mathematical Theory of Magic Fruits Archimedes-lab.

LINKS

R.Miyadera, General Theory of Russian Roulette, Mathematica source.

R.Miyadera, nteresting patterns offractions,Archimedes-lab

Index to sequences with linear recurrences with constant coefficients, signature (2,0,0,0,1,-2).

FORMULA

Let p = 5 and a(n) = (2^(n + p-1) - 2^(Mod[n - 1, p]))/(2^p - 1), where Mod[,p] is the remaining part of the number when divided by p. In the followings we present the formula based on the theory we used to define our sequence as a Mathematica code. The above formula is a lot easier to use, but the Mathematica code has an important mathematical meaning in it.

a(n) = floor(2^(n+4)/31), which is obtained by letting p=5 in the formula above.

G.f. x / ( (x-1)*(2*x-1)*(x^4+x^3+x^2+x+1) ). a(n)=+2*a(n-1)+a(n-5)-2*a(n-6). - Joerg Arndt, Jan 08 2011.

EXAMPLE

If the number of chambers is 3, then the number of the bullets can be

1,2,3. The first one get killed when one bullet is in the first chamber,

and the remaining bullets are in the second and the third chamber. All

the cases is {{1, 0, 0}, {1, 1, 0}, {1, 0, 1}, {1, 1, 1}}, where we

denote by 1 the chamber that contains the bullet. Therefore a(3) = 4.

MAPLE

seq(floor(2^(n+4)/31), n = 1..32); [From Mircea Merca, Dec 22 2010]

MATHEMATICA

U[p_, n_, m_, v_]:=Block[{t}, t=Floor[(1+p-m+n-v)/p]; Sum[Binomial[n-v-p*z, m-1], {z, 0, t-1}]]; A[p_, n_, v_]:=Sum[U[p, n, k, v], {k, 1, n}]; (*Here we let p = 5 to produce the above sequence, but this code can produce A000975, A033138, A083593, A195904, A117302 for p = 2, 3, 4, 6, 7.*) Table[B[5, n, 1], {n, 1, 20}]

CROSSREFS

Cf. A000975, A033138, A083593, A195904, A117302.

Sequence in context: A138814 A137181 A036373 * A121485 A098588 A126683

Adjacent sequences:  A119607 A119608 A119609 * A119611 A119612 A119613

KEYWORD

easy,nonn,uned

AUTHOR

Ryohei Miyadera (miyadera1272000(AT)yahoo.co.jp), Jun 04 2006

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 13 22:22 EST 2012. Contains 205566 sequences.