cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-3 of 3 results.

A119503 Increasing gaps in the even sieve (A056533) by lower term.

Original entry on oeis.org

1, 5, 11, 27, 59, 85, 131, 163, 501, 603, 1145, 1381, 1563, 1937, 2763, 3953, 6731, 7665, 10741, 13787, 22001, 30555, 47953, 52745, 60201, 111541, 137913, 162499, 186163, 282593, 343483, 351163, 386805, 476051, 522129, 540497, 660409, 714643
Offset: 1

Views

Author

Robert G. Wilson v, May 26 2006

Keywords

Examples

			The even sieve begins: 1, 3, 5, 9, 11, 17, 19, 25, 27, 35, 37 and between 1&3 there is a gap of 2;
the difference between 3&5 is also 2, but between 5&9 the difference or gap is 4; etc.
		

Crossrefs

Cf. A056533.

Programs

  • Mathematica
    lst = Range[10^6]; i = 2; While[i <= (len = Length[lst]), lst = Drop[lst, {i, len, i}]; i+=2]; l = {}; d = 0; Do[a = lst[[n + 1]] - lst[[n]]; If[a > d, d = a; AppendTo[l, lst[[n]]]], {n, Length@lst - 1}]; l

A247105 Variation of Flavius Josephus's sieve: Start with the natural numbers; at the k-th sieving step, make k passes removing every k-th term of the sequence remaining after the previous sieving step; iterate.

Original entry on oeis.org

1, 5, 25, 109, 385, 1373, 4645, 16009, 48817, 159757, 488377, 1571425, 4560901, 14482393, 43408013, 130394125, 380755429, 1118740741, 3326930413, 9931863461, 28466058257, 84243573797, 240453967777, 706827067045, 2009065808473, 5913933615149, 16711898903281
Offset: 1

Views

Author

Sergio Pimentel, Nov 18 2014

Keywords

Comments

Starting with the natural numbers, make 2 passes removing every 2nd number, 3 passes removing every 3rd number, etc.
Is the limiting value of a(n+1)/a(n)=3?
Since 1/(1-1/n)^n converges to e (as n -> inf), a(n+1)/a(n) converges to e. - Hiroaki Yamanouchi, Nov 27 2014

Examples

			The 1st pass removes 2, 4, 6, 8, 10, etc. The 2nd pass (also with 2) removes 3, 7, 11, 15, 19, etc. Then there are 3 passes removing every 3rd number, of which the 1st pass removes 9, 21, 33, 45, ..., the 2nd removes 13, 29, 49, ..., and the 3rd removes 17, 41, 73, ...; then there are 4 passes with 4; 5 passes with 5; etc.
		

Crossrefs

Programs

  • Mathematica
    A247105 = Reap[Quiet @ For[n=1, n<28, n++, m = n; For[i=n, i >= 1, i--, For[j=1, j <= i, j++, t = Floor[(m*i)/(i-1)]; While[t - Floor[t/i] >= m, t -= 1];  om = m; m = t+1]]; Sow[om]]][[2, 1]] (* Jean-François Alcover, Nov 28 2014, translated and adapted from Hiroaki Yamanouchi's Python script *)
  • PARI
    copydropmult(v,m)=vector(#v-#v\m,i,v[(i-1)*m\(m-1)+1])
    alim(n)=my(r=vector(n,i,i),j=2,k=1);while(j<#r,r=copydropmult(r,j);if(k++>j,j++;k=1));r
    
  • Python
    for n in range(1, 101):
      m = n
      for i in range(n, 1, -1):
        for j in range(i):
          t = m * i // (i - 1)
          while t - t // i >= m:
            t -= 1
          m = t + 1
      print(f"{n} {m}") # Hiroaki Yamanouchi, Nov 28 2014

Extensions

More values from Franklin T. Adams-Watters, Nov 21 2014
a(12)-a(20) from Alois P. Heinz, Nov 26 2014
a(21)-a(27) from Hiroaki Yamanouchi, Nov 27 2014

A361423 Start with natural numbers, for all positive integer periods p sieve out every p-th number p-1 times over.

Original entry on oeis.org

1, 3, 9, 27, 75, 225, 651, 1947, 5661, 15753, 44497, 128325, 357339, 1025029, 2881677, 8152327, 22251081, 62981541, 175699737, 491888331, 1353494089, 3827528649, 10655040429, 29413393659, 80737582089, 226955441541, 626061311481, 1745916338341, 4826531920159, 13166998285539
Offset: 1

Views

Author

Rok Cestnik, Jul 17 2023

Keywords

Comments

Appears to grow as: a(n) ~ c n^n/(n-1)! where c is approximately 0.56...
The terms remaining after the p-th sieve-batch grow on average with slope p^(p-1)/(p-1)!.

Examples

			Start with naturals: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, ...
Sieve out every 1st number 0 times (do nothing)
Sieve out every 2nd number 1 times: 1, 3, 5, 7, 9, 11, 13, 15, 17, 19, ...
Sieve out every 3rd number 2 times:
   first time: 1, 3, 7, 9, 13, 15, 19, 21, 25, 27, 31, 33, 37, 39, 43, ...
   second time: 1, 3, 9, 13, 19, 21, 27, 31, 37, 39, 45, 49, 55, 57, 63, ...
Sieve out every 4th number 3 times:
   first time: 1, 3, 9, 19, 21, 27, 37, 39, 45, 55, 57, 63, 73, 75, 81, ...
   second time: 1, 3, 9, 21, 27, 37, 45, 55, 57, 73, 75, 81, 93, 99, ...
   third time: 1, 3, 9, 27, 37, 45, 57, 73, 75, 93, 99, 109, 127, 129, ...
Sieve out every 5th number 4 times:
   first time: 1, 3, 9, 27, 45, 57, 73, 75, 99, 109, 127, 129, 153, 165, ...
   second time: 1, 3, 9, 27, 57, 73, 75, 99, 127, 129, 153, 165, 189, ...
   third time: 1, 3, 9, 27, 73, 75, 99, 127, 153, 165, 189, 201, 225, ...
   fourth time: 1, 3, 9, 27, 75, 99, 127, 153, 189, 201, 225, 261, 289, ...
Sieve out every 6th number 5 times:
   ...
		

Crossrefs

Cf. A000960 (sieve once each).

Programs

  • Python
    def A361423(n):
        for p in range(n,1,-1):
            for k in range(p-1):
                n += (n-1)//(p-1)
        return n
    # Bert Dobbelaere, Jul 21 2023

Extensions

More terms from Bert Dobbelaere, Jul 21 2023
Showing 1-3 of 3 results.