OFFSET
0,3
COMMENTS
LINKS
Index entries for linear recurrences with constant coefficients, signature (1, 8, -8).
FORMULA
a(n) = sum(k=0..n, A206917(k)).
a(n) = sum(k=1..(1/2)*(5-(-1)^n)*2^floor(n/2)-1, A006995(k)).
a(n) = (8/7)*((3/4)*((4-(-1)^n)/(3+(-1)^n))*2^(3*floor(n/2))-1).
G.f.: x*(1+3*x+4*x^2)/((x-1)*(8*x^2-1)). - Alois P. Heinz, Feb 28 2012
EXAMPLE
a(0) = 0, since p=0 is the only binary palindrome p<2^0;
a(3) = 16, since p=0, 1, 3, 5, 7 are the only binary palindromes < 2^3 and 0+1+3+5+7=16.
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Hieronymus Fischer, Feb 18 2012
STATUS
approved