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

A257926 Least positive integer k such that prime(k*n)+2 = prime(i*n)*prime(j*n) for some 0 < i < j.

Original entry on oeis.org

6, 4, 10, 8, 451, 426, 622, 175, 1424, 500, 33, 703, 1761, 4428, 1563, 959, 8147, 7055, 5948, 250, 7517, 12706, 8405, 2948, 2610, 1949, 10424, 2214, 6722, 1963, 3335, 16382, 15687, 17591, 15073, 7818, 32202, 31169, 2248, 14899, 69955, 7580, 2393, 39295, 42352, 5884, 9367, 3630, 14090, 1305
Offset: 1

Views

Author

Zhi-Wei Sun, Jul 14 2015

Keywords

Comments

Conjecture: a(n) exists for any n > 0.
This is much stronger than Chen's famous result that there are infinitely many Chen primes.

Examples

			a(1) = 6 since prime(6*1)+2 = 15 = 3*5 = prime(2*1)*prime(3*1).
a(3) = 10 since prime(10*3)+2 = 115 = 5*23 = prime(1*3)*prime(3*3).
a(149) = 1476387 since prime(1476387*149)+2 = 4666119529 = 8311*561439 = prime(7*149)*prime(310*149).
		

References

  • Jing-run Chen, On the representation of a large even integer as the sum of a prime and a product of at most two primes, Sci. Sinica 16(1973), 157-176.
  • 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
    Dv[n_]:=Divisors[Prime[n]+2]
    L[n_]:=Length[Dv[n]]
    P[k_,n_]:=L[k*n]==4&&PrimeQ[Part[Dv[k*n],2]]&&Mod[PrimePi[Part[Dv[k*n],2]],n]==0&&PrimeQ[Part[Dv[k*n],3]]&&Mod[PrimePi[Part[Dv[k*n],3]],n]==0
    Do[k=0;Label[bb];k=k+1;If[P[k,n],Goto[aa]];Goto[bb];Label[aa];Print[n," ", k];Continue,{n,1,50}]

A112021 Number of partitions of n into Chen primes.

Original entry on oeis.org

0, 1, 1, 1, 2, 2, 3, 3, 4, 5, 6, 7, 9, 10, 12, 14, 17, 19, 23, 26, 30, 35, 40, 46, 52, 60, 67, 77, 87, 98, 111, 124, 140, 157, 175, 197, 219, 244, 272, 302, 336, 372, 412, 456, 503, 556, 613, 675, 742, 816, 896, 983, 1078, 1180, 1291, 1411, 1542, 1683, 1836, 2001, 2178
Offset: 1

Views

Author

Reinhard Zumkeller, Aug 26 2005

Keywords

Comments

a(n) = A000607(n) for n <= 42.

Crossrefs

Programs

  • Mathematica
    fQ[n_] := PrimeQ@n && (PrimeQ[n + 2] || 2 == Plus @@ Last /@ FactorInteger[n + 2]); f[n_] := Block[{c = k = 0, l = PartitionsP@n, p = Union /@ IntegerPartitions@n}, While[k++; k < l, If[Union[fQ /@ p[[k]]] == {True}, c++ ]]; c]; lst = {}; Do[ AppendTo[lst, f[n]], {n, 61}]; lst (* or *)
    Rest@ CoefficientList[ Series[1/Times @@ (1 - x^Select[ Range@100, fQ@# &]), {x, 0, 61}], x] (* Robert G. Wilson v, Jun 16 2006 *)
  • PARI
    ok(n)={isprime(n) && bigomega(n+2)<3}
    {my(n=80); Vec(prod(k=1, n, if(ok(k), 1/(1-x^k) + O(x*x^n), 1))-1,-n)} \\ Andrew Howroyd, Dec 28 2017

Formula

G.f.: Product_{k>=1} 1/(1 - x^A109611(k)). - Andrew Howroyd, Dec 28 2017

A112022 Number of partitions of n into distinct Chen primes.

Original entry on oeis.org

1, 0, 1, 1, 0, 2, 0, 2, 1, 1, 2, 1, 2, 2, 2, 2, 3, 2, 4, 3, 4, 4, 4, 5, 5, 5, 6, 5, 6, 7, 6, 9, 7, 9, 9, 9, 11, 11, 11, 13, 12, 14, 15, 14, 17, 15, 17, 19, 18, 21, 21, 21, 24, 24, 26, 28, 27, 30, 30, 32, 35, 34, 37, 37, 39, 41, 43, 45, 46, 48, 51, 53, 56, 58, 59, 61, 64, 66, 70, 71, 73
Offset: 0

Views

Author

Reinhard Zumkeller, Aug 26 2005

Keywords

Comments

a(n) = A000586(n) for n <= 42.

Crossrefs

Programs

  • Mathematica
    terms = 81;
    gf = Times @@ (1 + x^SequencePosition[ PrimeOmega[ Range[terms]], {1, _, 1|2}][[All, 1]]) + O[x]^terms;
    CoefficientList[gf, x] (* Jean-François Alcover, Jul 02 2018 *)
  • PARI
    P=1+O(x^1001); forprime(p=2,1e3,if(bigomega(p+2)<3,P*=1+x^p)); Vec(P) \\ Charles R Greathouse IV, May 13 2013

Formula

G.f.: Product_{k>=1} (1 + x^A109611(k)). - Andrew Howroyd, Dec 28 2017

A225868 Numbers m for which max_{2 <= k <= (m-2)/2} Sum_{d>1, d|m+k, k|m+d} 1 = 3.

Original entry on oeis.org

6, 9, 12, 13, 16, 19, 24, 31, 32, 48, 53, 83, 89, 107, 113, 131, 139, 149, 167, 179, 191, 199, 227, 233, 251, 263, 409, 431, 449, 467, 479, 503, 587, 599, 631, 659, 683, 719, 769, 827, 983, 1019, 1091, 1259, 1367, 1409, 1439, 1487, 1499, 1511, 1583, 1619, 1979
Offset: 1

Views

Author

Vladimir Shevelev, May 18 2013

Keywords

Comments

Terms >= 53 are primes p such that p+2 is either prime or semiprime or, relatively rarely, the cube of a prime. However, according to calculations by Peter J. C. Moses, up to 4.2*10^13 there are no numbers p in the sequence for which p+2 is cube of a prime. One can prove that if such a prime p exists, then it is necessary (but not sufficient) for all numbers of the quadruple {r, 2*r - 1, 4*r^2 - 6*r + 3, (2*r - 1)^3 - 2} to be primes, where r == 19 (mod 30) is defined by the equality (2r-1)^3 - 2 = p. The first 3 suitable values of r are 229, 3109, and 17449. But the corresponding p's are not in the sequence. We conjecture that all primes of the sequence are Chen primes, that is, all of them are in A109611.

Crossrefs

Programs

  • Mathematica
    f[n_] := (m = 0; Do[s = Sum[ Boole[ Divisible[n+d, k]], {d, Divisors[n+k] // Rest}]; If[s > m, m = s], {k, 2, (n-2)/2}]; m); Reap[ For[n = 1, n <= 2000, n = If[n < 53, n+1, NextPrime[n]], If[f[n] == 3, Print[n]; Sow[n]]]][[2, 1]] (* Jean-François Alcover, Jul 09 2013, after Vladimir Shevelev *)

A261352 Primes p such that prime(p)+2 = prime(q)*prime(r) for distinct primes q and r.

Original entry on oeis.org

11, 23, 167, 197, 223, 317, 359, 461, 593, 619, 859, 1283, 1289, 1327, 1487, 1759, 1879, 2557, 2579, 2749, 2879, 3617, 4159, 4783, 5081, 5333, 5531, 5689, 5783, 5867, 6427, 6521, 7589, 7681, 7727, 7753, 9041, 9157, 9283, 9479, 10111, 10289, 10853, 11261, 11779, 11867, 12541, 13309, 13399, 13687
Offset: 1

Views

Author

Zhi-Wei Sun, Aug 15 2015

Keywords

Comments

Conjecture: The sequence has infinitely many terms.
See also A261354 for a similar conjecture, and A261353 for a stronger conjecture.
Recall that a prime p is called a Chen prime if p+2 is a product of at most two primes. It is known that there are infinitely many Chen primes.

Examples

			a(1) = 11 since 11 is a prime, and prime(11)+2 = 3*11 = prime(2)*prime(5) with 2 and 5 both prime.
a(2) = 23 since 23 is a prime, and prime(23)+2 = 5*17 = prime(3)*prime(7) with 3 and 7 both prime.
		

References

  • Jing-run Chen, On the representation of a large even integer as the sum of a prime and a product of at most two primes, Sci. Sinica 16(1973), 157-176.
  • 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
    Dv[n_]:=Divisors[n]
    PQ[n_]:=PrimeQ[n]&&PrimeQ[PrimePi[n]]
    q[n_]:=Length[Dv[n]]==4&&PQ[Part[Dv[n],2]]&&PQ[Part[Dv[n],3]]
    f[k_]:=Prime[Prime[k]]+2
    n=0;Do[If[q[f[k]],n=n+1;Print[n," ",Prime[k]]],{k,1,1620}]

A175634 Chen semiprimes: semiprimes m such that m+4 is either a prime or a semiprime.

Original entry on oeis.org

6, 9, 10, 15, 21, 22, 25, 33, 34, 35, 39, 49, 51, 55, 57, 58, 65, 69, 82, 85, 87, 91, 93, 111, 115, 118, 119, 123, 129, 133, 141, 142, 145, 155, 159, 169, 177, 183, 187, 201, 202, 205, 209, 213, 214, 215, 217, 219, 235, 237, 247, 249, 253, 259, 265, 267, 274, 287
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Aug 01 2010

Keywords

Crossrefs

Programs

  • Python
    from sympy.ntheory.factor_ import primeomega, isprime
    def issemiprime(n): return primeomega(n) == 2
    def ok(n): return issemiprime(n) and (issemiprime(n+4) or isprime(n+4))
    print(list(filter(ok, range(1, 288)))) # Michael S. Branicky, Apr 14 2021

Extensions

Corrected (86 replaced by 85) by R. J. Mathar, Aug 03 2010

A238580 a(n) = |{0 < k <= n: 2*k + 1 and prime(k)*prime(n) - 2 are both prime}|.

Original entry on oeis.org

1, 1, 2, 1, 2, 2, 1, 1, 3, 1, 2, 3, 2, 3, 3, 3, 2, 4, 2, 3, 3, 3, 2, 3, 2, 2, 3, 1, 1, 5, 3, 4, 3, 1, 4, 3, 1, 5, 4, 4, 2, 4, 5, 4, 5, 2, 5, 5, 3, 2, 4, 2, 4, 5, 3, 5, 2, 7, 4, 5, 2, 5, 4, 8, 4, 6, 5, 6, 5, 2, 5, 4, 3, 6, 2, 5, 1, 5, 8, 4
Offset: 1

Views

Author

Zhi-Wei Sun, Mar 01 2014

Keywords

Comments

Conjecture: a(n) > 0 for all n > 0, and a(n) = 1 only for n = 1, 2, 4, 7, 8, 10, 28, 34,37, 77.
Note that a prime p with p + 2 a product of at most two primes is called a Chen prime.

Examples

			a(7) = 1 since 2*3 + 1 = 7 and prime(3)*prime(7) - 2 = 5*17 - 2 = 83 are both prime.
a(8) = 1 since 2*8 + 1 = 17 and prime(8)*prime(8) - 2 = 19^2 - 2 = 359 are both prime.
a(77) = 1 since 2*20 + 1 = 41 and prime(20)*prime(77) - 2 = 71*389 - 2 = 27617 are both prime.
		

References

  • J.-R. Chen, On the representation of a large even integer as the sum of a prime and a product of at most two primes, Sci. Sinica 16(1973), 157-176.

Crossrefs

Programs

  • Mathematica
    p[n_,k_]:=PrimeQ[2k+1]&&PrimeQ[Prime[n]*Prime[k]-2]
    a[n_]:=Sum[If[p[n,k],1,0],{k,1,n}]
    Table[a[n],{n,1,80}]

A261282 Least positive integer k such that prime(k)*prime(k*n) = prime(p)+2 for some prime p.

Original entry on oeis.org

14, 60, 135, 41, 199, 2, 2, 2, 61, 2, 183, 25, 15, 12, 47, 143, 110, 294, 117, 88, 22, 402, 26, 269, 116, 145, 164, 6, 10, 488, 2, 44, 120, 4, 127, 144, 119, 704, 1058, 368, 104, 2, 6, 214, 4, 129, 2, 3, 301, 2, 2, 466, 20, 107, 280, 14, 337, 12, 22, 12, 242, 1705, 415, 10, 115, 50, 2, 420, 4, 15
Offset: 1

Views

Author

Zhi-Wei Sun, Aug 14 2015

Keywords

Comments

Conjecture: a(n) exists for any n > 0. In general, any positive rational number r can be written as m/n, where m and n are positive integers such that prime(m)*prime(n) = prime(p)+2 for some prime p.
For example, 14/19 = 24528/33288, and prime(24528)*prime(33288) = 281153*392723 = 110415249619 = prime(4528436431)+2 with 4528436431 prime.
The conjecture implies that there are infinitely many primes p such that prime(p)+2 is a product of two primes. Recall that a prime p is called a Chen prime if p+2 is a product of at most two primes.

Examples

			a(2) = 60 since prime(60)*prime(60*2) = 281*659 = 185179 = prime(16763)+2 with 16763 prime.
		

References

  • Jing-run Chen, On the representation of a large even integer as the sum of a prime and a product of at most two primes, Sci. Sinica 16(1973), 157-176.
  • 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[n_]:=PrimeQ[n]&&PrimeQ[PrimePi[n]]
    Do[k=0;Label[bb];k=k+1;If[PQ[f[k]*f[k*n]-2],Goto[aa],Goto[bb]];Label[aa];Print[n," ", k];Continue,{n,1,70}]

A261353 Least positive integer k such that prime(prime(k))*prime(prime(k*n)) = prime(p)+2 for some prime p.

Original entry on oeis.org

11, 2, 1, 606, 350, 166, 53, 1865, 7, 45, 1308, 68, 215, 61, 256, 13, 248, 90, 1, 1779, 796, 1, 4, 444, 650, 55, 157, 303, 82, 84, 25, 3, 1912, 621, 128, 205, 164, 1091, 61, 12, 337, 1, 303, 15, 23, 418, 212, 23, 2494, 1, 472, 771, 1, 36, 8, 46, 8, 18, 264, 22, 725, 85, 65, 231, 606, 3, 1, 43, 144, 164
Offset: 1

Views

Author

Zhi-Wei Sun, Aug 15 2015

Keywords

Comments

Conjecture: a(n) exists for any n > 0. In general, any positive rational number r can be written as m/n, where m and n are positive integers such that prime(prime(m))*prime(prime(n)) = prime(p)+2 for some prime p.
This implies that the sequence A261352 has infinitely many terms.

Examples

			a(1) = 11 since prime(prime(11))*prime(prime(11*1)) = prime(31)^2 = 127^2 = 16129 = prime(1877)+2 with 1877 prime.
a(4) = 606 since prime(prime(606))*prime(prime(606*4)) = prime(4457)*prime(21589) = 42643*244471 = 10424976853 = prime(473490161)+2 with 473490161 prime.
		

References

  • Jing-run Chen, On the representation of a large even integer as the sum of a prime and a product of at most two primes, Sci. Sinica 16(1973), 157-176.
  • 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[Prime[n]]
    PQ[p_]:=PrimeQ[p]&&PrimeQ[PrimePi[p]]
    Do[k=0;Label[bb];k=k+1;If[PQ[f[k]*f[k*n]-2],Goto[aa],Goto[bb]];Label[aa];Print[n, " ", k];Continue,{n,1,70}]

A118725 Chen primes for which the reversal is also a Chen prime.

Original entry on oeis.org

2, 3, 5, 7, 11, 13, 17, 31, 71, 101, 107, 113, 131, 149, 157, 167, 179, 181, 191, 199, 311, 347, 353, 359, 389, 701, 743, 751, 761, 787, 797, 919, 941, 953, 971, 983, 991, 1009, 1031, 1061, 1091, 1097, 1109, 1151, 1217, 1229, 1259, 1283, 1301, 1409, 1439
Offset: 1

Views

Author

Luc Stevens (lms022(AT)yahoo.com), May 21 2006

Keywords

Examples

			17 and its reversal 71 are both Chen primes.
		

Crossrefs

Cf. A109611.

Programs

  • Maple
    revdigs:= proc(n) local L,k;
      L:= convert(n,base,10);
      add(L[-k]*10^(k-1),k=1..nops(L))
    end proc:
    filter:= proc(n) local r;
      if not isprime(n) then return false fi;
      r:= revdigs(n);
      isprime(r) and numtheory:-bigomega(n+2) <= 2 and numtheory:-bigomega(r+2) <= 2
    end proc:
    select(filter, [2,seq(i,i=3..2000,2)]); # Robert Israel, Jun 16 2020
  • Mathematica
    cpQ[n_]:=Module[{rev=FromDigits[Reverse[IntegerDigits[n]]]}, PrimeOmega[ n+2]<3 && PrimeQ[rev]&&PrimeOmega[rev+2]<3]; Select[Prime[ Range[ 400]], cpQ] (* Harvey P. Dale, Jul 17 2011 *)

Extensions

Corrected by Harvey P. Dale, Jul 17 2011
Previous Showing 11-20 of 71 results. Next