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.

A225812 Irregular triangle read by rows: T(n,k) is the number of binary pattern classes in the (4,n)-rectangular grid with k '1's and (4n-k) '0's: two patterns are in same class if one of them can be obtained by a reflection or 180-degree rotation of the other.

Original entry on oeis.org

1, 1, 2, 4, 2, 1, 1, 2, 10, 14, 22, 14, 10, 2, 1, 1, 4, 22, 60, 139, 208, 252, 208, 139, 60, 22, 4, 1, 1, 4, 36, 140, 476, 1092, 2044, 2860, 3270, 2860, 2044, 1092, 476, 140, 36, 4, 1, 1, 6, 56, 294, 1253, 3912, 9808, 19464, 31706, 42116, 46448, 42116, 31706
Offset: 0

Views

Author

Keywords

Comments

The length of row n is 4*n+1.
Sum of rows (see example) gives A225828.
This triangle is to A225828 as Losanitsch's triangle A034851 is to A005418, triangle A226048 to A225826, and triangle A226290 to A225827.
Also the number of equivalence classes of ways of placing k 1 X 1 tiles in an n X 4 rectangle under all symmetry operations of the rectangle. - Christopher Hunt Gribble, Apr 24 2015

Examples

			Irregular triangle:
1
1 2  4   2   1
1 2 10  14  22   14   10    2    1
1 4 22  60 139  208  252  208  139   60   22    4   1
1 4 36 140 476 1092 2044 2860 3270 2860 2044 1092 476 140 36  4  1 ...
		

Crossrefs

Programs

  • Mathematica
    T[n_, k_] := (Binomial[4n, k] + If[EvenQ[k], 2 Binomial[2n, k/2], 0] + Sum[Binomial[4 Mod[n, 2], k - 2i] Binomial[4 Quotient[n, 2], i], {i, 0, Quotient[k, 2]}])/4; Table[T[n, k], {n, 0, 5}, {k, 0, 4n}] // Flatten (* Jean-François Alcover, Oct 06 2017, after Andrew Howroyd *)
  • PARI
    T(n,k)={(binomial(4*n,k) + if(k%2==0,2*binomial(2*n,k/2),0) + sum(i=0,k\2,binomial(4*(n%2),k-2*i)*binomial(4*(n\2),i)))/4}
    for(n=0,4,for(k=0,4*n, print1(T(n,k), ", "));print) \\ Andrew Howroyd, May 30 2017

Extensions

Definition corrected by María Merino, May 19 2017