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.

Previous Showing 11-12 of 12 results.

A252503 Smallest prime p such that Phi_n(p) is also prime, where Phi is the cyclotomic polynomial, or 0 if no such p exists.

Original entry on oeis.org

3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 5, 2, 2, 2, 2, 2, 2, 7, 2, 11, 3, 2, 113, 2, 43, 2, 2, 5, 151, 2, 2, 2, 2, 2, 179, 3, 61, 2, 23, 2, 53, 2, 89, 137, 11, 2, 5, 5, 2, 7, 73, 11, 307, 7, 7, 2, 5, 7, 19, 3, 2, 2, 3, 0, 2, 53, 491, 197, 2, 3, 3, 3, 11, 19, 59, 7, 2, 2, 271, 2, 191, 61, 41, 7, 2, 2, 59, 5, 2, 2
Offset: 1

Views

Author

Eric Chen, Dec 18 2014

Keywords

Comments

Conjecture: a(n) > 0 for all n != 2^k (k>5).
Clearly, if n is a power of 2, and Phi_n(2) is not prime, then a(n) = 0.
Records: 3, 5, 7, 11, 113, 151, 179, 307, 491, 839, 1427, 2411, 5987, 6389, 8933, 11813, 18587, 31721, 40763, 46349, ..., . - Robert G. Wilson v, May 21 2017

Crossrefs

Programs

  • Mathematica
    Do[n=1; p=Prime[n]; cp=Cyclotomic[k, p]; While[!PrimeQ[cp], n=n+1; p=Prime[n]; cp=Cyclotomic[k, p]]; Print[p], {k, 1, 300}]
  • PARI
    a(n)=if(n>>valuation(n,2)==1 && n>32, if(ispseudoprime(2^(n/2)+1), 2, 0), my(P=polcyclo(n)); forprime(p=2,, if(ispseudoprime(subst(P,'x,p)), return(p)))) \\ Charles R Greathouse IV, Dec 18 2014

A353101 Least b > 1 such that (b^(prime(n)^2) - 1)/(b^prime(n) - 1) is prime.

Original entry on oeis.org

2, 2, 22, 2, 43, 24, 315, 38, 54, 265, 605, 61, 697, 306, 1153, 370, 2, 10688, 3075, 2338, 1153, 3243, 130, 2301, 315, 200, 1155, 14739, 4591, 2230, 263, 6665, 250, 10520, 2228, 3699, 1126, 8925, 8732, 10556, 19860, 29121, 32804, 4666, 2313, 27398, 14280, 2013, 29022, 26131, 21430, 21996, 95774, 49363, 12648, 54308, 6737, 8745, 11121, 49627
Offset: 1

Views

Author

Jeppe Stig Nielsen, Apr 24 2022

Keywords

Comments

The expression is the cyclotomic polynomial value Phi_{p^2}(b) where p=prime(n).
By definition, a(n) > 1. The occurrences of a(n)=2 correspond exactly to the terms of A156585.
Does a(n) tend to infinity (is liminf a(n) infinite)?
If it exists, a(27) > 857. - J.W.L. (Jan) Eerland, Dec 23 2022
a(65) = 1624. - Serge Batalov, Nov 17 2023

Crossrefs

Programs

  • Mathematica
    Table[k=2;Monitor[Parallelize[While[True,If[PrimeQ[(k^(Prime[n]^2)-1)/(k^Prime[n]-1)],Break[]];k++];k],k],{n,1,10}] (* J.W.L. (Jan) Eerland, Dec 22 2022 *)
  • PARI
    forprime(p=2,,for(b=2,+oo,if(ispseudoprime(polcyclo(p^2,b)),print1(b,", ");break())))
    
  • Python
    from sympy import isprime, prime
    def a(n, startb=2):
        pn = prime(n); pn2 = pn**2; b = startb
        while not isprime((b**pn2-1)//(b**pn-1)): b += 1
        return b
    print([a(n) for n in range(1, 10)]) # Michael S. Branicky, Jun 21 2022

Formula

a(n) = A085398(prime(n)^2) = A085398(A001248(n)).

Extensions

a(25)-a(26) from J.W.L. (Jan) Eerland, Dec 23 2022
a(27) from Michael S. Branicky, Apr 04 2023
a(28)-a(33) from Martin Hopf, Nov 10 2023
a(34)-a(60) from Ryan Propper, Nov 17 2023
Previous Showing 11-12 of 12 results.