login
A166465
a(n) = 3*a(n-2) for n > 2; a(1) = 1, a(2) = 5.
1
1, 5, 3, 15, 9, 45, 27, 135, 81, 405, 243, 1215, 729, 3645, 2187, 10935, 6561, 32805, 19683, 98415, 59049, 295245, 177147, 885735, 531441, 2657205, 1594323, 7971615, 4782969, 23914845, 14348907, 71744535, 43046721, 215233605, 129140163
OFFSET
1,2
COMMENTS
Interleaving of A000244 and A005030.
Second binomial transform is A054485.
Fifth binomial transform is A153596.
FORMULA
a(n) = (4 + (-1)^n) * 3^((2*n - 5 + (-1)^n)/4).
G.f.: x*(1+5*x)/(1-3*x^2).
a(n) = A162813(n-1), for n >= 2.
From G. C. Greubel, Jul 27 2024: (Start)
a(n) = (1/6)*3^(n/2)*( 5*(1+(-1)^n) + sqrt(3)*(1-(-1)^n) ).
E.g.f.: (1/3)*(sqrt(3)*sinh(sqrt(3)*x) + 10*(sinh(sqrt(3)*x/2))^2). (End)
MATHEMATICA
LinearRecurrence[{0, 3}, {1, 5}, 41] (* G. C. Greubel, Jul 27 2024 *)
PROG
(Magma) [ n le 2 select 4*n-3 else 3*Self(n-2): n in [1..35] ];
(SageMath) [3^(n/2)*(5*((n+1)%2) +sqrt(3)*(n%2))/3 for n in range(1, 41)] # G. C. Greubel, Jul 27 2024
CROSSREFS
Cf. A000244 (powers of 3), A005030 (5*3^n), A054485, A153596, A162813.
Sequence in context: A248983 A298975 A070375 * A162813 A146934 A213762
KEYWORD
nonn,easy
AUTHOR
Klaus Brockhaus, Oct 14 2009
STATUS
approved