This site is supported by donations to The OEIS Foundation. Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A195904 Base 2 digits are, in order, the first n terms of the periodic sequence with initial period 1,0,0,0,0,0. 5
 1, 2, 4, 8, 16, 32, 65, 130, 260, 520, 1040, 2080, 4161, 8322, 16644, 33288, 66576, 133152, 266305, 532610, 1065220, 2130440, 4260880, 8521760, 17043521, 34087042, 68174084, 136348168, 272696336, 545392672, 1090785345, 2181570690, 4363141380, 8726282760 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,2 COMMENTS Here we let p = 6 to produce the above sequence, but p can be an arbitrary natural number. By letting p = 2, 3, 4, 7 we produce A000975, A033138,A083593 and A117302. 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]. - Ryohei Miyadera, Tomohide Hashiba, Yuta Nakagawa, Hiroshi Matsui, Jun 04 2006 LINKS G. C. Greubel, Table of n, a(n) for n = 1..1000 Index entries for linear recurrences with constant coefficients, signature (2,0,0,0,0,1,-2). FORMULA From Colin Barker, Jun 09 2013: (Start) a(n) = floor(2^(n+5)/63). G.f.: x /(2*x^7 -x^6 -2*x +1). G.f.: x /((x-1)*(x+1)*(2*x-1)*(x^2-x+1)*( x^2+x+1)). (End) 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 = 6 to produce the above sequence, but this code can produce A000975, A033138, A083593, A117302 for p = 2, 3, 4, 7.*)Table[A[6, n, 1], {n, 1, 20}] - Ryohei Miyadera, Tomohide Hashiba, Yuta Nakagawa, Hiroshi Matsui, Jun 04 2006 Rest[CoefficientList[Series[x/(2*x^7 - x^6 - 2*x + 1), {x, 0, 50}], x]] (* G. C. Greubel, Sep 28 2017 *) PROG (PARI) x='x+O('x^50); Vec(x/(2*x^7 - x^6 - 2*x + 1)) \\ G. C. Greubel, Sep 28 2017 CROSSREFS Cf. A000975, A033138, A083593, A117302. Sequence in context: A180209 A275073 A264701 * A101333 A023421 A098051 Adjacent sequences:  A195901 A195902 A195903 * A195905 A195906 A195907 KEYWORD nonn,base,easy AUTHOR Jeremy Gardiner, Sep 25 2011 EXTENSIONS More terms from Colin Barker, Jun 09 2013 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified October 20 15:07 EDT 2019. Contains 328267 sequences. (Running on oeis4.)