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.

A131421 Triangle read by rows (n>=1, 1<=k<=n): T(n,k) = 2*(n+k) - 3.

Original entry on oeis.org

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

Views

Author

Gary W. Adamson, Jul 10 2007

Keywords

Comments

Row sums = A000567, the octagonal numbers: (1, 8, 21, 40, 65, 96,...).

Examples

			First few rows of the triangle are:
1;
3, 5;
5, 7, 9;
7, 9, 11, 13;
9, 11, 13, 15, 17;
11, 13, 15, 17, 19, 21;
13, 15, 17, 19, 21, 23, 25;
...
		

Crossrefs

Programs

  • Mathematica
    Table[2 (n + k) - 3, {n, 150}, {k, n}] // Flatten (* Michael De Vlieger, Oct 06 2017 *)
  • PARI
    tabl(nn) = {ma = matrix(nn, nn, n, k, (k<=n)); mb = matrix(nn, nn, n, k, (2*n - 1)*(k==n)); mr = ma*mb + mb*ma - ma; for (n = 1, nn, for (k = 1, n, print1(mr[n, k], ", ");); print(););} \\ Michel Marcus, Mar 04 2014

Formula

(A000012 * A127775) + (A127775 * A000012) - A000012, where all the sequences and the result are interpreted as infinite lower triangular matrices.

Extensions

Corrected and extended by Michel Marcus, Mar 04 2014
New name from Andrey Zabolotskiy, Oct 06 2017