Taken from problem 46 on Project Euler:

It was proposed by Christian Goldbach that every odd composite number can be written as the sum of a prime and twice a square.

$9 = 7 + 2 \times 1^2$

$15 = 7 + 2 \times 2^2$

$21 = 3 + 2 \times 3^2$


It turns out that the conjecture was false.

Now, suppose the phrase "twice a square" was replaced with "two squares." In other words, this revision of the conjecture would state that all odd composites $C$ can be written in the following form:


Where $p$ is a prime and $a$ and $b$ can take on any non-negative integer values. Making the substitution $a=b$ reduces this problem to the classical conjecture.

Now, is this weaker conjecture true?

My Attempt at the Problem:

Let $d=a^2+b^2$. A well-known theorem states that the sum of two squares can be rewritten as $2^{e_0} \left( {p_1}^{e_1}...{p_n}^{e_n} \right) \left( {q_1}^{2 o_1}...{q_n}^{2 o_n} \right)$, where $p_i$ is a prime of the form $4k+1$ and $q_i$ is a prime of the form $4k+3$. We can therefore write the conjecture as follows:


$C=p+ 2^{e_0} \left( {p_1}^{e_1}...{p_n}^{e_n} \right) \left( {q_1}^{2 o_1}...{q_n}^{2 o_n} \right)$

$C=p+ 2^{e_0}g$

Where $g$ is any integer such that $g=1 \left( \text{mod } 4 \right)$. Letting $p=2$ and $e_0=0$ shows us that the conjecture is true when $C$ is of the form $4k+3$.

From here I am not sure where to go. Any clues?


Yes, this conjecture is true. Moreover, Hua in $1938$ proved that if $n$ is odd and $n\ne 2 (\mod 3),$ then $n=p_1^2+p_2^2+p$ where $p_1$ and $p_2$ are primes. Unfortunately, all methods to prove such results are far from being elementary.

| cite | improve this answer | |
  • $\begingroup$ Do you have a link or reference to this paper? And how exactly is this conjecture proven for all composite numbers - is it through some sort of extension of Hua's method? $\endgroup$ – Ryan Sep 1 '13 at 2:54
  • 1
    $\begingroup$ The result stated here does not imply the conjectured result in the question, which refers to all odd numbers. $\endgroup$ – John Bentin Sep 1 '13 at 5:41
  • $\begingroup$ I'm wondering if leshik meant to say "This conjecture is not true"? Not quite sure. $\endgroup$ – Ryan Sep 1 '13 at 21:17
  • 1
    $\begingroup$ @Ryan The paper is "Some results in the additive prime number theory." I can't find a free link to the full text, but from a preview it appears the the result was proven for almost all $n$ satisfying the above. Regardless, this appears to neither prove nor disprove your conjecture, since it only considers the cases $n \equiv 1,3 \bmod 6$. $\endgroup$ – Jaycob Coleman Sep 3 '13 at 3:25
  • $\begingroup$ chiense?XD ~~~~~ $\endgroup$ – Snowmanzzz Sep 14 '17 at 13:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.