OFFSET
0,2
COMMENTS
a(n) indexes the corner blocks on the Jacobsthal spiral built from blocks of unit area (using J(1) and J(2) as the sides of the first block). - Paul Barry, Mar 06 2008
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (3,-1,-3,2).
FORMULA
G.f.: (1 -x^2 +2*x^3)/((1-x)*(1-2*x)*(1-x^2)). - Ralf Stephan, Apr 30 2004
From Paul Barry, Mar 06 2008: (Start)
a(n) = A001045(n+3) - 2*floor((n+2)/2).
a(n+1) = 2*a(n) + A109613(n), a(0)=1. - Paul Curtz, Sep 22 2019
MATHEMATICA
CoefficientList[Series[(1-x^2+2x^3)/((1-x)(1-2x)(1-x^2)), {x, 0, 29}], x] (* Metin Sariyar, Sep 22 2019 *)
LinearRecurrence[{3, -1, -3, 2}, {1, 3, 7, 17}, 41] (* G. C. Greubel, Jul 01 2024 *)
PROG
(Magma) [(2^(n+4) -(6*n+9+(-1)^n))/6: n in [0..40]]; // G. C. Greubel, Jul 01 2024
(SageMath) [(2^(n+4) - (-1)^n -9 - 6*n)/6 for n in range(41)] # G. C. Greubel, Jul 01 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved