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.

A143978 a(n) = floor(2*n*(n+1)/3).

Original entry on oeis.org

1, 4, 8, 13, 20, 28, 37, 48, 60, 73, 88, 104, 121, 140, 160, 181, 204, 228, 253, 280, 308, 337, 368, 400, 433, 468, 504, 541, 580, 620, 661, 704, 748, 793, 840, 888, 937, 988, 1040, 1093, 1148, 1204, 1261, 1320, 1380, 1441, 1504, 1568, 1633, 1700, 1768, 1837
Offset: 1

Views

Author

Clark Kimberling, Sep 06 2008

Keywords

Comments

Second diagonal of array A143979, which counts certain unit squares in a lattice. First diagonal: A030511.
Convolution of A042965 with A000012, convolution of A131534 with A000027, and convolution of A106510 with A000217. - L. Edson Jeffery, Jan 24 2015
From Miquel A. Fiol, Aug 31 2024: (Start)
a(n+1) is the maximum number N of vertices of a circulant digraph with steps +-s1, s2, and diameter n.
Depending on the value of n, the following table shows the values of N, s1, and s2:
n | 3*r | 3*r-1 | 3*r-2 |
N | 6*r^2+6*r+1 | 6*r^2+2*r | 6*r^2-2*r |
s1 | 1 | r | r |
s2 | 6*r+3 | 3*r+1 | 3*r-1 |
(End)

Crossrefs

Cf. A000217, A030511, A042965 (first differences), A106510, A131534, A143979.

Programs

  • Maple
    A143978:= n-> (6*n*(n+1) -1 + `mod`(n+2,3) - `mod`(n+1,3))/9;
    seq(A143978(n), n=1..60); # G. C. Greubel, May 27 2020
  • Mathematica
    Table[(6*n^2 +6*n -1  + Mod[n+2, 3] - Mod[n+1, 3])/9, {n, 60}] (* G. C. Greubel, May 27 2020 *)
    Table[Floor[2n (n+1)/3],{n,60}] (* or *) LinearRecurrence[{2,-1,1,-2,1},{1,4,8,13,20},60] (* Harvey P. Dale, Aug 12 2025 *)

Formula

From R. J. Mathar, Oct 05 2009: (Start)
G.f.: x*(1 + x)^2/((1 + x + x^2)*(1-x)^3).
a(n) = 2*a(n-1) - a(n-2) + a(n-3) - 2*a(n-4) + a(n-5). (End)
a(n) = Sum_{k=1..(n+1)} A042965(k). - Klaus Purath, May 23 2020
From G. C. Greubel, May 27 2020: (Start)
a(n) = (ChebyshevU(n, -1/2) - ChebyshevU(n-1, -1/2) + (6*n^2 + 6*n -1))/9.
a(n) = (JacobiSymbol(n+1, 3) - JacobiSymbol(n, 3) + (6*n^2 + 6*n -1))/9.
a(n) = (A102283(n+1) - A102283(n) + A103115(n+1))/9
a(n) = (A131713(n) + A103115(n+1))/9. (End)
Sum_{n>=1} 1/a(n) = 3/2 + (tan(Pi/(2*sqrt(3)))-1)*Pi/(2*sqrt(3)). - Amiram Eldar, Sep 27 2022
E.g.f.: exp(-x/2)*(exp(3*x/2)*(6*x^2 + 12*x - 1) + cos(sqrt(3)*x/2) - sqrt(3)*sin(sqrt(3)*x/2))/9. - Stefano Spezia, Apr 05 2023

A143976 Rectangular array R by antidiagonals: label each unit square in the first quadrant lattice by its northeast vertex (x,y) and mark squares having x + y == 1 (mod 3); then R(m,n) is the number of UNmarked squares in the rectangle [0,m] X [0,n].

Original entry on oeis.org

1, 2, 2, 2, 3, 2, 3, 4, 4, 3, 4, 6, 6, 6, 4, 4, 7, 8, 8, 7, 4, 5, 8, 10, 11, 10, 8, 5, 6, 10, 12, 14, 14, 12, 10, 6, 6, 11, 14, 16, 17, 16, 14, 11, 6, 7, 12, 16, 19, 20, 20, 19, 16, 12, 7, 8, 14, 18, 22, 24, 24, 24, 22, 18, 14, 8, 8, 15, 20, 24, 27, 28, 28, 27, 24, 20, 15, 8
Offset: 1

Views

Author

Clark Kimberling, Sep 06 2008

Keywords

Comments

Rows numbered 3,6,9,12,15,... are, except for initial terms, multiples of (1,2,3,4,5,6,7,...) = A000027.

Examples

			Northwest corner:
  1  2  2  3  4  4  5
  2  3  4  6  7  8 10
  2  4  6  8 10 12 14
  3  6  8 11 14 16 18
  4  7 10 14 17 20 24
See A143974.
		

Crossrefs

Rows: A004523, A004772, A005843, A047399, et al.
Main diagonal: A071619.

Programs

  • Mathematica
    T[m_,n_]:=m*n-Floor[m*n/3]; Flatten[Table[T[n-k+1,k],{n,12},{k,n}]] (* Stefano Spezia, Oct 25 2022 *)

Formula

R(m,n) = m*n - floor(m*n/3).

A143977 Rectangular array R by antidiagonals: label each unit square in the first quadrant lattice by its northeast vertex (x,y) and mark squares having |x-y| == 0 (mod 3); then R(m,n) is the number of marked squares in the rectangle [0,m] X [0,n].

Original entry on oeis.org

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

Views

Author

Clark Kimberling, Sep 06 2008

Keywords

Comments

Rows numbered 3,6,9,12,15,... are, except for initial terms, multiples of (1,2,3,4,5,6,7,...) = A000027.

Examples

			Northwest corner:
  1  1  1  2  2  2  3
  1  2  2  3  4  4  5
  1  2  3  4  5  6  7
  2  3  4  6  7  8 10
  2  4  5  7  9 10 12
		

Crossrefs

Rows and columns: A002264, A004523, A000027, A004772, A047212, et al.

Programs

  • Mathematica
    T[m_,n_]:=Ceiling[m n/3];Flatten[Table[T[m-n+1,n],{m,13},{n,m}]] (* Stefano Spezia, Oct 27 2022 *)

Formula

R(m,n) = ceiling(m*n/3). [Corrected by Stefano Spezia, Oct 27 2022]

A358163 a(n) is the permanent of the n X n matrix M(n) that is defined by M[i,j] = i*j - ceiling(i*j/3).

Original entry on oeis.org

1, 0, 1, 30, 1272, 113224, 18615680, 4299553536, 1507609286784, 781464165813504, 525599814806986752, 473934337123421786112, 567876971785035135320064, 837723761443461191423754240, 1549608938859438129393893376000, 3582000047767392376356107059200000, 9838495669776145718724862743674880000
Offset: 0

Views

Author

Stefano Spezia, Nov 01 2022

Keywords

Comments

The matrix M(n) is the n-th principal submatrix of the rectangular array A143979.
det(M(0)) = 1, det(M(2)) = -1, det(M(3)) = 2, and otherwise det(M(n)) = 0.

Examples

			a(5) = 113224:
    0  1   2   2   3
    1  2   4   5   6
    2  4   6   8  10
    2  5   8  10  13
    3  6  10  13  16
		

Crossrefs

Cf. A143979.
Cf. A030511 (matrix element M[n-1,n-1]), A358164 (hafnian of M(2*n)).

Programs

  • Mathematica
    a[n_]:=Permanent[Table[i*j-Ceiling[i*j/3],{i,n},{j,n}]]; Join[{1},Array[a,16]]
  • Python
    from fractions import Fraction
    from sympy import Matrix
    def A358163(n): return Matrix(n,n,[i*j-Fraction(i*j,3)._ceil_() for i in range(1,n+1) for j in range(1,n+1)]).per() if n else 1 # Chai Wah Wu, Nov 02 2022

A358164 a(n) is the hafnian of the 2n X 2n symmetric matrix defined by M[i,j] = i*j - ceiling(i*j/3).

Original entry on oeis.org

1, 1, 26, 2704, 698568, 384890688, 378771904512, 597991783196160, 1450380828625459200, 5077825865646165964800, 24487520383436615392204800
Offset: 0

Views

Author

Stefano Spezia, Nov 01 2022

Keywords

Comments

The matrix M(n) is the n-th principal submatrix of the rectangular array A143979.

Examples

			a(2) = 26:
    0  1   2   2
    1  2   4   5
    2  4   6   8
    2  5   8  10
		

Crossrefs

Cf. A143979.
Cf. A030511 (matrix element M[n-1,n-1]), A358163 (permanent of M(n)).

Programs

  • Mathematica
    M[i_, j_, n_]:=Part[Part[Table[r*c-Ceiling[r*c/3], {r, n}, {c, n}], i], j]; a[n_]:=Sum[Product[M[Part[PermutationList[s, 2n], 2i-1], Part[PermutationList[s, 2n], 2i], 2n], {i, n}], {s, SymmetricGroup[2n]//GroupElements}]/(n!*2^n); Array[a, 6, 0]
  • PARI
    tm(n) = matrix(n, n, i, j, i*j - ceil((i*j)/3));
    a(n) = my(m = tm(2*n), s=0); forperm([1..2*n], p, s += prod(j=1, n, m[p[2*j-1], p[2*j]]); ); s/(n!*2^n); \\ Michel Marcus, May 02 2023

Extensions

a(6) from Michel Marcus, May 02 2023
a(7)-a(10) from Pontus von Brömssen, Oct 15 2023
Showing 1-5 of 5 results.