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”).

a(2n) = 2a(n)+2^(2n), a(2n+1) = 2^(2n+1), a(0)=0.
1

%I #7 Jul 08 2013 10:14:58

%S 0,2,8,8,32,32,80,128,320,512,1088,2048,4256,8192,16640,32768,66176,

%T 131072,263168,524288,1050752,2097152,4198400,8388608,16785728,

%U 33554432,67125248,134217728,268468736,536870912,1073807360,2147483648,4295099648,8589934592

%N a(2n) = 2a(n)+2^(2n), a(2n+1) = 2^(2n+1), a(0)=0.

%C Simplest sequence of form a(2n)=c*a(n)+f(n), a(2n+1)=g(n) that cannot be easily expressed as a function of A007814(n).

%H Reinhard Zumkeller, <a href="/A227326/b227326.txt">Table of n, a(n) for n = 0..1000</a>

%F a(n) = sum(k=0..A007814(n), 2^(k+n/2^k) ).

%o (PARI) a(n)=sum(k=0,valuation(n,2),2^(k+n/2^k))

%o (PARI) a(n)=if(n<1,0,if(n%2==0,2*a(n/2)+2^n,2^n))

%o (Haskell)

%o import Data.List (transpose)

%o a227326 n = a227326_list !! n

%o a227326_list = 0 : xs where

%o xs = concat $ transpose

%o [a004171_list, zipWith (+) (tail a000302_list) (map (* 2) xs)]

%o -- _Reinhard Zumkeller_, Jul 08 2013

%Y Cf. A000302, A004171.

%K nonn,easy

%O 0,2

%A _Ralf Stephan_, Jul 07 2013