OFFSET
1,2
LINKS
Chai Wah Wu, Table of n, a(n) for n = 1..100
Index entries for linear recurrences with constant coefficients, signature (0,110,0,-1000).
FORMULA
From Colin Barker, Mar 25 2020: (Start)
G.f.: 100*x^2*(3 + 201*x + 2677*x^2 - 2100*x^3 + 172280*x^4 - 1998000*x^6) / ((1 - 10*x)*(1 + 10*x)*(1 - 10*x^2)).
a(n) = 110*a(n-2) - 1000*a(n-4) for n>6.
(End)
MATHEMATICA
nsmall = Table[Infinity, 20];
For[i = 0, i <= 10^6, i++, p = PolygonalNumber[i];
n0 = Count[IntegerDigits[p], 0];
If[nsmall[[n0]] > p, nsmall[[n0]] = p]];
ReplaceAll[nsmall, Infinity -> "?"] (* Robert Price, Mar 22 2020 *)
LinearRecurrence[{0, 110, 0, -1000}, {0, 300, 20100, 300700, 2001000, 50005000, 200010000, 5000050000}, 30] (* Harvey P. Dale, Jul 31 2021 *)
PROG
(PARI) concat(0, Vec(100*x^2*(3 + 201*x + 2677*x^2 - 2100*x^3 + 172280*x^4 - 1998000*x^6) / ((1 - 10*x)*(1 + 10*x)*(1 - 10*x^2)) + O(x^20))) \\ Colin Barker, Mar 25 2020
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
STATUS
approved