|
|
A037743
|
|
Decimal expansion of a(n) is given by the first n terms of the periodic sequence with initial period 2,1,3,0.
|
|
0
|
|
|
2, 21, 213, 2130, 21302, 213021, 2130213, 21302130, 213021302, 2130213021, 21302130213, 213021302130, 2130213021302, 21302130213021, 213021302130213, 2130213021302130, 21302130213021302, 213021302130213021, 2130213021302130213, 21302130213021302130
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
LINKS
|
|
|
FORMULA
|
a(n) = 10*a(n-1) + a(n-4) - 10*a(n-5). G.f.: x*(2+x+3*x^2) / ((x-1)*(10*x-1)*(1+x)*(x^2+1)). - R. J. Mathar, Oct 05 2009
|
|
MATHEMATICA
|
nn=10; With[{c=PadLeft[{}, 4nn, {2, 1, 3, 0}]}, Table[FromDigits[Take[c, n]], {n, 4nn}]] (* Harvey P. Dale, Aug 16 2011 *)
|
|
PROG
|
(PARI) Vec(x*(2+x+3*x^2)/((x-1)*(10*x-1)*(1+x)*(x^2+1)) + O(x^25)) \\ Jinyuan Wang, Apr 14 2020
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base,easy
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|