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-7 of 7 results.

A381221 Partial sums of A381116.

Original entry on oeis.org

6, 9, 16, 23, 29, 40, 48, 56, 57, 72, 84, 93, 106, 116, 135, 142, 160, 171, 189, 194, 216, 228, 249, 252, 272, 283, 318, 323, 339, 357, 375, 398, 415, 435, 461, 478, 481, 523, 527, 534, 576, 598, 623, 624, 658, 667, 675, 722, 728, 783, 791, 840, 847, 855, 861, 903, 917, 949, 968, 974, 1025, 1027, 1077, 1088, 1115, 1157
Offset: 1

Views

Author

N. J. A. Sloane, Feb 18 2025

Keywords

A381220 First differences of A381116.

Original entry on oeis.org

6, 3, 7, 7, 6, 11, 8, 8, 1, 15, 12, 9, 13, 10, 19, 7, 18, 11, 18, 5, 22, 12, 21, 3, 20, 11, 35, 5, 16, 18, 18, 23, 17, 20, 26, 17, 3, 42, 4, 7, 42, 22, 25, 1, 34, 9, 8, 47, 6, 55, 8, 49, 7, 8, 6, 42, 14, 32, 19, 6, 51, 2, 50, 11, 27, 42, 25, 46, 54, 21, 22, 45, 4, 16, 53, 4, 73, 10, 25, 39, 9, 70, 11, 46, 33, 49, 27, 11, 20, 17
Offset: 1

Views

Author

N. J. A. Sloane, Feb 18 2025

Keywords

Crossrefs

A381115 Composite terms in A381019 in order of appearance.

Original entry on oeis.org

4, 9, 8, 6, 25, 12, 10, 49, 15, 16, 14, 27, 20, 21, 22, 18, 35, 24, 169, 28, 33, 26, 85, 32, 57, 77, 30, 34, 39, 55, 38, 51, 40, 91, 36, 121, 42, 65, 44, 45, 529, 48, 119, 46, 95, 81, 143, 50, 63, 52, 54, 115, 56, 841, 187, 69, 62, 125, 87, 64, 133, 75, 58, 221
Offset: 1

Views

Author

N. J. A. Sloane, Feb 14 2025

Keywords

Crossrefs

Programs

  • Mathematica
    nn = 500; c[_] = False; u = v = 2; a[1] = 1;
    Monitor[Reap[
      Do[k = u;
        While[Or[c[k],
          ! CoprimeQ[k, Product[a[h], {h, n - Min[k, n - 1], n - 1}] ] ],
          If[k > n - 1, k = v, k++]];
        Set[{a[n], c[k]}, {k, True}];
        If[CompositeQ[k], Sow[k]];
        If[k == u, While[c[u], u++]];
    If[k == v, While[Or[c[v], CompositeQ[v]], v++]], {n, 2, nn}] ][[-1, 1]], n] (* Michael De Vlieger, Feb 14 2025 *)
  • Python
    from math import gcd
    from sympy import isprime
    from itertools import count, islice
    def agen(): # generator of terms
        alst, aset, an, m = [1], {1}, 1, 2
        for n in count(2):
            if an > 3 and not isprime(an):
                yield an
            an = next(k for k in count(m) if k not in aset and all(gcd(alst[-j], k) == 1 for j in range(1, min(k, n-1)+1)))
            alst.append(an)
            aset.add(an)
            while m in aset: m += 1
    print(list(islice(agen(), 64))) # Michael S. Branicky, Feb 14 2025

A381117 Lengths of runs of consecutive primes in A381019.

Original entry on oeis.org

5, 5, 2, 6, 6, 5, 10, 7, 7, 14, 11, 8, 12, 9, 18, 6, 17, 10, 17, 4, 21, 11, 20, 2, 19, 10, 34, 4, 15, 17, 17, 22, 16, 19, 25, 16, 2, 41, 3, 6, 41, 21, 24, 33, 8, 7, 46, 5, 54, 7, 48, 6, 7, 5, 41, 13, 31, 18, 5, 50, 1, 49, 10, 26, 41, 24, 45, 53, 20, 21, 44, 3
Offset: 1

Views

Author

N. J. A. Sloane, Feb 14 2025

Keywords

Comments

For n > 1, a(n) = A381116(n) - A381116(n-1) - 1. (This is a trivial consequence of the definitions.)

Crossrefs

Programs

  • Mathematica
    nn = 500; c[_] = False; i = 0; u = v = 2; a[1] = 1;
    Monitor[Reap[
      Do[k = u;
        While[Or[c[k],
          ! CoprimeQ[k, Product[a[h], {h, n - Min[k, n - 1], n - 1}] ] ],
        If[k > n - 1, k = v, k++]];
        Set[{a[n], c[k]}, {k, True}];
        If[CompositeQ[k], Sow[i]; i = 0, i++];
        If[k == u, While[c[u], u++]];
    If[k == v, While[Or[c[v], CompositeQ[v]], v++]], {n, 2, nn}] ][[-1, 1]], n] (* Michael De Vlieger, Feb 14 2025 *)

A381119 Index of n in A381019.

Original entry on oeis.org

1, 2, 3, 7, 4, 23, 5, 16, 13, 47, 6, 36, 8, 79, 63, 64, 9, 142, 10, 100, 113, 123, 11, 167, 30, 223, 91, 196, 12, 290, 14, 256, 201, 325, 149, 442, 15, 364, 330, 405, 17, 485, 18, 530, 534, 630, 19, 583, 55, 682, 382, 735, 20, 790, 346, 847, 259, 1034, 21, 1095
Offset: 1

Views

Author

N. J. A. Sloane, Feb 14 2025

Keywords

Comments

Every number does eventually appear in A381019 (see that sequence for proof).

Crossrefs

Extensions

More terms from Alois P. Heinz, Feb 14 2025

A381118 Index of 2^n in A381019.

Original entry on oeis.org

1, 2, 7, 16, 64, 256, 975, 3856, 16647, 65039, 260112, 1044504, 4177980, 16777224
Offset: 0

Views

Author

N. J. A. Sloane, Feb 14 2025

Keywords

Comments

Every power of 2 appears in A381019 (see that entry for proof).

Crossrefs

Extensions

a(7) from Michael S. Branicky, Feb 14 2025
a(8) from Michael S. Branicky, Feb 15 2025
a(9)-a(13) from Jinyuan Wang, Feb 16 2025

A381095 Indices of prime squares in A381019.

Original entry on oeis.org

7, 13, 30, 55, 178, 468, 541, 854, 1454, 2099, 3744, 7330, 9091, 10138, 11917, 14154, 14350, 19363, 21555, 23553, 26615, 36109, 36533, 37302, 51588, 52576, 57183, 58064, 58144, 63067, 69927, 70135, 80174, 81920, 85923, 89936, 93749, 99240, 121884, 124693, 151411
Offset: 1

Views

Author

Michael De Vlieger, Feb 16 2025

Keywords

Comments

Let S = A381019.
Observation: S(n) < n for S(n) = prime(i)^2 for some i.

Examples

			Table listing n and S(n), where i = pi(sqrt(S(n))) and S = A381019. Asterisks denote confirmed S(n) = prime(i)^2 coprime to P(r)/prime(i), where P = A002110 and r, the index of the largest prime in S(1..n-1).
      n    i             S(n)
  --------------------------
      7    1     2^2 =     4 *
     13    2     3^2 =     9 *
     30    3     5^2 =    25 *
     55    4     7^2 =    49 *
    178    6    13^2 =   169 *
    468    5    11^2 =   121
    541    9    23^2 =   529 *
    854   10    29^2 =   841 *
   1454    7    17^2 =   289
   2099    8    19^2 =   361
   3744   18    61^2 =  3721 *
   7330   11    31^2 =   961
   9091   12    37^2 =  1369
  10138   13    41^2 =  1681
  11917   29   109^2 = 11881
  14154   14    43^2 =  1849
  14350   15    47^2 =  2209
  19363   34   139^2 = 19321
  21555   16    53^2 =  2809
  23553   17    59^2 =  3481
  26615   38   163^2 = 26569
  36109   21    73^2 =  5329
  36533   43   191^2 = 36481
  37302   44   193^2 = 37249
  51588   49   227^2 = 51529
  52576   20    71^2 =  5041
  57183   52   239^2 = 57121
  58064   19    67^2 =  4489
  58144   53   241^2 = 58081
  63067   54   251^2 = 63001
		

Crossrefs

Programs

  • Mathematica
    s = {1}; nn = 4000; r = 1; u = v = 2; c[_] = False;
    MapIndexed[Set[{a[First[#2]], c[#1]}, {#1, True}] &, s];
    While[c[u], u++]; While[Or[c[v], CompositeQ[v]], v++];
    Monitor[Reap[
      Do[k = u; q = Product[a[h], {h, n - Min[k, n - 1], n - 1}];
        While[Or[c[k], ! CoprimeQ[k, q]],
          If[k > n - 1, k = v; q = Product[a[i], {i, r}],
            k++; q *= a[n - k] ] ];
        Set[{a[n], c[k]}, {k, True}];
        If[And[PrimeQ[k], # > r], r = #] &[PrimePi[k]];
        If[PrimeQ@ Sqrt[k], Sow[n]];
        If[k == u, While[c[u], u++]];
        If[k == v, While[Or[c[v], CompositeQ[v]], v++]],
      {n, Length[s] + 1, nn}] ][[-1, 1]], n]

Extensions

More terms from Jinyuan Wang, Feb 25 2025
Showing 1-7 of 7 results.