Metamath Proof Explorer


Theorem cphpyth

Description: The pythagorean theorem for a subcomplex pre-Hilbert space. The square of the norm of the sum of two orthogonal vectors (i.e., whose inner product is 0) is the sum of the squares of their norms. Problem 2 in Kreyszig p. 135. This is Metamath 100 proof #4. (Contributed by NM, 17-Apr-2008) (Revised by SN, 22-Sep-2024)

Ref Expression
Hypotheses cphpyth.v V=BaseW
cphpyth.h ,˙=𝑖W
cphpyth.p +˙=+W
cphpyth.n N=normW
cphpyth.w φWCPreHil
cphpyth.a φAV
cphpyth.b φBV
Assertion cphpyth φA,˙B=0NA+˙B2=NA2+NB2

Proof

Step Hyp Ref Expression
1 cphpyth.v V=BaseW
2 cphpyth.h ,˙=𝑖W
3 cphpyth.p +˙=+W
4 cphpyth.n N=normW
5 cphpyth.w φWCPreHil
6 cphpyth.a φAV
7 cphpyth.b φBV
8 2 1 3 5 6 7 6 7 cph2di φA+˙B,˙A+˙B=A,˙A+B,˙B+A,˙B+B,˙A
9 8 adantr φA,˙B=0A+˙B,˙A+˙B=A,˙A+B,˙B+A,˙B+B,˙A
10 simpr φA,˙B=0A,˙B=0
11 2 1 cphorthcom WCPreHilAVBVA,˙B=0B,˙A=0
12 5 6 7 11 syl3anc φA,˙B=0B,˙A=0
13 12 biimpa φA,˙B=0B,˙A=0
14 10 13 oveq12d φA,˙B=0A,˙B+B,˙A=0+0
15 00id 0+0=0
16 14 15 eqtrdi φA,˙B=0A,˙B+B,˙A=0
17 16 oveq2d φA,˙B=0A,˙A+B,˙B+A,˙B+B,˙A=A,˙A+B,˙B+0
18 1 2 cphipcl WCPreHilAVAVA,˙A
19 5 6 6 18 syl3anc φA,˙A
20 1 2 cphipcl WCPreHilBVBVB,˙B
21 5 7 7 20 syl3anc φB,˙B
22 19 21 addcld φA,˙A+B,˙B
23 22 addridd φA,˙A+B,˙B+0=A,˙A+B,˙B
24 23 adantr φA,˙B=0A,˙A+B,˙B+0=A,˙A+B,˙B
25 9 17 24 3eqtrd φA,˙B=0A+˙B,˙A+˙B=A,˙A+B,˙B
26 cphngp WCPreHilWNrmGrp
27 ngpgrp WNrmGrpWGrp
28 5 26 27 3syl φWGrp
29 1 3 28 6 7 grpcld φA+˙BV
30 1 2 4 nmsq WCPreHilA+˙BVNA+˙B2=A+˙B,˙A+˙B
31 5 29 30 syl2anc φNA+˙B2=A+˙B,˙A+˙B
32 31 adantr φA,˙B=0NA+˙B2=A+˙B,˙A+˙B
33 1 2 4 nmsq WCPreHilAVNA2=A,˙A
34 5 6 33 syl2anc φNA2=A,˙A
35 1 2 4 nmsq WCPreHilBVNB2=B,˙B
36 5 7 35 syl2anc φNB2=B,˙B
37 34 36 oveq12d φNA2+NB2=A,˙A+B,˙B
38 37 adantr φA,˙B=0NA2+NB2=A,˙A+B,˙B
39 25 32 38 3eqtr4d φA,˙B=0NA+˙B2=NA2+NB2