The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A350211 Numbers k such that the arithmetic mean of the digits of k! is an integer. 0
0, 1, 2, 3, 4, 5, 6, 12, 26, 28, 32, 59, 262, 391, 533, 579 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
COMMENTS
A heuristic argument suggests that this short list is complete. By Stirling's approximation, n! has order n*log(n) digits of which n/4 are terminal zeros. If the remaining digits are random, the mean will be just below 4.5. For n > 6, n! and also its digits sum are divisible by 9. 12! is the only factorial with 9 digits. The others have 27, 30, 36, 81, 522, 846, 1224, and 1350 digits, respectively.
LINKS
EXAMPLE
4 is a term because 4! = 24 and (2+4)/2 = 3 is an integer.
MAPLE
q:= n-> (f-> (add(i, i=convert(f, base, 10))/length(f))::integer)(n!):
select(q, [$0..1000])[]; # Alois P. Heinz, Dec 19 2021
MATHEMATICA
Do[If[IntegerQ[Mean[IntegerDigits[n!]]], Print[n, " ", Mean[IntegerDigits[n!]]]], {n, 1, 100000}]
PROG
(PARI) isok(k) = my(d=digits(k!)); (vecsum(d) % #d) == 0; \\ Michel Marcus, Dec 19 2021
CROSSREFS
Sequence in context: A218345 A059460 A125141 * A282505 A165304 A266642
KEYWORD
nonn,base,more
AUTHOR
Zachary M Franco, Dec 19 2021
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 12 20:41 EDT 2024. Contains 372494 sequences. (Running on oeis4.)