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-8 of 8 results.

A260714 Row 4 of A260717.

Original entry on oeis.org

7, 11, 13, 17, 23, 25, 29, 31, 37, 41, 43, 47, 53, 55, 59, 61, 67, 71, 73, 77, 83, 85, 89, 91, 97, 101, 103, 107, 113, 115, 119, 121, 127, 131, 133, 137, 143, 145, 149, 151, 157, 161, 163, 167, 173, 175, 179, 181, 187, 191, 193, 197, 203, 205, 209, 211, 217, 221, 223, 227, 233, 235, 239, 241, 247, 251, 253, 257
Offset: 1

Views

Author

Antti Karttunen, Jul 30 2015

Keywords

Crossrefs

Row 4 of A260717.
Setwise difference of A007310(2..) \ A255413.
Cf. A255414 (only every seventh term of this sequence, starting from 7).

Programs

Formula

Other identities. For all n >= 1:
a(1+(7*(n-1))) = A255414(n).

A260715 Row 5 of A260717.

Original entry on oeis.org

11, 13, 17, 23, 25, 29, 37, 41, 43, 47, 53, 55, 61, 67, 71, 73, 77, 83, 89, 91, 97, 101, 103, 107, 115, 119, 121, 127, 131, 133, 143, 145, 149, 151, 157, 161, 167, 173, 175, 179, 181, 187, 193, 197, 203, 205, 209, 211, 221, 223, 227, 233, 235, 239, 247, 251, 253, 257, 263, 265, 271, 277, 281, 283, 287, 293, 299, 301, 307, 311, 313
Offset: 1

Views

Author

Antti Karttunen, Jul 30 2015

Keywords

Crossrefs

Row 5 of A260717.
Setwise difference of A260714 \ A255414.
Cf. A255415 (only every eleventh term of this sequence, starting from 11).
Differs from A003309(n+5) for the first time at n=12, as a(12) = 55, the first nonludic number to be removed at stage 5 of the sieve, which is missing from A003309.

Programs

Formula

Other identities. For all n >= 1:
a(1+(11*(n-1))) = A255415(n).

A260718 Square array A260717 transposed.

Original entry on oeis.org

2, 3, 3, 5, 5, 4, 7, 7, 7, 5, 11, 11, 11, 9, 6, 13, 13, 13, 13, 11, 7, 17, 17, 17, 17, 17, 13, 8, 23, 23, 23, 23, 23, 19, 15, 9, 25, 25, 25, 25, 25, 25, 23, 17, 10, 29, 29, 29, 29, 29, 29, 29, 25, 19, 11, 37, 37, 37, 37, 37, 37, 37, 31, 29, 21, 12, 41, 41, 41, 41, 41, 41, 41, 41, 37, 31, 23, 13, 43, 43, 43, 43, 43, 43, 43, 43, 43, 41, 35, 25, 14
Offset: 1

Views

Author

Antti Karttunen, Jul 30 2015

Keywords

Examples

			The top left corner of the array:
   2,  3,  5,  7, 11, 13, 17, 23,  25,  29,  37,  41,  43,  47,  53,  61
   3,  5,  7, 11, 13, 17, 23, 25,  29,  37,  41,  43,  47,  53,  61,  67
   4,  7, 11, 13, 17, 23, 25, 29,  37,  41,  43,  47,  53,  61,  67,  71
   5,  9, 13, 17, 23, 25, 29, 37,  41,  43,  47,  53,  61,  67,  71,  77
   6, 11, 17, 23, 25, 29, 37, 41,  43,  47,  53,  61,  67,  71,  77,  83
   7, 13, 19, 25, 29, 37, 41, 43,  47,  53,  61,  67,  71,  77,  83,  89
   8, 15, 23, 29, 37, 41, 43, 47,  53,  61,  67,  71,  77,  83,  89,  91
   9, 17, 25, 31, 41, 43, 47, 53,  61,  67,  71,  77,  83,  89,  91,  97
  10, 19, 29, 37, 43, 47, 53, 61,  67,  71,  77,  83,  89,  91,  97, 107
  11, 21, 31, 41, 47, 53, 61, 67,  71,  77,  83,  89,  91,  97, 107, 115
  12, 23, 35, 43, 53, 61, 67, 71,  77,  83,  89,  91,  97, 107, 115, 119
  13, 25, 37, 47, 55, 67, 71, 77,  83,  89,  91,  97, 107, 115, 119, 121
  14, 27, 41, 53, 61, 71, 77, 83,  89,  91,  97, 107, 115, 119, 121, 127
  15, 29, 43, 55, 67, 73, 83, 89,  91,  97, 107, 115, 119, 121, 127, 131
  16, 31, 47, 59, 71, 77, 89, 91,  97, 107, 115, 119, 121, 127, 131, 143
  17, 33, 49, 61, 73, 83, 91, 97, 107, 115, 119, 121, 127, 131, 143, 149
  etc.
		

Crossrefs

Transpose: A260717.

Programs

A007310 Numbers congruent to 1 or 5 mod 6.

Original entry on oeis.org

1, 5, 7, 11, 13, 17, 19, 23, 25, 29, 31, 35, 37, 41, 43, 47, 49, 53, 55, 59, 61, 65, 67, 71, 73, 77, 79, 83, 85, 89, 91, 95, 97, 101, 103, 107, 109, 113, 115, 119, 121, 125, 127, 131, 133, 137, 139, 143, 145, 149, 151, 155, 157, 161, 163, 167, 169, 173, 175
Offset: 1

Views

Author

C. Christofferson (Magpie56(AT)aol.com)

Keywords

Comments

Numbers n such that phi(4n) = phi(3n). - Benoit Cloitre, Aug 06 2003
Or, numbers relatively prime to 2 and 3, or coprime to 6, or having only prime factors >= 5; also known as 5-rough numbers. (Edited by M. F. Hasler, Nov 01 2014: merged with comments from Zak Seidov, Apr 26 2007 and Michael B. Porter, Oct 09 2009)
Apart from initial term(s), dimension of the space of weight 2n cuspidal newforms for Gamma_0( 38 ).
Numbers k such that k mod 2 = 1 and (k+1) mod 3 <> 1. - Klaus Brockhaus, Jun 15 2004
Also numbers n such that the sum of the squares of the first n integers is divisible by n, or A000330(n) = n*(n+1)*(2*n+1)/6 is divisible by n. - Alexander Adamchuk, Jan 04 2007
Numbers n such that the sum of squares of n consecutive integers is divisible by n, because A000330(m+n) - A000330(m) = n*(n+1)*(2*n+1)/6 + n*(m^2+n*m+m) is divisible by n independent of m. - Kaupo Palo, Dec 10 2016
A126759(a(n)) = n + 1. - Reinhard Zumkeller, Jun 16 2008
Terms of this sequence (starting from the second term) are equal to the result of the expression sqrt(4!*(k+1) + 1) - but only when this expression yields integral values (that is when the parameter k takes values, which are terms of A144065). - Alexander R. Povolotsky, Sep 09 2008
For n > 1: a(n) is prime if and only if A075743(n-2) = 1; a(2*n-1) = A016969(n-1), a(2*n) = A016921(n-1). - Reinhard Zumkeller, Oct 02 2008
A156543 is a subsequence. - Reinhard Zumkeller, Feb 10 2009
Numbers n such that ChebyshevT(x, x/2) is not an integer (is integer/2). - Artur Jasinski, Feb 13 2010
If 12*k + 1 is a perfect square (k = 0, 2, 4, 10, 14, 24, 30, 44, ... = A152749) then the square root of 12*k + 1 = a(n). - Gary Detlefs, Feb 22 2010
A089128(a(n)) = 1. Complement of A047229(n+1) for n >= 1. See A164576 for corresponding values A175485(a(n)). - Jaroslav Krizek, May 28 2010
Cf. property described by Gary Detlefs in A113801 and in Comment: more generally, these numbers are of the form (2*h*n+(h-4)*(-1)^n-h)/4 (with h, n natural numbers), therefore ((2*h*n+(h-4)*(-1)^n-h)/4)^2-1 == 0 (mod h); in this case, a(n)^2 - 1 == 0 (mod 6). Also a(n)^2 - 1 == 0 (mod 12). - Bruno Berselli, Nov 05 2010 - Nov 17 2010
Numbers n such that ( Sum_{k = 1..n} k^14 ) mod n = 0. (Conjectured) - Gary Detlefs, Dec 27 2011
From Peter Bala, May 02 2018: (Start)
The above conjecture is true. Apply Ireland and Rosen, Proposition 15.2.2. with m = 14 to obtain the congruence 6*( Sum_{k = 1..n} k^14 )/n = 7 (mod n), true for all n >= 1. Suppose n is coprime to 6, then 6 is a unit in Z/nZ, and it follows from the congruence that ( Sum_{k = 1..n} k^14 )/n is an integer. On the other hand, if either 2 divides n or 3 divides n then the congruence shows that ( Sum_{k = 1..n} k^14 )/n cannot be integral. (End)
A126759(a(n)) = n and A126759(m) < n for m < a(n). - Reinhard Zumkeller, May 23 2013
(a(n-1)^2 - 1)/24 = A001318(n), the generalized pentagonal numbers. - Richard R. Forberg, May 30 2013
Numbers k for which A001580(k) is divisible by 3. - Bruno Berselli, Jun 18 2014
Numbers n such that sigma(n) + sigma(2n) = sigma(3n). - Jahangeer Kholdi and Farideh Firoozbakht, Aug 15 2014
a(n) are values of k such that Sum_{m = 1..k-1} m*(k-m)/k is an integer. Sums for those k are given by A062717. Also see Detlefs formula below based on A062717. - Richard R. Forberg, Feb 16 2015
a(n) are exactly those positive integers m such that the sequence b(n) = n*(n + m)*(n + 2*m)/6 is integral, and also such that the sequence c(n) = n*(n + m)*(n + 2*m)*(n + 3*m)/24 is integral. Cf. A007775. - Peter Bala, Nov 13 2015
Along with 2, these are the numbers k such that the k-th Fibonacci number is coprime to every Lucas number. - Clark Kimberling, Jun 21 2016
This sequence is the Engel expansion of 1F2(1; 5/6, 7/6; 1/36) + 1F2(1; 7/6, 11/6; 1/36)/5. - Benedict W. J. Irwin, Dec 16 2016
The sequence a(n), n >= 4 is generated by the successor of the pair of polygonal numbers {P_s(4) + 1, P_(2*s - 1)(3) + 1}, s >= 3. - Ralf Steiner, May 25 2018
The asymptotic density of this sequence is 1/3. - Amiram Eldar, Oct 18 2020
Also, the only vertices in the odd Collatz tree A088975 that are branch values to other odd nodes t == 1 (mod 2) of A005408. - Heinz Ebert, Apr 14 2021
From Flávio V. Fernandes, Aug 01 2021: (Start)
For any two terms j and k, the product j*k is also a term (the same property as p^n and smooth numbers).
From a(2) to a(phi(A033845(n))), or a((A033845(n))/3), the terms are the totatives of the A033845(n) itself. (End)
Also orders n for which cyclic and semicyclic diagonal Latin squares exist (see A123565 and A342990). - Eduard I. Vatutin, Jul 11 2023
If k is in the sequence, then k*2^m + 3 is also in the sequence, for all m > 0. - Jules Beauchamp, Aug 29 2024

Examples

			G.f. = x + 5*x^2 + 7*x^3 + 11*x^4 + 13*x^5 + 17*x^6 + 19*x^7 + 23*x^8 + ...
		

References

  • K. Ireland and M. Rosen, A Classical Introduction to Modern Number Theory, Springer-Verlag, 1980.

Crossrefs

A005408 \ A016945. Union of A016921 and A016969; union of A038509 and A140475. Essentially the same as A038179. Complement of A047229. Subsequence of A186422.
Cf. A000330, A001580, A002194, A019670, A032528 (partial sums), A038509 (subsequence of composites), A047209, A047336, A047522, A056020, A084967, A090771, A091998, A144065, A175885-A175887.
For k-rough numbers with other values of k, see A000027, A005408, A007775, A008364-A008366, A166061, A166063.
Cf. A126760 (a left inverse).
Row 3 of A260717 (without the initial 1).
Cf. A105397 (first differences).

Programs

Formula

a(n) = (6*n + (-1)^n - 3)/2. - Antonio Esposito, Jan 18 2002
a(n) = a(n-1) + a(n-2) - a(n-3), n >= 4. - Roger L. Bagula
a(n) = 3*n - 1 - (n mod 2). - Zak Seidov, Jan 18 2006
a(1) = 1 then alternatively add 4 and 2. a(1) = 1, a(n) = a(n-1) + 3 + (-1)^n. - Zak Seidov, Mar 25 2006
1 + 1/5^2 + 1/7^2 + 1/11^2 + ... = Pi^2/9 [Jolley]. - Gary W. Adamson, Dec 20 2006
For n >= 3 a(n) = a(n-2) + 6. - Zak Seidov, Apr 18 2007
From R. J. Mathar, May 23 2008: (Start)
Expand (x+x^5)/(1-x^6) = x + x^5 + x^7 + x^11 + x^13 + ...
O.g.f.: x*(1+4*x+x^2)/((1+x)*(1-x)^2). (End)
a(n) = 6*floor(n/2) - 1 + 2*(n mod 2). - Reinhard Zumkeller, Oct 02 2008
1 + 1/5 - 1/7 - 1/11 + + - - ... = Pi/3 = A019670 [Jolley eq (315)]. - Jaume Oliver Lafont, Oct 23 2009
a(n) = ( 6*A062717(n)+1 )^(1/2). - Gary Detlefs, Feb 22 2010
a(n) = 6*A000217(n-1) + 1 - 2*Sum_{i=1..n-1} a(i), with n > 1. - Bruno Berselli, Nov 05 2010
a(n) = 6*n - a(n-1) - 6 for n>1, a(1) = 1. - Vincenzo Librandi, Nov 18 2010
Sum_{n >= 1} (-1)^(n+1)/a(n) = A093766 [Jolley eq (84)]. - R. J. Mathar, Mar 24 2011
a(n) = 6*floor(n/2) + (-1)^(n+1). - Gary Detlefs, Dec 29 2011
a(n) = 3*n + ((n+1) mod 2) - 2. - Gary Detlefs, Jan 08 2012
a(n) = 2*n + 1 + 2*floor((n-2)/2) = 2*n - 1 + 2*floor(n/2), leading to the o.g.f. given by R. J. Mathar above. - Wolfdieter Lang, Jan 20 2012
1 - 1/5 + 1/7 - 1/11 + - ... = Pi*sqrt(3)/6 = A093766 (L. Euler). - Philippe Deléham, Mar 09 2013
1 - 1/5^3 + 1/7^3 - 1/11^3 + - ... = Pi^3*sqrt(3)/54 (L. Euler). - Philippe Deléham, Mar 09 2013
gcd(a(n), 6) = 1. - Reinhard Zumkeller, Nov 14 2013
a(n) = sqrt(6*n*(3*n + (-1)^n - 3)-3*(-1)^n + 5)/sqrt(2). - Alexander R. Povolotsky, May 16 2014
a(n) = 3*n + 6/(9*n mod 6 - 6). - Mikk Heidemaa, Feb 05 2016
From Mikk Heidemaa, Feb 11 2016: (Start)
a(n) = 2*floor(3*n/2) - 1.
a(n) = A047238(n+1) - 1. (suggested by Michel Marcus) (End)
E.g.f.: (2 + (6*x - 3)*exp(x) + exp(-x))/2. - Ilya Gutkovskiy, Jun 18 2016
From Bruno Berselli, Apr 27 2017: (Start)
a(k*n) = k*a(n) + (4*k + (-1)^k - 3)/2 for k>0 and odd n, a(k*n) = k*a(n) + k - 1 for even n. Some special cases:
k=2: a(2*n) = 2*a(n) + 3 for odd n, a(2*n) = 2*a(n) + 1 for even n;
k=3: a(3*n) = 3*a(n) + 4 for odd n, a(3*n) = 3*a(n) + 2 for even n;
k=4: a(4*n) = 4*a(n) + 7 for odd n, a(4*n) = 4*a(n) + 3 for even n;
k=5: a(5*n) = 5*a(n) + 8 for odd n, a(5*n) = 5*a(n) + 4 for even n, etc. (End)
From Antti Karttunen, May 20 2017: (Start)
a(A273669(n)) = 5*a(n) = A084967(n).
a((5*n)-3) = A255413(n).
A126760(a(n)) = n. (End)
a(2*m) = 6*m - 1, m >= 1; a(2*m + 1) = 6*m + 1, m >= 0. - Ralf Steiner, May 17 2018
From Amiram Eldar, Nov 22 2024: (Start)
Product_{n>=1} (1 - (-1)^n/a(n)) = sqrt(3) (A002194).
Product_{n>=2} (1 + (-1)^n/a(n)) = Pi/3 (A019670). (End)

A003309 Ludic numbers: apply the same sieve as Eratosthenes, but cross off every k-th remaining number.

Original entry on oeis.org

1, 2, 3, 5, 7, 11, 13, 17, 23, 25, 29, 37, 41, 43, 47, 53, 61, 67, 71, 77, 83, 89, 91, 97, 107, 115, 119, 121, 127, 131, 143, 149, 157, 161, 173, 175, 179, 181, 193, 209, 211, 221, 223, 227, 233, 235, 239, 247, 257, 265, 277, 283, 287, 301, 307, 313
Offset: 1

Views

Author

Keywords

Comments

The definition can obviously only be applied from k = a(2) = 2 on: for k = 1, all remaining numbers would be deleted. - M. F. Hasler, Nov 02 2024

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Without the initial 1 occurs as the leftmost column in arrays A255127 and A260717.
Cf. A003310, A003311, A100464, A100585, A100586 (variants).
Cf. A192503 (primes in sequence), A192504 (nonprimes), A192512 (number of terms <= n).
Cf. A192490 (characteristic function).
Cf. A192607 (complement).
Cf. A260723 (first differences).
Cf. A255420 (iterates of f(n) = A003309(n+1) starting from n=1).
Subsequence of A302036.
Cf. A237056, A237126, A237427, A235491, A255407, A255408, A255421, A255422, A260435, A260436, A260741, A260742 (permutations constructed from Ludic numbers).
Cf. also A000959, A008578, A255324, A254100, A272565 (Ludic factor of n), A297158, A302032, A302038.
Cf. A376237 (ludic factorial: cumulative product), A376236 (ludic Fortunate numbers).

Programs

  • Haskell
    a003309 n = a003309_list !! (n - 1)
    a003309_list = 1 : f [2..] :: [Int]
       where f (x:xs) = x : f (map snd [(u, v) | (u, v) <- zip [1..] xs,
                                                 mod u x > 0])
    -- Reinhard Zumkeller, Feb 10 2014, Jul 03 2011
    
  • Maple
    ludic:= proc(N) local i, k,S,R;
      S:= {$2..N};
      R:= 1;
      while nops(S) > 0 do
        k:= S[1];
        R:= R,k;
        S:= subsop(seq(1+k*j=NULL, j=0..floor((nops(S)-1)/k)),S);
      od:
    [R];
    end proc:
    ludic(1000); # Robert Israel, Feb 23 2015
  • Mathematica
    t = Range[2, 400]; r = {1}; While[Length[t] > 0, k = First[t]; AppendTo[r, k]; t = Drop[t, {1, -1, k}];]; r (* Ray Chandler, Dec 02 2004 *)
  • PARI
    t=vector(399,x,x+1); r=[1]; while(length(t)>0, k=t[1];r=concat(r,[k]);t=vector((length(t)*(k-1))\k,x,t[(x*k+k-2)\(k-1)])); r \\ Phil Carmody, Feb 07 2007
    
  • PARI
    A3309=[1]; next_A003309(n)=nn && break); n+!if(n=setsearch(A3309,n+1,1),return(A3309[n])) \\ Should be made more efficient if n >> max(A3309). - M. F. Hasler, Nov 02 2024
    {A003309(n) = while(n>#A3309, next_A003309(A3309[#A3309])); A3309[n]} \\ Should be made more efficient in case n >> #A3309. - M. F. Hasler, Nov 03 2024
    
  • PARI
    upto(nn)= my(r=List([1..nn]), p=1); while(p++<#r, my(k=r[p], i=p); while((i+=k)<=#r, listpop(~r, i); i--)); Vec(r); \\ Ruud H.G. van Tol, Dec 13 2024
    
  • Python
    remainders = [0]
    ludics = [2]
    N_MAX = 313
    for i in range(3, N_MAX) :
        ludic_index = 0
        while ludic_index < len(ludics) :
            ludic = ludics[ludic_index]
            remainder = remainders[ludic_index]
            remainders[ludic_index] = (remainder + 1) % ludic
            if remainders[ludic_index] == 0 :
                break
            ludic_index += 1
        if ludic_index == len(ludics) :
            remainders.append(0)
            ludics.append(i)
    ludics = [1] + ludics
    print(ludics)
    # Alexandre Herrera, Aug 10 2023
    
  • Python
    def A003309(): # generator of the infinite list of ludic numbers
        L = [2, 3]; yield 1; yield 2; yield 3
        while k := len(L)//2: # could take min{k | k >= L[-1-k]-1}
            for j in L[-1-k::-1]: k += 1 + k//(j-1)
            L.append(k+2); yield k+2
    A003309_upto = lambda N=99: [t for t,_ in zip(A003309(),range(N))]
    # M. F. Hasler, Nov 02 2024
  • Scheme
    (define (A003309 n) (if (= 1 n) n (A255127bi (- n 1) 1))) ;; Code for A255127bi given in A255127.
    ;; Antti Karttunen, Feb 23 2015
    

Formula

Complement of A192607; A192490(a(n)) = 1. - Reinhard Zumkeller, Jul 05 2011
From Antti Karttunen, Feb 23 2015: (Start)
a(n) = A255407(A008578(n)).
a(n) = A008578(n) + A255324(n).
(End)

Extensions

More terms from David Applegate and N. J. A. Sloane, Nov 23 2004

A255127 Ludic array: square array A(row,col), where row n lists the numbers removed at stage n in the sieve which produces Ludic numbers. Array is read by antidiagonals A(1,1), A(1,2), A(2,1), A(1,3), A(2,2), A(3,1), ...

Original entry on oeis.org

2, 4, 3, 6, 9, 5, 8, 15, 19, 7, 10, 21, 35, 31, 11, 12, 27, 49, 59, 55, 13, 14, 33, 65, 85, 103, 73, 17, 16, 39, 79, 113, 151, 133, 101, 23, 18, 45, 95, 137, 203, 197, 187, 145, 25, 20, 51, 109, 163, 251, 263, 281, 271, 167, 29, 22, 57, 125, 191, 299, 325, 367, 403, 311, 205, 37, 24, 63, 139, 217, 343, 385, 461, 523, 457, 371, 253, 41
Offset: 2

Views

Author

Antti Karttunen, Feb 22 2015

Keywords

Comments

The starting offset of the sequence giving the terms of square array is 2. However, we can tacitly assume that a(1) = 1 when the sequence is used as a permutation of natural numbers. However, term 1 itself is out of the array.
The choice of offset = 2 for the terms starting in rows >= 1 is motivated by the desire to have a permutation of the integers n -> a(n) with a(n) = A(A002260(n-1), A004736(n-1)) for n > 1 and a(1) := 1. However, since this sequence is declared as a "table", offset = 2 would mean that the first *row* (not element) has index 2. I think the sequence should have offset = 1 and the permutation of the integers would be n -> a(n-1) with a(0) := 1 (if a(1) = A(1,1) = 2). Or, the sequence could have offset 0, with an additional row 0 of length 1 with the only element a(0) = A(0,1) = 1, the permutation still being n -> a(n-1) if a(n=0, 1, 2, ...) = (1, 2, 4, ...). This would be in line with considering 1 as the first ludic number, and A(n, 1) = A003309(n+1) for n >= 0. - M. F. Hasler, Nov 12 2024

Examples

			The top left corner of the array:
   2,   4,   6,   8,  10,  12,   14,   16,   18,   20,   22,   24,   26
   3,   9,  15,  21,  27,  33,   39,   45,   51,   57,   63,   69,   75
   5,  19,  35,  49,  65,  79,   95,  109,  125,  139,  155,  169,  185
   7,  31,  59,  85, 113, 137,  163,  191,  217,  241,  269,  295,  323
  11,  55, 103, 151, 203, 251,  299,  343,  391,  443,  491,  539,  587
  13,  73, 133, 197, 263, 325,  385,  449,  511,  571,  641,  701,  761
  17, 101, 187, 281, 367, 461,  547,  629,  721,  809,  901,  989, 1079
  23, 145, 271, 403, 523, 655,  781,  911, 1037, 1157, 1289, 1417, 1543
  25, 167, 311, 457, 599, 745,  883, 1033, 1181, 1321, 1469, 1615, 1753
  29, 205, 371, 551, 719, 895, 1073, 1243, 1421, 1591, 1771, 1945, 2117
...
		

Crossrefs

Transpose: A255129.
Inverse: A255128. (When considered as a permutation of natural numbers with a(1) = 1).
Cf. A260738 (index of the row where n occurs), A260739 (of the column).
Main diagonal: A255410.
Column 1: A003309 (without the initial 1). Column 2: A254100.
Row 1: A005843, Row 2: A016945, Row 3: A255413, Row 4: A255414, Row 5: A255415, Row 6: A255416, Row 7: A255417, Row 8: A255418, Row 9: A255419.
A192607 gives all the numbers right of the leftmost column, and A192506 gives the composites among them.
Cf. A272565, A271419, A271420 and permutations A269379, A269380, A269384.
Cf. also related or derived arrays A260717, A257257, A257258 (first differences of rows), A276610 (of columns), A276580.
Analogous arrays for other sieves: A083221, A255551, A255543.
Cf. A376237 (ludic factorials), A377469 (ludic analog of A005867).

Programs

  • Mathematica
    rows = 12; cols = 12; t = Range[2, 3000]; r = {1}; n = 1; While[n <= rows, k = First[t]; AppendTo[r, k]; t0 = t; t = Drop[t, {1, -1, k}]; ro[n++] = Complement[t0, t][[1 ;; cols]]]; A = Array[ro, rows]; Table[ A[[n - k + 1, k]], {n, 1, rows}, {k, n, 1, -1}] // Flatten (* Jean-François Alcover, Mar 14 2016, after Ray Chandler *)
  • Python
    a255127 = lambda n: A255127(A002260(k-1), A004736(k-1))
    def A255127(n, k):
        A = A255127; R = A.rows
        while len(R) <= n or len(R[n]) < min(k, A.P[n]): A255127_extend(2*n)
        return R[n][(k-1) % A.P[n]] + (k-1)//A.P[n] * A.S[n]
    A=A255127; A.rows=[[1],[2],[3]]; A.P=[1]*3; A.S=[0,2,6]; A.limit=30
    def A255127_extend(rMax=9, A=A255127):
        A.limit *= 2; L = [x+5-x%2 for x in range(0, A.limit, 3)]
        for r in range(3, rMax):
            if len(A.P) == r:
                A.P += [ A.P[-1] * (A.rows[-1][0] - 1) ]  # A377469
                A.rows += [[]]; A.S += [ A.S[-1] * L[0] ] # ludic factorials
            if len(R := A.rows[r]) < A.P[r]: # append more terms to this row
                R += L[ L[0]*len(R) : A.S[r] : L[0] ]
            L = [x for i, x in enumerate(L) if i%L[0]] # M. F. Hasler, Nov 17 2024
  • Scheme
    (define (A255127 n) (if (<= n 1) n (A255127bi (A002260 (- n 1)) (A004736 (- n 1)))))
    (define (A255127bi row col) ((rowfun_n_for_A255127 row) col))
    ;; definec-macro memoizes its results:
    (definec (rowfun_n_for_A255127 n) (if (= 1 n) (lambda (n) (+ n n)) (let* ((rowfun_for_remaining (rowfun_n_for_remaining_numbers (- n 1))) (eka (rowfun_for_remaining 0))) (COMPOSE rowfun_for_remaining (lambda (n) (* eka (- n 1)))))))
    (definec (rowfun_n_for_remaining_numbers n) (if (= 1 n) (lambda (n) (+ n n 3)) (let* ((rowfun_for_prevrow (rowfun_n_for_remaining_numbers (- n 1))) (off (rowfun_for_prevrow 0))) (COMPOSE rowfun_for_prevrow (lambda (n) (+ 1 n (floor->exact (/ n (- off 1)))))))))
    

Formula

From M. F. Hasler, Nov 12 2024: (Start)
A(r, c) = A(r, c-P(r)) + S(r) = A(r, ((c-1) mod P(r)) + 1) + floor((c-1)/P(r))*S(r) with periods P = (1, 1, 2, 8, 48, 480, 5760, ...) = A377469, and shifts S = (2, 6, 30, 210, 2310, 30030, 510510) = A376237(2, 3, ...). For example:
A(1, c) = A(1, c-1) + 2 = 2 + (c-1)*2 = 2*c,
A(2, c) = A(2, c-1) + 6 = 3 + (c-1)*6 = 6*c - 3,
A(3, c) = A(3, c-2) + 30 = {5 if c is odd else 19} + floor((c-1)/2)*30 = 15*c - 11 + (c mod 2),
A(4, c) = A(4, c-8) + 210 = A(4, ((c-1) mod 8)+1) + floor((c-1)/8)*210, etc. (End)

A258207 Square array: row n gives the numbers remaining after the stage n of Lucky sieve.

Original entry on oeis.org

1, 3, 1, 5, 3, 1, 7, 7, 3, 1, 9, 9, 7, 3, 1, 11, 13, 9, 7, 3, 1, 13, 15, 13, 9, 7, 3, 1, 15, 19, 15, 13, 9, 7, 3, 1, 17, 21, 21, 15, 13, 9, 7, 3, 1, 19, 25, 25, 21, 15, 13, 9, 7, 3, 1, 21, 27, 27, 25, 21, 15, 13, 9, 7, 3, 1, 23, 31, 31, 31, 25, 21, 15, 13, 9, 7, 3, 1, 25, 33, 33, 33, 31, 25, 21, 15, 13, 9, 7, 3, 1, 27, 37, 37, 37, 33, 31, 25, 21, 15, 13, 9, 7, 3, 1, 29, 39, 43, 43, 37, 33, 31, 25, 21, 15, 13, 9, 7, 3, 1
Offset: 1

Views

Author

Antti Karttunen, Jul 27 2015

Keywords

Comments

This square array A(row,col) is read by downwards antidiagonals as: A(1,1), A(1,2), A(2,1), A(1,3), A(2,2), A(3,1), etc.
Lucky sieve starts with natural numbers: 1, 2, 3, 4, 5, 6, 7, ... from which at first stage the even numbers are removed, and on each subsequent stage n (n > 1) one sets k = (these k will form the Lucky numbers) and removes every k-th term (from column positions k, 2k, 3k, etc.) of the preceding row to produce the next row of this array.
On each row n, the first term that differs from the n-th Lucky number (A000959(n)) occurs at the column position A000959(n+1) and that number is A219178(n) when n > 1.

Examples

			The top left corner of the array:
1, 3, 5, 7,  9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39
1, 3, 7, 9, 13, 15, 19, 21, 25, 27, 31, 33, 37, 39, 43, 45, 49, 51, 55, 57
1, 3, 7, 9, 13, 15, 21, 25, 27, 31, 33, 37, 43, 45, 49, 51, 55, 57, 63, 67
1, 3, 7, 9, 13, 15, 21, 25, 31, 33, 37, 43, 45, 49, 51, 55, 63, 67, 69, 73
1, 3, 7, 9, 13, 15, 21, 25, 31, 33, 37, 43, 49, 51, 55, 63, 67, 69, 73, 75
1, 3, 7, 9, 13, 15, 21, 25, 31, 33, 37, 43, 49, 51, 63, 67, 69, 73, 75, 79
...
To get row 2 from row 1, we use the second term of the first row, which is 3, to remove every third term from row 1: 5, 11, 17, ... which leaves 1, 3, 7, 9, 13, ...
To get row 3 from row 2, we use the third term of row 2, which is 7, to remove every seventh term from row 2: 19, 39, ... which then results in the third row.
		

Crossrefs

Cf. A000959 (Lucky numbers), which occur at the main and also any subdiagonal of this array. Also the rows converge towards A000959.
Row 1: A005408. Row 2: A047241. Row 3: A258011.
Transpose: A258208.
Cf. also A219178, A255543, A260717.

Programs

  • Scheme
    (define (A258207 n) (A258207bi (A002260 n) (A004736 n)))
    (define (A258207bi row col) ((rowfun_n_for_A000959sieve row) col))
    ;; Uses definec-macro which can memoize also function-closures:
    (definec (rowfun_n_for_A000959sieve n) (if (= 1 n) A005408shifted (let* ((prevrowfun (rowfun_n_for_A000959sieve (- n 1))) (everynth (prevrowfun n))) (compose-funs prevrowfun (nonzero-pos 1 1 (lambda (i) (modulo i everynth)))))))
    (define (A005408shifted n) (- (* 2 n) 1))

A278492 Square array where row n (n >= 0) gives the numbers remaining after the n-th round of the Flavius sieve, read by descending antidiagonals.

Original entry on oeis.org

1, 2, 1, 3, 3, 1, 4, 5, 3, 1, 5, 7, 7, 3, 1, 6, 9, 9, 7, 3, 1, 7, 11, 13, 13, 7, 3, 1, 8, 13, 15, 15, 13, 7, 3, 1, 9, 15, 19, 19, 19, 13, 7, 3, 1, 10, 17, 21, 25, 25, 19, 13, 7, 3, 1, 11, 19, 25, 27, 27, 27, 19, 13, 7, 3, 1, 12, 21, 27, 31, 31, 31, 27, 19, 13, 7, 3, 1, 13, 23, 31, 37, 39, 39, 39, 27, 19, 13, 7, 3, 1
Offset: 0

Views

Author

Antti Karttunen, Nov 23 2016, after David W. Wilson's posting on SeqFan-list Nov 22 2016

Keywords

Comments

The terms of square array A(row,col) are read by descending antidiagonals as A(0,0), A(0,1), A(1,0), A(0,2), A(1,1), A(2,0), ...

Examples

			The top left corner of the array:
1, 2, 3,  4,  5,  6,  7,  8,  9, 10 (row 0: start from A000027)
1, 3, 5,  7,  9, 11, 13, 15, 17, 19 (after the 1st round, A005408 remain)
1, 3, 7,  9, 13, 15, 19, 21, 25, 27 (after the 2nd, A047241)
1, 3, 7, 13, 15, 19, 25, 27, 31, 37
1, 3, 7, 13, 19, 25, 27, 31, 39, 43
1, 3, 7, 13, 19, 27, 31, 39, 43, 49
1, 3, 7, 13, 19, 27, 39, 43, 49, 61
1, 3, 7, 13, 19, 27, 39, 49, 61, 63
1, 3, 7, 13, 19, 27, 39, 49, 63, 67
1, 3, 7, 13, 19, 27, 39, 49, 63, 79
		

Crossrefs

One more than A278482.
Transpose: A278493.
Main diagonal: A000960.
Cf. A278507 (the numbers removed at each round).
Similarly constructed arrays for other sieves: A258207, A260717.

Programs

Formula

A(n,k) = 1 + A278482(n,k).
Showing 1-8 of 8 results.