login
Number of palindromes of length n (in base 4).
1

%I #22 Sep 13 2024 00:39:27

%S 3,3,12,12,48,48,192,192,768,768,3072,3072,12288,12288,49152,49152,

%T 196608,196608,786432,786432,3145728,3145728,12582912,12582912,

%U 50331648,50331648,201326592,201326592,805306368,805306368,3221225472,3221225472,12884901888

%N Number of palindromes of length n (in base 4).

%H <a href="/index/Rec#order_02">Index entries for linear recurrences with constant coefficients</a>, signature (0,4).

%F a(n) = 3*4^floor((n-1)/2).

%F From _Colin Barker_, Feb 15 2013: (Start)

%F a(n) = 4*a(n-2).

%F G.f.: -3*x*(x+1) / ((2*x-1)*(2*x+1)). (End)

%t NestList[4#&,{3,3},20]//Flatten (* _Harvey P. Dale_, Dec 19 2016 *)

%Y Cf. A050683.

%K nonn,base,easy

%O 1,1

%A _Martin Renner_, May 02 2006

%E More terms from _Colin Barker_, Feb 15 2013