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.

A233439 a(n) = |{0 < k < n: prime(k)^2 + 4*prime(n-k)^2 is prime}|.

Original entry on oeis.org

0, 0, 0, 1, 2, 1, 2, 1, 3, 4, 4, 8, 4, 6, 3, 1, 7, 3, 8, 5, 2, 9, 2, 11, 8, 7, 5, 4, 8, 7, 8, 8, 8, 7, 5, 9, 5, 10, 9, 7, 13, 9, 11, 10, 14, 5, 11, 10, 10, 11, 12, 7, 13, 10, 10, 8, 15, 11, 12, 11, 13, 14, 6, 12, 11, 22, 21, 5, 15, 7, 13, 15, 17, 15, 10, 16, 11, 13, 14, 12, 17, 12, 16, 16, 19, 22, 17, 12, 19, 17, 19, 17, 16, 17, 18, 20, 19, 17, 10, 16
Offset: 1

Views

Author

Zhi-Wei Sun, Dec 09 2013

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 3.
(ii) For any integer n > 10, prime(j)^3 + 2*prime(n-j)^2 is prime for some 0 < j < n, and prime(k)^3 + 2*prime(n-k)^3 is prime for some 0 < k < n.
(iii) If n > 5, then prime(k)^3 + 2*p(n-k)^3 is prime for some 0 < k < n, where p(.) is the partition function (A000041). If n > 2, then prime(k)^3 + 2*q(n-k)^3 is prime for some 0 < k < n, where q(.) is the strict partition function (A000009).

Examples

			a(4) = 1 since prime(3)^2 + 4*prime(1)^2 = 5^2 + 4*2^2 = 41 is prime.
a(6) = 1 since prime(5)^2 + 4*prime(1)^2 = 11^2 + 4*2^2 = 137 is prime.
a(8) = 1 since prime(3)^2 + 4*prime(5)^2 = 5^2 + 4*11^2 = 509 is prime.
a(16) = 1 since prime(6)^2 + 4*prime(10)^2 = 13^2 + 4*29^2 = 3533 is prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[Prime[k]^2+4*Prime[n-k]^2],1,0],{k,1,n-1}]
    Table[a[n],{n,1,100}]