A127218 Half-indexed Lucas numbers second version L(n)=A000032=Lucas numbers a(0)=2, a(1)=2, a(2)=1, a(3)=2, a(4)=3, a(5)=3, a(2n)=L(n), for n>2: a(2n+1)=L(n)+L(n-3)=2*L(n-1) for n>5: a(n)+a(n+2)=a(n+4) a(2n)=L(n), so a(n)=L(n/2).
2, 2, 1, 2, 3, 3, 4, 6, 7, 8, 11, 14, 18, 22, 29, 36, 47, 58, 76, 94, 123, 152, 199, 246, 322, 398, 521, 644, 843, 1042, 1364, 1686, 2207, 2728, 3571, 4414, 5778, 7142, 9349, 11556, 15127, 18698, 24476, 30254, 39603, 48952, 64079
Offset: 0
Links
- Colin Barker, Table of n, a(n) for n = 0..1000
- Index entries for linear recurrences with constant coefficients, signature (0,1,0,1).
Programs
-
Maple
b[0]:=2:b[1]:=1:for n from 2 to 80 do b[n]:=b[n-1]+b[n-2] od: a[0]:=2:a[1]:=2:a[2]:=1:a[3]:=2:a[4]:=3:a[5]:=3: for n from 3 to 39 do a[2*n]:=b[n]:a[2*n+1]:=b[n]+b[n-3] od: seq(a[n],n=0..79);
-
Mathematica
LinearRecurrence[{0,1,0,1},{2,2,1,2,3,3,4,6,7,8},60] (* Harvey P. Dale, Jun 22 2022 *)
-
PARI
Vec((1 + x)*(2 - x^2 + x^3 - x^4 + x^7 - x^8) / (1 - x^2 - x^4) + O(x^45)) \\ Colin Barker, Aug 03 2020
Formula
From Colin Barker, Aug 03 2020: (Start)
G.f.: (1 + x)*(2 - x^2 + x^3 - x^4 + x^7 - x^8) / (1 - x^2 - x^4).
a(n) = a(n-2) + a(n-4) for n>10.
(End)
Comments