cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A381139 a(1) = 1, a(2) = 2. Let j = a(n-1) and let d = A160995(j) be the smallest non-divisor of j which shares a prime factor with j. Then for n > 2 a(n) is the smallest multiple of d which is not yet in the sequence.

Original entry on oeis.org

1, 2, 4, 6, 8, 12, 16, 18, 20, 24, 9, 30, 28, 36, 32, 42, 40, 48, 27, 54, 44, 60, 56, 66, 52, 72, 10, 64, 78, 68, 84, 80, 90, 76, 96, 45, 102, 88, 108, 104, 114, 92, 120, 63, 126, 100, 132, 112, 138, 116, 144, 50, 124, 150, 128, 156, 136, 162, 140, 168, 81, 174
Offset: 1

Views

Author

Keywords

Comments

2 is the only prime in the sequence. Initially every odd term > 1 is a multiple of 9.
The first 3 odd terms not divisible by 9 are the following: a(19241) = 25, a(38481) = 75, a(57719) = 125, a(76959) = 175, a(115438) = 275. Differences between indices of odd terms divisible by 25 but not 9 are approximately 19240.
In this sequence, 25 follows 55440 = 2^4 * 3^2 * 5 * 7 * 11. The number 49 is missing for n <= 2^24.
Though a(n+1) must neither divide a(n) nor be coprime to same, a(n) may divide a(n+1). Examples: the sequence begins with {1, 2, 4}, a(19) = 27 and a(20) = 54, a(44) = 63 and a(45) = 126, etc.

Examples

			a(3) = 4, the smallest non divisor of 2 which shares a divisor with 2.
a(4) = 6, the smallest non divisor of 4 which shares a divisor with 4.
a(5) = 8 because 4 is the smallest non divisor of 6 with a factor in common but 4 has been seen earlier and 8 is the least novel multiple of 4.
a(10) = 24 implies a(11) = 9 since A160995(24) = 9, and 9 has not occurred earlier. This is the first odd number in the sequence. Thereafter we see a(19) = 27, a(36) = 45, a(44) = 63, a(61) = 81, etc (consecutive odd multiples of 9). It is not known if this behavior continues as the sequence extends.
		

Crossrefs

Programs

  • Mathematica
    nn = 120; c[] := False; m[] := 1; j = 2;
    {1, 2}~Join~
      Reap[Do[k = 2; Until[Nor[Divisible[j, k], CoprimeQ[j, k]], k++];
        While[Or[c[#], Divisible[j, #], CoprimeQ[j, #]] &[k*m[k]], m[k]++];
          k *= m[k]; c[k] = True; j = Sow[k],
    {n, nn}] ][[-1, 1]] (* Michael De Vlieger, Feb 18 2025 *)

A162564 a(n) is the smallest positive integer neither coprime to n! nor a divisor of n!.

Original entry on oeis.org

4, 4, 9, 9, 14, 22, 22, 22, 22, 26, 26, 34, 34, 34, 34, 38, 38, 46, 46, 46, 46, 58, 58, 58, 58, 58, 58, 62, 62, 74, 74, 74, 74, 74, 74, 82, 82, 82, 82, 86, 86, 94, 94, 94, 94, 106, 106, 106, 106, 106, 106, 118, 118, 118, 118, 118, 118, 122, 122, 134, 134, 134, 134, 134
Offset: 2

Views

Author

Leroy Quet, Jul 06 2009

Keywords

Comments

Alternately, smallest composite not dividing n!. For n > 5, twice the smallest prime greater than n. - Charles R Greathouse IV, Apr 04 2013

Crossrefs

Cf. A160995.

Programs

  • Maple
    a := proc (n) local j: for j while gcd(j, factorial(n)) = 1 or `mod`(factorial(n), j) = 0 do end do: j end proc: seq(a(n), n = 2 .. 75); # Emeric Deutsch, Jul 23 2009
  • PARI
    a(n)=my(N=n!,k=n);while(N%k++==0||isprime(k),);k \\ Charles R Greathouse IV, Apr 04 2013
    
  • PARI
    a(n)=if(n>5,2*nextprime(n+1),(n\2+1)^2) \\ Charles R Greathouse IV, Apr 04 2013

Formula

a(n) = A160995(n!).

Extensions

Extended by Emeric Deutsch, Jul 23 2009
Showing 1-2 of 2 results.