[go: up one dir, main page]

login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Search: a101909 -id:a101909
     Sort: relevance | references | number | modified | created      Format: long | short | data
A101909 sorted and duplicates removed.
+20
5
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 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
OFFSET
1,2
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
PROG
(PARI) bet2n4n(n) = { local(c, c1, x, y); a=vector(5001); for(x=1, n, c=0; forprime(y=2*x+1, 4*x-1, c++; ); a[x] = c; ); b=vecsort(a); for(x=1, 5000, if(b[x]>0, if(b[x]<>b[x+1], print1(b[x]", ") ) ); ) }
(PARI) s=0; v=vectorsmall(10^6, n, s+=isprime(4*n-1)+isprime(4*n-3)-isprime(2*n-1)); v=vecsort(v, , 8); vecextract(v, Str("1..", #v\2)) \\ Charles R Greathouse IV, Mar 12 2012
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Cino Hilliard, Jan 28 2005
STATUS
approved
Numbers that do not occur in A101909 (= number of primes between 2n and 4n).
+20
3
11, 79, 134, 184, 186, 215, 245, 262, 284, 305, 387, 544, 694, 700, 706, 776, 814, 881, 939, 974, 1002, 1027, 1079, 1104, 1133, 1146, 1184, 1193, 1207, 1354, 1387, 1415, 1441, 1495, 1574, 1587, 1608, 1662, 1690, 1801, 1915, 1987, 2054, 2067, 2104, 2170
OFFSET
1,1
EXAMPLE
11 is the first number that does not equal a count of primes between 2n and 4n for some n.
MATHEMATICA
f[n_] := PrimePi[4n] - PrimePi[2n]; t = Union[ Table[ f[n], {n, 12000}]]; Complement[ Range[ t[[ -1]]], t] (* Robert G. Wilson v, Feb 10 2005 *)
PROG
(PARI) bet2n4n(n)={ my( b=vecsort(vector(n, x, my(c=0); forprime(y=2*x+1, 4*x-1, c++); c))); for(x=1, n-2, while(b[x+1]-b[x]>1, print1(b[x]++, ", ")))} \\ It's probably faster to use A101909 instead of forprime(...). Edited and corrected by M. F. Hasler, Sep 29 2019
(PARI) primecount(a, b)=primepi(b)-primepi(a);
v=vector(20000);
for(k=1, oo, j=primecount(2*k, 4*k); if(j>#v, break, v[j]++));
for(k=1, 2170, if(v[k]==0, print1(k, ", "))) \\ Hugo Pfoertner, Sep 29 2019
CROSSREFS
Complement of A101947.
Cf. A101909.
KEYWORD
easy,nonn
AUTHOR
Cino Hilliard, Jan 28 2005
EXTENSIONS
More terms from Robert G. Wilson v, Feb 10 2005
Name edited by M. F. Hasler, Sep 29 2019
STATUS
approved
Numbers that occur exactly once in A101909 (= count of primes between 2n and 4n).
+20
2
1, 3, 5, 8, 22, 36, 37, 46, 47, 48, 53, 63, 83, 98, 99, 101, 105, 108, 113, 114, 127, 135, 139, 148, 150, 155, 158, 171, 172, 173, 174, 175, 177, 178, 188, 205, 210, 218, 219, 220, 221, 226, 231, 240, 246, 254, 277, 282, 297, 298, 301, 303, 327, 333, 334, 339
OFFSET
1,2
EXAMPLE
There are 5 primes between 16 and 32 and nowhere else between 2n and 4n.
PROG
(PARI) bet2n4n(n)={ my(b=vecsort(vector(n, x, my(c=0); forprime(y=2*x+1, 4*x-1, c++); c))); print1(1", "); for(x=1, n-2, if(b[x+1]>b[x] && b[x+1]<b[x+2], print1(b[x+1]", ")))} \\ Edited and corrected, following a suggestion by Don Reble. - M. F. Hasler, Sep 29 2019
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Cino Hilliard, Jan 28 2005
EXTENSIONS
Better name from N. J. A. Sloane, Sep 29 2019
Corrected a(22) and a(45), following an observation by Don Reble. - M. F. Hasler, Sep 29 2019
STATUS
approved
Number of primes between n and 2n exclusive.
+10
58
0, 1, 1, 2, 1, 2, 2, 2, 3, 4, 3, 4, 3, 3, 4, 5, 4, 4, 4, 4, 5, 6, 5, 6, 6, 6, 7, 7, 6, 7, 7, 7, 7, 8, 8, 9, 9, 9, 9, 10, 9, 10, 9, 9, 10, 10, 9, 9, 10, 10, 11, 12, 11, 12, 13, 13, 14, 14, 13, 13, 12, 12, 12, 13, 13, 14, 13, 13, 14, 15, 14, 14, 13, 13, 14, 15, 15
OFFSET
1,4
COMMENTS
See the additional references and links mentioned in A143227. - Jonathan Sondow, Aug 03 2008
a(A060756(n)) = n and a(m) <> n for m < A060756(n). - Reinhard Zumkeller, Jan 08 2012
For prime n conjecturally a(n) = A226859(n). - Vladimir Shevelev, Jun 27 2013
The number of partitions of 2n+2 into exactly two parts where the first part is a prime strictly less than 2n+1. - Wesley Ivan Hurt, Aug 21 2013
REFERENCES
M. Aigner and C. M. Ziegler, Proofs from The Book, Chapter 2, Springer NY 2001.
LINKS
N. J. A. Sloane, Table of n, a(n) for n = 1..20000 [First 1000 terms from T. D. Noe]
C. K. Caldwell, The Prime Glossary, Bertrand's postulate
R. Chapman, Bertrand postulate [Broken link]
Math Olympiads, Bertrand's Postulate [Broken link]
S. Ramanujan, A proof of Bertrand's postulate, J. Indian Math. Soc., 11 (1919), 181-182.
Vladimir Shevelev, Ramanujan and Labos Primes, Their Generalizations, and Classifications of Primes, Journal of Integer Sequences, Vol. 15 (2012), Article 12.5.4
M. Slone, PlanetMath.org, Proof of Bertrand's conjecture
Jonathan Sondow and Eric Weisstein, Bertrand's Postulate, World of Mathematics
Dr. Wilkinson, The Math Forum, Erdos' Proof
Wolfram Research, Bertrand hypothesis
FORMULA
a(n) = Sum_{k=1..n-1} A010051(n+k). - Reinhard Zumkeller, Dec 03 2009
a(n) = pi(2n-1) - pi(n). - Wesley Ivan Hurt, Aug 21 2013
a(n) = Sum_{k=(n^2-n+2)/2..(n^2+n-2)/2} A010051(A128076(k)). - Wesley Ivan Hurt, Jan 08 2022
EXAMPLE
a(35)=8 since eight consecutive primes (37,41,43,47,53,59,61,67) are located between 35 and 70.
MAPLE
a := proc(n) local counter, i; counter := 0; from i from n+1 to 2*n-1 do if isprime(i) then counter := counter +1; fi; od; return counter; end:
with(numtheory); seq(pi(2*k-1)-pi(k), k=1..100); # Wesley Ivan Hurt, Aug 21 2013
MATHEMATICA
a[n_]:=PrimePi[2n-1]-PrimePi[n]; Table[a[n], {n, 1, 84}] (* Jean-François Alcover, Mar 20 2011 *)
PROG
(PARI) { for (n=1, 1000, write("b060715.txt", n, " ", primepi(2*n - 1) - primepi(n)); ) } \\ Harry J. Smith, Jul 10 2009
(Haskell)
a060715 n = sum $ map a010051 [n+1..2*n-1] -- Reinhard Zumkeller, Jan 08 2012
(Magma) [0] cat [#PrimesInInterval(n+1, 2*n-1): n in [2..80]]; // Bruno Berselli, Sep 05 2012
(Python) from sympy import primerange as pr
def A060715(n): return len(list(pr(n+1, 2*n))) # Karl-Heinz Hofmann, May 05 2022
CROSSREFS
Related sequences:
Primes (p) and composites (c): A000040, A002808, A000720, A065855.
Primes between p(n) and 2*p(n): A063124, A070046; between c(n) and 2*c(n): A376761; between n and 2*n: A035250, A060715, A077463, A108954.
Composites between p(n) and 2*p(n): A246514; between c(n) and 2*c(n): A376760; between n and 2*n: A075084, A307912, A307989, A376759.
KEYWORD
nonn,easy
AUTHOR
Lekraj Beedassy, Apr 25 2001
EXTENSIONS
Corrected by Dug Eichelberger (dug(AT)mit.edu), Jun 04 2001
More terms from Larry Reeves (larryr(AT)acm.org), Jun 05 2001
STATUS
approved

Search completed in 0.008 seconds