:: The Inner Product of Finite Sequences and of Points of $n$-dimensional Topological Space :: by Kanchun and Yatsuka Nakamura :: :: Received February 3, 2003 :: Copyright (c) 2003-2012 Association of Mizar Users begin theorem Th1: :: EUCLID_2:1 for n, i being Nat for v being Element of n -tuples_on REAL holds (mlt (v,(0* n))) . i = 0 proofend; theorem Th2: :: EUCLID_2:2 for n being Nat for v being Element of n -tuples_on REAL holds mlt (v,(0* n)) = 0* n proofend; begin theorem Th3: :: EUCLID_2:3 for n being Nat for y1, y2 being real-valued FinSequence for x1, x2 being Element of REAL n st x1 = y1 & x2 = y2 holds |(y1,y2)| = (1 / 4) * ((|.(x1 + x2).| ^2) - (|.(x1 - x2).| ^2)) proofend; Lm1: now__::_thesis:_for_x_being_real-valued_FinSequence_holds_x_is_FinSequence_of_REAL let x be real-valued FinSequence; ::_thesis: x is FinSequence of REAL rng x c= REAL ; hence x is FinSequence of REAL by FINSEQ_1:def_4; ::_thesis: verum end; theorem Th4: :: EUCLID_2:4 for x being real-valued FinSequence holds |.x.| ^2 = |(x,x)| proofend; theorem Th5: :: EUCLID_2:5 for x being real-valued FinSequence holds |.x.| = sqrt |(x,x)| proofend; theorem Th6: :: EUCLID_2:6 for x being real-valued FinSequence holds 0 <= |.x.| proofend; theorem Th7: :: EUCLID_2:7 for x being real-valued FinSequence holds ( |(x,x)| = 0 iff x = 0* (len x) ) proofend; theorem :: EUCLID_2:8 for x being real-valued FinSequence holds ( |(x,x)| = 0 iff |.x.| = 0 ) proofend; theorem Th9: :: EUCLID_2:9 for x being real-valued FinSequence holds |(x,(0* (len x)))| = 0 proofend; theorem :: EUCLID_2:10 for x being real-valued FinSequence holds |((0* (len x)),x)| = 0 by Th9; theorem Th11: :: EUCLID_2:11 for x, y being real-valued FinSequence st len x = len y holds |.(x + y).| ^2 = ((|.x.| ^2) + (2 * |(y,x)|)) + (|.y.| ^2) proofend; theorem Th12: :: EUCLID_2:12 for x, y being real-valued FinSequence st len x = len y holds |.(x - y).| ^2 = ((|.x.| ^2) - (2 * |(y,x)|)) + (|.y.| ^2) proofend; theorem :: EUCLID_2:13 for x, y being real-valued FinSequence st len x = len y holds (|.(x + y).| ^2) + (|.(x - y).| ^2) = 2 * ((|.x.| ^2) + (|.y.| ^2)) proofend; theorem :: EUCLID_2:14 for x, y being real-valued FinSequence st len x = len y holds (|.(x + y).| ^2) - (|.(x - y).| ^2) = 4 * |(x,y)| proofend; theorem Th15: :: EUCLID_2:15 for x, y being real-valued FinSequence st len x = len y holds abs |(x,y)| <= |.x.| * |.y.| proofend; theorem Th16: :: EUCLID_2:16 for x, y being real-valued FinSequence st len x = len y holds |.(x + y).| <= |.x.| + |.y.| proofend; begin theorem :: EUCLID_2:17 for n being Nat for p1, p2 being Point of (TOP-REAL n) holds |(p1,p2)| = (1 / 4) * ((|.(p1 + p2).| ^2) - (|.(p1 - p2).| ^2)) proofend; theorem Th18: :: EUCLID_2:18 for n being Nat for p1, p2, p3 being Point of (TOP-REAL n) holds |((p1 + p2),p3)| = |(p1,p3)| + |(p2,p3)| proofend; theorem Th19: :: EUCLID_2:19 for n being Nat for p1, p2 being Point of (TOP-REAL n) for x being real number holds |((x * p1),p2)| = x * |(p1,p2)| proofend; theorem :: EUCLID_2:20 for n being Nat for p1, p2 being Point of (TOP-REAL n) for x being real number holds |(p1,(x * p2))| = x * |(p1,p2)| by Th19; theorem Th21: :: EUCLID_2:21 for n being Nat for p1, p2 being Point of (TOP-REAL n) holds |((- p1),p2)| = - |(p1,p2)| proofend; theorem :: EUCLID_2:22 for n being Nat for p1, p2 being Point of (TOP-REAL n) holds |(p1,(- p2))| = - |(p1,p2)| by Th21; theorem :: EUCLID_2:23 for n being Nat for p1, p2 being Point of (TOP-REAL n) holds |((- p1),(- p2))| = |(p1,p2)| proofend; theorem Th24: :: EUCLID_2:24 for n being Nat for p1, p2, p3 being Point of (TOP-REAL n) holds |((p1 - p2),p3)| = |(p1,p3)| - |(p2,p3)| proofend; theorem :: EUCLID_2:25 for n being Nat for x, y being real number for p1, p2, p3 being Point of (TOP-REAL n) holds |(((x * p1) + (y * p2)),p3)| = (x * |(p1,p3)|) + (y * |(p2,p3)|) proofend; theorem :: EUCLID_2:26 for n being Nat for p, q1, q2 being Point of (TOP-REAL n) holds |(p,(q1 + q2))| = |(p,q1)| + |(p,q2)| by Th18; theorem :: EUCLID_2:27 for n being Nat for p, q1, q2 being Point of (TOP-REAL n) holds |(p,(q1 - q2))| = |(p,q1)| - |(p,q2)| by Th24; theorem Th28: :: EUCLID_2:28 for n being Nat for p1, p2, q1, q2 being Point of (TOP-REAL n) holds |((p1 + p2),(q1 + q2))| = ((|(p1,q1)| + |(p1,q2)|) + |(p2,q1)|) + |(p2,q2)| proofend; theorem Th29: :: EUCLID_2:29 for n being Nat for p1, p2, q1, q2 being Point of (TOP-REAL n) holds |((p1 - p2),(q1 - q2))| = ((|(p1,q1)| - |(p1,q2)|) - |(p2,q1)|) + |(p2,q2)| proofend; theorem Th30: :: EUCLID_2:30 for n being Nat for p, q being Point of (TOP-REAL n) holds |((p + q),(p + q))| = (|(p,p)| + (2 * |(p,q)|)) + |(q,q)| proofend; theorem Th31: :: EUCLID_2:31 for n being Nat for p, q being Point of (TOP-REAL n) holds |((p - q),(p - q))| = (|(p,p)| - (2 * |(p,q)|)) + |(q,q)| proofend; theorem Th32: :: EUCLID_2:32 for n being Nat for p being Point of (TOP-REAL n) holds |(p,(0. (TOP-REAL n)))| = 0 proofend; theorem :: EUCLID_2:33 for n being Nat for p being Point of (TOP-REAL n) holds |((0. (TOP-REAL n)),p)| = 0 by Th32; theorem :: EUCLID_2:34 for n being Nat holds |((0. (TOP-REAL n)),(0. (TOP-REAL n)))| = 0 by Th32; theorem Th35: :: EUCLID_2:35 for n being Nat for p being Point of (TOP-REAL n) holds |(p,p)| >= 0 by RVSUM_1:119; theorem Th36: :: EUCLID_2:36 for n being Nat for p being Point of (TOP-REAL n) holds |(p,p)| = |.p.| ^2 by Th4; theorem Th37: :: EUCLID_2:37 for n being Nat for p being Point of (TOP-REAL n) holds |.p.| = sqrt |(p,p)| proofend; theorem Th38: :: EUCLID_2:38 for n being Nat for p being Point of (TOP-REAL n) holds 0 <= |.p.| proofend; theorem Th39: :: EUCLID_2:39 for n being Nat holds |.(0. (TOP-REAL n)).| = 0 proofend; theorem Th40: :: EUCLID_2:40 for n being Nat for p being Point of (TOP-REAL n) holds ( |(p,p)| = 0 iff |.p.| = 0 ) proofend; theorem Th41: :: EUCLID_2:41 for n being Nat for p being Point of (TOP-REAL n) holds ( |(p,p)| = 0 iff p = 0. (TOP-REAL n) ) proofend; theorem :: EUCLID_2:42 for n being Nat for p being Point of (TOP-REAL n) holds ( |.p.| = 0 iff p = 0. (TOP-REAL n) ) proofend; theorem :: EUCLID_2:43 for n being Nat for p being Point of (TOP-REAL n) holds ( p <> 0. (TOP-REAL n) iff |(p,p)| > 0 ) proofend; theorem :: EUCLID_2:44 for n being Nat for p being Point of (TOP-REAL n) holds ( p <> 0. (TOP-REAL n) iff |.p.| > 0 ) proofend; theorem Th45: :: EUCLID_2:45 for n being Nat for p, q being Point of (TOP-REAL n) holds |.(p + q).| ^2 = ((|.p.| ^2) + (2 * |(q,p)|)) + (|.q.| ^2) proofend; theorem Th46: :: EUCLID_2:46 for n being Nat for p, q being Point of (TOP-REAL n) holds |.(p - q).| ^2 = ((|.p.| ^2) - (2 * |(q,p)|)) + (|.q.| ^2) proofend; theorem :: EUCLID_2:47 for n being Nat for p, q being Point of (TOP-REAL n) holds (|.(p + q).| ^2) + (|.(p - q).| ^2) = 2 * ((|.p.| ^2) + (|.q.| ^2)) proofend; theorem :: EUCLID_2:48 for n being Nat for p, q being Point of (TOP-REAL n) holds (|.(p + q).| ^2) - (|.(p - q).| ^2) = 4 * |(p,q)| proofend; theorem :: EUCLID_2:49 for n being Nat for p, q being Point of (TOP-REAL n) holds |(p,q)| = (1 / 4) * ((|.(p + q).| ^2) - (|.(p - q).| ^2)) proofend; theorem :: EUCLID_2:50 for n being Nat for p, q being Point of (TOP-REAL n) holds |(p,q)| <= |(p,p)| + |(q,q)| proofend; theorem :: EUCLID_2:51 for n being Nat for p, q being Point of (TOP-REAL n) holds abs |(p,q)| <= |.p.| * |.q.| proofend; theorem :: EUCLID_2:52 for n being Nat for p, q being Point of (TOP-REAL n) holds |.(p + q).| <= |.p.| + |.q.| proofend; theorem Th53: :: EUCLID_2:53 for n being Nat for p being Point of (TOP-REAL n) holds p, 0. (TOP-REAL n) are_orthogonal proofend; theorem :: EUCLID_2:54 for n being Nat for p being Point of (TOP-REAL n) holds 0. (TOP-REAL n),p are_orthogonal by Th53; theorem Th55: :: EUCLID_2:55 for n being Nat for p being Point of (TOP-REAL n) holds ( p,p are_orthogonal iff p = 0. (TOP-REAL n) ) proofend; theorem Th56: :: EUCLID_2:56 for n being Nat for a being real number for p, q being Point of (TOP-REAL n) st p,q are_orthogonal holds a * p,q are_orthogonal proofend; theorem :: EUCLID_2:57 for n being Nat for a being real number for p, q being Point of (TOP-REAL n) st p,q are_orthogonal holds p,a * q are_orthogonal by Th56; theorem :: EUCLID_2:58 for n being Nat for p being Point of (TOP-REAL n) st ( for q being Point of (TOP-REAL n) holds p,q are_orthogonal ) holds p = 0. (TOP-REAL n) proofend;