OFFSET
0,3
COMMENTS
LINKS
Zhuorui He, Table of n, a(n) for n = 0..10000
Wikipedia, Innings pitched.
Index entries for linear recurrences with constant coefficients, signature (1,0,1,-1).
FORMULA
G.f.: x*(1 + x + 8*x^2)/((-1 + x)^2*(1 + x + x^2)).
a(n)= A054967(n) + 1 for n >= 1.
E.g.f.: exp(-x/2)*(3*exp(3*x/2)*(10*x - 7) + 21*cos(sqrt(3)*x/2) + 7*sqrt(3)*sin(sqrt(3)*x/2))/9. - Stefano Spezia, Dec 05 2025
EXAMPLE
A pitcher that has recorded 22 outs has pitched 7.1 innings, so a(22) = 71.
MATHEMATICA
a[n_] := Total[QuotientRemainder[n, 3] * {10, 1}]; Array[a, 61, 0]
Select[Range[0, 200], Mod[#, 10]<3&] (* or *) LinearRecurrence[{1, 0, 1, -1}, {0, 1, 2, 10}, 100] (* Harvey P. Dale, Jan 27 2026 *)
CROSSREFS
KEYWORD
nonn,easy,base
AUTHOR
Jason Bard, Dec 01 2025
STATUS
approved
