The OEIS is supported by the many generous donors to the OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A079162 a(n) = 5a(n-2) - 2a(n-4). 2
 0, 1, 2, 4, 10, 18, 46, 82, 210, 374, 958, 1706, 4370, 7782, 19934, 35498, 90930, 161926, 414782, 738634, 1892050, 3369318, 8630686, 15369322, 39369330, 70107974, 179585278, 319801226, 819187730, 1458790182, 3736768094 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,3 LINKS Table of n, a(n) for n=0..30. Index entries for linear recurrences with constant coefficients, signature (0,5,0,-2). FORMULA Also a(n) = a(n-1) + 2a(n-2) if n is odd, else a(n) = 2a(n-1) + a(n-2). a(2n) = 2*A005824(2n), a(2n+1) = A005824(2n) + A005824(2n+1). G.f.: x*(1+2*x-x^2)/(1-5*x^2+2*x^4). a(n)=(1/68) * (-1)^n * [5/2 + (1/2) * sqrt(17)]^(-1/4) * [5/2 + (1/2) * sqrt(17)]^[(1/4) * (-1)^n] * [5/2 + (1/2) * sqrt(17)]^(1/2) * n * sqrt(17)-(1/68) * [5/2-(1/2) * sqrt(17)]^(-1/4) * (-1)^n * sqrt(17) * [5/2 -(1/2) * sqrt(17)]^[(1/4) * (-1)^n] * [5/2-(1/2) * sqrt(17)]^(1/ 2) * n + (1/4) * [5/2-(1/2) * sqrt(17)]^( -1/4) * [5/2-(1/2) * sqrt(17)]^[(1/ 4) * (-1)^n] * [5/2-(1/2) * sqrt(17)]^(1/2) * n + (1/4) * [5/2 + (1/2) * sqrt(17)]^(-1/4) * [5/2 + (1/2) * sqrt(17)]^[(1/4) * (-1)^n] * [5/2 + (1/2) * sqrt(17)]^(1/2) * n-(1/4) * (-1)^n * [5/2 + (1/2) * sqrt(17)]^(-1/4) * [5/2 + (1/2) * sqrt(17)]^[(1/4) * (-1)^n] * [5/2 + (1/2) * sqrt(17)]^[(1/2) * n]-(1/4) * [5/2-(1/2) * sqrt(17)]^(-1/ 4) * (-1)^n * [5/2-(1/2) * sqrt(17)]^[(1/4) * (-1)^n] * [5/2-(1/2) * sqrt(17)]^(1/2) * n + (7/68) * [5/2 + (1/2) * sqrt(17)]^(-1/4) * [5/2 + (1/2) * sqrt(17)]^[(1/4) * (-1)^n] * [5/2 + (1/2) * sqrt(17)]^(1/ 2) * n * sqrt(17)-(7/68) * [5/2-(1/2) * sqrt(17)]^(-1/4) * sqrt(17) * [5/2-(1/2) * sqrt(17)]^[(1/4) * (-1)^n] * [5/2-(1/2) * sqrt(17)]^[(1 /2) * n], with n>=0 [From Paolo P. Lava, Oct 06 2008] MATHEMATICA a[0] = 0; a[1] = 1; a[n_] := a[n] = If[ OddQ[n], a[n - 1] + 2a[n - 2], 2a[n - 1] + a[n - 2]]; Table[a[n], {n, 0, 30}] LinearRecurrence[{0, 5, 0, -2}, {0, 1, 2, 4}, 40] (* Harvey P. Dale, Jul 05 2022 *) CROSSREFS Cf. A005824. a(2n+1) = A052913(n). Sequence in context: A348396 A104723 A206140 * A257593 A197926 A228705 Adjacent sequences: A079159 A079160 A079161 * A079163 A079164 A079165 KEYWORD nonn AUTHOR Robert G. Wilson v, Dec 29 2002 EXTENSIONS Corrected the g.f. and index in formula with A052913 R. J. Mathar, Apr 01 2009, May 02 2009 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified June 10 03:15 EDT 2023. Contains 363186 sequences. (Running on oeis4.)