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

A090864 Complement of generalized pentagonal numbers (A001318).

Original entry on oeis.org

3, 4, 6, 8, 9, 10, 11, 13, 14, 16, 17, 18, 19, 20, 21, 23, 24, 25, 27, 28, 29, 30, 31, 32, 33, 34, 36, 37, 38, 39, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 52, 53, 54, 55, 56, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 71, 72, 73, 74, 75, 76, 78, 79, 80, 81, 82, 83, 84
Offset: 1

Views

Author

Jon Perry, Feb 12 2004

Keywords

Comments

Also n for which A006906(n) is even, or equivalently n for which A000009(n) is even (since A006906 and A000009 have the same parity).
The number of partitions of a(n) into distinct parts with an even number of parts equals the number of such partitions with an odd number of parts: A067661(a(n)) = A067659(a(n)). See, e.g., the Freitag-Busam reference, p. 410 given in A036499. - Wolfdieter Lang, Jan 19 2016

Crossrefs

Programs

  • Mathematica
    Complement[Range[200], Select[Accumulate[Range[0,200]]/3, IntegerQ]] (* G. C. Greubel, Jun 06 2017 *)
  • PARI
    a(n) = my(q,r); [q,r]=divrem(sqrtint(24*n),3); n + q + (r >= bitnegimply(1,q)); \\ Kevin Ryde, Sep 15 2024
  • Python
    from math import isqrt
    def A090864(n):
        def f(x): return n+(m:=isqrt(24*x+1)+1)//6+(m-2)//6
        kmin, kmax = 0,1
        while f(kmax) > kmax:
            kmax <<= 1
        while kmax-kmin > 1:
            kmid = kmax+kmin>>1
            if f(kmid) <= kmid:
                kmax = kmid
            else:
                kmin = kmid
        return kmax # Chai Wah Wu, Aug 29 2024
    

Formula

A080995(a(n)) = 0; A000009(a(n)) = A118303(n). - Reinhard Zumkeller, Apr 22 2006
A010815(a(n)) = A067661(a(n)) - A067659(a(n)) = 0, n >= 1. See a comment above. - Wolfdieter Lang, Jan 19 2016
a(n) = n+1 + A085141(n-1) + A111651(n). - Kevin Ryde, Sep 15 2024

Extensions

More terms from Reinhard Zumkeller, Apr 22 2006
Edited by Ray Chandler, Dec 14 2011
Edited by Jon E. Schoenfield, Nov 25 2016

A111650 2n appears n times (n>0).

Original entry on oeis.org

2, 4, 4, 6, 6, 6, 8, 8, 8, 8, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 14, 14, 14, 14, 14, 14, 14, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18, 18, 18, 18, 18, 18, 18, 18, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 24, 24, 24, 24, 24, 24, 24
Offset: 1

Views

Author

Jonathan Vos Post, Aug 12 2005

Keywords

Comments

Seen as a triangle read by rows: T(n,k) = 2*n, 1<=k<=n. - Reinhard Zumkeller, Mar 18 2011

Crossrefs

Programs

  • Haskell
    a111650 n k = a111650_tabl !! (n-1) !! (k-1)
    a111650_row n = a111650_tabl !! (n-1)
    a111650_tabl = iterate (\xs@(x:_) -> map (+ 2) (x:xs)) [2]
    a111650_list = concat a111650_tabl
    -- Reinhard Zumkeller, Nov 14 2015, Mar 18 2011
    
  • Mathematica
    Table[Table[2n,n],{n,12}]//Flatten (* Harvey P. Dale, Apr 21 2018 *)
  • Python
    from math import isqrt
    def A111650(n): return isqrt(n<<3)+1&-2 # Chai Wah Wu, Jun 06 2025

Formula

a(n) = 2*A002024(n). - Chai Wah Wu, Jun 06 2025

A111652 3n appears n times.

Original entry on oeis.org

3, 6, 6, 9, 9, 9, 12, 12, 12, 12, 15, 15, 15, 15, 15, 18, 18, 18, 18, 18, 18, 21, 21, 21, 21, 21, 21, 21, 24, 24, 24, 24, 24, 24, 24, 24, 27, 27, 27, 27, 27, 27, 27, 27, 27, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 36, 36, 36, 36, 36
Offset: 1

Views

Author

Jonathan Vos Post, Aug 12 2005

Keywords

Crossrefs

Programs

  • Mathematica
    Flatten[Table[Table[3n,{n}],{n,15}]] (* Harvey P. Dale, Jul 23 2013 *)
  • Python
    from math import isqrt
    def A111652(n): return (m:=isqrt(n<<3)+1&-2)+(m>>1) # Chai Wah Wu, Jun 06 2025

Formula

a(n) = 3*A002024(n) = A111650(n)*3/2. - Chai Wah Wu, Jun 06 2025

A183217 Complement of the pentagonal numbers.

Original entry on oeis.org

2, 3, 4, 6, 7, 8, 9, 10, 11, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 93
Offset: 1

Views

Author

Clark Kimberling, Jan 01 2011

Keywords

Examples

			The pentagonal numbers A000326 = (1,5,12,22,35,...), so that this sequence = (2,3,4,6,7,8,9,10,11,13,14,...).
		

Crossrefs

Programs

  • Mathematica
    Table[n+Floor[1/2+(2n/3)^(1/2)], {n,100}]
  • PARI
    a(n) = n + sqrtint(24*n)\/6; \\ Kevin Ryde, Aug 31 2024
    
  • Python
    from math import isqrt
    def A183217(n): return n+(isqrt((n<<3)//3)+1>>1) # Chai Wah Wu, Oct 05 2024

Formula

a(n) = n + floor(1/2+(2n/3)^(1/2)).
a(n) = n + A111651(n). - Kevin Ryde, Aug 31 2024

A375797 Table T(n, k) read by upward antidiagonals. The sequences in each column k is a triangle read by rows (blocks), where each row is a permutation of the numbers of its constituents. Row number n in column k has length n*k = A003991(n,k); see Comments.

Original entry on oeis.org

1, 2, 1, 3, 2, 3, 6, 3, 2, 1, 5, 5, 1, 3, 5, 4, 4, 4, 2, 2, 1, 7, 6, 8, 4, 3, 5, 7, 9, 7, 6, 5, 4, 3, 2, 1, 8, 11, 7, 11, 1, 4, 5, 7, 9, 10, 9, 5, 7, 6, 2, 4, 3, 2, 1, 15, 10, 9, 9, 14, 6, 3, 5, 7, 9, 11, 12, 8, 18, 8, 8, 7, 6, 4, 4, 3, 2, 1, 13, 12, 11, 10, 12, 17, 1, 6, 5, 7, 9, 11, 13, 14, 13, 16, 6, 10, 9, 8, 2, 6, 5, 4, 3, 2, 1
Offset: 1

Views

Author

Boris Putievskiy, Aug 29 2024

Keywords

Comments

A208233 presents an algorithm for generating permutations, where each generated permutation is self-inverse.
The sequence in each column k possesses two properties: it is both a self-inverse permutation and an intra-block permutation of natural numbers.

Examples

			Table begins:
    k=    1   2   3   4   5   6
  -----------------------------------
  n= 1:   1,  1,  3,  1,  5,  1, ...
  n= 2:   2,  2,  2,  3,  2,  5, ...
  n= 3:   3,  3,  1,  2,  3,  3, ...
  n= 4:   6,  5,  4,  4,  4,  4, ...
  n= 5:   5,  4,  8,  5,  1,  2, ...
  n= 6:   4,  6,  6, 11,  6,  6, ...
  n= 7:   7,  7,  7,  7, 14,  7, ...
  n= 8:   9, 11,  5,  9,  8, 17, ...
  n= 9:   8,  9,  9,  8, 12,  9, ...
  n= 10: 10, 10, 18, 10, 10, 15, ...
  n= 11: 15,  8, 11,  6, 11, 11, ...
  n= 12: 12, 12, 16, 12,  9, 13, ...
  n= 13: 13, 13, 13, 13, 13, 12, ...
  n= 14: 14, 19, 14, 23,  7, 14, ...
  n= 15: 11, 15, 15, 15, 15, 10, ...
  n= 16: 16, 17, 12, 21, 30, 16, ...
  n= 17: 20, 16, 17, 17, 17,  8, ...
  n= 18: 18, 18, 10, 19, 28, 18, ...
     ... .
In column 3, the first 3 blocks have lengths 3,6 and 9. In column 6, the first 2 blocks have lengths 6 and 12. Each block is a permutation of the numbers of its constituents.
The first 6 antidiagonals are:
  1;
  2,1;
  3,2,3;
  6,3,2,1;
  5,5,1,3,5;
  4,4,4,2,2,1;
		

Crossrefs

Programs

  • Mathematica
    T[n_,k_]:=Module[{L,R,P,result},L=Ceiling[(Sqrt[8*n*k+k^2]-k)/(2*k)]; R=n-k*(L-1)*L/2; P=(((-1)^Max[R,k*L+1-R]+1)*R-((-1)^Max[R,k*L+1-R]-1)*(k*L+1-R))/2; result=P+k*(L-1)*L/2]
    Nmax=18; Table[T[n,k],{n,1,Nmax},{k,1,Nmax}]

Formula

T(n,k) = P(n,k) + k*(L(n,k)-1)*L(n,k)/2 = P(n,k) + A062707(L(n-1),k), where L(n,k) = ceiling((sqrt(8*n*k+k^2)-k)/(2*k)), R(n,k) = n-k*(L(n,k)-1)*L(n,k)/2, P(n,k) = (((-1)^max(R(n,k),k*L(n,k)+1-R(n,k))+1)*R(n,k)-((-1)^max(R(n,k),k*L(n,k)+1-R(n,k))-1)*(k*L(n,k)+1-R(n,k)))/2.
T(n,1) = A188568(n). T(1,k) = A093178(k). T(n,n) = A124625(n). L(n,1) = A002024(n). L(n,2) = A000194(n). L(n,3) = A111651(n). L(n,4) = A371355(n). R(n,1) = A002260(n). R(n,2) = A074294(n).
Showing 1-5 of 5 results.