login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A218654 Number of ways to write n as x+y with 0<x<=y and x^2+3xy+y^2 prime. 12
0, 1, 1, 1, 2, 1, 2, 2, 2, 1, 4, 1, 4, 2, 4, 2, 3, 2, 6, 3, 4, 3, 6, 2, 6, 3, 4, 3, 8, 3, 8, 2, 5, 5, 8, 4, 8, 6, 5, 4, 8, 2, 10, 6, 6, 3, 11, 4, 9, 6, 9, 7, 10, 4, 14, 6, 9, 3, 11, 4, 12, 7, 9, 10, 10, 4, 11, 5, 10, 9, 15, 4, 15, 9, 9, 8, 14, 6, 12, 8, 9, 8, 18, 4, 17, 11, 9, 11, 20, 5, 14, 10, 13, 7, 16, 9, 17, 6, 16, 10 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,5

COMMENTS

Conjecture: a(n)>0 for all n=2,3,4,...

It is known that any prime p = 1 or -1 (mod 5) can be written uniquely in the form x(p)^2+3x(p)y(p)+y(p)^2 with x(p)>y(p)>0.

Zhi-Wei Sun also conjectured that

   (sum_{p<N, p=1,-1(mod 5)}x(p))

     /(sum_{p<N, p=1,-1(mod 5)}y(p))

has the limit 1+sqrt(5) as N tends to the infinity.

These conjectures are similar to the ones mentioned in the comments in A218585.

LINKS

Zhi-Wei Sun, Table of n, a(n) for n = 1..20000

Zhi-Wei Sun, Conjectures involving primes and quadratic forms, arXiv preprint arXiv:1211.1588, 2012.

EXAMPLE

For n=12 we have a(12)=1 since x^2+3x(12-x)+(12-x)^2 with 0<x<=6 is prime only when x=5.

MATHEMATICA

a[n_]:=a[n]=Sum[If[PrimeQ[x^2+3x(n-x)+(n-x)^2]==True, 1, 0], {x, 1, n/2}]; Do[Print[n, " ", a[n]], {n, 1, 20000}]

Table[Count[IntegerPartitions[n, {2}], _?(PrimeQ[#[[1]]^2+3Times@@#+ #[[2]]^2]&)], {n, 110}] (* Harvey P. Dale, Feb 28 2018 *)

PROG

(PARI) A218654(n)=sum(x=1, n\2, isprime(x^2+(2*x+n)*(n-x)))  \\ - M. F. Hasler, Nov 05 2012

CROSSREFS

Cf. A038872, A218585.

Sequence in context: A223853 A023645 A167865 * A054571 A126865 A104640

Adjacent sequences:  A218651 A218652 A218653 * A218655 A218656 A218657

KEYWORD

nonn

AUTHOR

Zhi-Wei Sun, Nov 03 2012

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 18 21:04 EST 2018. Contains 317331 sequences. (Running on oeis4.)