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.

A128177 A128174 * A004736 as infinite lower triangular matrices.

Original entry on oeis.org

1, 2, 1, 4, 2, 1, 6, 4, 2, 1, 9, 6, 4, 2, 1, 12, 9, 6, 4, 2, 1, 16, 12, 9, 6, 4, 2, 1, 20, 16, 12, 9, 6, 4, 2, 1, 25, 20, 16, 12, 9, 6, 4, 2, 1, 30, 25, 20, 16, 12, 9, 6, 4, 2, 1, 36, 30, 25, 20, 16, 12, 9, 6, 4, 2, 1, 42, 36, 30, 25, 20, 16, 12, 9, 6, 4, 2, 1
Offset: 1

Views

Author

Gary W. Adamson, Feb 17 2007

Keywords

Comments

n-th row has n nonzero terms of A002620: (1, 2, 4, 6, 9, 12, 16, ...) in reverse.
Row sums = A002623: (1, 3, 7, 13, 22, 34, 50, ...).

Examples

			First few rows of the triangle:
   1;
   2, 1;
   4, 2, 1;
   6, 4, 2, 1;
   9, 6, 4, 2, 1;
  12, 9, 6, 4, 2, 1;
  ...
		

Crossrefs

Programs

  • Maple
    seq(seq(floor((n-k+2)^2/4), k=1..n), n=1..20); # Ridouane Oudra, Mar 23 2024
  • Mathematica
    T[n_,k_]:=Floor[(n-k+2)^2/4];Table[T[n,k],{n,12},{k,n}]//Flatten (* James C. McMahon, Jan 05 2025 *)
  • PARI
    lista(nn) = {t128174 = matrix(nn, nn, n, k, (k<=n)*(1+(-1)^(n-k))/2); t004736 = matrix(nn, nn, n, k, (k<=n)*(n - k + 1)); t128177 = t128174*t004736; for (n = 1, nn, for (k = 1, n, print1(t128177[n, k], ", ");););} \\ Michel Marcus, Feb 11 2014

Formula

From Ridouane Oudra, Mar 23 2024: (Start)
T(n, k) = A002620(n-k+2), with 1 <= k <= n;
T(n, k) = floor((n-k+2)^2/4);
T(n, k) = (1/2)*floor((n-k+2)^2/2);
T(n, k) = (1/8)*(2*(n-k+2)^2 + (-1)^(n-k) - 1). (End)

Extensions

Partially edited and more terms from Michel Marcus, Feb 11 2014