Metamath Proof Explorer


Theorem 2sqn0

Description: If the sum of two squares is prime, none of the original number is zero. (Contributed by Thierry Arnoux, 4-Feb-2020)

Ref Expression
Hypotheses 2sqcoprm.1 φP
2sqcoprm.2 φA
2sqcoprm.3 φB
2sqcoprm.4 φA2+B2=P
Assertion 2sqn0 φA0

Proof

Step Hyp Ref Expression
1 2sqcoprm.1 φP
2 2sqcoprm.2 φA
3 2sqcoprm.3 φB
4 2sqcoprm.4 φA2+B2=P
5 4 1 eqeltrd φA2+B2
6 5 adantr φA=0A2+B2
7 sq0i A=0A2=0
8 7 oveq1d A=0A2+B2=0+B2
9 3 zcnd φB
10 9 sqcld φB2
11 10 addlidd φ0+B2=B2
12 8 11 sylan9eqr φA=0A2+B2=B2
13 sqnprm B¬B2
14 3 13 syl φ¬B2
15 14 adantr φA=0¬B2
16 12 15 eqneltrd φA=0¬A2+B2
17 6 16 pm2.65da φ¬A=0
18 17 neqned φA0