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.

User: ?(#===1||PrimeQ[PrimePi[#]]&),

?(#===1||PrimeQ[PrimePi[#]]&),'s wiki page.

?(#===1||PrimeQ[PrimePi[#]]&), has authored 114 sequences. Here are the ten most recent ones:

A361502 Index of n-th prime in A359804.

Original entry on oeis.org

2, 3, 4, 8, 13, 42, 347, 3466, 49012, 528231, 717126, 63056215, 1375559400, 7038527851
Offset: 1

Author

N. J. A. Sloane, Mar 18 2023, based on a comment made by Michael De Vlieger in A359804 in which he gave the values of a(1) to a(12)

Keywords

Comments

Theorem: Every prime appears in A359804. For proof see A359804.
It appears that the primes in A359804 appear in order.

Crossrefs

Programs

  • Mathematica
    nn = 2^20; c[] = False; q[] = 1;
     i = 1; j = 2; c[1] = c[2] = True; u = 3;
     {2}~Join~Reap[Monitor[Do[
          (k = q[#]; While[c[k #], k++]; k *= #;
             While[c[# q[#]], q[#]++]) &[(p = 2;
            While[Divisible[i j, p], p = NextPrime[p]]; p)];
          If[PrimeQ[k], Sow[n]; Print[n]];
          Set[{c[k], i, j}, {True, j, k}];
    If[k == u, While[c[u], u++]], {n, 3, nn}], n]][[-1, -1]] (* Michael De Vlieger, Mar 19 2023 *)

Extensions

a(13)-a(14) from Rémy Sigrist, Mar 19 2023

A360359 Numbers k such that A360331(k) = A360331(k+1).

Original entry on oeis.org

69, 574, 713, 781, 2394, 2506, 5699, 5750, 6499, 6509, 8441, 19250, 26529, 32130, 36549, 38065, 41749, 41929, 43239, 48025, 50301, 53037, 53382, 59178, 59822, 61754, 66906, 67689, 70277, 71198, 81620, 94000, 100775, 119214, 124640, 127442, 134665, 153202, 154908
Offset: 1

Author

Amiram Eldar, Feb 04 2023

Keywords

Examples

			69 is a term since A360331(69) = A360331(70) = 24.
		

Crossrefs

Cf. A360331.
Similar sequences: A002961, A064115, A064125, A293183, A306985, A360358.

Programs

  • Mathematica
    f[p_, e_] := If[PrimeQ[PrimePi[p]], 1, (p^(e+1)-1)/(p-1)]; s[1] = 1; s[n_] := Times @@ f @@@ FactorInteger[n]; seq = {}; s1 = s[1]; n = 2; c = 0; While[c < 40, s2 = s[n]; If[s1 == s2, c++; AppendTo[seq, n - 1]]; s1 = s2; n++]; seq
  • PARI
    s(n) = {my(f = factor(n), p = f[,1], e = f[,2]); prod(i = 1, #p, if(isprime(primepi(p[i])), 1, (p[i]^(e[i]+1)-1)/(p[i]-1)));}
    lista(nmax) = {my(s1 = s(1), s2); for(n=2, nmax, s2=s(n); if(s1 == s2, print1(n-1, ", ")); s1 = s2); }

A360358 Numbers k such that A360327(k) = A360327(k+1) > 1.

Original entry on oeis.org

714, 6603, 16115, 18920, 23154, 24530, 39984, 41360, 42789, 51204, 56814, 58190, 59619, 60995, 65229, 66605, 68034, 69410, 73644, 79304, 82059, 84249, 84864, 86240, 94655, 101375, 101694, 103070, 107304, 108680, 121374, 125510, 126125, 126939, 135128, 135354, 137329
Offset: 1

Author

Amiram Eldar, Feb 04 2023

Keywords

Comments

Numbers k such that A360327(k) = A360327(k+1) = 1 are terms of A360357.

Examples

			714 is a term since A360327(714) = A360327(715) = 72 > 1.
		

Crossrefs

Similar sequences: A002961, A064115, A064125, A293183, A306985, A360359.

Programs

  • Mathematica
    f[p_, e_] := If[PrimeQ[PrimePi[p]], (p^(e+1)-1)/(p-1), 1]; s[1] = 1; s[n_] := Times @@ f @@@ FactorInteger[n]; seq = {}; s1 = s[1]; n = 2; c = 0; While[c < 40, s2 = s[n]; If[s1 == s2 > 1, c++; AppendTo[seq, n - 1]]; s1 = s2; n++]; seq
  • PARI
    s(n) = {my(f = factor(n), p = f[,1], e = f[,2]); prod(i = 1, #p, if(isprime(primepi(p[i])), (p[i]^(e[i]+1)-1)/(p[i]-1), 1));}
    lista(nmax) = {my(s1 = s(1), s2); for(n=2, nmax, s2=s(n); if(s2 > 1 && s1 == s2, print1(n-1, ", ")); s1 = s2); }

A360357 Numbers k such that k and k+1 are both products of primes of nonprime index (A320628).

Original entry on oeis.org

1, 7, 13, 28, 37, 46, 52, 73, 91, 97, 103, 106, 112, 148, 151, 172, 181, 193, 196, 202, 223, 226, 232, 256, 262, 292, 298, 301, 316, 337, 343, 346, 361, 376, 388, 397, 427, 448, 457, 463, 466, 478, 487, 502, 511, 523, 541, 556, 568, 592, 601, 607, 613, 622, 631
Offset: 1

Author

Amiram Eldar, Feb 04 2023

Keywords

Comments

There are no 3 consecutive integers that are products of primes of nonprime index since 1 out of 3 consecutive integers is divisible by 3 which is a prime-indexed prime (A006450).
If a Mersenne prime (A000668) is a prime of nonprime index, then it is in this sequence. Of the first 10 Mersenne primes 6 are in this in sequence: A000668(k) for k = 2, 5, 7, 8, 9, 10 (see A059305).

Examples

			7 = prime(4) is a term since 4 is nonprime, 7 + 1 = 8 = prime(1)^3, and 1 is also nonprime.
		

Crossrefs

Programs

  • Mathematica
    q[n_] := AllTrue[FactorInteger[n][[;; , 1]], ! PrimeQ[PrimePi[#]] &]; seq = {}; q1 = q[1]; n = 2; c = 0; While[c < 55, q2 = q[n]; If[q1 && q2, c++; AppendTo[seq, n - 1]]; q1 = q2; n++]; seq
  • PARI
    is(n) = {my(p = factor(n)[,1]); for(i = 1, #p, if(isprime(primepi(p[i])), return(0))); 1;}
    lista(nmax) = {my(q1 = is(1), q2); for(n = 2, nmax, q2 = is(n); if(q1 && q2, print1(n-1, ", ")); q1 = q2); }

A360356 Primitive terms of A360332: terms of A360332 with no proper divisor in A360332.

Original entry on oeis.org

56, 104, 196, 304, 364, 368, 464, 532, 644, 812, 1036, 1184, 1204, 1316, 1376, 1484, 1504, 1696, 1708, 1952, 1988, 2044, 2212, 2492, 2716, 2828, 2884, 2996, 3164, 3496, 3668, 3836, 3892, 4172, 4228, 4408, 4544, 4564, 4672, 4676, 4844, 5056, 5068, 5336, 5404, 5516
Offset: 1

Author

Amiram Eldar, Feb 04 2023

Keywords

Comments

If m is a term then k*m is a term of A360332 for all k in A320628.
Analogous to primitive abundant numbers (A091191) with divisors that are restricted to numbers that have only nonprime-indexed prime factors.

Crossrefs

Subsequence of A360332.
Cf. A320628.
Similar sequences: A006038, A091191, A249263, A302574, A360355.

Programs

  • Mathematica
    f[p_, e_] := If[PrimeQ[PrimePi[p]], 1, (p^(e + 1) - 1)/(p - 1)]; s[1] = 1; s[n_] := Times @@ f @@@ FactorInteger[n]; primQ[n_] := s[n] > 2*n && AllTrue[Divisors[n], # == n || s[#] <= 2*# &]; Select[Range[6000], primQ]
  • PARI
    isab(n) = {my(f = factor(n), p = f[,1], e = f[,2]); prod(i = 1, #p, if(isprime(primepi(p[i])), 1, (p[i]^(e[i]+1)-1)/(p[i]-1))) > 2*n;}
    is(n) = {if(!isab(n), return(0)); fordiv(n, d, if(d < n && isab(d), return(0))); return(1)};

A360355 Primitive terms of A360328: terms of A360328 with no proper divisor in A360328.

Original entry on oeis.org

7425, 8415, 46035, 76725, 101475, 182655, 355725, 669735, 1411425, 1606275, 2352375, 2891295, 3592215, 3650625, 4079295, 4861575, 5053455, 5870205, 6093225, 6636465, 6920595, 7732395, 8750835, 9120375, 9783675, 9850005, 9958905, 10155375, 11298375, 11532375, 12120075
Offset: 1

Author

Amiram Eldar, Feb 04 2023

Keywords

Comments

If m is a term then k*m is a term of A360328 for all k in A076610.
Analogous to primitive abundant numbers (A091191) with divisors that are restricted to numbers that have only prime-indexed prime factors.

Crossrefs

Subsequence of A360328.
Cf. A076610.
Similar sequences: A006038, A091191, A249263, A302574, A360356.

Programs

  • Mathematica
    f[p_, e_] := If[PrimeQ[PrimePi[p]], (p^(e + 1) - 1)/(p - 1), 1]; s[1] = 1; s[n_] := Times @@ f @@@ FactorInteger[n]; primQ[n_] := s[n] > 2*n && AllTrue[Divisors[n], # == n || s[#] <= 2*# &]; Select[Range[10^6], primQ]
  • PARI
    isab(n) = {my(f = factor(n), p = f[,1], e = f[,2]); prod(i = 1, #p, if(isprime(primepi(p[i])), (p[i]^(e[i]+1)-1)/(p[i]-1), 1)) > 2*n;}
    is(n) = {if(!isab(n), return(0)); fordiv(n, d, if(d < n && isab(d), return(0))); return(1)};

A360332 Numbers k such that A360331(k) > 2*k.

Original entry on oeis.org

56, 104, 112, 196, 208, 224, 304, 364, 368, 392, 416, 448, 464, 532, 608, 644, 728, 736, 784, 812, 832, 896, 928, 1036, 1064, 1184, 1204, 1216, 1288, 1316, 1352, 1372, 1376, 1456, 1472, 1484, 1504, 1568, 1624, 1664, 1696, 1708, 1792, 1856, 1952, 1976, 1988, 2044
Offset: 1

Author

Amiram Eldar, Feb 03 2023

Keywords

Comments

Analogous to abundant numbers (A005101) with divisors that are restricted to numbers that have only nonprime-indexed prime factors.
The least odd term is 7^4 * (13*19)^3 * (29*...*71)^2 * (73*...*281) = 2.411... * 10^105 (where the dots are for consecutive terms in A007821).
Includes all the abundant (A005101) terms of A320628.
There are terms that are not in A320628, and the least of them is 3 * m, where m is a term of A320628 with sigma(m) > 6. Such a number exists, and it should be a positive multiple of Product_{i=1..k} A007821(k) = 2 * 7 * ... * 11443 = 9.164... * 10^4148, where k = 1160 is the least number such that Product_{i=1..k} A007821(k)/(A007821(k)-1) > 6.
The numbers of terms not exceeding 10^k, for k = 1, 2, ..., are 0, 1, 23, 215, 1997, 19231, 189457, 1873511, 18593697, ... . Apparently, the asymptotic density of this sequence equals 0.018... .

Crossrefs

Subsequence of A005101.

Programs

  • Maple
    q:= n-> is(mul(`if`(isprime(numtheory[pi](i[1])), 1,
       (i[1]^(i[2]+1)-1)/(i[1]-1)), i=ifactors(n)[2])>2*n):
    select(q, [$1..2050])[];  # Alois P. Heinz, Feb 03 2023
  • Mathematica
    f[p_, e_] := If[PrimeQ[PrimePi[p]], 1, (p^(e+1)-1)/(p-1)]; s[1] = 1; s[n_] := Times @@ f @@@ FactorInteger[n]; Select[Range[2000], s[#] > 2*# &]
  • PARI
    is(n) = {my(f = factor(n), p = f[,1], e = f[,2]); prod(i = 1, #p, if(isprime(primepi(p[i])), 1, (p[i]^(e[i]+1)-1)/(p[i]-1))) > 2*n;}

A360331 a(n) is the sum of divisors of n that have only prime factors that are not prime-indexed primes.

Original entry on oeis.org

1, 3, 1, 7, 1, 3, 8, 15, 1, 3, 1, 7, 14, 24, 1, 31, 1, 3, 20, 7, 8, 3, 24, 15, 1, 42, 1, 56, 30, 3, 1, 63, 1, 3, 8, 7, 38, 60, 14, 15, 1, 24, 44, 7, 1, 72, 48, 31, 57, 3, 1, 98, 54, 3, 1, 120, 20, 90, 1, 7, 62, 3, 8, 127, 14, 3, 1, 7, 24, 24, 72, 15, 74, 114, 1
Offset: 1

Author

Amiram Eldar, Feb 03 2023

Keywords

Comments

Equivalently, a(n) is the sum of divisors of the largest divisor of n that has only prime factors that are not prime-indexed primes.

Programs

  • Maple
    a:= n-> mul(`if`(isprime(numtheory[pi](i[1])), 1,
       (i[1]^(i[2]+1)-1)/(i[1]-1)), i=ifactors(n)[2]):
    seq(a(n), n=1..75);  # Alois P. Heinz, Feb 03 2023
  • Mathematica
    f[p_, e_] := If[PrimeQ[PrimePi[p]], 1, (p^(e+1)-1)/(p-1)]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
  • PARI
    a(n) = {my(f = factor(n), p = f[,1], e = f[,2]); prod(i = 1, #p, if(isprime(primepi(p[i])), 1, (p[i]^(e[i]+1)-1)/(p[i]-1)));}

Formula

a(n) = 1 if and only if n is in A076610.
a(n) = A000203(n) if and only if n is in A320628.
a(n) = A000203(A360329(n)).
Multiplicative with a(p^e) = 1 if p is a prime-indexed prime (A006450), and (p^(e+1)-1)/(p-1) otherwise (A007821).

A360330 a(n) is the number of divisors of n that have only prime factors that are not prime-indexed primes.

Original entry on oeis.org

1, 2, 1, 3, 1, 2, 2, 4, 1, 2, 1, 3, 2, 4, 1, 5, 1, 2, 2, 3, 2, 2, 2, 4, 1, 4, 1, 6, 2, 2, 1, 6, 1, 2, 2, 3, 2, 4, 2, 4, 1, 4, 2, 3, 1, 4, 2, 5, 3, 2, 1, 6, 2, 2, 1, 8, 2, 4, 1, 3, 2, 2, 2, 7, 2, 2, 1, 3, 2, 4, 2, 4, 2, 4, 1, 6, 2, 4, 2, 5, 1, 2, 1, 6, 1, 4, 2
Offset: 1

Author

Amiram Eldar, Feb 03 2023

Keywords

Comments

Equivalently, a(n) is the number of divisors of the largest divisor of n that has only prime factors that are not prime-indexed primes.

Programs

  • Maple
    a:= n-> mul(`if`(isprime(numtheory[pi](i[1])), 1, i[2]+1), i=ifactors(n)[2]):
    seq(a(n), n=1..87);  # Alois P. Heinz, Feb 03 2023
  • Mathematica
    f[p_, e_] := If[PrimeQ[PrimePi[p]], 1, e+1]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
  • PARI
    a(n) = {my(f = factor(n), p = f[,1], e = f[,2]); prod(i = 1, #p, if(isprime(primepi(p[i])), 1, e[i]+1));}

Formula

a(n) = 1 if and only if n is in A076610.
a(n) = A000005(n) if and only if n is in A320628.
a(n) = A000005(A360329(n)).
Multiplicative with a(p^e) = 1 if p is a prime-indexed prime (A006450), and e+1 otherwise (A007821).

A360329 a(n) is the largest divisor of n that has only prime factors that are not prime-indexed primes.

Original entry on oeis.org

1, 2, 1, 4, 1, 2, 7, 8, 1, 2, 1, 4, 13, 14, 1, 16, 1, 2, 19, 4, 7, 2, 23, 8, 1, 26, 1, 28, 29, 2, 1, 32, 1, 2, 7, 4, 37, 38, 13, 8, 1, 14, 43, 4, 1, 46, 47, 16, 49, 2, 1, 52, 53, 2, 1, 56, 19, 58, 1, 4, 61, 2, 7, 64, 13, 2, 1, 4, 23, 14, 71, 8, 73, 74, 1, 76, 7
Offset: 1

Author

Amiram Eldar, Feb 03 2023

Keywords

Programs

  • Mathematica
    f[p_, e_] := If[PrimeQ[PrimePi[p]], 1, p^e]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
  • PARI
    a(n) = {my(f = factor(n)); for(i = 1, #f~, if(isprime(primepi(f[i,1])), f[i,1]=1)); factorback(f);}

Formula

a(n) = 1 if and only if n is in A076610.
a(n) = n if and only if n is in A320628.
a(n) = n/A360325(n).
Multiplicative with a(p^e) = 1 if p is a prime-indexed prime (A006450), and p^e otherwise (A007821).
Sum_{k=1..n} a(k) ~ (1/2) * c * n^2, where c = Product_{p in A006450} p/(p+1) < 0.4 (see A302590 for an estimate of 1/c).