# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/ Search: id:a007952 Showing 1-1 of 1 %I A007952 #61 Sep 30 2022 07:50:11 %S A007952 0,1,3,5,9,11,17,21,29,33,41,47,57,59,77,81,101,107,117,131,149,153, %T A007952 173,191,209,213,239,257,273,281,321,329,359,371,401,417,441,453,497, %U A007952 509,539,569,611,621,647,671,717,731,779,801,839,869,917,929,989,1001,1053,1067 %N A007952 Generated by a sieve: keep first number, drop every 2nd, keep first, drop every 3rd, keep first, drop every 4th, etc. %C A007952 Also called the sieve of Tchoukaillon (or Mancala, or Kalahari). %C A007952 If k+1 occurs at rank i for the first time, then i is given by the program: i = 0: for j = k to 1 step -1: i = 1 + i + int ( i / j ): next: - Claude Lenormand (claude.lenormand(AT)free.fr), Jan 15 2001 %C A007952 A082447(n+1) = (number of terms <= n); see A141262 for primes. - _Reinhard Zumkeller_, Jun 21 2008 %D A007952 Y. David, On a sequence generated by a sieving process, Riveon Lematematika, 11 (1957), 26-31. %D A007952 M. Le, On the Smarandache n-ary Sieve, Smarandache Notions Journal, Vol. 10, No. 1-2-3, 1999, 146-147. %H A007952 L. K. Mitchell, Table of n, a(n) for n = 0..7549 %H A007952 D. Betten, Kalahari and the Sequence "Sloane No. 377", Annals Discrete Math., 37, 51-58, 1988. %H A007952 D. M. Broline and Daniel E. Loeb, The combinatorics of Mancala-Type games: Ayo, Tchoukaillon and 1/Pi, arXiv:math/9502225 [math.CO], 1995; J. Undergrad. Math. Applic., vol. 16 (1995), pp. 21-36. %H A007952 P. Erdős and E. Jabotinsky, On a sequence of integers ..., Indagationes Math., 20, 115-128, 1958. part I part II %H A007952 N. J. A. Sloane, My favorite integer sequences, in Sequences and their Applications (Proceedings of SETA '98). %H A007952 F. Smarandache, Only Problems, Not Solutions! %H A007952 Index entries for sequences generated by sieves %F A007952 Equals A002491(n) - 1. Equals A108696 - 2. %t A007952 f[n_] := Fold[#2*Floor[#1/#2 + 1] &, n, Reverse@ Range[n - 1]]; Array[f, 55] (* From David Wilson *) %o A007952 (Haskell) %o A007952 a007952 n = a007952_list !! n %o A007952 a007952_list = f 1 [0..] where %o A007952 f k (x:xs) = x : f (k + 1) (g xs) where %o A007952 g ws = us ++ (g vs) where (us, _:vs) = splitAt k ws %o A007952 -- _Reinhard Zumkeller_, Jan 19 2014 %o A007952 (PARI) a(n) = my(ret=0); forstep(k=n,1,-1, ret++; ret+=(-ret)%k); ret; \\ _Kevin Ryde_, Sep 30 2022 %Y A007952 Cf. A002491, A028920, A028931, A028932, A028933, A108696, A140060, A141271, A141272. %K A007952 nonn,easy,nice %O A007952 0,3 %A A007952 _N. J. A. Sloane_, R. Muller %E A007952 Corrected and extended by _David W. Wilson_ # Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE