Metamath Proof Explorer


Theorem absreimsq

Description: Square of the absolute value of a number that has been decomposed into real and imaginary parts. (Contributed by NM, 1-Feb-2007)

Ref Expression
Assertion absreimsq
|- ( ( A e. RR /\ B e. RR ) -> ( ( abs ` ( A + ( _i x. B ) ) ) ^ 2 ) = ( ( A ^ 2 ) + ( B ^ 2 ) ) )

Proof

Step Hyp Ref Expression
1 recn
 |-  ( A e. RR -> A e. CC )
2 ax-icn
 |-  _i e. CC
3 recn
 |-  ( B e. RR -> B e. CC )
4 mulcl
 |-  ( ( _i e. CC /\ B e. CC ) -> ( _i x. B ) e. CC )
5 2 3 4 sylancr
 |-  ( B e. RR -> ( _i x. B ) e. CC )
6 addcl
 |-  ( ( A e. CC /\ ( _i x. B ) e. CC ) -> ( A + ( _i x. B ) ) e. CC )
7 1 5 6 syl2an
 |-  ( ( A e. RR /\ B e. RR ) -> ( A + ( _i x. B ) ) e. CC )
8 absvalsq2
 |-  ( ( A + ( _i x. B ) ) e. CC -> ( ( abs ` ( A + ( _i x. B ) ) ) ^ 2 ) = ( ( ( Re ` ( A + ( _i x. B ) ) ) ^ 2 ) + ( ( Im ` ( A + ( _i x. B ) ) ) ^ 2 ) ) )
9 7 8 syl
 |-  ( ( A e. RR /\ B e. RR ) -> ( ( abs ` ( A + ( _i x. B ) ) ) ^ 2 ) = ( ( ( Re ` ( A + ( _i x. B ) ) ) ^ 2 ) + ( ( Im ` ( A + ( _i x. B ) ) ) ^ 2 ) ) )
10 crre
 |-  ( ( A e. RR /\ B e. RR ) -> ( Re ` ( A + ( _i x. B ) ) ) = A )
11 10 oveq1d
 |-  ( ( A e. RR /\ B e. RR ) -> ( ( Re ` ( A + ( _i x. B ) ) ) ^ 2 ) = ( A ^ 2 ) )
12 crim
 |-  ( ( A e. RR /\ B e. RR ) -> ( Im ` ( A + ( _i x. B ) ) ) = B )
13 12 oveq1d
 |-  ( ( A e. RR /\ B e. RR ) -> ( ( Im ` ( A + ( _i x. B ) ) ) ^ 2 ) = ( B ^ 2 ) )
14 11 13 oveq12d
 |-  ( ( A e. RR /\ B e. RR ) -> ( ( ( Re ` ( A + ( _i x. B ) ) ) ^ 2 ) + ( ( Im ` ( A + ( _i x. B ) ) ) ^ 2 ) ) = ( ( A ^ 2 ) + ( B ^ 2 ) ) )
15 9 14 eqtrd
 |-  ( ( A e. RR /\ B e. RR ) -> ( ( abs ` ( A + ( _i x. B ) ) ) ^ 2 ) = ( ( A ^ 2 ) + ( B ^ 2 ) ) )