login
A037581
Base 9 digits are, in order, the first n terms of the periodic sequence with initial period 1,3.
1
1, 12, 109, 984, 8857, 79716, 717445, 6457008, 58113073, 523017660, 4707158941, 42364430472, 381279874249, 3431518868244, 30883669814197, 277953028327776, 2501577254949985, 22514195294549868, 202627757650948813, 1823649818858539320, 16412848369726853881
OFFSET
1,2
FORMULA
From Colin Barker, Dec 27 2012: (Start)
a(n) = (3^(1+2*n) + 2*(-1)^n - 5)/20.
a(n) = 9*a(n-1) + a(n-2) - 9*a(n-3).
G.f.: x*(3*x+1) / ((x-1)*(x+1)*(9*x-1)). (End)
E.g.f.: (3*(cosh(9*x) - cosh(x) + sinh(9*x)) - 7*sinh(x))/20. - Stefano Spezia, Oct 25 2023
MATHEMATICA
CoefficientList[Series[(3 x + 1)/((x - 1) (x + 1) (9 x - 1)), {x, 0, 30}], x] (* Vincenzo Librandi, Oct 22 2013 *)
Module[{nn=30, d}, d=PadRight[{}, nn, {1, 3}]; Table[FromDigits[Take[d, n], 9], {n, nn}]] (* Harvey P. Dale, Jul 22 2015 *)
PROG
(Magma) [(3^(1+2*n)+2*(-1)^n-5)/20: n in [1..30]]; // Vincenzo Librandi, Oct 22 2013
CROSSREFS
Sequence in context: A081200 A351161 A016214 * A177071 A081183 A069294
KEYWORD
nonn,base,easy
EXTENSIONS
More terms from Colin Barker, Dec 27 2012
STATUS
approved