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-10 of 13 results. Next

A005384 Sophie Germain primes p: 2p+1 is also prime.

Original entry on oeis.org

2, 3, 5, 11, 23, 29, 41, 53, 83, 89, 113, 131, 173, 179, 191, 233, 239, 251, 281, 293, 359, 419, 431, 443, 491, 509, 593, 641, 653, 659, 683, 719, 743, 761, 809, 911, 953, 1013, 1019, 1031, 1049, 1103, 1223, 1229, 1289, 1409, 1439, 1451, 1481, 1499, 1511, 1559
Offset: 1

Views

Author

Keywords

Comments

Then 2p+1 is called a safe prime: see A005385.
Primes p such that the equation phi(x) = 2p has solutions, where phi is the totient function. See A087634 for another such collection of primes. - T. D. Noe, Oct 24 2003
Subsequence of A117360. - Reinhard Zumkeller, Mar 10 2006
Let q = 2n+1. For these n (and q), the difference of two cyclotomic polynomials can be written as a cyclotomic polynomial in x^2: Phi(q,x) - Phi(2q,x) = 2x Phi(n,x^2). - T. D. Noe, Jan 04 2008
A Sophie Germain prime p is 2, 3 or of the form 6k-1, k >= 1, i.e., p = 5 (mod 6). A prime p of the form 6k+1, k >= 1, i.e., p = 1 (mod 6), cannot be a Sophie Germain prime since 2p+1 is divisible by 3. - Daniel Forgues, Jul 31 2009
Also solutions to the equation: floor(4/A000005(2*n^2+n)) = 1. - Enrique Pérez Herrero, May 03 2012
In the spirit of the conjecture related to A217788, we conjecture that for any integers n >= m > 0 there are infinitely many integers b > a(n) such that the number Sum_{k=m..n} a(k)*b^(n-k) is prime. - Zhi-Wei Sun, Mar 26 2013
If k is the product of a Sophie Germain prime p and its corresponding safe prime 2p+1, then a(n) = (k-phi(k))/3, where phi is Euler's totient function. - Wesley Ivan Hurt, Oct 03 2013
Giovanni Resta found the first Sophie Germain prime which is also a Brazilian number (A125134), 28792661 = 1 + 73 + 73^2 + 73^3 + 73^4 = (11111)73. - _Bernard Schott, Mar 07 2019
For all Sophie Germain primes p >= 5, 2*p + 1 = min(A, B) where A is the smallest prime factor of 2^p - 1 and B the smallest prime factor of (2^p + 1) / 3. - Alain Rocchelli, Feb 01 2023
Consider a pair of numbers (p, 2*p+1), with p >= 3. Then p is a Sophie Germain prime iff (p-1)!^2 + 6*p == 1 (mod p*(2*p+1)). - Davide Rotondo, May 02 2024

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 870.
  • A. Peretti, The quantity of Sophie Germain primes less than x, Bull. Number Theory Related Topics, Vol. 11, No. 1-3 (1987), pp. 81-92.
  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See pp. 76, 227-230.
  • Joe Roberts, Lure of the Integers, Math. Assoc. America, 1992, p. 83.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, page 114.

Crossrefs

Cf. also A000355, A156541, A156542, A156592, A161896, A156660, A156874, A092816, A023212, A007528 (primes of the form 6k-1).
For primes p that remains prime through k iterations of the function f(x) = 2x + 1: this sequence (k=1), A007700 (k=2), A023272 (k=3), A023302 (k=4), A023330 (k=5), A278932 (k=6), A138025 (k=7), A138030 (k=8).

Programs

  • GAP
    Filtered([1..1600],p->IsPrime(p) and IsPrime(2*p+1)); # Muniru A Asiru, Mar 06 2019
    
  • Magma
    [ p: p in PrimesUpTo(1560) | IsPrime(2*p+1) ]; // Klaus Brockhaus, Jan 01 2009
    
  • Maple
    A:={}: for n from 1 to 246 do if isprime(2*ithprime(n)+1) then A:=A union {ithprime(n)} fi od: A:=A; # Emeric Deutsch, Dec 09 2004
  • Mathematica
    Select[Prime[Range[1000]],PrimeQ[2#+1]&]
    lst = {}; Do[If[PrimeQ[n + 1] && PrimeOmega[n] == 2, AppendTo[lst, n/2]], {n, 2, 10^4}]; lst (* Hilko Koning, Aug 17 2021 *)
  • PARI
    select(p->isprime(2*p+1), primes(1000)) \\ In old PARI versions <= 2.4.2, use select(primes(1000), p->isprime(2*p+1)).
    
  • PARI
    forprime(n=2, 10^3, if(ispseudoprime(2*n+1), print1(n, ", "))) \\ Felix Fröhlich, Jun 15 2014
    
  • PARI
    is_A005384=(p->isprime(2*p+1)&&isprime(p));
      {A005384_vec(N=100,p=1)=vector(N,i,until(isprime(2*p+1),p=nextprime(p+1));p)} \\ M. F. Hasler, Mar 03 2020
    
  • Python
    from sympy import isprime, nextprime
    def ok(p): return isprime(2*p+1)
    def aupto(limit): # only test primes
      alst, p = [], 2
      while p <= limit:
        if ok(p): alst.append(p)
        p = nextprime(p)
      return alst
    print(aupto(1559)) # Michael S. Branicky, Feb 03 2021

Formula

a(n) mod 10 <> 7. - Reinhard Zumkeller, Feb 12 2009
A156660(a(n)) = 1; A156874 gives numbers of Sophie Germain primes <= n. - Reinhard Zumkeller, Feb 18 2009
tau(4*a(n) + 2) = tau(4*a(n)) - 2, for n > 1. - Arkadiusz Wesolowski, Aug 25 2012
eulerphi(4*a(n) + 2) = eulerphi(4*a(n)) + 2, for n > 1. - Arkadiusz Wesolowski, Aug 26 2012
A005097 INTERSECT A000040. - R. J. Mathar, Mar 23 2017
Sum_{n>=1} 1/a(n) is in the interval (1.533944198, 1.8026367) (Wagstaff, 2021). - Amiram Eldar, Nov 04 2021
a(n) >> n log^2 n. - Charles R Greathouse IV, Jul 25 2024

A218465 Least integer b>2n+1 such that the numbers written as [1,3,...,2n-1,2n+1] and [2n+1,2n-1,...,3,1] in base b are both prime.

Original entry on oeis.org

4, 6, 8, 13, 54, 21, 56, 141, 282, 335, 132, 82, 3752, 93, 40, 5141, 774, 204, 60790, 27366, 270, 31591, 60, 247, 1976, 4848, 7112, 4954, 62808, 84, 17912, 78441, 3696, 8083, 5754, 19210, 21154, 17973, 59580
Offset: 1

Views

Author

Zhi-Wei Sun, Mar 26 2013

Keywords

Comments

Conjecture: Let n be any positive integer. Then a(n) exists, moreover there are infinitely many integers b > 2n+1 such that [1,3,...,2n-1,2n+1] and [2n+1,2n-1,...,3,1] in base b are both prime. Also, the polynomial S_n(x) = sum_{k=0}^n (2k+1)*x^{n-k} is irreducible modulo some prime p < (n+1)(n+2), and the Galois group of S_n(x) over the field of rational numbers is isomorphic to the symmetric group S_n.
This conjecture can be extended by replacing 2k+1 by (2k+1)^m. For example, [1^2,3^2,5^2,...,61^2,63^2] and [63^2,61^2,...,3^2,1^2] in base b=241784 are both prime.

Examples

			a(2)=6, since [1,3,5] in base 6 is 1*6^2+3*6+5=59, [5,3,1] in base 6 is 5*6^2+3*6+1=199, and both 59 and 199 are prime.
		

Crossrefs

Programs

  • Mathematica
    A[n_,x_]:=A[n,x]=Sum[(2k+1)*x^(n-k),{k,0,n}]
    B[n_,x_]:=B[n,x]=Sum[(2k+1)*x^k,{k,0,n}]
    Do[Do[Do[If[PrimeQ[A[n,b]]==True&&PrimeQ[B[n,b]]==True,Print[n," ",b];Goto[aa]],{b,2n+2,10^7}];
    Print[n," ",counterexample];Label[aa];Continue,{n,1,20}]]

A220072 Least prime p such that sum_{k=0}^n A005117(k+1)*x^{n-k} is irreducible modulo p.

Original entry on oeis.org

2, 5, 2, 7, 11, 31, 13, 19, 89, 17, 37, 37, 43, 19, 137, 29, 3, 7, 2, 19, 13, 59, 139, 37, 2, 239, 31, 337, 487, 97, 337, 97, 307, 181, 223, 19, 79, 401, 2, 491, 269, 211, 97, 193, 719, 149, 97, 191, 83, 613
Offset: 1

Views

Author

Zhi-Wei Sun, Mar 28 2013

Keywords

Comments

Conjecture: For any n>0, we have a(n) <= n*(n+1), and the Galois group of SF_n(x) = sum_{k=0}^n A005117(k+1)*x^{n-k} over the rationals is isomorphic to the symmetric group S_n.
For another related conjecture, see the author's comment on A005117.

Examples

			a(4)=7 since SF_4(x)=x^4+2x^3+3x^2+5x+6 is irreducible modulo 7 but reducible modulo any of 2, 3, 5. It is easy to check that SF_4(x)==(x-2)*(x^3-x^2+x+2) (mod 5).
		

Crossrefs

A223934 Least prime p such that x^n-x-1 is irreducible modulo p.

Original entry on oeis.org

2, 2, 2, 3, 2, 2, 7, 2, 17, 7, 5, 3, 3, 2, 109, 3, 101, 19, 229, 5, 2, 23, 23, 17, 107, 269, 2, 29, 2, 31, 37, 197, 107, 73, 37, 7, 59, 233, 3, 3, 7, 43, 43, 5, 2, 47, 269, 61, 43, 3, 53, 13, 3, 643, 13, 5, 151, 59, 2
Offset: 2

Views

Author

Zhi-Wei Sun, Mar 29 2013

Keywords

Comments

Conjecture: a(n) < n*(n+3)/2 for all n>1.
Note that a(20) = 229 < 20*(20+3)/2 = 230.
The conjecture was motivated by E. S. Selmer's result that for any n>1 the polynomial x^n-x-1 is irreducible over the field of rational numbers.
We also conjecture that for every n=2,3,... there is a positive integer z not exceeding the (2n-2)-th prime such that z^n-z-1 is prime, and the Galois group of x^n-x-1 over the field of rationals is isomorphic to the symmetric group S_n.

Examples

			a(8)=7 since f(x)=x^8-x-1 is irreducible modulo 7 but reducible modulo any of 2, 3, 5, for,
   f(x)==(x^2+x+1)*(x^6+x^5+x^3+x^2+1) (mod 2),
   f(x)==(x^3+x^2-x+1)*(x^5-x^4-x^3-x^2+x-1) (mod 3),
   f(x)==(x^2-2x-2)*(x^6+2x^5+x^4+x^3-x^2-2) (mod 5).
		

Crossrefs

Cf. A002475 (n such that x^n-x-1 is irreducible over GF(2)).
Cf. A223938 (n such that x^n-x-1 is irreducible over GF(3)).

Programs

  • Mathematica
    Do[Do[If[IrreduciblePolynomialQ[x^n-x-1,Modulus->Prime[k]]==True,Print[n," ",Prime[k]];Goto[aa]],{k,1,PrimePi[n*(n+3)/2-1]}];
    Print[n," ",counterexample];Label[aa];Continue,{n,2,100}]

A224197 Least b > p_n^2 such that [p_1^2,p_2^2,...,p_n^2] in base b is prime, where p_j denotes the j-th prime.

Original entry on oeis.org

11, 26, 51, 124, 177, 312, 394, 668, 843, 978, 1398, 1730, 1911, 2242, 2859, 3496, 3724, 4532, 5073, 5358, 6269, 6906, 7927, 9422, 10205, 10766, 11522, 12060, 12923, 16142, 17220, 18788, 19409, 22806, 22965, 25562, 26570, 28038, 30636
Offset: 2

Views

Author

Zhi-Wei Sun, Apr 01 2013

Keywords

Comments

Conjecture: (i) For any positive integer k and distinct positive integers a_1< a_2 < ... < a_n with a_n prime, there are infinitely many integers b > a_n^k such that [a_1^k,a_2^k,...,a_n^k] in base b is prime.
(ii) For positive integers k, m and n>m, let s_k(m,n) denote the smallest integer b > p_n^k such that [p_m^k,p_{m+1}^k,...,p_n^k] in base b is prime. Then we have the inequality s_k(m,n) <= (n+1)^k*(m+n+1)^k.
This is the k-th power version of the author's conjecture related to A217788. Note that s(m,n) defined there is identical with s_1(m,n). It seems that s_2(m,n) < p_{n+1}*p_{m+n+1}.
For example, [2^2,6^2,9^2,20^2,29^2] in base 900 and [37^2,38^2,60^2,90^2,101^2] in base 10268 are both prime. Also, s_3(1,15) = 103960 and s_5(3,5) = 161098.
Note that for any integer b>13^2 the number [2^2,5,6,156,13^2] in base b is composite since
4x^4+5x^3+6x^2+156x+169 = (4x+13)*(x^3-2x^2+8x+13).
Although 1, 2, 3, 113, 115 are pairwise relatively prime, [1,2,3,113,115] in any base b>115 is composite since x^4+2x^3+3x^2+113x+115 = (x+5)*(x^3-3x^2+18x+23).

Examples

			a(35) = s_2(1,35) = 22806 since [p_1^2,p_2^2,...,p_{35}^2] in base 22806 is prime. Note that p_{36}^2 = 22801 < 22806 < p_{35}*p_{37} = 23393 < p_{36}*p_{37} = 23707.
a(287) = s_2(1,287) = 3519434 since [p_1^2,p_2^2,...,p_{287}^2] in base 3519434 is prime. Note that p_{287}*p_{289} = 3519367 < 3519434 < p_{288}^2 = 3523129 < p_{288}*p_{289} = 3526883.
		

Crossrefs

Programs

  • Mathematica
    A[n_,x_]:=A[n,x]=Sum[Prime[k]^2*x^(n-k),{k,1,n}]
    Do[Do[Do[If[PrimeQ[A[n,b]]==True,Print[n," ",b];Goto[aa]],{b,Prime[n]^2+1,Prime[n+1]Prime[n+2]-1}];
    Print[n," ",counterexample];Label[aa];Continue,{n,2,100}]]

A224210 Least prime p such that sum_{k=0}^n (k+1)^2*x^{n-k} is irreducible modulo p.

Original entry on oeis.org

2, 11, 7, 17, 11, 3, 7, 97, 3, 89, 31, 113, 43, 7, 23, 23, 17, 67, 23, 109, 17, 277, 103, 283, 59, 101, 157, 127, 29, 79, 23, 223, 73, 269, 433, 137, 5, 659, 109, 401, 419, 7, 373, 131, 89, 269, 149, 61, 829, 881
Offset: 1

Views

Author

Zhi-Wei Sun, Apr 01 2013

Keywords

Comments

Conjecture: a(n) does not exceed the (4n-3)-th prime for each n>0. Moreover, for any integers m>1 and n>0 the polynomial sum_{k=0}^n (k+1)^m*x^{n-k} is irreducible modulo some prime, and its Galois group over the rationals is isomorphic to the symmetric group S_n. Also, for m,n=2,3,... there are infinitely many integers b > n^m such that [n^m,...,2^m,1^m] in base b is prime.
We have a similar conjecture with the above (k+1)^m replaced by (2k+1)^m.

Examples

			a(3) = 7 since f(x) = x^3+4x^2+9x+16 is irreducible modulo 7 but reducible modulo any of 2, 3, 5. Note that
   f(x)==x*(x-1)^2 (mod 2),  f(x)==(x-1)*(x^2-x-1) (mod 3)
and
          f(x)==(x+1)*(x-1)^2 (mod 5).
		

Crossrefs

Programs

  • Mathematica
    A[n_,x_]:=Sum[(k+1)^2*x^(n-k),{k,0,n}]
    Do[Do[If[IrreduciblePolynomialQ[A[n,x],Modulus->Prime[k]]==True,Print[n," ",Prime[k]];Goto[aa]],{k,1,Prime[4n-3]}];
    Print[n," ",counterexample];Label[aa];Continue,{n,1,100}]

A224416 Least prime p such that the polynomial sum_{k=0}^n C_k*x^{n-k} is irreducible modulo p, where C_k denotes the Catalan number binomial(2k,k)/(k+1).

Original entry on oeis.org

2, 3, 2, 3, 17, 7, 47, 3, 53, 5, 137, 109, 79, 11, 37, 7, 59, 13, 53, 251, 251, 101, 467, 149, 79, 3, 83, 61, 239, 31, 79, 73, 73, 373, 199, 5, 337, 167, 17, 683, 523, 269, 37, 163, 431, 163, 163, 7, 487, 7, 167, 163, 197, 1549, 137, 503, 139, 263, 151, 283
Offset: 1

Views

Author

Zhi-Wei Sun, Apr 06 2013

Keywords

Comments

Conjecture: (i) a(n) does not exceed n^2+n+5 for each n>0, and the Galois group of sum_{k=0}^n C_k*x^{n-k} over the rationals is isomorphic to the symmetric group S_n.
(ii) For any positive integer n, the polynomial sum_{k=0}^n binomial(2k,k)*x^{n-k} is irreducible modulo some prime if and only if n is not of the form 2k(k+1), where k is a positive integer.
(iii) For any positive integer n, the polynomial sum_{k=0}^n T_k*x^{n-k} is irreducible modulo some prime not exceeding n^2+n+5, where T_k referes to the central trinomial coefficient A002426(k) which is the coefficient of x^k in the expansion of (x^2+x+1)^k.

Examples

			a(10) = 5 since sum_{k=0}^{10} C_k*x^{n-k} irreducible modulo 5 but reducible modulo any of 2 and 3.
Note also that a(11) = 137 coincides with 11^2+11+5.
		

Crossrefs

Programs

  • Mathematica
    A[n_,x_]:=A[n,x]=Sum[Binomial[2k,k]/(k+1)*x^(n-k),{k,0,n}]
    Do[Do[If[IrreduciblePolynomialQ[A[n,x],Modulus->Prime[k]]==True,Print[n," ",Prime[k]];Goto[aa]],{k,1,PrimePi[n^2+n+5]}];
    Print[n," ",counterexample];Label[aa];Continue,{n,1,100}]

A224417 Least prime p such that sum_{k=0}^n B_k*x^{n-k} is irreducible modulo p, where B_k refers to the Bell number A000110(k).

Original entry on oeis.org

2, 3, 2, 11, 3, 2, 193, 113, 2, 29, 71, 167, 19, 3, 7, 13, 199, 5, 101, 59, 13, 41, 3, 359, 7, 11, 2, 31, 197, 139, 3, 59, 2, 139, 83, 37, 23, 193, 587, 199, 67, 47, 401, 41, 571, 73, 1063, 229, 1163, 47, 53, 239, 347, 223, 577, 499, 271, 269, 11, 179
Offset: 1

Views

Author

Zhi-Wei Sun, Apr 06 2013

Keywords

Comments

Conjecture: a(n) < 4n^2-1 for all n>0.

Examples

			a(5) = 3 since the polynomial sum_{k=0}^5 B_5*x^{5-k} = x^5+x^4+2*x^3+5*x^2+15*x+52 is irreducible modulo 3 but reducible modulo 2.
Note also that a(7) = 193 < 4*7^2-1 = 195.
		

Crossrefs

Programs

  • Mathematica
    A[n_,x_]:=A[n,x]=Sum[BellB[k]*x^(n-k),{k,0,n}]
    Do[Do[If[IrreduciblePolynomialQ[A[n,x],Modulus->Prime[k]]==True,Print[n," ",Prime[k]];Goto[aa]],{k,1,PrimePi[4n^2-2]}];
    Print[n," ",counterexample];Label[aa];Continue,{n,1,100}]

A224418 Least prime q such that sum_{k=0}^n p(k)*x^{n-k} is irreducible modulo q, where p(k) refers to the partition number A000041(k).

Original entry on oeis.org

2, 3, 2, 11, 2, 13, 19, 19, 13, 29, 73, 47, 19, 43, 7, 59, 13, 29, 3, 13, 179, 29, 173, 19, 3, 163, 23, 3, 101, 71, 131, 977, 5, 157, 43, 13, 73, 2, 89, 197, 151, 151, 313, 3, 13, 31, 23, 97, 173, 241, 181, 109, 487, 157, 17, 29, 89, 109, 257, 317
Offset: 1

Views

Author

Zhi-Wei Sun, Apr 06 2013

Keywords

Comments

Conjecture: a(n) < n^2 for all n > 1.

Examples

			a(2) = 3 since sum_{k=0}^2 p(k)*x^{n-k} = x^2 + x + 2  is irreducible modulo 3 but reducible modulo 2.
		

Crossrefs

Programs

  • Mathematica
    A[n_,x_]:=A[n,x]=Sum[PartitionsP[k]*x^(n-k),{k,0,n}]
    Do[Do[If[IrreduciblePolynomialQ[A[n,x],Modulus->Prime[k]]==True,Print[n," ",Prime[k]];Goto[aa]],{k,1,PrimePi[Max[1,n^2-1]]}];
    Print[n," ",counterexample];Label[aa];Continue,{n,1,100}]

A224480 Least prime q such that x^n + sum_{k=1}^n p_k*x^{n-k} is irreducible modulo q, where p_k denotes the k-th prime.

Original entry on oeis.org

2, 11, 2, 2, 2, 2, 2, 53, 13, 3, 5, 2, 2, 2, 2, 421, 29, 19, 7, 2, 29, 37, 2, 743, 41, 23, 13, 47, 5, 2, 269, 139, 211, 31, 73, 307, 2, 2, 5, 89, 23, 839, 181, 379, 173, 89, 2, 353, 101, 307, 3, 29, 389, 2, 863, 71, 503, 619, 193, 2
Offset: 1

Views

Author

Zhi-Wei Sun, Apr 07 2013

Keywords

Comments

Conjecture: a(n) <= (n+4)*(n+5)+1 for all n>0.

Examples

			a(10) = 3 since P(x) = x^{10} + 2*x^9 + 3*x^8 + 5*x^7 + 7*x^6
+ 11*x^5 + 13*x^4 + 17*x^3 + 19*x^2 + 23*x + 29 is irreducible modulo 3, but reducible modulo 2, for,
    P(x)==(x+1)^2*(x^3+x+1)*(x^5+x^3+1) (mod 2).
Note also that a(16) = 421 = (16+4)*(16+5)+1.
		

Crossrefs

Programs

  • Mathematica
    A[n_,x_]:=A[n,x]=Sum[x^n+Prime[k]*x^(n-k),{k,1,n}]
    Do[Do[If[IrreduciblePolynomialQ[A[n,x],Modulus->Prime[k]]==True,Print[n," ",Prime[k]];Goto[aa]],{k,1,PrimePi[n^2+9n+21]}];
    Print[n," ",counterexample];Label[aa];Continue,{n,1,100}]
Showing 1-10 of 13 results. Next