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-6 of 6 results.

A279419 Numbers k from A284919 such that either k-1 or k+1 is in A277688.

Original entry on oeis.org

0, 2, 4, 6, 28, 58, 62, 80, 82, 88, 112, 118, 124, 128, 148, 152, 164, 166, 178, 190, 208, 212, 214, 224, 238, 242, 248, 250, 268, 284, 290, 292, 296, 298, 308, 320, 322, 326, 328, 332, 338, 346, 358, 368, 380, 388, 392, 398, 406, 410, 418, 422, 430, 434, 440
Offset: 1

Views

Author

Vladimir Shevelev, Apr 11 2017

Keywords

Comments

We conjecture that the sequence is infinite. This sequence shows the proximity of A284919 and A277688 based on Goldbach and Lemoine-Levy representations of even and odd numbers respectively.
The differences between the positions of the corresponding terms of A284919 and A277688 are 0,0,0,1,0,2,2,1,1,1,2,3,2,2,2,2,3,1,... .
The differences between these terms are -1,-1,-1,1,-1,-1,1,1,-1,-1,-1,-1,-1,1,-1,1,1,... .

Crossrefs

Extensions

More terms from Peter J. C. Moses, Apr 11 2017

A277688 Odd numbers k such that there is no prime p < k/2 with k - 2*p and k + 2*p both prime.

Original entry on oeis.org

1, 3, 5, 19, 29, 31, 43, 49, 55, 59, 61, 71, 79, 83, 89, 91, 101, 109, 113, 115, 119, 125, 127, 131, 139, 149, 151, 155, 161, 163, 167, 169, 175, 179, 191, 193, 197, 199, 203, 209, 211, 215, 223, 227, 229, 239, 241, 247, 251, 253, 259, 265, 269, 271, 281, 283
Offset: 1

Views

Author

Vladimir Shevelev, Apr 11 2017

Keywords

Comments

Or, odd integers k such that k + 2*p is composite for all primes p, q with 2*p + q = k. By the Lemoine-Levy conjecture, for every odd k>5, there are primes p and q such that k=2*p+q. Numbers 1,3,5 formally satisfy the condition.
The sequence is an analog of A284919 for odd numbers.
Conjecture: k=59 and k=151 are the only terms k>5 satisfying the additional condition that k + 2*q is composite for every prime p,q such that 2*p+q=k.
This conjecture arose from the calculations up to 500001 by Peter J. C. Moses and confirmed by M. F. Hasler.
More than half of all odd numbers are in this sequence: for k < 2000, the percentage is below 50%, but for k < 1e4, 2e4 and 4e4 the percentage is > 55%, 56% and 58%, respectively. - M. F. Hasler, Apr 11 2017

Crossrefs

Programs

  • Mathematica
    Select[Range[1, 283, 2], Total@ Boole@ Map[Function[p, Times @@ Boole@ Map[PrimeQ, {# - 2 p, # + 2 p}] == 1], Prime@ Range@ PrimePi[#/2]] == 0 &] (* Michael De Vlieger, Apr 22 2017 *)
  • PARI
    is(k)=bittest(k,0)&&!forprime(p=2,k\2,(isprime(k-2*p)&&isprime(k+2*p))&&return) \\ M. F. Hasler, Apr 11 2017

Extensions

More terms from Peter J. C. Moses, Apr 11 2017

A284928 Numbers k such that 2k + p is composite for all primes p, q with p + q = 2k.

Original entry on oeis.org

0, 1, 2, 3, 14, 19, 26, 29, 31, 34, 37, 40, 41, 44, 47, 49, 56, 59, 61, 62, 64, 68, 73, 74, 76, 79, 82, 83, 86, 89, 91, 92, 94, 95, 103, 104, 106, 107, 109, 110, 112, 119, 121, 122, 124, 125, 128, 131, 134, 139, 142, 145, 146, 148, 149, 151, 152, 154, 158, 160, 161, 163, 164, 166, 169
Offset: 1

Views

Author

M. F. Hasler, Apr 06 2017

Keywords

Comments

Or, numbers k such that there is no prime p < 2k with 2k - p and 2k + p both prime.
The two initial terms vacuously satisfy the definition, but all even numbers >= 4 are the sum of two primes, according to the Goldbach conjecture.
See also A284919, twice this sequence, which lists the values of 2k.

Crossrefs

Cf. A284919 (twice this), A002375 (number of decompositions p + q = 2k), A020481 (least p: p + q = 2k).

Programs

  • PARI
    is_A284928(n)=!forprime(p=2,n, isprime(2*n-p) && (isprime(2*n+p) || isprime(4*n-p)) && return) \\ M. F. Hasler, Apr 06 2017

A284950 Number of primes p <= n such that 2*n-p and 2*n+p are prime.

Original entry on oeis.org

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

Views

Author

Neil Fernandez, Apr 06 2017

Keywords

Comments

If n is not divisible by 3, a(n)<=1, as the only possible p is 3. - Robert Israel, Jul 20 2020

Examples

			a(5) is 1, because of all the pairs of primes p1 <= p2 which sum to 5*2=10, namely {3,7} and {5,5}, only (3,7) has p1+10 prime.
		

Crossrefs

Programs

  • Maple
    f:= proc(n) local p1,p2,t;
      t:= 0: p1:= 2:
      do
        p1:= nextprime(p1);
        if p1 > n then return t fi;
        if isprime(p1+2*n) and isprime(2*n-p1)  then
          t:= t+1
        fi
      od
    end proc:
    map(f, [$1..1000]); # Robert Israel, Jul 20 2020
  • Mathematica
    For[i = 1, i < 1001, i++,
    ee = 2*i;
    a = 0;
    For[j = 3, j < ee/2, j += 2,
      If[PrimeQ[j] == True && PrimeQ[ee - j] == True,
       If[PrimeQ[ee + j] == True, a += 1, a = a]]];
    Print[ee, " ", a]]

Extensions

Definition corrected by Robert Israel, Jul 20 2020

A284967 Even numbers n such that for every prime p for which n-p is also prime, the number n + (odd part of p-1) is composite.

Original entry on oeis.org

0, 2, 8, 118, 868
Offset: 1

Views

Author

Vladimir Shevelev, Apr 15 2017

Keywords

Comments

Terms 0 and 2 formally satisfy the definition.
The definition is similar to A284919, where the condition "n+p is composite" is replaced by "n+odd part of p-1 is composite".
If there is a(6), it is more than 300000. - Peter J. C. Moses, Apr 15 2017

Examples

			For n=76 the suitable primes p are 3, 5, 17, 23, 53, 59, 71, 73; 76 is not in the sequence since only for p=53 n+odd part of (53-1) = 76 + 13 = 89 is prime.
For n=118 the suitable primes p are 5, 11, 17, 29, 47, 59, 71, 89, 101, 107, 113; 118 is a member since all numbers 118+odd part of (p-1) for these primes p are composite.
		

Crossrefs

Cf. A284919.

Programs

  • Mathematica
    Select[Range[0, 10^4, 2], Function[n, Times @@ Boole@ Map[CompositeQ, n + Map[NestWhile[#/2 &, #, EvenQ] &, (Select[Prime@ Range@ PrimePi@ n, PrimeQ[n - #] &] - 1)]] == 1]] (* Michael De Vlieger, Apr 22 2017 *)
  • PARI
    isok(n) = {if ((n%2)==0, forprime(p=2, n, if (isprime(n-p), if (isprime(n + (p-1)/2^valuation(p-1,2)), return (0)););); return (1););} \\ Michel Marcus, Apr 22 2017

Extensions

a(5) was calculated by Peter J. C. Moses, Apr 15 2017

A285813 Let p_1

Original entry on oeis.org

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

Views

Author

Vladimir Shevelev, Apr 27 2017

Keywords

Comments

The sequence of positions of zeros either grows very fast or is finite. We are inclined to the latter option (cf. our comments in A284919 and in A285770). By A284967, the first three positions of zeros are {4,59,434} and, according to the last calculations by Michel Marcus, no more positions up to 5*10^7.
There are many more terms in A284919 than zeros in this sequence. The reason of this phenomenon is the following. In A284919, if n is not divisible by 3 and 2*n-3 is composite then 2*n+p is composite for every prime for which 2*n-p is prime. Indeed, for these 2*n all such primes p are in the interval (3, 2*n-3). Then either 2*n-p or 2*n+p should be divisible by 3, but 2*n-p is prime >3. So, 2*n+p is composite.

Crossrefs

Programs

  • Mathematica
    Flatten@ Table[FirstPosition[#, p_ /; PrimeQ@ p] /. k_ /; MissingQ@ k -> {0} &@ Map[2 n + NestWhile[#/2 &, # - 1, EvenQ@ # &] &, Select[Prime@ Range@ PrimePi[2 n - 2], PrimeQ[2 n - #] &]], {n, 86}] (* Michael De Vlieger, Apr 27 2017, Version 10.2 *)
  • PARI
    oddp(n) = n/2^valuation(n,2);
    a(n) = {i = 0; forprime(p=2, 2*n, if (isprime(2*n-p), i++; if (isprime(2*n+oddp(p-1)), return(i)););); return(0);} \\ Michel Marcus, Apr 29 2017

Extensions

More terms from Michael De Vlieger, Apr 27 2017
Showing 1-6 of 6 results.