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

A265759 Numerators of primes-only best approximates (POBAs) to 1; see Comments.

Original entry on oeis.org

3, 2, 5, 13, 11, 19, 17, 31, 29, 43, 41, 61, 59, 73, 71, 103, 101, 109, 107, 139, 137, 151, 149, 181, 179, 193, 191, 199, 197, 229, 227, 241, 239, 271, 269, 283, 281, 313, 311, 349, 347, 421, 419, 433, 431, 463, 461, 523, 521, 571, 569, 601, 599, 619, 617
Offset: 1

Views

Author

Clark Kimberling, Dec 15 2015

Keywords

Comments

Suppose that x > 0. A fraction p/q of primes is a primes-only best approximate (POBA), and we write "p/q in B(x)", if 0 < |x - p/q| < |x - u/v| for all primes u and v such that v < q. Note that for some choices of x, there are values of q for which there are two POBAs. In these cases, the greater is placed first; e.g., B(3) = (7/2, 5/2, 17/5, 13/5, 23/7, 19/7, ...).
See A265772 and A265774 for definitions of lower POBA and upper POBA. In the following guide, for example, A001359/A006512 represents (conjecturally in some cases) the Lower POBAs p(n)/q(n) to 1, where p = A001359 and q = A006512 except for first terms in some cases. Every POBA is either a lower POBA or an upper POBA.
x Lower POBA Upper POBA POBA

Examples

			The POBAs for 1 start with 3/2, 2/3, 5/7, 13/11, 11/13, 19/17, 17/19, 31/29, 29/31, 43/41, 41/43, 61/59, 59/61. For example, if p and q are primes and q > 13, then 11/13 is closer to 1 than p/q is.
		

Crossrefs

Programs

  • Mathematica
    x = 1; z = 200; p[k_] := p[k] = Prime[k];
    t = Table[Max[Table[NextPrime[x*p[k], -1]/p[k], {k, 1, n}]], {n, 1, z}];
    d = DeleteDuplicates[t]; tL = Select[d, # > 0 &] (* lower POBA *)
    t = Table[Min[Table[NextPrime[x*p[k]]/p[k], {k, 1, n}]], {n, 1, z}];
    d = DeleteDuplicates[t]; tU = Select[d, # > 0 &] (* upper POBA *)
    v = Sort[Union[tL, tU], Abs[#1 - x] > Abs[#2 - x] &];
    b = Denominator[v]; s = Select[Range[Length[b]], b[[#]] == Min[Drop[b, # - 1]] &];
    y = Table[v[[s[[n]]]], {n, 1, Length[s]}] (* POBA, A265759/A265760 *)
    Numerator[tL]   (* A001359 *)
    Denominator[tL] (* A006512 *)
    Numerator[tU]   (* A006512 *)
    Denominator[tU] (* A001359 *)
    Numerator[y]    (* A265759 *)
    Denominator[y]  (* A265760 *)

A051644 Primes of the form 6*p + 1 where p is also prime.

Original entry on oeis.org

13, 19, 31, 43, 67, 79, 103, 139, 223, 283, 367, 439, 499, 607, 619, 643, 787, 823, 907, 1039, 1087, 1399, 1447, 1543, 1579, 1627, 1663, 1699, 1759, 1867, 1879, 1987, 2083, 2203, 2239, 2383, 2659, 2767, 2803, 3019, 3343, 3463, 3559, 3607, 3643, 3847, 3919
Offset: 1

Views

Author

Keywords

Comments

Analogous to A005385; can be called 6-safe primes.

Examples

			103 is in the sequence because both 17 and 6*17 + 1 = 103 are primes.
		

Crossrefs

Programs

  • Mathematica
    Select[1 + 6Prime@Range[120], PrimeQ] (* Ray Chandler, Mar 14 2007 *)
  • PARI
    isok(k) = isprime(k) && k % 6 == 1 && isprime((k-1)/6); \\ Amiram Eldar, Feb 24 2025

Formula

a(n) = 6*A007693(n) + 1.

Extensions

Edited, corrected and extended by Ray Chandler, Mar 14 2007

A023287 Primes that remain prime through 3 iterations of function f(x) = 6x + 1.

Original entry on oeis.org

61, 101, 1811, 3491, 4091, 5711, 5801, 6361, 7121, 10391, 10771, 11311, 13421, 15131, 17791, 18911, 19471, 20011, 24391, 25601, 25951, 30091, 35251, 41911, 45631, 47431, 55631, 58711, 62921, 67891, 70451, 70571, 72271, 74051, 74161, 75431, 80471, 86341
Offset: 1

Views

Author

Keywords

Comments

Primes p such that s1=p, s2=6*s1+1, s3=6*s2+1 and s4=6*s3+1 are primes forming a special chain of four primes. A fifth term in such a chain cannot arise. See A085956, A086361, A086362.
Entries in chains are congruent to {1,7,3,9} mod 10.

Examples

			First chain is {61, 367, 2203, 13219};
319th chain is {1291391, 7748347, 46490083, 278940499}.
		

Crossrefs

Subsequence of A007693, A023256, and A024899.

Programs

  • Magma
    [n: n in [1..150000] | IsPrime(n) and IsPrime(6*n+1) and IsPrime(36*n+7) and IsPrime(216*n+43)] // Vincenzo Librandi, Aug 04 2010
  • Mathematica
    k=0; m=6; Do[s=Prime[n]; s1=m*s+1; s2=m*s1+1; s3=m*s2+1; If[PrimeQ[s1]&&PrimeQ[s2]&&PrimeQ[s3], k=k+1; Print[{k, n, s, s1, s2, s3}]], {n, 1, 100000}] (* edited by Zak Seidov, Feb 08 2011 *)
    thrQ[n_]:=AllTrue[Rest[NestList[6#+1&,n ,3]],PrimeQ]; Select[Prime[Range[9000]],thrQ] (* Harvey P. Dale, Mar 03 2024 *)

Formula

{p, 6p+1, 36p+7, 216p+43} are all primes, where p is prime.

Extensions

Additional comments from Labos Elemer, Jul 23 2003

A051887 Minimal and special 2k-Germain primes, where 2k is in A002110 (primorial numbers).

Original entry on oeis.org

2, 2, 2, 2, 2, 5, 17, 11, 11, 11, 2, 23, 7, 43, 19, 3, 5, 2, 7, 3, 61, 53, 2, 41, 47, 2, 5, 7, 31, 2, 47, 13, 113, 7, 137, 103, 43, 41, 97, 3, 173, 97, 41, 13, 97, 59, 29, 53, 3, 107, 127, 197, 3, 487, 433, 31, 281, 587, 7, 89, 41, 47, 193, 239, 41, 7, 31, 67
Offset: 1

Views

Author

Labos Elemer, Dec 15 1999

Keywords

Comments

a(n) is the minimal prime p such that primorial(n)*p + 1 is also prime.
While p is in A005384, the primorial(n)*p + 1 primes are in A051902 (primorial-safe primes).
Analogous to or subset of A051686, where the even numbers are 2, 6, ..., A002110(n), ...

Examples

			a(25) = 47 because primorial(25)*47 + 1 is also prime and minimal with this property: primorial(25)*47 + 1 = 47*2305567963945518424753102147331756070 + 1 = 108361694305439365963395800924592535291 is a minimal prime. The first 6 terms (2,2,2,2,2,5) correspond to first entries in A005384, A007693, A051645, A051647, A051653, A051654, respectively.
		

Crossrefs

Programs

  • Mathematica
    Table[p = 2; While[! PrimeQ[Product[Prime@ i, {i, n}] p + 1], p = NextPrime@ p]; p, {n, 68}] (* Michael De Vlieger, Jun 29 2017 *)
  • PARI
    a(n) = {my(p = 2, r = vecprod(primes(n))); while(!isprime(p * r + 1), p = nextprime(p+1)); p;} \\ Amiram Eldar, Feb 25 2025

Formula

a(n) = (A051902(n)-1)/A002110(n). - Amiram Eldar, Feb 25 2025

Extensions

More terms from Michael De Vlieger, Jun 29 2017

A023256 Primes that remain prime through 2 iterations of function f(x) = 6x + 1.

Original entry on oeis.org

2, 17, 47, 61, 101, 131, 151, 331, 367, 461, 607, 751, 937, 971, 1151, 1321, 1327, 1361, 1481, 1511, 1607, 1811, 1847, 1907, 2081, 2287, 2347, 2357, 2791, 2851, 2971, 3251, 3257, 3457, 3491, 3581, 3761, 4007, 4091, 4127, 4861, 4967, 5231, 5347, 5387, 5407
Offset: 1

Views

Author

Keywords

Comments

Primes p such that 6*p+1 and 36*p+7 are also primes. - Vincenzo Librandi, Aug 04 2010
Subsequence of A007693. - Michel Marcus, Oct 17 2015

Crossrefs

Cf. A007693 (1 iteration), A023287 (3 iterations).

Programs

  • Magma
    [n: n in [0..100000] | IsPrime(n) and IsPrime(6*n+1) and IsPrime(36*n+7)] // Vincenzo Librandi, Aug 04 2010
    
  • Mathematica
    Select[Prime[Range[800]],AllTrue[Rest[NestList[6#+1&,#,2]],PrimeQ]&] (* Harvey P. Dale, Oct 17 2020 *)
  • PARI
    lista(nn) = forprime(n=1, nn, if (isprime(p=6*n+1) && isprime(6*p+1), print1(n, ", "))); \\ Michel Marcus, Oct 17 2015

Formula

a(n) == 1 or 7 (mod 10) for n > 1. - John Cerkan, Sep 14 2016

A051647 Primes p such that 210*p + 1 is also prime.

Original entry on oeis.org

2, 3, 5, 7, 11, 13, 17, 23, 29, 47, 53, 59, 67, 73, 83, 89, 101, 137, 139, 157, 163, 179, 181, 191, 193, 223, 229, 251, 271, 277, 281, 313, 317, 347, 349, 353, 359, 401, 419, 421, 431, 433, 449, 457, 463, 479, 523, 577, 599, 601, 631, 653, 701, 709, 719, 727
Offset: 1

Views

Author

Keywords

Comments

Analogous to A005384, Sophie Germain primes.
A002110(4)*p + 1 = 210*p + 1 and p are both primes.

Examples

			11 is in the sequence because 210*11 + 1 = 2311 is also prime.
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(900) | IsPrime(210*p+1)]; // Vincenzo Librandi, Apr 11 2013
    
  • Mathematica
    Select[Prime[Range[200]],PrimeQ[210#+1]&]  (* Harvey P. Dale, Apr 25 2011 *)
  • PARI
    isok(k) = isprime(k) && isprime(210*k+1); \\ Amiram Eldar, Feb 24 2025

Formula

a(n) = (A051648(n)-1)/210. - Amiram Eldar, Feb 24 2025

A051645 Primes p such that 30*p+1 is also prime.

Original entry on oeis.org

2, 5, 7, 11, 19, 23, 41, 43, 61, 67, 71, 79, 89, 109, 113, 131, 137, 167, 181, 193, 223, 229, 233, 277, 281, 313, 317, 331, 337, 359, 383, 439, 443, 457, 461, 467, 491, 503, 509, 541, 547, 593, 599, 607, 641, 691, 701, 733, 739, 743, 751, 769, 797, 821, 823
Offset: 1

Views

Author

Keywords

Comments

A002110(3)*p+1 and p are primes.

Examples

			p = 19 is in the sequence because 30*p+1 = 571 is also prime.
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(900) | IsPrime(30*p+1)]; // Vincenzo Librandi, Apr 11 2013
    
  • Mathematica
    Select[Prime[Range[900]], PrimeQ[30 # + 1] &] (* Vincenzo Librandi, Apr 11 2013 *)
  • PARI
    isok(k) = isprime(k) && isprime(30*k+1); \\ Amiram Eldar, Feb 24 2025

Formula

a(n) = (A051646(n)-1)/30. - Amiram Eldar, Feb 24 2025

A051646 Primes of the form 30*p + 1 where p is also prime.

Original entry on oeis.org

61, 151, 211, 331, 571, 691, 1231, 1291, 1831, 2011, 2131, 2371, 2671, 3271, 3391, 3931, 4111, 5011, 5431, 5791, 6691, 6871, 6991, 8311, 8431, 9391, 9511, 9931, 10111, 10771, 11491, 13171, 13291, 13711, 13831, 14011, 14731, 15091, 15271, 16231, 16411, 17791, 17971
Offset: 1

Views

Author

Keywords

Comments

Analogous to A005385, safe primes. Can be called 30-safe primes.

Examples

			61 is in the sequence because both 2 and 30*2 + 1 = 61 are primes.
		

Crossrefs

Programs

  • Mathematica
    Select[30 * Prime[Range[120]] + 1, PrimeQ] (* Amiram Eldar, Feb 24 2025 *)
  • PARI
    isok(k) = isprime(k) && k % 30 == 1 && isprime((k-1)/30); \\ Amiram Eldar, Feb 24 2025

Formula

a(n) = A128470(A051645(n)) = 30 * A051645(n) + 1. - Amiram Eldar, Feb 24 2025

A051648 Primes of form 210*p + 1 where p is a prime.

Original entry on oeis.org

421, 631, 1051, 1471, 2311, 2731, 3571, 4831, 6091, 9871, 11131, 12391, 14071, 15331, 17431, 18691, 21211, 28771, 29191, 32971, 34231, 37591, 38011, 40111, 40531, 46831, 48091, 52711, 56911, 58171, 59011, 65731, 66571, 72871, 73291, 74131, 75391, 84211, 87991
Offset: 1

Views

Author

Keywords

Comments

Generalization of A005385. Can be called 210-safe primes.
A002110(4)*p + 1 = 210*p + 1 (prime).

Examples

			631 is in the sequence because 631 = 210*p + 1, where p=3.
		

Crossrefs

Programs

  • Mathematica
    Select[Table[210n+1,{n,Prime[Range[100]]}],PrimeQ] (* Harvey P. Dale, Dec 25 2016 *)
  • PARI
    isok(k) = isprime(k) && k % 210 == 1 && isprime((k-1)/210); \\ Amiram Eldar, Feb 24 2025

Formula

a(n) = 210 * A051647(n) + 1. - Amiram Eldar, Feb 24 2025

A051649 Primes of the form 2310*p + 1 where p is a prime.

Original entry on oeis.org

4621, 11551, 25411, 43891, 108571, 164011, 168631, 224071, 251791, 261031, 316471, 321091, 348811, 376531, 385771, 459691, 528991, 552091, 607531, 626011, 718411, 723031, 732271, 764611, 801571, 815431, 875491, 995611, 1000231, 1055671, 1064911, 1106491, 1161931
Offset: 1

Views

Author

Keywords

Comments

Generalization of A005385; can be called 2310-safe primes.
A002110(5)*p + 1 = 2310*p + 1 (prime).

Examples

			11551 is a term because 11551 = 2310*p + 1 is prime, where p = 5.
		

Crossrefs

Programs

  • Mathematica
    Select[Table[2310n+1,{n,Prime[Range[100]]}],PrimeQ] (* Harvey P. Dale, Jan 18 2017 *)
  • PARI
    isok(k) = isprime(k) && k % 2310 == 1 && isprime((k-1)/2310); \\ Amiram Eldar, Feb 24 2025

Formula

a(n) = 2310 * A051653(n) + 1. - Amiram Eldar, Feb 24 2025
Showing 1-10 of 23 results. Next