login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A266620 a(n) = least non-divisor of n!. 2
2, 3, 4, 5, 7, 7, 11, 11, 11, 11, 13, 13, 17, 17, 17, 17, 19, 19, 23, 23, 23, 23, 29, 29, 29, 29, 29, 29, 31, 31, 37, 37, 37, 37, 37, 37, 41, 41, 41, 41, 43, 43, 47, 47, 47, 47, 53, 53, 53, 53, 53, 53, 59, 59, 59, 59, 59, 59, 61, 61, 67, 67, 67, 67, 67, 67, 71 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

It appears that a(n) = A151800(n) with the exception of n = 3. - Robert Israel, Jan 13 2016

LINKS

Robert Israel, Table of n, a(n) for n = 1..10000

FORMULA

a(n) = min_{k >= 1} prime(k)^(1 + v(n!, prime(k))) where v(m, p) is the p-adic order of m. - Robert Israel, Jan 13 2016

a(n) = prime(pi(n) + 1) except for n = 3, in which case the least non-divisor of 3! is 4, not 5. - Alonso del Arte, Sep 23 2017

EXAMPLE

For n = 4 the least non-divisor of 4! = 24 = 2^3 * 3 is 5.

For n = 5 the least non-divisor of 5! = 120 = 2^3 * 3 * 5 is 7.

MAPLE

N:= 100: # to get a(1)..a(N)

m:= 1 + numtheory:-pi(N):

Primes:= [seq(ithprime(i), i=1..m)]:

for i from 1 to m do pindex[Primes[i]]:= i od:

V:= Vector(m):

k:= 0:

for n from 1 to N do

  for f in ifactors(n)[2] do

    q:= pindex[f[1]];

    V[q]:= V[q] + f[2];

    k:= max(k, q);

  od:

  a[n]:= min(seq(Primes[i]^(1+V[i]), i=1..k), Primes[k+1]);

od:

seq(a[n], n=1..N); # Robert Israel, Jan 13 2016

MATHEMATICA

Table[Complement[Range[2n], Divisors[n!]][[1]], {n, 30}] (* Alonso del Arte, Sep 23 2017 *)

Table[Block[{m = n!, k = n + 1}, While[Divisible[m, k], k++]; k], {n, 67}] (* Michael De Vlieger, Sep 23 2017 *)

CROSSREFS

Cf. A007918, A007978, A066169, A115627, A151800.

Sequence in context: A320466 A237824 A227972 * A222415 A022473 A214921

Adjacent sequences:  A266617 A266618 A266619 * A266621 A266622 A266623

KEYWORD

nonn,easy

AUTHOR

Jeffrey Shallit, Jan 01 2016

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 11 20:03 EDT 2020. Contains 335652 sequences. (Running on oeis4.)