OFFSET
1,1
COMMENTS
Amounts in cents of coins in denominations 1, 5 and 10 cents that must include change for a 25-cent coin. Regarding currently-minted US coins, note that the 25-cent quarter is the only denomination for which a smaller denomination exists (the 10-cent dime) which is not a divisor. As a result, an amount that may consist only of any number of dimes and up to four 1-cent pennies does not guarantee change for a quarter.
LINKS
Index entries for linear recurrences with constant coefficients, signature (1,0,0,0,1,-1).
FORMULA
a(n) = 10 + a(n-5) for n >= 6.
From Chai Wah Wu, Jun 10 2016: (Start)
a(n) = a(n-1) + a(n-5) - a(n-6) for n > 6.
G.f.: x*(-19*x^5 + x^4 + x^3 + x^2 + x + 25)/(x^6 - x^5 - x + 1). (End)
a(n) = 25 + ((n-1) mod 5) + 10*floor((n-1)/5). - Wesley Ivan Hurt, Nov 03 2016
MATHEMATICA
Table[25 + Mod[n - 1, 5] + 10*Floor[(n - 1)/5], {n, 50}] (* Wesley Ivan Hurt, Nov 03 2016 *)
PROG
(PARI) is(n) = n > 24 && n % 10 > 4 \\ Felix Fröhlich, Nov 03 2016
(Magma) [n : n in [25..150] | n mod 10 in [5..9]]; // Vincenzo Librandi, Nov 04 2016
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Rick L. Shepherd, May 05 2008
STATUS
approved