OFFSET
0,3
COMMENTS
Inverse binomial transform of A060816.
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (1,2).
FORMULA
a(n) = (5*2^n - 3*0^n + 4*(-1)^n)/6.
G.f.: (1+x^2)/((1+x)*(1-2*x)).
E.g.f.: (5*exp(2*x) - 3*exp(0) + 4*exp(-x))/6.
From Paul Barry, May 04 2004: (Start)
The binomial transform of a(n+1) is A020989(n).
a(n) = Sum_{k=0..n} A001045(n+1)*C(1, k/2)*(1+(-1)^k)/2. - Paul Barry, Oct 15 2004
a(n) = a(n-1) + 2*a(n-2) for n > 2. - Klaus Brockhaus, Dec 01 2009
From Yuchun Ji, Mar 18 2019: (Start)
a(n+1) = Sum_{i=0..n} a(i) + 1 - (-1)^n, a(0)=1.
a(n) = A000975(n-3)*10 + 5 + (-1)^(n-3), a(0)=1, a(1)=1, a(2)=4. (End)
a(n) = A081254(n) + (n-1 mod 2). - Kevin Ryde, Dec 20 2023
MAPLE
A084214 := proc(n)
(5*2^n - 3*0^n + 4*(-1)^n)/6 ;
end proc:
seq(A084214(n), n=0..60) ; # R. J. Mathar, Aug 18 2024
MATHEMATICA
f[n_]:=2/(n+1); x=3; Table[x=f[x]; Numerator[x], {n, 0, 5!}] (* Vladimir Joseph Stephan Orlovsky, Mar 12 2010 *)
LinearRecurrence[{1, 2}, {1, 1, 4}, 50] (* Harvey P. Dale, Mar 05 2021 *)
PROG
(Magma) [(5*2^n-3*0^n+4*(-1)^n)/6: n in [0..35]]; // Vincenzo Librandi, Jun 15 2011
(Haskell)
a084214 n = a084214_list !! n
a084214_list = 1 : xs where
xs = 1 : 4 : zipWith (+) (map (* 2) xs) (tail xs)
-- Reinhard Zumkeller, Aug 01 2011
(PARI) a(n) = 5<<(n-1)\3 + bitnegimply(1, n); \\ Kevin Ryde, Dec 20 2023
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Paul Barry, May 19 2003
STATUS
approved