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.

A210480 Number of primes p

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Jan 23 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>3.
This is stronger than Goldbach's conjecture and the author's conjecture that any odd number greater than one is the sum of a prime and a practical number. Also, it implies that there are infinitely many primes p with p-1 and p+1 both practical.
The author has verified this new conjecture for n up to 10^7.

Examples

			a(1846)=1 since 1846=1289+557 with 1289 and 557 both prime, and 1288 and 1290 both practical.
a(15675)=1 since 15675=919+14756 with 919 prime, and 918, 920, 14756 all practical.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[pr[Prime[k]-1]==True&&pr[Prime[k]+1]==True&&(PrimeQ[n-Prime[k]]==True||pr[n-Prime[k]]==True),1,0],{k,1,PrimePi[n-1]}]
    Do[Print[n," ",a[n]],{n,1,100}]