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 12 results. Next

A278574 Records in A179210.

Original entry on oeis.org

5, 31, 8123, 45439, 156157, 480209, 2181737, 6012899, 13626257, 60487759, 217795247, 240485257, 995151679, 4002927023, 7186211917, 10514388763, 18553663237, 34434090797, 196122821897
Offset: 1

Views

Author

Keywords

Crossrefs

Cf. A179210.

Extensions

a(17)-a(19) from Robert G. Wilson v, Dec 09 2016

A179234 a(n) is the smallest prime q such that, for the previous prime p and the following prime r, the fraction (r-q)/(q-p) has denominator n in lowest terms.

Original entry on oeis.org

3, 11, 29, 367, 149, 521, 127, 1847, 1087, 1657, 1151, 4201, 2503, 2999, 5779, 10831, 1361, 9587, 30631, 19373, 16183, 36433, 81509, 28277, 31957, 25523, 40343, 82129, 44351, 102761, 34123, 89753, 282559, 134581, 173429, 705389, 404671, 212777, 371027, 1060861, 265703, 461801, 156007, 544367, 576881, 927961, 1101071, 1904407, 604171, 396833
Offset: 1

Views

Author

Vladimir Shevelev, Jan 05 2011

Keywords

Comments

The conjecture that a(n) exists for every n is a weaker conjecture than a related one in the comment to A179210.

Examples

			For q=3 we have (r-q)/(q-p)=2/1. Therefore, a(1)=3.
For q=5: (r-q)/(q-p) = 1/1; for q = 7: (r-q)/(q-p) = 2/1; for q = 11: (r-q)/(q-p) = 1/2. Therefore, a(2)=11.
		

Crossrefs

Programs

Extensions

Revised definition, new program, and terms past a(5) from Charles R Greathouse IV, Jan 12 2011

A168253 a(n) is the smallest prime q such that, for the previous prime p and the following prime r, the fraction (q-p)/(r-q) has denominator n (or 0, if such a prime does not exist).

Original entry on oeis.org

5, 3, 23, 89, 139, 199, 113, 1933, 523, 3089, 1129, 1669, 2477, 2971, 4297, 5591, 1327, 28351, 30593, 19333, 16141, 36389, 81463, 28229, 31907, 19609, 35617, 82073, 44293, 102701, 34061, 288583, 221327, 134513, 173359, 360091
Offset: 1

Views

Author

Vladimir Shevelev, Jan 05 2011

Keywords

Comments

Conjecture: a(n)>0 for all n.

Crossrefs

Programs

A179256 a(n) is the smallest prime q such that (q-p)/(r-q) = n, where p

Original entry on oeis.org

5, 11, 29, 6421, 149, 521, 84913, 1949, 1277, 43391, 1151, 4547, 933151, 2999, 6947, 1568867, 10007, 32297, 4131223, 25301, 78779, 12809491, 91079, 28277, 13626407, 35729, 117497, 37305881, 399851, 102761, 217795433, 288647, 296909, 240485461, 173429, 1026029, 213158501, 1053179, 371027, 1163010421, 1885151, 461801, 1661688551, 1155821, 576881, 3403741987, 4876607, 4252679, 10394432611, 838349, 1775171
Offset: 1

Views

Author

Vladimir Shevelev, Jan 05 2011

Keywords

Comments

Conjecture: a(n)>0 for n >= 1.
It would appear that a(3n+1) is greater than either a(3n) or a(3n+2).
Records appear for a(n) for n's: 1, 2, 3, 4, 7, 13, 16, 19, 22, 25, 28, 31, 34, 40, 43, 46, 49, ..., .

Crossrefs

Programs

A275785 Primes such that the ratio between the distance to the next prime and from the previous prime appears for the first time.

Original entry on oeis.org

3, 5, 11, 23, 29, 31, 37, 89, 113, 127, 139, 149, 199, 251, 293, 331, 337, 367, 409, 521, 523, 631, 701, 787, 797, 953, 1087, 1129, 1151, 1259, 1277, 1327, 1361, 1381, 1399, 1657, 1669, 1847, 1933, 1949, 1951, 1973, 2477, 2503, 2579, 2633, 2861, 2879, 2971, 2999, 3089, 3137, 3163, 3229, 3407
Offset: 1

Views

Author

Andres Cicuttin, Nov 14 2016

Keywords

Comments

Number of terms less than 10^n: 2, 8, 26, 85, 224, 511, 1035, 1905, 3338, ..., . - Robert G. Wilson v, Nov 30 2016

Examples

			a(1) = 3 because this is the first prime for which it is possible to determine the ratio between the distance to the next prime (5) and from the previous prime (2). This first ratio is 2.
a(2) = 5 because the ratio between the distance to the next prime (7) and from the previous prime (3) is 1 and this ratio has not appeared before.
The third element a(3) is not 7 because (11-7)/(7-5) = 2, a ratio that appeared before with a(1), so a(3) = 11 because (13-11)/(11-7) = 1/2, a ratio that did not appear before.
		

Crossrefs

Programs

  • Mathematica
    nmax = 720;
    a = Prime[Range[nmax]];
    gaps = Rest[a] - Most[a];
    gapsratio = Rest[gaps]/Most[gaps];
    newpindex = {}; newgratios = {}; i = 1;
    While[i < Length[gapsratio] + 1,
    If[Cases[newgratios, gapsratio[[i]]] == {},
      AppendTo[newpindex, i + 1];
      AppendTo[newgratios, gapsratio[[i]]] ];
      i++];
    Prime[newpindex]
    p = 2; q = 3; r = 5; rtlst = qlst = {}; While[q < 10000, rt = (r - q)/(q - p); If[ !MemberQ[rtlst, rt], AppendTo[rtlst, rt]; AppendTo[qlst, q]]; p = q; q = r; r = NextPrime@ r]; qlst (* Robert G. Wilson v, Nov 30 2016 *)

A179240 a(n) is the smallest prime q > a(n-1) such that, for the previous prime p and the following prime r, the fraction (q-p)/(r-q) has denominator equal to A006843(n) (or 0, if such a prime does not exist).

Original entry on oeis.org

5, 11, 17, 19, 29, 41, 47, 67, 73, 97, 101, 359, 367, 379, 383, 389, 397, 419, 421, 449, 467, 547, 613, 631, 647, 683, 691, 733, 769, 797, 811, 929, 941, 1021, 1087, 1153, 1181, 1193, 1249, 1709, 1721, 1747, 1847, 1889, 2017, 2153, 2357
Offset: 1

Views

Author

Vladimir Shevelev, Jan 06 2011

Keywords

Comments

Conjecture: a(n) > 0 for all n.

Examples

			For n = 1..3, A006843(n) = 1, and p,q,r have to obey the condition
r-q | q-p. Thus a(1) = 5, a(2) = 11, a(3) = 17.
		

Crossrefs

Extensions

More terms from Alois P. Heinz, Jan 06 2011

A179328 a(n) is the smallest prime q > a(n-1) such that, for the previous prime p and the following prime r, the fraction (q-p)/(r-q) has denominator prime(n) (or 0, if such a prime does not exist).

Original entry on oeis.org

3, 23, 139, 293, 1129, 2477, 8467, 30593, 81463, 85933, 190409, 404597, 535399, 840353, 1100977, 2127163, 4640599, 6613631, 6958667, 10343761, 24120233, 49269581, 83751121, 101649649, 166726367, 273469741, 310845683, 568951459
Offset: 1

Views

Author

Vladimir Shevelev, Jan 06 2011

Keywords

Comments

Conjecture: a(n) > 0 for all n.

Crossrefs

Programs

  • Maple
    with(numtheory):
    a:= proc(n) option remember; local k, p, q, r, pn;
          pn:= ithprime(n);
          for k from `if`(n=1, 1, pi(a(n-1))) do
            p:= ithprime(k);
            q:= ithprime(k+1);
            r:= ithprime(k+2);
            if denom((q-p)/(r-q)) = pn then break fi
          od; q
        end:
    seq(a(n), n=1..10);  # Alois P. Heinz, Jan 06 2011
  • Mathematica
    a[n_] := a[n] = Module[{k, p, q, r, pn},
         pn = Prime[n];
         For[k = If[n == 1, 1, PrimePi[a[n - 1]]], True, k++,
         p = Prime[k];
         q = Prime[k + 1];
         r = Prime[k + 2];
         If [Denominator[(q - p)/(r - q)] == pn, Break[]]]; q];
    Table[a[n], {n, 1, 10}] (* Jean-François Alcover, Mar 18 2022, after Alois P. Heinz *)

Extensions

More terms from Alois P. Heinz, Jan 06 2011

A181994 Initial members of prime triples p < q < r such that r-q = n*(q-p).

Original entry on oeis.org

3, 2, 29, 8117, 137, 197, 45433, 1931, 521, 156151, 1949, 1667, 480203, 2969, 7757, 2181731, 12161, 28349, 6012893, 20807, 16139, 3933593, 163061, 86627, 13626251, 25469, 40637, 60487753, 79697, 149627, 217795241, 625697, 552401, 240485251, 173357, 360089, 122164741
Offset: 1

Views

Author

Zak Seidov, May 31 2012

Keywords

Comments

For some n, a(n) are abnormally large: note, e.g., that if q-p=2, then n cannot be of the form 4+3k, that is why a(4), a(7), a(10), ... are larger than neighbor terms; also, a(67) > 1.1*10^11. Is the sequence infinite?

Examples

			First 10 cases of {n,p,q,r}: {1,3,5,7}, {2,2,3,5}, {3,29,31,37}, {4,8117,8123,8147}, {5,137,139,149}, {6,197,199,211}, {7,45433,45439,45481}, {8,1931,1933,1949}, {9,521,523,541}, {10,156151,156157,156217}.
		

Crossrefs

Particular cases with q-p=2: A022004 [(r-q)=2*(q-p)], A049437 [(r-q)=3*(q-p) starting with 2nd term].
Cf. A179210.

Formula

a(n) = prevprime(A179210(n)). - Robert G. Wilson v, Dec 23 2016

A178942 a(1) = 3; for n >= 2, a(n) is the smallest prime q > a(n-1) such that, for the previous prime p and the following prime r, the fraction (q-p)/(r-q) has denominator equal to A001223(n)/2 (or 0, if no such prime exists).

Original entry on oeis.org

3, 5, 11, 13, 17, 19, 29, 37, 47, 53, 61, 67, 71, 79, 83, 131, 137, 151, 163, 173, 233, 277, 331, 359, 379, 397, 401, 419, 439, 773, 823, 941, 947, 1021, 1031, 1033, 1063, 1087, 1097, 1117, 1123, 1153, 1187, 1237, 1277, 1709, 1789, 1823
Offset: 1

Views

Author

Vladimir Shevelev, Jan 06 2011

Keywords

Comments

Conjecture: a(n) > 0 for all n.
The smallest prime(k) > a(n-1) such that the denominator of A001223(k-1)/A001223(k) equals A001223(n)/2. - R. J. Mathar, Jan 07 2011

Crossrefs

Programs

  • Maple
    A001223 := proc(n) ithprime(n+1)-ithprime(n) ; end proc:
    A178942 := proc(n) option remember; local p,q,r ; if n = 1 then 3; else for q from procname(n-1)+1 do if isprime(q) then p := prevprime(q) ; r := nextprime(q) ; denom((q-p)/(r-q)) ; if % = A001223(n)/2 then return q; end if; end if; end do: end if; end proc: # R. J. Mathar, Jan 07 2011
  • Mathematica
    A001223[n_] := Prime[n + 1] - Prime[n];
    a[n_] := a[n] = Module[{p, q, r, d}, If[n == 1, 3, For[q = a[n - 1] + 1, True, q++, If [PrimeQ[q], p = NextPrime[q, -1]; r = NextPrime[q]; d = Denominator[(q - p)/(r - q)]; If[d == A001223[n]/2, Return[q]]]]]];
    Array[a, 48] (* Jean-François Alcover, May 21 2020, after Maple *)

Extensions

More terms from Alois P. Heinz, Jan 06 2011

A279066 Least prime q such that (q-p)/(r-q), where pA038566/A038567.

Original entry on oeis.org

5, 3, 31, 23, 8123, 89, 139, 7963, 337, 409, 199, 797, 45439, 113, 953, 88547, 293, 2633, 1933, 3643, 137029, 13381, 523, 2861, 1381, 1259, 7621, 7433, 156157, 3089, 546781, 30911, 1951, 294563, 1129, 3229, 285871, 10369, 14221, 3651341, 25819, 3967, 1669, 6173, 23473, 51383
Offset: 1

Views

Author

Keywords

Comments

Almost a bisection of A275785 with only the term 5 being in both A279066 & A279067.
The union of A279066 & A279067 is A275785 with only 5 as a common term.
1/n = A179210(n).
Records: 5, 31, 8123, 45439, 88547, 137029, 156157, 546781, 3651341, 11931613, 16613347, 54636251, 72510257, 102626747, 148379059, 290018137, 847428851, 1165527283, 8232085373, 32592174133, 40113962921, ..., .

Examples

			Row 1:        1/1                                       5
Row 2:        1/2                                       3
Row 3:     1/3  2/3                                 31      23
Row 4:     1/4  3/4                               8123      89
Row 5: 1/5 2/5  3/5 4/5                      139  7963     337    409
Row 6:     1/6  5/6                                199     797
Row 7:    1/7 .. 6/7                   45439 113   953   88547    293   2633
Row 8: 1/8 3/8  5/8 7/8                     1933  3643  137029  13381
etc.
		

Crossrefs

Programs

  • Mathematica
    f[n_] := Block[{p = 2, q = 3, r = 5}, While[q != n(r - q) + p, p = q; q = r; r = NextPrime@ r]; q]; Farey[n_] := Union@ Flatten@ Table[a/b, {b, n}, {a, 0, b}]; ff = Rest@ Reverse@ Sort[ Farey[25], Denominator[#2] < Denominator[#1] &]; f@# & /@ ff
Showing 1-10 of 12 results. Next