OFFSET
0,2
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
FORMULA
From G. C. Greubel, May 28 2024: (Start)
a(n) = (1/2)*( (1+(-1)^n)*A134762(n/2) + 2*(1-(-1)^n) ).
a(n) = (3/2)*(1+(-1)^n)*A001405(n) - 2*(-1)^n.
G.f.: 3/sqrt(1-4*x^2) - 2/(1+x).
E.g.f.: 3*BesselI(0, 2*x) - 2*exp(-x). (End)
EXAMPLE
First few terms of the sequence are: (1, 2, 4, 2, 16, 2, 58, ...), interpolating two's in the sequence A134762: (1, 4, 16, 58, ...).
MATHEMATICA
Table[(3/2)*(1+(-1)^n)*Binomial[n, n/2] -2*(-1)^n, {n, 0, 40}] (* G. C. Greubel, May 28 2024 *)
PROG
(Magma) [3*((n+1) mod 2)*Binomial(n, Floor(n/2)) - 2*(-1)^n : n in [0..40]]; // G. C. Greubel, May 28 2024
(SageMath) [3*((n+1)%2)*binomial(n, n//2) - 2*(-1)^n for n in range(41)] # G. C. Greubel, May 28 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Gary W. Adamson, Nov 09 2007
EXTENSIONS
Name change and terms a(14) onward added by G. C. Greubel, May 28 2024
STATUS
approved