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.

A056886 Determinant of the n X n Hankel matrix whose entries are s_2 (i+j), 0 <= i, j < n, where s_2 is the sum of the base-2 bits.

Original entry on oeis.org

1, 0, -1, 2, 5, -8, 3, 8, 141, -204, 11, -4, -11, -30, 99, 1836, 164997, -224532, 2403, -126, -39, 14, -5, -14, -267, -738, 351, -1134, -28431, -538002, 9537507, 891167508, 361226647845, -471103550820, 1127461923, -11787930, -675783, 34992, -1377, -432, -927
Offset: 0

Views

Author

Jeffrey Shallit, Sep 04 2000

Keywords

Comments

Hankel transform of A000120.

Examples

			a(2) = -1 because det [[0,1],[1,1]] = -1.
		

Programs

  • Maple
    with(LinearAlgebra):
    wt:= proc(n) local m, t; m:=n; t:=0;
           while m>0 do t:= t+irem(m, 2, 'm') od; t
         end:
    a:= n-> Determinant(Matrix(n, (i, j)-> wt(i+j-2))):
    seq(a(n), n=0..40);  # Alois P. Heinz, May 25 2013
  • Mathematica
    a[n_] := Det[Array[DigitCount[#1 + #2 - 2, 2, 1]&, {n, n}]]; a[0] = 1;
    a /@ Range[0, 40] (* Jean-François Alcover, Nov 10 2020 *)
  • PARI
    {a(n) = if( n<0, 0, matdet( matrix( n, n, i, j, 2*i + 2*j - 4 - valuation( (2*i + 2*j - 4)!, 2))))} /* Michael Somos, Feb 08 2011 */

Extensions

a(0)=1 added by Michael Somos, Feb 08 2011
More terms from Alois P. Heinz, May 25 2013