login
a(n) = 2*a(n-2) for n > 2; a(1) = 5, a(2) = 2.
6

%I #11 Sep 08 2022 08:45:46

%S 5,2,10,4,20,8,40,16,80,32,160,64,320,128,640,256,1280,512,2560,1024,

%T 5120,2048,10240,4096,20480,8192,40960,16384,81920,32768,163840,65536,

%U 327680,131072,655360,262144,1310720,524288,2621440,1048576,5242880

%N a(n) = 2*a(n-2) for n > 2; a(1) = 5, a(2) = 2.

%C Binomial transform is A162268. Fifth binomial transform is A083880 without initial 1.

%H Vincenzo Librandi, <a href="/A162396/b162396.txt">Table of n, a(n) for n = 1..1000</a>

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

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

%F G.f.: x*(5+2*x)/(1-2*x^2).

%p A162396:=n->(3/2-(-1)^n)*2^(1/4*(2*n+3+(-1)^n)): seq(A162396(n), n=1..60); # _Wesley Ivan Hurt_, Oct 08 2017

%t CoefficientList[Series[(5 + 2*x)/(1 - 2*x^2), {x, 0, 40}], x] (* _Wesley Ivan Hurt_, Oct 08 2017 *)

%t RecurrenceTable[{a[1]==5, a[2]==2, a[n]==2 a[n-2]}, a, {n, 40}] (* _Vincenzo Librandi_, Oct 09 2017 *)

%o (Magma) [ n le 2 select 8-3*n else 2*Self(n-2): n in [1..41] ];

%o (Magma) [Floor((3/2-(-1)^n)*2^(1/4*(2*n+3+(-1)^n))): n in [1..50]]; // _Vincenzo Librandi_, Oct 09 2017

%Y Cf. A083880, A162255, A162268.

%K nonn,easy

%O 1,1

%A _Klaus Brockhaus_, Jul 02 2009

%E G.f. corrected, formula simplified, comment added by _Klaus Brockhaus_, Sep 18 2009