[go: up one dir, main page]

login
A037615
Base 8 digits are, in order, the first n terms of the periodic sequence with initial period 1,3,2.
0
1, 11, 90, 721, 5771, 46170, 369361, 2954891, 23639130, 189113041, 1512904331, 12103234650, 96825877201, 774607017611, 6196856140890, 49574849127121, 396598793016971, 3172790344135770, 25382322753086161, 203058582024689291, 1624468656197514330
OFFSET
1,2
FORMULA
G.f.: x*(1+x)*(2*x+1) / ( (x-1)*(8*x-1)*(1+x+x^2) ). - R. J. Mathar, Apr 27 2015
A007094(a(n)) = A037617(n). - R. J. Mathar, Apr 27 2015
MATHEMATICA
Module[{nn=30, str}, str=PadRight[{}, nn, {1, 3, 2}]; Table[FromDigits[Take[ str, n], 8], {n, nn}]] (* Harvey P. Dale, Apr 22 2013 *)
PROG
(PARI) a(n)=([0, 1, 0, 0; 0, 0, 1, 0; 0, 0, 0, 1; -8, 1, 0, 8]^(n-1)*[1; 11; 90; 721])[1, 1] \\ Charles R Greathouse IV, Feb 13 2017
CROSSREFS
Sequence in context: A055425 A016212 A037713 * A068973 A138649 A077711
KEYWORD
nonn,base,easy
STATUS
approved