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!)
A074198 Largest k such that 1!*2!*3!*...*k! divides n!. 2
1, 2, 2, 3, 3, 3, 3, 4, 4, 5, 5, 5, 5, 5, 5, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
FORMULA
a(n) is asymptotic to sqrt(2*n) and for n > 300 a(n) = ceiling(1/2 + sqrt(1+8*n)/2) (+0 or +1).
EXAMPLE
18!/Product_{i=1..7} i! = 51051 but 18!/Product_{i=1..8} i! = 2431/1920, hence a(18) = 7.
MATHEMATICA
a[n_] := Module[{k = 1}, NestWhile[#/(++k)! &, n!, IntegerQ]; k - 1]; Array[a, 100] (* Amiram Eldar, May 14 2024 *)
PROG
(PARI) a(n)=if(n<0, 0, my(s=1); while(n!%prod(i=1, s, i!) == 0, s++); s-1)
CROSSREFS
Sequence in context: A321318 A270362 A196383 * A196169 A330561 A048688
KEYWORD
easy,nonn
AUTHOR
Benoit Cloitre, Sep 17 2002
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 August 26 07:40 EDT 2024. Contains 375454 sequences. (Running on oeis4.)