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-20 of 78 results. Next

A111870 Prime p with prime gap q - p of n-th record merit, where q is smallest prime larger than p and the merit of a prime gap is (q-p)/log(p).

Original entry on oeis.org

2, 3, 7, 113, 1129, 1327, 19609, 31397, 155921, 360653, 370261, 1357201, 2010733, 17051707, 20831323, 191912783, 436273009, 2300942549, 3842610773, 4302407359, 10726904659, 25056082087, 304599508537, 461690510011, 1346294310749, 1408695493609, 1968188556461, 2614941710599, 13829048559701, 19581334192423, 218209405436543, 1693182318746371
Offset: 1

Views

Author

N. J. A. Sloane, based on correspondence with Ed Pegg Jr, Nov 23 2005

Keywords

Comments

As I understand it, the sequence refers to "Smallest prime p whose following gap has bigger merit than the other primes smaller than p." If that is the case, then it has an error. The sequence starts: 2, 3, 7, 113, 1129, 1327, 19609, 31397, 155921, 360653, 370261, 1357201, 4652353, 2010733, ... but you can see that 4652353 > 2010733, so in any case it should be listed after, not before it. But above that, its merit is 10.03 < 10.20, the merit of 2010733, so it is not in a mistaken position: it shouldn't appear in the sequence. - Jose Brox, Dec 31 2005
The logarithmic (base 10) graph seems to be linearly asymptotic to n with slope ~ 1/log(10) which would imply that: log(prime with n-th record merit) ~ n as n goes to infinity. - N. J. A. Sloane, Aug 27 2010
The sequence b(n) = (prime(n+1)/prime(n))^n is increasing for terms prime(n) of this sequence. - Thomas Ordowski, May 04 2012
The smallest prime(n) such that (prime(n+1)/prime(n))^n is increasing: 2, 3, 7, 23, 113, 1129, 1327, ... (A205827). - Thomas Ordowski, May 04 2012
(prime(n+1)/prime(n))^n > 1 + merit(n) for n > 2, where merit(n) = (prime(n+1)-prime(n))/log(prime(n)). - Thomas Ordowski, May 14 2012
Merit(1) + merit(2) + ... + merit(n) =: S(n) ~ n, where merit(n) is as above. - Thomas Ordowski, Aug 03 2012
For the index of a(n), see the comment at A214935. - John W. Nicholson, Nov 21 2013

Examples

			The first few entries correspond to the following gaps. The table gives n, p, gap = q-p and the merit of the gap.
   1,       2,   1, 1.4427
   2,       3,   2, 1.82048
   3,       7,   4, 2.05559
   4,     113,  14, 2.96147
   5,    1129,  22, 3.12985
   6,    1327,  34, 4.72835
   7,   19609,  52, 5.26116
   8,   31397,  72, 6.95352
   9,  155921,  86, 7.19238
  10,  360653,  96, 7.50254
  11,  370261, 112, 8.73501
  12, 1357201, 132, 9.34782
		

References

  • Ed Pegg, Jr., Posting to Seq Fan mailing list, Nov 23 2005

Crossrefs

For the gaps, see A111871.

Programs

  • Mathematica
    With[{s = Map[(#2 - #1)/Log[#1] & @@ # &, Partition[Prime@ Range[10^6], 2, 1]]}, Map[Prime@ FirstPosition[s, #][[1]] &, Union@ FoldList[Max, s]]] (* Michael De Vlieger, Jul 19 2018 *)

Formula

a(n) = A277552(n) - A111871(n). - Bobby Jacobs, Nov 13 2016

Extensions

Corrected by Jose Brox, Dec 31 2005
Corrected and edited by Daniel Forgues, Oct 23 2009
Further edited by Daniel Forgues, Nov 01 2009, Nov 13 2009, Nov 24 2009

A337372 Primitively primeshift-abundant numbers: Numbers that are included in A246282 (k with A003961(k) > 2k), but none of whose proper divisors are.

Original entry on oeis.org

4, 6, 9, 10, 14, 15, 21, 35, 39, 49, 57, 69, 91, 125, 242, 275, 286, 325, 338, 363, 418, 425, 442, 475, 494, 506, 561, 575, 598, 646, 682, 715, 722, 725, 754, 775, 782, 806, 845, 847, 867, 874, 925, 957, 962, 1023, 1025, 1045, 1054, 1058, 1066, 1075, 1105, 1118, 1175, 1178, 1221, 1222, 1235, 1265, 1309, 1325, 1334, 1353
Offset: 1

Views

Author

Antti Karttunen, Aug 27 2020

Keywords

Comments

Numbers k whose only divisor in A246282 is k itself, i.e., A003961(k) > 2k, but for none of the proper divisors d|k, dA003961(d) > 2d.
Question: Do the odd terms in A326134 all occur here? Answer is yes, if the following conjecture holds: This is a subsequence of A263837, nonabundant numbers. In other words, we claim that any abundant number k (A005101) has A337345(k) > 1 and thus is a term of A341610. (The conjecture indeed holds. See the proof below).
From Antti Karttunen, Dec 06 2024: (Start)
Observation 1: The thirteen initial terms (4, 6, 9, ..., 69, 91) are only semiprimes in A246282, all other semiprimes being in A246281 (but none in A341610), and there seems to be only 678 terms m with A001222(m) = 3, from a(14) = 125 to the last one of them, a(2691) = 519963. There are more than 150000 terms m with A001222(m) = 4. In general, there should be only a finite number of terms m for any given k = A001222(m). Compare for example with A287728.
Observation 2: The intersection with A005101 (and thus also with A091191) is empty, which then implies the claims made in the sequences A378662, A378664, from which further follows that there are no 1's present in any of these sequences: A378658, A378736, A378740.
(End)
Proof of the latter observation by Jianing Song, Dec 11 2024: (Start)
Let's write p' for the next prime after the prime p. Also, write Q(n) = A003961(n)/sigma(n) which is multiplicative.
Proposition: For n > 1 not being a prime nor twice a prime, n has a factor p such that Q(n) > p'/p.
This implies that if n is abundant [including any primitively abundant n in A091191], then n has a factor p such that A003961(n/p)/(n/p) = (A003961(n)/n)/(p'/p) > sigma(n)/n [which is > 2 because n is abundant], so n/p is in A246282, meaning that n cannot be in this sequence.
Proof. We see that 1 <= Q(p) <= Q(p^2) <= ..., which implies that if n verifies the proposition, then every multiple of n also verifies it. Since n = p^2 > 4 and n = 8 verify the proposition, it suffices to consider the case where n = pq is the product of two distinct odd primes. Suppose WLOG that p < q, so q >= p', then using q/(q+1) >= p'/(p'+1) we have
Q(n) = p'q'/((p+1)(q+1)) >= p'^2*q'/(q(p+1)(p'+1)) > (p'^2-1)*q'/(q(p+1)(p'+1)) = (p'-1)/(p+1) * q'/q >= q'/q.
(End)

Examples

			14 = 2*7 is in the sequence as setting every prime to the next larger prime gives 3*11 = 33 > 28 = 2*14. Doing so for any proper divisor d of 14 gives a number < 2 * d. - _David A. Corneth_, Dec 07 2024
		

Crossrefs

Setwise difference A246282 \ A341610.
Positions of ones in A337345 and in A341609 (characteristic function).
Subsequence of A263837 and thus also of A341614.
Cf. also A005101, A091191, A326134.
Cf. also A337543.

Programs

  • Mathematica
    Block[{a = {}, b = {}}, Do[If[2 i < Times @@ Map[#1^#2 & @@ # &, FactorInteger[i] /. {p_, e_} /; e > 0 :> {Prime[PrimePi@ p + 1], e}] - Boole[i == 1], AppendTo[a, i]; If[IntersectingQ[Most@ Divisors[i], a], AppendTo[b, i]]], {i, 1400}]; Complement[a, b]] (* Michael De Vlieger, Feb 22 2021 *)
  • PARI
    A003961(n) = { my(f = factor(n)); for (i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); factorback(f); };
    A252742(n) = (A003961(n) > (2*n));
    A337346(n) = sumdiv(n,d,(dA252742(d));
    isA337372(n) = ((1==A252742(n))&&(0==A337346(n)));
    
  • PARI
    is_A337372 = A341609;
    
  • PARI
    \\ See Corneth link

Formula

{k: 1==A337345(k)}.

A014320 The next new gap between successive primes.

Original entry on oeis.org

1, 2, 4, 6, 8, 14, 10, 12, 18, 20, 22, 34, 24, 16, 26, 28, 30, 32, 36, 44, 42, 40, 52, 48, 38, 72, 50, 62, 54, 60, 58, 46, 56, 64, 68, 86, 66, 70, 78, 76, 82, 96, 112, 100, 74, 90, 84, 114, 80, 88, 98, 92, 106, 94, 118, 132, 104, 102, 110, 126, 120, 148, 108, 122, 138
Offset: 1

Views

Author

Hynek Mlcousek (hynek(AT)dior.ics.muni.cz)

Keywords

Comments

Prime differences A001223 in natural order with duplicates removed. - Reinhard Zumkeller, Apr 03 2015
Conjecture: a(n) = O(n). See arXiv:2002.02115 for discussion. - Alexei Kourbatov, Jun 04 2020

Examples

			The first two primes are 2 and 3, and the first prime gap is 3 - 2 = 1; so a(1) = 1. The next prime is 5, and the next gap is 5 - 3 = 2; this gap size has not occurred before, so a(2) = 2. The next prime is 7, and the next gap is 7 - 5 = 2; the gap size 2 has already occurred before, so nothing is added to the sequence.
		

Crossrefs

Programs

  • Haskell
    import Data.List (nub)
    a014320 n = a014320_list !! (n-1)
    a014320_list = nub $ a001223_list
    -- Reinhard Zumkeller, Apr 03 2015
    
  • Mathematica
    max = 300000; allGaps = Transpose[ {gaps = Differences[ Prime[ Range[max]]], Range[ Length[gaps]]}]; equalGaps = Split[ Sort[ allGaps, #1[[1]] < #2[[1]] & ], #1[[1]] == #2[[1]] & ]; firstGaps = ((Sort[#1, #1[[1]] < #2[[1]] & ] & ) /@ equalGaps)[[All, 1]]; Sort[ firstGaps, #1[[2]] < #2[[2]] & ][[All, 1]] (* Jean-François Alcover, Oct 21 2011 *)
    DeleteDuplicates[Differences[Prime[Range[10000]]]] (* Alonso del Arte, Jun 05 2020 *)
  • PARI
    my(isFirstOcc=vector(9999, j, 1), s=2); forprime(p=3, 1e8, my(g=p-s); if(isFirstOcc[g], print1(g, ", "); isFirstOcc[g]=0); s=p) \\ Alexei Kourbatov, Jun 03 2020
    
  • Scala
    val prime: LazyList[Int] = 2 #:: LazyList.from(3).filter(i => prime.takeWhile {
       j => j * j <= i
    }.forall {
       k => i % k != 0
    })
    val primes = prime.take(1000).toList
    primes.zip(primes.tail).map(p => p.2 - p._1).distinct // _Alonso del Arte, Jun 04 2020

Formula

a(n) = A335367(n) - A335366(n). - Alexei Kourbatov, Jun 04 2020
a(n) = 2*A014321(n-1) for n >= 2. - Robert Israel, May 27 2024

Extensions

More terms from Sascha Kurz, Mar 24 2002

A001632 Smallest prime p such that there is a gap of 2n between p and previous prime.

Original entry on oeis.org

5, 11, 29, 97, 149, 211, 127, 1847, 541, 907, 1151, 1693, 2503, 2999, 4327, 5623, 1361, 9587, 30631, 19373, 16183, 15727, 81509, 28277, 31957, 19661, 35671, 82129, 44351, 43391, 34123, 89753, 162209, 134581, 173429, 31469, 404671, 212777
Offset: 1

Views

Author

Keywords

Comments

Smallest prime preceded by 2n-1 successive composites. - Lekraj Beedassy, Apr 23 2010

Examples

			The first time a gap of 4 occurs between primes is between 7 and 11, so A000230(2)=7 and A001632(2)=11.
		

References

  • J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 97, p. 34, Ellipses, Paris 2008.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Mathematica
    With[{pr=Partition[Prime[Range[35000]],2,1]},Transpose[ Flatten[ Table[ Select[pr,#[[2]]-#[[1]]==2n&,1],{n,40}],1]][[2]]] (* Harvey P. Dale, Apr 20 2012 *)
  • PARI
    LIMIT=10^9; a=[]; i=2; o=2; g=0; forprime(p=3,LIMIT, bittest(g,-o+o=p) && next; a=concat(a,[[p,p-precprime(p-1)]]); g+=1<=i && a[i][2]<2*i, print1(a[i][1]",");i++)) \\ a[1] = [3, 1] is not printed, cf. A000230(0). Limit 10^7 yields a(1),...,a(70) in 0.3 sec @ 2.5 GHz. \\ M. F. Hasler, Jan 13 2011, updated Jan 26 2015.

Formula

a(n) = 2n + A000230(n) = nextprime(A000230(n)).
a(n) = A000040(A038664(n)+1). - M. F. Hasler, Jan 26 2015

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Nov 28 2000 and from Labos Elemer, Nov 29 2000
Terms a(1)-a(146) checked with the PARI program by M. F. Hasler, Jan 13 2011, Jan 26 2015

A168421 Small Associated Ramanujan Prime, p_(i-n).

Original entry on oeis.org

2, 7, 11, 17, 23, 29, 31, 37, 37, 53, 53, 59, 67, 79, 79, 89, 97, 97, 127, 127, 127, 127, 127, 137, 137, 149, 157, 157, 179, 179, 191, 191, 211, 211, 211, 223, 223, 223, 233, 251, 251, 257, 293, 293, 307, 307, 307, 307, 307, 331, 331, 331
Offset: 1

Views

Author

John W. Nicholson, Nov 25 2009

Keywords

Comments

a(n) is the smallest prime p_(k+1-n) on the left side of the Ramanujan Prime Corollary, 2*p_(i-n) > p_i for i > k, where the n-th Ramanujan Prime R_n is the k-th prime p_k. [Comment clarified and shortened by Jonathan Sondow, Dec 20 2013]
Smallest prime number, a(n), such that if x >= a(n), then there are at least n primes between x and 2x exclusively.
This is very useful in showing the number of primes in the range [p_k, 2*p_(i-n)] is greater than or equal to 1. By taking into account the size of the gaps between primes in [p_(i-n),p_k], one can see that the average prime gap is about log(p_k) using the following R_n / (2*n) ~ log(R_n).
Proof of Corollary: See Wikipedia link
The number of primes until the next Ramanujan prime, R_(n+1), can be found in A190874.
Not the same as A124136.
A084140(n) is the smallest integer where ceiling ((A104272(n)+1)/2), a(n) is the next prime after A084140(n). - John W. Nicholson, Oct 09 2013
If a(n) is in A005382(k) then A005383(k) is a twin prime with the Ramanujan prime, A104272(n) = A005383(k) - 2, and A005383(k) = A168425(n). If this sequence has an infinite number of terms in A005382, then the twin prime conjecture can be proved. - John W. Nicholson, Dec 05 2013
Except for A000101(1)=3 and A000101(2)=5, A000101(k) = a(n). Because of the large size of a gap, there are many repeats of the prime number in this sequence. - John W. Nicholson, Dec 10 2013
For some n and k, we see that a(n) = A104272(k) as to form a chain of primes similar to a Cunningham chain. For example (and the first example), a(2) = 7, links A104272(2) = 11 = a(3), links A104272(3) = 17 = a(4), links A104272(4) = 29 = a(6), links A104272(6) = 47. Note that the links do not have to be of a form like q = 2*p+1 or q = 2*p-1. - John W. Nicholson, Dec 14 2013
Srinivasan's Lemma (2014): p_(k-n) < (p_k)/2 if R_n = p_k and n > 1. Proof: By the minimality of R_n, the interval ((p_k)/2,p_k] contains exactly n primes, so p_(k-n) < (p_k)/2. - Jonathan Sondow, May 10 2014
In spite of the name Small Associated Ramanujan Prime, a(n) is not a Ramanujan prime for many values of n. - Jonathan Sondow, May 10 2014
Prime index of a(n), pi(a(n)) = i-n, is equal to A179196(n) - n + 1. - John W. Nicholson, Sep 15 2015
All maximal prime pairs in A002386 and A000101 are bounded by, for a particular n and i, the prime A104272(n) and twice a prime in A000040() following a(n). This means the gap between maximal prime pair cannot be more than twice the prior maximal prime gap. - John W. Nicholson, Feb 07 2019

Examples

			For n=10, the n-th Ramanujan prime is A104272(n)= 97, the value of k = 25, so i is >= 26, i-n >= 16, the i-n prime is 53, and 2*53 = 106. This leaves the range [97, 106] for the 26th prime which is 101. In this example, 53 is the small associated Ramanujan prime.
		

Crossrefs

Cf. A165959 (range size), A230147 (records).

Programs

Formula

a(n) = prime(primepi(A104272(n)) + 1 - n).
a(n) = nextprime(A084139(n+1)), where nextprime(x) is the next prime > x. Note: some A084139(n) may be prime, therefore nextprime(x) not equal to x. - John W. Nicholson, Oct 11 2013
a(n) = nextprime(A084140(n)). - John W. Nicholson, Oct 11 2013

Extensions

Extended by T. D. Noe, Nov 22 2010

A138198 First occurrence of prime gaps which are squares.

Original entry on oeis.org

2, 7, 1831, 9551, 89689, 396733, 11981443, 70396393, 1872851947, 10958687879, 47203303159, 767644374817, 8817792098461, 78610833115261, 497687231721157, 2069461000669981, 22790428875364879, 78944802602538877, 1799235198379903447, 30789586795090405813
Offset: 0

Views

Author

Zak Seidov, Mar 05 2008

Keywords

Comments

More precisely, consider the possible squares which can occur as prime gaps: g_0=1, g_1=2^2, g_2=4^2, g_3=6^2, g_4=8^2, ... Then a(n) = smallest prime p(i) such that p(i+1)-p(i) = g_n, or a(n) = -1 if the gap g_n never occurs. - N. J. A. Sloane, Oct 28 2016

Examples

			Notes by Thomas R. Nicely:
No gap exceeding 1442 has been definitively established as a first occurrence; larger gaps included in these lists are instead first occurrences presently known of prime gaps. The smallest gap whose first occurrence remains uncertain is the (nonsquare) gap of 1208.
prime,gap
2, 1=1^2
7, 4=2^2
1831, 16=4^2
9551, 36=6^2
89689, 64=8^2
396733, 100=10^2
11981443, 144=12^2
70396393, 196=14^2
1872851947, 256=16^2
10958687879, 324=18^2
47203303159, 400=20^2
767644374817, 484=22^2
8817792098461, 576=24^2
78610833115261, 676=26^2
497687231721157, 784=28^2
2069461000669981, 900=30^2
22790428875364879, 1024=32^2
78944802602538877, 1156=34^2
2980374211158121907, 1296=36^2
18479982848279580912452968237, 1444=38^2
10338270318362067887873513954823823, 1600=40^2
5462539353768233509094313080601639583, 1764=42^2
9634432076725832064810529394509018411, 1936=44^2
24103660699017475735076387748469761375352177, 2116=46^2
1171872038536282864481405693168029955108099, (*48^2*)
169512938487733553802932479078305855585466971701227, (*50^2*)
228422210024736896126707605155690522381875250546666532046327, (*52^2*)
7229972437439469171089374324333535009566526827968927563, (*54^2*)
1263895714932859021916447978075625934206362807439043695674222113, (*56^2*)
569493611436727594340298806603382857255173440636060754222617328828425379, (*58^2*)
281376087412013738611508677824321032930454474305215907812114263492815921, (*60^2*)
680561565394793619717614472954048053005171290126070180152868857556290989645629867 (*62^2*)
		

Programs

  • Mathematica
    Function[w, Prime@ First@ # & /@ Map[w[[ Key@ # ]] &, Select[Keys@ w, IntegerQ@ Sqrt@ # &]]]@ PositionIndex@ Differences@ Prime@ Range[10^7] (* Michael De Vlieger, Oct 27 2016 *)
  • PARI
    a(n)=my(k=max(1,4*(n-1)^2),p=2);forprime(q=3,,if(q-p==k,return(p));p=q) \\ Charles R Greathouse IV, Jun 05 2013

Formula

a(n) = A000230(2*n^2). - R. J. Mathar, Feb 13 2025

Extensions

Edited by N. J. A. Sloane, Oct 28 2016
Misprints in EXAMPLE fixed by Zak Seidov, Oct 18 2018
a(18)-a(19) from Brian Kehrig, May 02 2025

A205827 Primes prime(k) corresponding to the records in the sequence (prime(k+1)/prime(k))^k.

Original entry on oeis.org

2, 3, 7, 23, 113, 1129, 1327, 19609, 31397, 155921, 360653, 370261, 1357201, 2010733, 17051707, 20831323, 191912783, 436273009, 2300942549, 3842610773, 4302407359, 10726904659, 25056082087, 304599508537, 461690510011, 1346294310749, 1408695493609
Offset: 1

Views

Author

Thomas Ordowski, May 07 2012

Keywords

Comments

Probably A111870 is this sequence with the exception of the term a(4) = 23. - Farideh Firoozbakht, May 07 2012
For n from 5 to 28, a(n) = A111870(n-1). - Donovan Johnson, Oct 26 2012
The statement prime(k) > (prime(k+1)/prime(k))^k for k>=1 is a rewrite of the Firoozbakht conjecture (see link). - John W. Nicholson, Oct 27 2012
Values of k are in A214935.
The logarithmic (base 10) graph seems to be linearly asymptotic to n with slope ~ 1/log(10) which would imply that: log(prime(k)) ~ n as n goes to infinity. [Copy of comment by N. J. A. Sloane, Aug 27 2010 for A111870, copied and corrected for prime(k) by John W. Nicholson, Oct 29 2012]
(prime(k+1)/prime(k))^k ~ e^merit(k), where merit(k) = (prime(k+1)-prime(k))/log(prime(k)). - Thomas Ordowski, Mar 18 2013
Subset of A002386. - John W. Nicholson, Nov 19 2013
Copied comment from A111870 (modified variable to k): (prime(k+1)/prime(k))^k > 1 + merit(k) for k > 2, where merit(k) = (prime(k+1)-prime(k))/log(prime(k)). - Thomas Ordowski, May 14 2012 : Copied and modified by John W. Nicholson, Nov 20 2013

Examples

			The sequence (prime(k+1)/prime(k))^k for k=1,2,... starts with:
*1.500, *2.777, 2.744, *6.098, 2.305, 5.001, 2.178, 4.611, *8.054, 1.948, ...,
where records are marked with *. The corresponding primes are a(1)=prime(1)=2, a(2)=prime(2)=3, a(3)=prime(4)=7, a(4)=prime(9)=23, ...
		

Crossrefs

Programs

  • Mathematica
    t = {}; p = 2; best = 0; n = 0; While[n++; last = p; p = NextPrime[p]; p <= 100000, f = (p/last)^n; If[f > best, best = f; AppendTo[t, last]]]; t (* T. D. Noe, May 08 2012 *)
  • PARI
    record=0;for(n=1,75,current=(A000101[n]/A002386[n]*1.)^A005669[n];if(current>record,record=current;print1(A002386[n],", "))) \\ Each sequence is read in as a vector as to overcome PARI's primelimit. John W. Nicholson, Dec 01 2013

Formula

a(n) = A000040(A214935(n)).

Extensions

a(13)-a(25) from Donovan Johnson, May 08 2012
Definition corrected by Max Alekseyev, Oct 23 2012
Clarified definition with k as index of a(n)=prime(k) instead of index n, John W. Nicholson, Oct 24 2012
a(26)-a(28) from Donovan Johnson, Oct 26 2012
a(29)-a(38) from John W. Nicholson, Dec 01 2013

A008996 Increasing length runs of consecutive composite numbers (records).

Original entry on oeis.org

1, 3, 5, 7, 13, 17, 19, 21, 33, 35, 43, 51, 71, 85, 95, 111, 113, 117, 131, 147, 153, 179, 209, 219, 221, 233, 247, 249, 281, 287, 291, 319, 335, 353, 381, 383, 393, 455, 463, 467, 473, 485, 489, 499, 513, 515, 531, 533, 539, 581, 587, 601, 651, 673, 715, 765
Offset: 1

Views

Author

Mark Cramer (m.cramer(AT)qut.edu.au), Mar 15 1996

Keywords

Comments

Conjecture: a(n) = O(n^2); specifically, a(n) <= n^2. - Alexei Kourbatov, Jan 23 2019

Crossrefs

Programs

  • Haskell
    a008996 n = a008996_list !! (n-1)
    a008996_list = 1 : f 0 (filter (> 1) $
                            map length $ group $ drop 3 a010051_list)
       where f m (u : us) = if u <= m then f m us else u : f u us
    -- Reinhard Zumkeller, Nov 27 2012
  • Mathematica
    maxGap = 1; Reap[ Do[ gap = Prime[n+1] - Prime[n]; If[gap > maxGap, Print[gap-1]; Sow[gap-1]; maxGap = gap], {n, 2, 10^8}]][[2, 1]] (* Jean-François Alcover, Jun 12 2013 *)
    Module[{nn=10^8,cmps},cmps=Table[If[CompositeQ[n],1,{}],{n,nn}];DeleteDuplicates[ Rest[ Length/@ Split[cmps]],GreaterEqual]] (* The program generates the first 24 terms of the sequnece. To generate more, increase the nn constant. *) (* Harvey P. Dale, Sep 04 2022 *)

Formula

a(n) = A005250(n+1) - 1.

Extensions

More terms from Warren D. Smith, Dec 11 2000
a(40) corrected by Bert Sierra, Jul 12 2025

A045881 Smallest of first string of exactly 2n-1 consecutive composite integers.

Original entry on oeis.org

4, 8, 24, 90, 140, 200, 114, 1832, 524, 888, 1130, 1670, 2478, 2972, 4298, 5592, 1328, 9552, 30594, 19334, 16142, 15684, 81464, 28230, 31908, 19610, 35618, 82074, 44294, 43332, 34062, 89690, 162144, 134514, 173360, 31398, 404598, 212702, 188030, 542604
Offset: 1

Views

Author

Keywords

Crossrefs

Equals A000230(n) + 1.

Programs

  • Mathematica
    Reap[For[k=2, k <= 80, k = k+2, p=3; q=5; While[q-p != k, p=q; q=NextPrime[p+1]]; Print[p+1]; Sow[p+1]]][[2, 1]] (* Jean-François Alcover, May 17 2013, after Klaus Brockhaus *)
    With[{cmps=Table[If[CompositeQ[n],1,0],{n,10^6}]},Flatten[Table[ SequencePosition[ cmps,Join[{0},PadRight[{},i,1],{0}],1],{i,1,81,2}],1][[All,1]]+1] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, May 02 2017 *)
  • PARI
    forstep(k=2,80,2,p=3;q=5;while(q-p!=k,p=q;q=nextprime(p+1));print1(p+1,",")) \\ Klaus Brockhaus, Jan 24 2008

Extensions

More terms from Harvey P. Dale, Jul 27 2001

A058320 Distinct even prime-gap lengths (number of composites between primes), from 3+2, 7+4, 23+6,...

Original entry on oeis.org

2, 4, 6, 8, 14, 10, 12, 18, 20, 22, 34, 24, 16, 26, 28, 30, 32, 36, 44, 42, 40, 52, 48, 38, 72, 50, 62, 54, 60, 58, 46, 56, 64, 68, 86, 66, 70, 78, 76, 82, 96, 112, 100, 74, 90, 84, 114, 80, 88, 98, 92, 106, 94, 118, 132, 104, 102, 110, 126, 120, 148, 108
Offset: 0

Views

Author

Warren D. Smith, Dec 11 2000

Keywords

Comments

Nicely and Nyman have sieved up to 1.3565*10^16 at least. They admit it is likely they have suffered from hardware or software bugs, but believe the probability the sequence up to this point is incorrect is <1 in a million. This sequence is presumably all even integers (in different order). It is not monotonic. The monotonic subsequence of record-breaking prime gaps is A005250.
Essentially the same as A014320. [From R. J. Mathar, Oct 13 2008]

Crossrefs

Equals 2*A014321(n-1).

Programs

  • Mathematica
    DeleteDuplicates[Differences[Prime[Range[2,200000]]]] (* Harvey P. Dale, Dec 07 2014 *)

Extensions

Comment corrected by Harvey P. Dale, Dec 07 2014
Previous Showing 11-20 of 78 results. Next