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

A235914 Odd primes p = 2*m + 1 with m*(m-1) - prime(m) and m*(m+1) - prime(m) both prime.

Original entry on oeis.org

13, 17, 23, 29, 31, 43, 73, 89, 181, 229, 313, 367, 379, 557, 631, 683, 1021, 1069, 1093, 1151, 1303, 1459, 1471, 1663, 1733, 1831, 1871, 2411, 2473, 2791, 2843, 2887, 3673, 3691, 3793, 3797, 3863, 4001, 4139, 4261, 5261, 5431, 6091, 6301, 6661, 6737, 6883, 7489, 7523, 7873
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 16 2014

Keywords

Comments

By the conjecture in A235912, this sequence should have infinitely many terms.

Examples

			a(1) = 13 since none of 1*2 - prime(1) = 0, 1*2 - prime(2) = -1, 2*3 - prime(3) = 1 and 2*4 + 1 = 9 = 4*5 - prime(5) is prime, but 2*6 + 1 = 13, 5*6 - prime(6) = 30 - 13 = 17 and 6*7 - prime(6) = 42 - 13 = 29 are all prime.
		

Crossrefs

Programs

  • Mathematica
    PQ[n_]:=n>0&&PrimeQ[n]
    q[n_]:=PQ[n(n-1)-Prime[n]]&&PQ[n(n+1)-Prime[n]]
    n=0;Do[If[q[(Prime[k]-1)/2],n=n+1;Print[n," ",Prime[k]]],{k,2,1000}]

A235917 a(n) = |{0 < k < n - 2: p = prime(k) + phi(n-k)/2, p^2 - 1 - prime(p) and (p^2 - 1)/2 - prime(p) are all prime}|, where phi(.) is Euler's totient function.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Jan 17 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 14.
(ii) For any integer n > 12, there is a positive integer k < n such that p = prime(k) + phi(n-k), (p^2 - 1)/2 - prime(p) and (p^2 - 1)/4 - prime(p) are all prime.
Clearly, part (i) of the conjecture implies that there are infinitely many primes p with p^2 - 1 - prime(p) and (p^2 - 1)/2 - prime(p) both prime.

Examples

			a(10) = 1 since prime(5) + phi(5)/2 = 11 + 2 = 13, 13^2 - 1 - prime(13) = 168 - 41 = 127 and (13^2 - 1)/2 - prime(13) = 84 - 41 = 43 are all prime.
a(71) = 1 since prime(19) + phi(52)/2 = 67 + 12 = 79, 79^2 - 1 - prime(79) = 6240 - 401 = 5839 and (79^2 - 1)/2 - prime(79) = 3120 - 401 = 2719 are all prime.
		

Crossrefs

Programs

  • Mathematica
    PQ[n_]:=n>0&&PrimeQ[n]
    p[n_]:=PrimeQ[n]&&PQ[n^2-1-Prime[n]]&&PQ[(n^2-1)/2-Prime[n]]
    f[n_,k_]:=Prime[k]+EulerPhi[n-k]/2
    a[n_]:=Sum[If[p[f[n,k]],1,0],{k,1,n-3}]
    Table[a[n],{n,1,100}]
Showing 1-2 of 2 results.