I am to formulate the logical proposition for
Every positive integer can be written as the sum of 2 squares (domain of integers)
One of the previous questions was
Formulate the logical proposition for the sentence "The number 100 can be written as the sum of 2 squares" (domain of integers)
And my answer was $$ \exists x \exists y(x^2 + y^2 = 100)$$
So I thought to take the same approach with
Every positive integer can be written as the sum of 2 squares
And came up with
$$ \forall x \exists a \exists b (a^2 + b^2 = x)$$
But there's no where stating that $x$ is positive, so would
$$ \exists x \exists a \exists b (a^2 + b^2 = x)$$
be correct instead?
If someone could tell me where I went wrong or give me a hint I'd greatly appreciate the help, thank you very much.
Best Answer
Why would you switch from "forall" to "exists" if you wanted to specify "$x$ is positive"?
You're going to want $$(\forall x > 0)(\exists a \exists b)(a^2+b^2 = x)$$ or, if your language doesn't let you formulate that, $$(\forall x)[x > 0 \to (\exists a \exists b)(a^2+b^2 = x)]$$
As an aside, the proposition is false: $3$ cannot be written as the sum of two squares. It is necessary and sufficient that primes $3 \pmod{4}$ appear only to even powers in the prime factorisation.