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 11 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

A005597 Decimal expansion of the twin prime constant C_2 = Product_{ p prime >= 3 } (1-1/(p-1)^2).

Original entry on oeis.org

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

Views

Author

Keywords

Comments

C_2 = Product_{ p prime > 2} (p * (p-2) / (p-1)^2) is the 2-tuple case of the Hardy-Littlewood prime k-tuple constant (part of First H-L Conjecture): C_k = Product_{ p prime > k} (p^(k-1) * (p-k) / (p-1)^k).
Although C_2 is commonly called the twin prime constant, it is actually the prime 2-tuple constant (prime pair constant) which is relevant to prime pairs (p, p+2m), m >= 1.
The Hardy-Littlewood asymptotic conjecture for Pi_2m(n), the number of prime pairs (p, p+2m), m >= 1, with p <= n, claims that Pi_2m(n) ~ C_2(2m) * Li_2(n), where Li_2(n) = Integral_{2, n} (dx/log^2(x)) and C_2(2m) = 2 * C_2 * Product_{p prime > 2, p | m} (p-1)/(p-2), which gives: C_2(2) = 2 * C_2 as the prime pair (p, p+2) constant, C_2(4) = 2 * C_2 as the prime pair (p, p+4) constant, C_2(6) = 2* (2/1) * C_2 as the prime pair (p, p+6) constant, C_2(8) = 2 * C_2 as the prime pair (p, p+8) constant, C_2(10) = 2 * (4/3) * C_2 as the prime pair (p, p+10) constant, C_2(12) = 2 * (2/1) * C_2 as the prime pair (p, p+12) constant, C_2(14) = 2 * (6/5) * C_2 as the prime pair (p, p+14) constant, C_2(16) = 2 * C_2 as the prime pair (p, p+16) constant, ... and, for i >= 1, C_2(2^i) = 2 * C_2 as the prime pair (p, p+2^i) constant.
C_2 also occurs as part of other Hardy-Littlewood conjectures related to prime pairs, e.g., the Hardy-Littlewood conjecture concerning the distribution of the Sophie Germain primes (A156874) on primes p such that 2p+1 is also prime.
Another constant related to the twin primes is Viggo Brun's constant B (sometimes also called the twin primes Viggo Brun's constant B_2) A065421, where B_2 = Sum (1/p + 1/q) as (p,q) runs through the twin primes.
Reciprocal of the Selberg-Delange constant A167864. See A167864 for additional comments and references. - Jonathan Sondow, Nov 18 2009
C_2 = Product_{prime p>2} (p-2)p/(p-1)^2 is an analog for primes of Wallis' product 2/Pi = Product_{n=1 to oo} (2n-1)(2n+1)/(2n)^2. - Jonathan Sondow, Nov 18 2009
One can compute a cubic variant, product_{primes >2} (1-1/(p-1)^3) = 0.855392... = (2/3) * 0.6601618...* 1.943596... by multiplying this constant with 2/3 and A082695. - R. J. Mathar, Apr 03 2011
Cohen (1998, p. 7) referred to this number as the "twin prime and Goldbach constant" and noted that, conjecturally, the number of twin prime pairs (p,p+2) with p <= X tends to 2*C_2*X/log(X)^2 as X tends to infinity. - Artur Jasinski, Feb 01 2021

Examples

			0.6601618158468695739278121100145557784326233602847334133194484233354056423...
		

References

  • Henri Cohen, Number Theory, Volume II: Analytic and Modern Tools, GTM Vol. 240, Springer, 2007; see pp. 208-209.
  • Richard Crandall and Carl Pomerance, Prime Numbers: A Computational Perspective, Springer, NY, 2001; see p. 11.
  • Steven R. Finch, Mathematical Constants, Encyclopedia of Mathematics and its Applications, Vol. 94, Cambridge University Press, 2003, pp. 84-93, 133.
  • R. K. Guy, Unsolved Problems in Number Theory, Section A8.
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 5th ed., Oxford Univ. Press, 1979, ch. 22.20.
  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See pp. 194, 263-264.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A065645 (continued fraction), A065646 (denominators of convergents to twin prime constant), A065647 (numerators of convergents to twin prime constant), A062270, A062271, A114907, A065418 (C_3), A167864, A000010, A008683.

Programs

  • Mathematica
    s[n_] := (1/n)*N[ Sum[ MoebiusMu[d]*2^(n/d), {d, Divisors[n]}], 160]; C2 = (175/256)*Product[ (Zeta[n]*(1 - 2^(-n))*(1 - 3^(-n))*(1 - 5^(-n))*(1 - 7^(-n)))^(-s[n]), {n, 2, 160}]; RealDigits[C2][[1]][[1 ;; 105]] (* Jean-François Alcover, Oct 15 2012, after PARI *)
    digits = 105; f[n_] := -2*(2^n-1)/(n+1); C2 = Exp[NSum[f[n]*(PrimeZetaP[n+1] - 1/2^(n+1)), {n, 1, Infinity}, NSumTerms -> 5 digits, WorkingPrecision -> 5 digits]]; RealDigits[C2, 10, digits][[1]] (* Jean-François Alcover, Apr 16 2016, updated Apr 24 2018 *)
  • PARI
    \p1000; 175/256*prod(k=2,500,(zeta(k)*(1-1/2^k)*(1-1/3^k)*(1-1/5^k)*(1-1/7^k))^(-sumdiv(k,d,moebius(d)*2^(k/d))/k))
    
  • PARI
    prodeulerrat(1-1/(p-1)^2, 1, 3) \\ Amiram Eldar, Mar 12 2021

Formula

Equals Product_{k>=2} (zeta(k)*(1-1/2^k))^(-Sum_{d|k} mu(d)*2^(k/d)/k). - Benoit Cloitre, Aug 06 2003
Equals 1/A167864. - Jonathan Sondow, Nov 18 2009
Equals Sum_{k>=1} mu(2*k-1)/phi(2*k-1)^2, where mu is the Möbius function (A008683) and phi is the Euler totient function (A000010) (Bruckman, 2001). - Amiram Eldar, Jan 14 2022

Extensions

More terms from Vladeta Jovovic, Nov 08 2001
Commented and edited by Daniel Forgues, Jul 28 2009, Aug 04 2009, Aug 12 2009
PARI code removed by D. S. McNeil, Dec 26 2010

A156660 Characteristic function of Sophie Germain primes.

Original entry on oeis.org

0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Reinhard Zumkeller, Feb 13 2009

Keywords

Crossrefs

Programs

  • Haskell
    a156660 n = fromEnum $ a010051 n == 1 && a010051 (2 * n + 1) == 1
    -- Reinhard Zumkeller, May 01 2012
    
  • PARI
    a(n)=isprime(n)&&isprime(2*n+1) \\ Felix Fröhlich, Aug 11 2014

Formula

a(n) = if n and also 2*n+1 is prime then 1 else 0.
a(A005384(n)) = 1; a(A138887(n)) = 0; a(A053176(n)) = 0.
A156874(n) = Sum_{k=1..n} a(k). - Reinhard Zumkeller, Feb 18 2009
a(n) = A010051(n)*A010051(2*n+1).
For n>1 a(n) = floor((floor(phi(n)/(n-1)) + floor(phi(2*n+1)/(2*n)))/2). - Enrique Pérez Herrero, Apr 28 2012
For n>1 a(n) = floor(phi(2*n^2+n)/(2*n^2-2*n)). - Enrique Pérez Herrero, May 02 2012

Extensions

Definition corrected by Daniel Forgues, Aug 04 2009

A092816 Number of Sophie Germain primes less than 10^n.

Original entry on oeis.org

3, 10, 37, 190, 1171, 7746, 56032, 423140, 3308859, 26569515, 218116524, 1822848478, 15462601989, 132822315652
Offset: 1

Views

Author

Eric W. Weisstein, Mar 06 2004

Keywords

Comments

Hardy-Littlewood conjecture: Number of Sophie Germain primes less than n ~ 2*C2*n/(log(n))^2, where C2 = 0.6601618158... is the twin prime constant (see A005597). The truth of the above conjecture would imply that there are an infinite number of Sophie Germain primes (which is also conjectured). - Robert G. Wilson v, Jan 31 2013

Examples

			The Sophie Germain primes up to 10 are 2 (since 5 is prime), 3 (since 7 is prime), and 5 (since 11 is prime), so a(1) = 3.
		

References

  • P. Ribenboim, The Little Book of Big Primes, Springer-Verlag, New York, 1991, p. 228.

Crossrefs

Formula

For 1 < n < 15, a(n) ~ e * (pi(2*10^n) - pi(10^n)) / (5*n - 5) where e is Napier's constant, see A001113 (we use n > 1 to avoid division by zero; whether the formula holds for any n > 14 is unknown). - Sergey Pavlov, Apr 07 2021 [This formula fails under the Hardy-Littlewood conjecture; the leading constant is wrong. - Charles R Greathouse IV, Aug 03 2023]
For any n, a(n) = qcc(x) - (10^n - pi(10^n) - pi(2 * 10^n + 1) + 1) where qcc(x) is the number of "common composite numbers" c <= 10^n such that both c and c' = 2*c + 1 are composite (trivial). - Sergey Pavlov, Apr 08 2021

Extensions

a(10) computed by Eric W. Weisstein, Nov 02 2005
a(11)-a(12) from Donovan Johnson, Jun 19 2010
a(13)-a(14) from Giovanni Resta, Sep 04 2017

A156875 Number of safe primes <= n.

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, Feb 18 2009

Keywords

Comments

a(n) = SUM(A156659(k): 1<=k<=n);
a(n) = A156874(floor((n-1)\2)).

Examples

			a(120) = #{5, 7, 11, 23, 47, 59, 83, 107} = 8.
		

Crossrefs

A156876 Number of primes <= n that are safe primes or Sophie Germain primes.

Original entry on oeis.org

0, 1, 2, 2, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12
Offset: 1

Views

Author

Reinhard Zumkeller, Feb 18 2009

Keywords

Examples

			a(120) = #{2,3,5,7,11,23,29,41,47,53,59,83,89,107,113} = 15.
		

Crossrefs

Programs

  • Mathematica
    Accumulate[Table[If[AllTrue[{n,2n+1},PrimeQ]||AllTrue[{n,(n-1)/2}, PrimeQ],1,0],{n,100}]] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Sep 24 2019 *)
  • PARI
    a(n) = my(nb=0); forprime(p=2, n, if (isprime(2*p+1) || isprime((p-1)/2), nb++)); nb; \\ Michel Marcus, Nov 06 2022

Formula

a(n) = A156874(n)+A156875(n)-A156877(n) = A000720(n)-A156878(n).

A156877 Number of primes <= n that are safe primes and also Sophie Germain primes.

Original entry on oeis.org

0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4
Offset: 1

Views

Author

Reinhard Zumkeller, Feb 18 2009

Keywords

Examples

			a(120) = #{5, 11, 23, 83} = 4.
		

Crossrefs

Formula

a(n) = A156874(n) + A156875(n) - A156876(n).
a(n) = Sum_{k=1..n} A156659(k)*A156660(k).

A305810 Filter sequence for a(Sophie Germain primes > 3) = constant sequences.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 5, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 5, 22, 23, 24, 25, 26, 5, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 5, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 5, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 5, 78, 79, 80, 81, 82, 5, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 5
Offset: 1

Views

Author

Antti Karttunen, Jun 16 2018

Keywords

Comments

Filer sequence for all such sequences S, for which S(A005384(k)) = constant for all k >= 3.
Restricted growth sequence transform of the ordered pair [A305900(n), A305901(1+n)].
For all i, j:
a(i) = a(j) => A305900(i) = A305900(j),
a(i) = a(j) => A305901(1+i) = A305901(1+j),
a(i) = a(j) => A305978(i) = A305978(j),
a(i) = a(j) => A305985(i) = A305985(j).

Crossrefs

Programs

  • PARI
    up_to = 100000;
    A156660(n) = (isprime(n)&&isprime(2*n+1)); \\ From A156660
    partialsums(f,up_to) = { my(v = vector(up_to), s=0); for(i=1,up_to,s += f(i); v[i] = s); (v); }
    v156874 = partialsums(A156660, up_to);
    A156874(n) = v156874[n];
    A305810(n) = if(n<5,n,if(A156660(n),5,3+n-A156874(n)));

Formula

If n < 5, a(n) = n; for n >= 5, a(n) = 5 if A156660(n) == 1 [when n is in A005384[3..] = 5, 11, 23, 29, 41, 53, 83, 89, 113, ...], otherwise a(n) = 3+n-A156874(n).

A182434 Number of primes p < n such that 4*p+1 is also prime.

Original entry on oeis.org

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

Views

Author

Enrique Pérez Herrero, Apr 28 2012

Keywords

Crossrefs

Programs

  • Mathematica
    Accumulate[Table[Boole[PrimeQ[n]&&PrimeQ[4n+1]],{n,1,200}]]
    Accumulate[If[AllTrue[{#,4#+1},PrimeQ],1,0]&/@Range[90]] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Feb 26 2015 *)

Formula

a(10^n) = A182265(n).
a(n) = sum(i=2..n, floor(phi(4*i^2+i)/(4*i^2-4*i))). - Enrique Pérez Herrero, May 02 2012.

A210684 Number of primes p < 10^n such that both 2*p+1 and 4*p+1 are composite.

Original entry on oeis.org

0, 7, 101, 864, 7365, 63331, 554839, 4931118, 44339730, 402709395, 3687732409, 34007530868
Offset: 1

Views

Author

Enrique Pérez Herrero, May 09 2012

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_] := Length[Select[Range[10^n], PrimeQ[#] && !PrimeQ[2#+1] && !PrimeQ[4#+1]&]]; Table[f[n], {n,7}]

Formula

a(n) = A006880(n) - A092816(n) - A182265(n) + 1.
a(n) ~ 10^n / (n log 10). - Charles R Greathouse IV, May 11 2012
Showing 1-10 of 11 results. Next