A375242 Numbers with digital root in {2, 4, 5, 7, 8}.
2, 4, 5, 7, 8, 11, 13, 14, 16, 17, 20, 22, 23, 25, 26, 29, 31, 32, 34, 35, 38, 40, 41, 43, 44, 47, 49, 50, 52, 53, 56, 58, 59, 61, 62, 65, 67, 68, 70, 71, 74, 76, 77, 79, 80, 83, 85, 86, 88, 89, 92, 94, 95, 97, 98, 101, 103, 104, 106, 107, 110, 112, 113, 115, 116
Offset: 1
References
- Albert H. Beiler, Recreations in the theory of numbers, New York, Dover, (2nd ed.) 1966. See p. 190.
Links
- Stefano Spezia, Table of n, a(n) for n = 1..10000
- Index entries for linear recurrences with constant coefficients, signature (1,0,0,0,1,-1).
Programs
-
Mathematica
A010888[n_]:=If[n>0,n - 9*Floor[(n-1)/9],0]; Select[Range[0,130], MemberQ[{2,4,5,7,8},A010888[#]] &]
-
PARI
list(lim)=my(v=List()); forstep(n=2,lim\1,[2, 1, 2, 1, 3], listput(v,n)); Vec(v) \\ Charles R Greathouse IV, Aug 07 2024
-
PARI
is(n)=!setsearch([0,1,3,6],n%9) \\ Charles R Greathouse IV, Aug 07 2024
Formula
G.f.: x*(2 + 2x + x^2 + 2*x^3 + x^4 + x^5)/((1 - x)^2*(1 + x + x^2 + x^3 + x^4)).
a(n) ~ 9*n/5.
Comments