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

A318239 a(n) is the smallest primitive root of A133433(n).

Original entry on oeis.org

2, 3, 5, 6, 7, 10, 11, 12, 18, 20, 24, 40, 42, 45, 48, 54, 72, 80, 96
Offset: 1

Views

Author

Jianing Song, Aug 22 2018

Keywords

Comments

Also with an initial 1, numbers k such that A023048(k) set a new record.
If A023048(108) != 0 (which is implied assuming generalized Artin's conjecture) then the next term of this sequence is 108.
Conjecturally 11 is the largest prime in this sequence, 42 is the largest squarefree term, and 45 is the largest odd term.

Examples

			The smallest prime with least primitive root 11 is 643, and the smallest prime with least primitive root 2, 3, 5, ..., 10 are all < 643, so 11 is a term.
The smallest prime with least primitive root 45 is 95525767, and the smallest prime with least primitive root 2, 3, 5, ..., 44 are all < 95525767, so 45 is a term.
13 is not a term since the smallest prime with least primitive root 13 is 457, but the smallest prime with least primitive root 12 is 4111, which is larger than 457.
		

Crossrefs

A023048 Smallest prime having least positive primitive root n, or 0 if no such prime exists.

Original entry on oeis.org

2, 3, 7, 0, 23, 41, 71, 0, 0, 313, 643, 4111, 457, 1031, 439, 0, 311, 53173, 191, 107227, 409, 3361, 2161, 533821, 0, 12391, 0, 133321, 15791, 124153, 5881, 0, 268969, 48889, 64609, 0, 36721, 55441, 166031, 1373989, 156601, 2494381, 95471, 71761, 95525767
Offset: 1

Views

Author

Keywords

Comments

a(n) = 0 iff n is a perfect power m^k, m >= 1, k >= 2 (i.e., a member of A001597).
Of course if n is a perfect power then a(n) = 0, but it seems that the other direction is true only assuming the generalized Artin's conjecture. See the link from Tomás Oliveira e Silva below. - Jianing Song, Jan 22 2019

Examples

			a(2) = 3, since 3 has 2 as smallest positive primitive root and no prime p < 3 has 2 as smallest positive primitive root.
a(24) = 533821, since prime 533821 has 24 as smallest positive primitive root and no prime p < 533821 has 24 as smallest positive primitive root.
		

References

  • A. E. Western and J. C. P. Miller, Tables of Indices and Primitive Roots. Royal Society Mathematical Tables, Vol. 9, Cambridge Univ. Press, 1968, p. XLIV.

Crossrefs

Indices of the primes: A066529.
For records see A133433. See A133432 for a version without the 0's.

Programs

  • Mathematica
    t = Table[0, {100}]; Do[a = PrimitiveRoot@Prime@n; If[a < 101 && t[[a]] == 0, t[[a]] = n], {n, 10^6}]; Unprotect[Prime]; Prime[0] = 0; Prime@t; Clear[Prime]; Protect[Prime] (* Robert G. Wilson v, Dec 15 2005 *)
  • Python
    from sympy import nextprime, perfect_power, primitive_root
    def a(n):
        if perfect_power(n): return 0
        p = 2
        while primitive_root(p) != n: p = nextprime(p)
        return p
    print([a(n) for n in range(1, 40)]) # Michael S. Branicky, Feb 13 2023
    
  • Python
    # faster version for initial segment of sequence
    from itertools import count, islice
    from sympy import nextprime, perfect_power, primitive_root
    def agen(): # generator of terms
        p, adict, n = 2, {None: 0}, 1
        for k in count(1):
            v = primitive_root(p)
            if v not in adict:
                adict[v] = p
            if perfect_power(n): adict[n] = 0
            while n in adict: yield adict[n]; n += 1
            p = nextprime(p)
    print(list(islice(agen(), 40))) # Michael S. Branicky, Feb 13 2023

Formula

a(n) = min { prime(k) | A001918(k) = n } U {0} = A000040(A066529(n)) (or zero). - M. F. Hasler, Jun 01 2018

Extensions

Comment corrected by Christopher J. Smyth, Oct 16 2013

A133432 Let m = n-th number that is not a perfect power, A007916(n). Then a(n) = smallest prime having least positive primitive root m.

Original entry on oeis.org

3, 7, 23, 41, 71, 313, 643, 4111, 457, 1031, 439, 311, 53173, 191, 107227, 409, 3361, 2161, 533821, 12391, 133321, 15791, 124153, 5881, 268969, 48889, 64609, 36721, 55441, 166031, 1373989, 156601, 2494381, 95471, 71761, 95525767
Offset: 1

Views

Author

N. J. A. Sloane, Nov 29 2007

Keywords

Comments

a(n) = A023048(A007916(n)).

Crossrefs

Cf. A023048, A007916, A001597, A133433 (records).

Extensions

Definition corrected by Christopher J. Smyth, Oct 16 2013
Showing 1-3 of 3 results.