login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Determinant of n X n matrix of first n^2 terms of Kolakoski sequence (A000002).
10

%I #15 Aug 09 2015 15:29:48

%S 0,1,-3,0,-2,-3,0,0,0,0,0,0,0,17,0,0,140,0,0,0,0,0,-205,0,-44,0,0,0,0,

%T 0,0,91050,0,-1350,8570,65392,0,187556,61650,0,-226,0,1402800,

%U -4810213,0,0,0,46764576,122333784,0,0,-82777822,-11359122,0,54911379,0,0

%N Determinant of n X n matrix of first n^2 terms of Kolakoski sequence (A000002).

%C When is next nonzero value, for n>11?

%e a(3) = 0 because for instance, first row = 3rd row = (1,2,2).

%e a(6) = 0 because for instance, 3rd column = 6th column = (2,2,2,2,2,2).

%e a(7) = 0 because for instance, first column = 4th column.

%e a(9) = 0 because for instance, 9th column = 2 * 4th column.

%p From _R. J. Mathar_, Oct 15 2010: (Start)

%p read("transforms3") ; L := BFILETOLIST("b000002.txt") ;

%p for s from 1 to floor(sqrt(nops(L))) do m := Matrix(1..s,1..s) ; for r from 0 to s-1 do for c from 0 to s-1 do m[r+1,c+1] := op(1+c+r*s,L) ; end do: end do: printf("%a,\n", LinearAlgebra[Determinant](m) ) ; end do: (End)

%t nmax = 56; a2 = {1, 2, 2}; Do[ a2 = Join[a2, {1 + Mod[n-1, 2]}], {n, 3, nmax^2}, {a2[[n]]}]; a[0] = 0; a[n_] := Det[ Partition[ Take[a2, n^2], n]]; Table[a[n], {n, 0, nmax}] (* _Jean-François Alcover_, Jun 18 2013 *)

%Y Cf. A000002.

%K easy,sign

%O 0,3

%A _Jonathan Vos Post_, May 25 2006

%E More terms from _R. J. Mathar_, Oct 15 2010