A117856 Number of palindromes of length n (in base 4).
3, 3, 12, 12, 48, 48, 192, 192, 768, 768, 3072, 3072, 12288, 12288, 49152, 49152, 196608, 196608, 786432, 786432, 3145728, 3145728, 12582912, 12582912, 50331648, 50331648, 201326592, 201326592, 805306368, 805306368, 3221225472, 3221225472, 12884901888
Offset: 1
Links
- Index entries for linear recurrences with constant coefficients, signature (0,4).
Crossrefs
Cf. A050683.
Programs
-
Mathematica
NestList[4#&,{3,3},20]//Flatten (* Harvey P. Dale, Dec 19 2016 *)
Formula
a(n) = 3*4^floor((n-1)/2).
From Colin Barker, Feb 15 2013: (Start)
a(n) = 4*a(n-2).
G.f.: -3*x*(x+1) / ((2*x-1)*(2*x+1)). (End)
Extensions
More terms from Colin Barker, Feb 15 2013