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.

A178112 Number triangle T(n,k)=C(floor(n/2),floor(k/2))*(1+(-1)^(n-k))/2.

Original entry on oeis.org

1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 2, 0, 1, 0, 1, 0, 2, 0, 1, 1, 0, 3, 0, 3, 0, 1, 0, 1, 0, 3, 0, 3, 0, 1, 1, 0, 4, 0, 6, 0, 4, 0, 1, 0, 1, 0, 4, 0, 6, 0, 4, 0, 1, 1, 0, 5, 0, 10, 0, 10, 0, 5, 0, 1, 0, 1, 0, 5, 0, 10, 0, 10, 0, 5, 0, 1, 1, 0, 6, 0, 15, 0, 20, 0, 15, 0, 6, 0, 1
Offset: 0

Views

Author

Paul Barry, May 20 2010

Keywords

Comments

Coefficient array of polynomials P(n,x)=xP(n-1,x)+((1+(-1)^n)/2)*P(n-2,x), P(0,x)=1,P(1,x)=x.
Inverse is A178111.

Examples

			Triangle begins
1,
0, 1,
1, 0, 1,
0, 1, 0, 1,
1, 0, 2, 0, 1,
0, 1, 0, 2, 0, 1,
1, 0, 3, 0, 3, 0, 1,
0, 1, 0, 3, 0, 3, 0, 1,
1, 0, 4, 0, 6, 0, 4, 0, 1,
0, 1, 0, 4, 0, 6, 0, 4, 0, 1,
1, 0, 5, 0, 10, 0, 10, 0, 5, 0, 1
Production matrix is
0, 1,
1, 0, 1,
0, 0, 0, 1,
0, 0, 1, 0, 1,
0, 0, 0, 0, 0, 1,
0, 0, 0, 0, 1, 0, 1,
0, 0, 0, 0, 0, 0, 0, 1,
0, 0, 0, 0, 0, 0, 1, 0, 1,
0, 0, 0, 0, 0, 0, 0, 0, 0, 1
Production matrix of inverse is
0, 1,
-1, 0, 1,
0, 0, 0, 1,
0, 0, -1, 0, 1,
0, 0, 0, 0, 0, 1,
0, 0, 0, 0, -1, 0, 1,
0, 0, 0, 0, 0, 0, 0, 1,
0, 0, 0, 0, 0, 0, -1, 0, 1,
0, 0, 0, 0, 0, 0, 0, 0, 0, 1
		

Programs

  • Maple
    A178112 := proc(n,k)
        binomial(floor(n/2),floor(k/2))*( 1+(-1)^(n-k) )/2 ;
    end proc:
    seq(seq(A178112(n,k),k=0..n),n=0..10) ; # R. J. Mathar, Feb 10 2015
  • Mathematica
    Table[Binomial[Floor[n/2], Floor[k/2]]*(1 + (-1)^(n - k))/2, {n, 0, 12}, {k, 0, n}] // Flatten (* Michael De Vlieger, Aug 31 2020 *)