%I #23 Jul 28 2015 10:52:30
%S 0,0,0,2,12,50,220,882,3612,14450,58140,232562,931612,3726450,
%T 14911260,59645042,238602012,954408050,3817719580,15270878322,
%U 61083862812,244335451250,977343203100,3909372812402
%N Total number of 2 X 2 squares appearing in the Thue-Morse sequence logical matrices after n stages.
%C a(n) is the total number of non-isolated "1s" (consecutive 1s on 2 rows, 2 columns) that appear as 2 X 2 squares in the Thue-Morse logical matrices after n stages. See links for more details.
%H Kival Ngaokrajang, <a href="/A241683/a241683.pdf">Illustration of initial terms</a>
%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Thue%E2%80%93Morse_sequence">Thue-Morse sequence</a>
%H <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (4, 5, -20, -4, 16).
%F a(n) = A007590(A000975(n - 1)).
%F Empirical g.f.: 2*x^3*(4*x^2-2*x-1) / ((x-1)*(x+1)*(2*x-1)*(2*x+1)*(4*x-1)). - _Colin Barker_, Apr 27 2014
%F a(n) = (1/18) * (4^n - 3*2^n - 6*(-1)^n + (-2)^n - 2), n>0 (from g.f.). - _Ralf Stephan_, Apr 27 2014
%o (PARI) {a0=0;print1(a0,", "); for (n=0,50, b=ceil(2*(2^n-1)/3); a=floor(b^2/2); print1(a,", "))}
%Y Cf. A010060.
%K nonn
%O 0,4
%A _Kival Ngaokrajang_, Apr 27 2014