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

A136204 Primes p such that 3p-2 and 3p+2 are primes (see A125272) and its decimal representation ends in 7.

Original entry on oeis.org

7, 37, 127, 167, 257, 337, 757, 797, 887, 1307, 1597, 1657, 1667, 2347, 2557, 2897, 2927, 3067, 4297, 4327, 4877, 5087, 5147, 5227, 5417, 5857, 6337, 6827, 6917, 6967, 7127, 7187, 7547, 7687, 7867, 7877, 8147, 8447, 8527, 8647, 9857, 10037, 10687
Offset: 1

Views

Author

Carlos Alves, Dec 21 2007

Keywords

Comments

Theorem: If in the triple (3n-2,n,3n+2) all numbers are primes, then n=5 or the decimal representation of n ends in 3 or 7. Proof: Similar to A136191. Alternative Mathematica proof: Table[nn = 10k + r; Intersection (AT)(AT) (Divisors[CoefficientList[(3nn - 2) nn(3nn + 2), k]]), {r, 1, 9, 2}]; This gives {{1, 5}, {1}, {1, 5}, {1}, {1, 5}}. Therefore only r=3 and r=7 allow nontrivial divisors (excluding nn=5 itself).

Crossrefs

Programs

  • Maple
    filter:= proc(n) isprime(n) and isprime(3*n-2) and isprime(3*n+2) end proc:
    select(filter, [seq(i,i=7..10^4,10)]); # Robert Israel, Nov 20 2023
  • Mathematica
    TPrimeQ = (PrimeQ[ # - 2] && PrimeQ[ #/3] && PrimeQ[ # + 2]) &; Select[Select[Range[100000], TPrimeQ]/3, Mod[ #, 10] == 7 &]

A133313 Primes p such that 3p-2 and 3p+2 are primes (see A125272) and its decimal representation finishes with 3.

Original entry on oeis.org

3, 13, 23, 43, 103, 163, 293, 313, 433, 523, 953, 1013, 1063, 1153, 1283, 1303, 1483, 1693, 1723, 1783, 1913, 2003, 2333, 3533, 3823, 3943, 4003, 4013, 4093, 4943, 5483, 6043, 6133, 6173, 6473, 6803, 7523, 7573, 7603, 7673, 7853, 7993, 8513, 9283, 9343
Offset: 1

Views

Author

Carlos Alves, Dec 21 2007

Keywords

Comments

Theorem: If in the triple (3n-2,n,3n+2) all numbers are primes, then n=5 or the decimal representation of n finishes with 3 or 7. Proof: Similar to A136191. Alternative Mathematica proof: Table[nn = 10k + r; Intersection @@ (Divisors[CoefficientList[(3nn - 2) nn(3nn + 2), k]]), {r, 1, 9, 2}]; This gives {{1, 5}, {1}, {1, 5}, {1}, {1, 5}}. Therefore only r=3 and r=7 allow nontrivial divisors (excluding nn=5 itself).

Crossrefs

Cf. A136204 (finishing with 7), A136191, A136192, A125272.

Programs

  • Maple
    filter:= proc(n) isprime(n) and isprime(3*n-2) and isprime(3*n+2) end proc:
    select(filter, [seq(i,i=3..10^4,10)]); # Robert Israel, Nov 20 2023
  • Mathematica
    TPrimeQ = (PrimeQ[ # - 2] && PrimeQ[ #/3] && PrimeQ[ # + 2]) &; Select[Select[Range[100000], TPrimeQ]/3, Mod[ #, 10] == 3 &]
    Select[Prime[Range[1200]],Mod[#,10]==3&&AllTrue[3#+{2,-2},PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Oct 18 2019 *)

A155006 Primes p such that (p-2)*(p+2)-+2*p are primes.

Original entry on oeis.org

5, 7, 13, 23, 37, 43, 73, 167, 233, 263, 433, 557, 587, 593, 607, 727, 857, 1153, 1597, 1627, 1753, 2143, 2663, 2713, 3433, 3607, 3863, 3947, 4027, 4363, 4423, 4673, 5147, 5477, 5623, 5807, 5903, 6277, 7237, 7333, 7577, 8287, 8647, 8837, 8887, 9043, 10067
Offset: 1

Views

Author

Keywords

Comments

3*7-10=11, 3*7+10=31,...

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=Prime[n];If[PrimeQ[(p-2)*(p+2)-2*p]&&PrimeQ[(p-2)*(p+2)+2*p],AppendTo[lst,p]],{n,7!}];lst
    Select[Prime[Range[1500]],AllTrue[(#-2)(#+2)+{2#,-2#},PrimeQ]&] (* Harvey P. Dale, Jan 01 2025 *)

A124098 Primes p such that 3p -+ 4 are primes.

Original entry on oeis.org

3, 5, 11, 19, 31, 59, 79, 89, 131, 151, 191, 199, 229, 241, 311, 389, 409, 431, 509, 521, 541, 661, 719, 739, 821, 971, 1109, 1151, 1181, 1451, 1549, 1669, 1759, 1801, 1949, 1951, 2011, 2039, 2069, 2089, 2111, 2131, 2341, 2411, 2671, 2699, 2791, 3001, 3181
Offset: 1

Views

Author

Zak Seidov, Nov 26 2006

Keywords

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(70000)| IsPrime(3*p-4)and IsPrime(3*p+4)] // Vincenzo Librandi, Jan 29 2011
  • Mathematica
    lst={}; Do[p=Prime[n]; If[PrimeQ[3*p-4]&&PrimeQ[3*p+4],AppendTo[lst,p]],{n,7!}]; lst (* Vladimir Joseph Stephan Orlovsky, Aug 16 2009 *)
    Select[Prime[Range[500]],AllTrue[3#+{4,-4},PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Oct 02 2015 *)

Formula

a(n)= A125216(n)/3.

A125215 Semiprimes s such that s-/+2 are primes.

Original entry on oeis.org

9, 15, 21, 39, 69, 111, 129, 309, 381, 489, 501, 771, 879, 939, 1011, 1299, 1569, 2271, 2391, 2661, 2859, 3039, 3189, 3459, 3849, 3909, 3921, 4449, 4791, 4971, 5001, 5079, 5169, 5349, 5739, 6009, 6999, 7041, 7671, 8691, 8781, 9201, 10599, 11469, 11829
Offset: 1

Views

Author

Zak Seidov, Nov 24 2006

Keywords

Comments

All terms are multiples of 3, a(n) = 3*A125272(n). - Zak Seidov, May 06 2013

Examples

			9 = 3^2 is a term since it is a semiprime, and both 9 - 2 = 7 and 9 + 2 = 11 are primes.
		

Crossrefs

Programs

  • Mathematica
    Reap[Do[p=Prime[i];If[PrimeQ[p+4]&&Total[Last/@FactorInteger[p+2]]==2,Sow[p+2]],{i,2*10^3}]][[2,1]]

A164566 Primes p such that 7*p-6 and 7*p+6 are also prime numbers.

Original entry on oeis.org

5, 11, 19, 31, 41, 61, 71, 109, 151, 211, 229, 269, 379, 419, 431, 439, 479, 619, 641, 709, 739, 809, 839, 971, 1009, 1069, 1229, 1259, 1319, 1361, 1439, 1451, 1499, 1531, 1579, 1669, 1801, 1879, 1889, 2011, 2111, 2239, 2269, 2381, 2411, 2551, 2579, 2591
Offset: 1

Views

Author

Keywords

Comments

Primes of the form A087681(k)/7, any index k.

Examples

			For p=5, both 7*5-6=29 and 7*5+6=41 are prime,
for p=11, both 7*11-6=71 and 7*11+6=83 are prime.
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(3000) | IsPrime(7*p-6) and IsPrime(7*p+6)]; // Vincenzo Librandi, Apr 09 2013
    
  • Mathematica
    lst={};Do[p=Prime[n];If[PrimeQ[7*p-6]&&PrimeQ[7*p+6],AppendTo[lst,p]], {n,6!}];lst
    Select[Prime[Range[700]], And @@ PrimeQ/@{7 # + 6, 7 # - 6}&] (* Vincenzo Librandi, Apr 09 2013 *)
  • PARI
    is(n)=isprime(n) && isprime(7*n-6) && isprime(7*n+6) \\ Charles R Greathouse IV, Mar 28 2017

Formula

A136052 INTERSECT A023225. [R. J. Mathar, Aug 20 2009]

Extensions

Examples rephrased by R. J. Mathar, Aug 20 2009

A155007 Primes p such that (p-3)*(p+3)-+3*p are primes.

Original entry on oeis.org

7, 17, 37, 113, 157, 227, 283, 293, 313, 347, 443, 587, 787, 883, 1063, 1097, 1237, 1303, 1327, 1427, 1567, 1723, 1933, 1973, 2087, 2347, 2467, 2687, 2777, 3457, 3593, 4447, 4703, 4793, 4967, 5737, 5827, 6317, 6607, 6793, 6857, 8297, 8563, 8803, 9433
Offset: 1

Views

Author

Keywords

Comments

4*10-3*7=19, 4*10+3*7=61, ...

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=Prime[n];If[PrimeQ[(p-3)*(p+3)-3*p]&&PrimeQ[(p-3)*(p+3)+3*p],AppendTo[lst,p]],{n,7!}];lst

A164568 Primes p such that 9*p-10 and 9*p+10 are prime numbers.

Original entry on oeis.org

3, 7, 11, 13, 29, 41, 53, 59, 67, 97, 109, 179, 223, 239, 263, 353, 389, 409, 461, 463, 557, 601, 613, 631, 673, 757, 773, 839, 857, 937, 967, 977, 1019, 1163, 1277, 1301, 1327, 1471, 1627, 1753, 1789, 1877, 1879, 2027, 2087, 2237, 2251, 2269, 2311, 2351
Offset: 1

Views

Author

Keywords

Examples

			9*3-10=17, 9*3+10=37, ...
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(2500) |IsPrime(9*p-10) and IsPrime(9*p+10)]; // Vincenzo Librandi, Jun 30 2016
  • Maple
    filter:= n -> isprime(n) and isprime(9*n-10) and isprime(9*n+10):
    select(filter, [seq(i,i=3..1000,2)]); # Robert Israel, Jun 29 2016
  • Mathematica
    lst={};Do[p=Prime[n];If[PrimeQ[9*p-10]&&PrimeQ[9*p+10],AppendTo[lst,p]],{n,2*6!}];lst
    Select[Prime[Range[400]], PrimeQ[9 # - 10] && PrimeQ[9 # + 10] &] (* Vincenzo Librandi, Jun 30 2016 *)
    Select[Prime[Range[400]],AllTrue[9#+{10,-10},PrimeQ]&] (* Harvey P. Dale, Dec 23 2023 *)
  • PARI
    forprime(p=3,1e4,if(isprime(9*p-10)&&isprime(9*p+10),print1(p",")))
    

Extensions

Edited by Charles R Greathouse IV, Nov 02 2009

A283562 Primes of the form (p^2 - q^2) / 24 with primes p > q > 3.

Original entry on oeis.org

2, 3, 5, 7, 11, 13, 17, 23, 37, 43, 47, 53, 67, 73, 97, 103, 107, 113, 127, 137, 157, 163, 167, 173, 193, 223, 233, 257, 263, 277, 283, 293, 313, 337, 347, 353, 373, 397, 433, 443, 467, 487, 523, 547, 563, 577, 593, 607, 613, 617, 643, 647, 653, 733, 743, 757, 773, 787, 797, 887, 907, 937, 947, 953, 977
Offset: 1

Views

Author

Altug Alkan and Thomas Ordowski, Mar 11 2017

Keywords

Comments

Note that p - q must be <= 12. Also note that there can be corresponding prime pairs (q, p) more than one way, i.e., (7, 13), (13, 17), (29, 31): (13^2 - 7^2)/24 = (17^2 - 13^2)/24 = (31^2 - 29^2)/24 = 5.
There are no terms of A045468 > 11.
Union of {2}, A006489, A060212, A092110, and A125272. - Robert Israel, Mar 13 2017

Examples

			3 is a term since (11^2 - 7^2)/24 = 3 and 3, 7, 11 are prime numbers.
		

Crossrefs

Programs

  • Maple
    select(r -> isprime(r) and ((isprime(3*r+2) and isprime(3*r-2))
      or (isprime(6*r+1) and isprime(6*r-1))
      or (isprime(2*r+3) and isprime(2*r-3))
    or (isprime(r+6) and isprime(r-6))), [2,seq(i,i=3..1000,2)]); # Robert Israel, Mar 13 2017
  • Mathematica
    ok[n_] := PrimeQ[n] && Block[{p, q, s = Reduce[p^2-q^2 == 24 n && p>3 && q>3, {p, q}, Integers]}, If[s === {}, False, Or @@ And @@@ PrimeQ[{p, q} /. List@ ToRules@s]]]; Select[Range@1000, ok] (* Giovanni Resta, Mar 11 2017 *)
  • PARI
    isA124865(n) = if(n%24, isprimepower(n+4)==2 || isprimepower(n+9)==2, fordiv(n/4, d, if(isprime(n/d/4+d) && isprime(n/d/4-d), return(1))); 0)
    lista(nn) = forprime(p=2, nn, if(isA124865(24*p), print1(p", ")))

Formula

For n > 5, a(n) == {3,7} mod 10.

A155008 Primes p such that (p-a)*(p+a)-+a*p are primes,a=4.

Original entry on oeis.org

3, 5, 7, 11, 19, 29, 31, 59, 101, 139, 239, 271, 829, 1031, 1201, 1439, 1511, 1531, 2251, 2609, 3929, 4349, 4969, 5449, 5639, 5711, 5801, 5881, 5981, 6521, 6569, 6701, 6949, 6959, 8221, 8831, 9001, 9181, 9209, 9419, 9511, 9929, 10139, 10711, 11839, 11981
Offset: 1

Views

Author

Keywords

Comments

3*11-28=5, 3*11+28=61, ...

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=Prime[n];If[PrimeQ[(p-4)*(p+4)-4*p]&&PrimeQ[(p-4)*(p+4)+4*p],AppendTo[lst,p]],{n,7!}];lst
    Select[Prime[Range[1500]],AllTrue[(#-4)(#+4)+{4#,-4#},PrimeQ]&] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, May 27 2020 *)
Showing 1-10 of 17 results. Next