login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A242560
Least number k such that (n!-k)/(n-k) is an integer.
0
2, 1, 2, 2, 4, 3, 6, 4, 6, 5, 10, 6, 12, 7, 10, 8, 16, 9, 18, 10, 14, 11, 22, 12, 24, 13, 18, 14, 28, 15, 30, 16, 22, 17, 28, 18, 36, 19, 26, 20, 40, 21, 42, 22, 30, 23, 46, 24, 42, 25, 34, 26, 52, 27, 44, 28, 38, 29, 58, 30, 60, 31, 42, 32, 52, 33, 66, 34, 46, 35
OFFSET
1,1
COMMENTS
It is conjectured that a(2n) = n.
The largest k such that (n!-k)/(n-k) is an integer is n!
a(2n+1) <= 2n for all n >= 1.
Does a(n) = A060681(n) for n>1? - Michel Marcus, Oct 24 2015
EXAMPLE
6-1 is not divisible by 6!-1, 6-2 is not divisible by 6!-2, but 6-3 is divisible by 6!-3. So a(6) = 3.
PROG
(PARI) a(n)=for(k=1, n!, if(k!=n, s = (n!-k)/(n-k); if(floor(s)==s, return(k)); ));
n=1; while(n<100, print(a(n)); n+=1) \\ corrected by Michel Marcus, Oct 24 2015
CROSSREFS
Sequence in context: A328678 A184199 A262346 * A204596 A324387 A163373
KEYWORD
nonn
AUTHOR
Derek Orr, May 21 2014
STATUS
approved