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 71-80 of 119 results. Next

A236509 Primes p with p + 2, p + 6 and prime(p) + 6 all prime.

Original entry on oeis.org

5, 11, 107, 227, 311, 347, 821, 857, 1091, 1607, 1997, 2657, 3527, 4931, 5231, 8087, 8231, 9431, 10331, 11171, 12917, 13691, 13877, 21377, 22271, 24917, 27737, 29567, 32057, 33347, 35591, 36467, 37307, 39227, 42017
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 27 2014

Keywords

Comments

According to the conjecture in A236508, this sequence should have infinitely many terms.

Examples

			a(1) = 5 since 5, 5 + 2 = 7, 5 + 6 = 11 and prime(5) + 6 = 17 are all prime, but 2 + 2 = 4 and 3 + 6 = 9 are both composite.
		

Crossrefs

Programs

  • Mathematica
    p[n_]:=p[n]=PrimeQ[n+2]&&PrimeQ[n+6]&&PrimeQ[Prime[n]+6]
    n=0;Do[If[p[Prime[m]],n=n+1;Print[n," ",Prime[m]]],{m,1,10^6}]

A254041 Number of decompositions of 2n into an unordered sum of two sexy primes.

Original entry on oeis.org

0, 0, 0, 0, 1, 1, 1, 1, 2, 1, 2, 3, 2, 2, 3, 1, 3, 4, 2, 2, 4, 2, 3, 5, 3, 3, 5, 2, 4, 6, 2, 4, 6, 2, 4, 6, 4, 3, 6, 4, 3, 7, 4, 3, 8, 3, 4, 7, 3, 4, 7, 4, 5, 7, 5, 5, 9, 5, 5, 12, 4, 4, 10, 3, 5, 7, 4, 5, 6, 5, 6, 8, 4, 5, 9, 2, 5, 8, 3, 5, 8, 4, 4, 9, 6, 4, 9
Offset: 1

Views

Author

Lei Zhou, Jan 23 2015

Keywords

Comments

"Sexy primes" are listed in A136207.
It is conjectured that a(n) > 0 for n > 4.

Examples

			When n = 79, 2n = 158 = 7 + 151 = 19 + 139 = 31 + 127 = 61 + 97 = 79 + 79 has five "two prime decompositions". Among the involved prime numbers 7, 19, 31, 61, 79, 97, 127, 139, 151, prime 127 and 139 are not sexy primes. So only three decompositions, 158 = 7 + 151 = 61 + 97 = 79 + 79 satisfy the definition of this sequence. Thus a(79) = 3.
		

Crossrefs

Programs

  • Mathematica
    Table[e = 2 n; ct = 0; p = 2; While[p = NextPrime[p]; p <= n, q = e - p; If[PrimeQ[q], If[(((p > 6) && PrimeQ[p - 6]) || PrimeQ[p + 6]) && (((q > 6) && PrimeQ[q - 6]) || PrimeQ[q + 6]), ct++]]]; ct, {n, 87}]

A261528 Least positive integer k such that both k and k*n belong to the set {m>0: prime(m)+2 is prime with prime(prime(m)+2) = prime(prime(m))+6}.

Original entry on oeis.org

2, 891, 81002, 814812, 86050, 5917, 65527, 109853, 2563344, 25379, 2640232, 266076, 775889, 67387, 68111, 37950, 353416, 347139, 56390, 11299, 89491, 545458, 910786, 353416, 1913477, 9025, 111569, 511796, 1456228, 37909, 1494675, 212092, 69352, 107769, 300657, 1155675, 391972, 1073031, 55074, 49892
Offset: 1

Views

Author

Zhi-Wei Sun, Aug 23 2015

Keywords

Comments

Conjecture: Any positive rational number r can be written as m/n with m and n in the set {k>0: prime(k)+2 is prime with prime(prime(k)+2) = prime(prime(k))+6}.
This implies that there are infinitely many twin prime pairs {p, p+2} with prime(p+2) - prime(p) = 6.
Note that if prime(n+2)-prime(n) = 6 then prime(n+1)-prime(n) = 2 or 4.

Examples

			a(1) = 2 since 2*1 = 2, and prime(2)+2 = 3+2 = 5 is prime with prime(5)-prime(3) = 11-5 = 6.
a(2) = 891 since prime(891)+2 = 6947 + 2 = 6949 is prime with prime(6949)-prime(6947) = 70123-70117 = 6, and prime(891*2)+2 = 15269 + 2 = 15271 is prime with prime(15271)-prime(15269) = 167119-167113 = 6.
		

References

  • Zhi-Wei Sun, Problems on combinatorial properties of primes, in: M. Kaneko, S. Kanemitsu and J. Liu (eds.), Number Theory: Plowing and Starring through High Wave Forms, Proc. 7th China-Japan Seminar (Fukuoka, Oct. 28 - Nov. 1, 2013), Ser. Number Theory Appl., Vol. 11, World Sci., Singapore, 2015, pp. 169-187.

Crossrefs

Programs

  • Mathematica
    f[n_]:=Prime[n]
    PQ[k_]:=PrimeQ[f[k]+2]&&f[f[k]+2]-f[f[k]]==6
    Do[k=0;Label[bb];k=k+1;If[PQ[k]&&PQ[k*n],Goto[aa],Goto[bb]];Label[aa];Print[n," ", k];Continue,{n,1,40}]

A261533 Primes p such that p+2 is prime with prime(p+2)-prime(p)=6.

Original entry on oeis.org

3, 5, 59, 2789, 5231, 6947, 8087, 11717, 15269, 16229, 17207, 17909, 18059, 18131, 24917, 28751, 35279, 37307, 39227, 39239, 41201, 43787, 45821, 47741, 51869, 53087, 53609, 58439, 64577, 69857, 70919, 75707, 79631, 84869, 92381, 93479, 96179, 102197, 102929, 106187
Offset: 1

Views

Author

Zhi-Wei Sun, Aug 23 2015

Keywords

Comments

The conjecture in A261528 implies that the current sequence has infinitely many terms.
Note that for each n > 2 the difference prime(n+2)-prime(n) is at least 6.

Examples

			a(1) = 3 since 3 and 3+2 = 5 are twin prime, and prime(5)-prime(3) = 11-5 = 6.
a(2) = 5 since 5 and 5+2 = 7 are twin prime, and prime(7)-prime(5) = 17-11 = 6.
		

References

  • Zhi-Wei Sun, Problems on combinatorial properties of primes, in: M. Kaneko, S. Kanemitsu and J. Liu (eds.), Number Theory: Plowing and Starring through High Wave Forms, Proc. 7th China-Japan Seminar (Fukuoka, Oct. 28 - Nov. 1, 2013), Ser. Number Theory Appl., Vol. 11, World Sci., Singapore, 2015, pp. 169-187.

Crossrefs

Programs

  • Mathematica
    f[n_]:=Prime[n]
    PQ[k_]:=PrimeQ[f[k]+2]&&f[f[k]+2]-f[f[k]]==6
    n=0;Do[If[PQ[k],n=n+1;Print[n," ",f[k]]],{k,1,10119}]
    Select[Partition[Prime[Range[11000]],2,1],#[[2]]-#[[1]]==2&&Prime[#[[1]]+ 2]- Prime[#[[1]]]==6&][[All,1]] (* Harvey P. Dale, Apr 26 2020 *)
  • PARI
    isok(i)=p=prime(i);isprime(p+2)&&prime(p+2)-prime(p)==6;
    first(m)=my(v=vector(m));i=1;for(j=1,m,while(!isok(i),i++);v[j]=prime(i);i++);v; \\ Anders Hellström, Aug 23 2015

A275681 Table read by rows: list of sexy prime triples (p, p+6, p+12) such that p+18 is composite.

Original entry on oeis.org

7, 13, 19, 17, 23, 29, 31, 37, 43, 47, 53, 59, 67, 73, 79, 97, 103, 109, 101, 107, 113, 151, 157, 163, 167, 173, 179, 227, 233, 239, 257, 263, 269, 271, 277, 283, 347, 353, 359, 367, 373, 379, 557, 563, 569, 587, 593, 599, 607, 613, 619, 647, 653, 659, 727, 733, 739
Offset: 1

Views

Author

Arkadiusz Wesolowski, Aug 05 2016

Keywords

Examples

			The table starts:
7, 13, 19;
17, 23, 29;
31, 37, 43;
...
		

Crossrefs

Cf. A023201 (sexy primes), A046118, A123082, A275682.

Programs

  • Magma
    lst:=[]; for p in PrimesUpTo(727) do b:=p+6; if IsPrime(b) then c:=b+6; if IsPrime(c) and not IsPrime(c+6) then lst:=lst cat [p, b, c]; end if; end if; end for; lst;
  • Maple
    N:= 10^4: # to get all entries <= N
    Primes:= select(isprime,{seq(i,i=1..N+18,2)}):
    S:= select(`<=`, Primes,N) intersect map(t -> t-6, Primes) intersect map(t -> t-12, Primes) minus map(t -> t-18, Primes):
    map(t ->(t,t+6,t+12), sort(convert(S,list))); # Robert Israel, Aug 05 2016
  • Mathematica
    Most[#]&/@Select[Table[n+{0,6,12,18},{n,Prime[Range[200]]}],PrimeQ[#] == {True,True,True,False}&]//Flatten (* Harvey P. Dale, Jan 19 2017 *)

Formula

a(3*n-2) = A046118(n).
a(3*n-1) = A046118(n)+6.
a(3*n) = A046118(n)+12.

A275682 Table read by rows: list of sexy prime quadruples (p, p+6, p+12, p+18) such that p+24 is composite.

Original entry on oeis.org

11, 17, 23, 29, 41, 47, 53, 59, 61, 67, 73, 79, 251, 257, 263, 269, 601, 607, 613, 619, 641, 647, 653, 659, 1091, 1097, 1103, 1109, 1481, 1487, 1493, 1499, 1601, 1607, 1613, 1619, 1741, 1747, 1753, 1759, 1861, 1867, 1873, 1879, 2371, 2377, 2383, 2389
Offset: 1

Views

Author

Arkadiusz Wesolowski, Aug 05 2016

Keywords

Comments

(5, 11, 17, 23, 29) is a sexy prime 5-tuple and this is the only sexy prime 5-tuple.
Essentially same as A123083.

Examples

			The table starts:
11, 17, 23, 29;
41, 47, 53, 59;
61, 67, 73, 79;
...
		

Crossrefs

Programs

  • Magma
    lst:=[]; for p in PrimesInInterval(7, 2371) do b:=p+6; if IsPrime(b) then c:=b+6; if IsPrime(c) then d:=c+6; if IsPrime(d) then lst:=lst cat [p, b, c, d]; end if; end if; end if; end for; lst;
  • Mathematica
    Most[#]&/@Select[Table[n + {0, 6, 12, 18, 24}, {n, Prime[Range[200]]}], PrimeQ[#]=={True, True, True, True, False}&]//Flatten (* Vincenzo Librandi, Jun 09 2017 *)
    #+{0,6,12,18}&/@Select[Prime[Range[400]],AllTrue[#+{6,12,18},PrimeQ] && CompositeQ[#+24]&]//Flatten (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Apr 29 2019 *)

Formula

a(n) = A123083(n+4).

A302087 Numbers k such that k^2+1 and (k+6)^2+1 are both prime.

Original entry on oeis.org

4, 10, 14, 20, 84, 110, 120, 124, 150, 170, 204, 224, 230, 250, 264, 300, 400, 430, 464, 490, 570, 674, 680, 690, 930, 960, 1004, 1054, 1060, 1140, 1144, 1150, 1314, 1410, 1434, 1550, 1564, 1570, 1580, 1654, 1784, 1870, 1964, 1974, 2050, 2074, 2080, 2120, 2260, 2304, 2314
Offset: 1

Views

Author

Seiichi Manyama, Mar 31 2018

Keywords

Crossrefs

Programs

  • Magma
    [n: n in [1..2500] | IsPrime(n^2+1) and IsPrime((n+6)^2+1)]; // Vincenzo Librandi, Apr 02 2018
    
  • Maple
    select(k->isprime(k^2+1) and isprime((k+6)^2+1),[$1..3000]); # Muniru A Asiru, Apr 02 2018
  • Mathematica
    Select[Range[3000], PrimeQ[#^2 + 1] && PrimeQ[(# + 6)^2 + 1]&] (* Vincenzo Librandi, Apr 02 2018 *)
  • PARI
    isok(k) = isprime(k^2+1) && isprime((k+6)^2+1); \\ Altug Alkan, Apr 02 2018
  • Python
    from sympy import isprime
    k, klist, A302087_list = 0, [isprime(i**2+1) for i in range(6)], []
    while len(A302087_list) < 10000:
        i = isprime((k+6)**2+1)
        if klist[0] and i:
            A302087_list.append(k)
        k += 1
        klist = klist[1:] + [i] # Chai Wah Wu, Apr 01 2018
    

A094231 Lesser member p of sexy primes (p, p+6) such that (p+1, p+2, p+3, p+4, p+5) all have the same number of prime divisors (counted with multiplicity).

Original entry on oeis.org

601, 42181, 70201, 240953, 277493, 414361, 418793, 619813, 632147, 637073, 723161, 732233, 739433, 761393, 781961, 879001, 934481, 979201, 1154233, 1320721, 1327673, 1357673, 1611361, 1685521, 1866233, 1877833, 1950457
Offset: 1

Views

Author

Jason Earls, May 29 2004

Keywords

Examples

			42181 is a term because 42181 and 42187 are sexy primes while 42182-42186 each have 4 prime divisors (counting multiplicity).
		

Crossrefs

Programs

  • Magma
    f:=func; [p:p in PrimesUpTo(2000000)| IsPrime(p+6) and forall{k:k in [2..5]|f(p+k) eq f(p+1)} ]; // Marius A. Burtea, Dec 16 2019
  • Mathematica
    Select[Range[2*10^6],AllTrue[{#,#+6},PrimeQ]&&Length[Union[ PrimeOmega[ Range[ #+1,#+5]]]]==1&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Dec 16 2015 *)

A104873 Concatenations of pairs of primes that differ by 10^12.

Original entry on oeis.org

611000000000061, 1631000000000163, 1931000000000193, 2111000000000211, 2711000000000271, 3311000000000331, 5471000000000547, 6611000000000661, 7511000000000751, 7871000000000787, 9971000000000997, 10511000000001051
Offset: 1

Views

Author

Jonathan Vos Post, Mar 29 2005

Keywords

Comments

Integers in this sequence can never be prime, as they are all multiples of 3. They can be semiprimes, as is the case for Prime(177) concatenated with Prime(37607912056) = 10511000000001051 = 3 * 3503666666667017.

Examples

			61 is prime, specifically prime(18) and 61 + 10^12 is prime, specifically prime(7607912020), so their concatenation is in this sequence: 611000000000061. The concatenation is not itself prime, as it equals 3 * 7 * 23 * 1265010351967.
		

Crossrefs

Programs

  • Mathematica
    #*10^13+10^12+#&/@Select[Prime[Range[200]],PrimeQ[#+10^12]&] (* Harvey P. Dale, Jan 18 2021 *)

Formula

a(n) = Concatenate(P, P+10^12) iff P prime and P+10^12 prime.

A106059 Primes p such that p + 6 and 6*p + 1 are primes.

Original entry on oeis.org

5, 7, 11, 13, 17, 23, 37, 47, 61, 73, 83, 101, 103, 107, 131, 151, 173, 233, 257, 263, 271, 277, 311, 331, 347, 367, 373, 443, 461, 503, 557, 593, 601, 607, 641, 653, 727, 751, 853, 941, 947, 971, 1013, 1033, 1063, 1091, 1103, 1117, 1283, 1321, 1361
Offset: 1

Views

Author

Zak Seidov, May 07 2005

Keywords

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(5000)|IsPrime(p+6) and IsPrime(6*p+1)]; // Vincenzo Librandi, Jan 30 2011
  • Mathematica
    Select[Prime[Range[220]], PrimeQ[6#+1]&&PrimeQ[1#+6]&]
Previous Showing 71-80 of 119 results. Next