login
A037617
Decimal expansion of a(n) is given by the first n terms of the periodic sequence with initial period 1,3,2.
6
1, 13, 132, 1321, 13213, 132132, 1321321, 13213213, 132132132, 1321321321, 13213213213, 132132132132, 1321321321321, 13213213213213, 132132132132132, 1321321321321321, 13213213213213213, 132132132132132132, 1321321321321321321, 13213213213213213213, 132132132132132132132
OFFSET
1,2
FORMULA
G.f.: x*(1+x)*(2*x+1) / ( (x-1)*(10*x-1)*(1+x+x^2) ). - R. J. Mathar, Aug 12 2013
a(n) ~ (44/333)*10^n = (44/333)*A011557(n). - Stefano Spezia, Oct 15 2023
MATHEMATICA
Table[FromDigits[PadRight[{}, n, {1, 3, 2}]], {n, 20}] (* Harvey P. Dale, Mar 29 2015 *)
PROG
(PARI) a(n)=([0, 1, 0, 0; 0, 0, 1, 0; 0, 0, 0, 1; -10, 1, 0, 10]^(n-1)*[1; 13; 132; 1321])[1, 1] \\ Charles R Greathouse IV, May 16 2026
CROSSREFS
Cf. A011557.
Sequence in context: A295349 A161498 A037715 * A295603 A199144 A198664
KEYWORD
nonn,base,easy
EXTENSIONS
a(17)-a(21) from Stefano Spezia, Oct 15 2023
STATUS
approved