OFFSET
1,2
LINKS
Index entries for linear recurrences with constant coefficients, signature (10,0,1,-10).
FORMULA
G.f.: x*(1+2*x+2*x^2) / ( (x-1)*(10*x-1)*(1+x+x^2) ). - R. J. Mathar, Aug 12 2013
a(1)=1, a(2)=12, a(3)=122, a(4)=1221, a(n) = 10*a(n-1) + a(n-3) - 10*a(n-4). - Harvey P. Dale, Jan 20 2015
MATHEMATICA
With[{nn=20}, Table[FromDigits[PadRight[{}, n, {1, 2, 2}]], {n, nn}]] (* or *) LinearRecurrence[{10, 0, 1, -10}, {1, 12, 122, 1221}, 20] (* Harvey P. Dale, Jan 20 2015 *)
PROG
(PARI) Vec(x*(1+2*x+2*x^2)/((x-1)*(10*x-1)*(1+x+x^2)) + O(x^25)) \\ Jinyuan Wang, Apr 14 2020
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
STATUS
approved