:: EUCLID_6 semantic presentation begin Lm1: for p1, p2 being Point of (TOP-REAL 2) holds ( |.(p1 - p2).| = 0 iff p1 = p2 ) proof let p1, p2 be Point of (TOP-REAL 2); ::_thesis: ( |.(p1 - p2).| = 0 iff p1 = p2 ) hereby ::_thesis: ( p1 = p2 implies |.(p1 - p2).| = 0 ) assume |.(p1 - p2).| = 0 ; ::_thesis: p1 = p2 then p1 - p2 = 0. (TOP-REAL 2) by EUCLID_2:42; hence p1 = p2 by EUCLID:43; ::_thesis: verum end; assume p1 = p2 ; ::_thesis: |.(p1 - p2).| = 0 then p1 - p2 = 0. (TOP-REAL 2) by EUCLID:42; hence |.(p1 - p2).| = 0 by EUCLID_2:39; ::_thesis: verum end; Lm2: for p1, p2 being Point of (TOP-REAL 2) holds |.(p1 - p2).| = |.(p2 - p1).| proof let p1, p2 be Point of (TOP-REAL 2); ::_thesis: |.(p1 - p2).| = |.(p2 - p1).| reconsider q = p1 - p2 as Element of REAL 2 by EUCLID:22; thus |.(p1 - p2).| = |.q.| .= |.(- q).| by EUCLID:10 .= |.(- (p1 - p2)).| .= |.(p2 - p1).| by EUCLID:44 ; ::_thesis: verum end; theorem Th1: :: EUCLID_6:1 for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) st sin (angle (p1,p2,p3)) = sin (angle (p4,p5,p6)) & cos (angle (p1,p2,p3)) = cos (angle (p4,p5,p6)) holds angle (p1,p2,p3) = angle (p4,p5,p6) proof let p1, p2, p3, p4, p5, p6 be Point of (TOP-REAL 2); ::_thesis: ( sin (angle (p1,p2,p3)) = sin (angle (p4,p5,p6)) & cos (angle (p1,p2,p3)) = cos (angle (p4,p5,p6)) implies angle (p1,p2,p3) = angle (p4,p5,p6) ) A1: ( (2 * PI) * 0 <= angle (p1,p2,p3) & angle (p1,p2,p3) < (2 * PI) + ((2 * PI) * 0) ) by COMPLEX2:70; A2: ( (2 * PI) * 0 <= angle (p4,p5,p6) & angle (p4,p5,p6) < (2 * PI) + ((2 * PI) * 0) ) by COMPLEX2:70; assume ( sin (angle (p1,p2,p3)) = sin (angle (p4,p5,p6)) & cos (angle (p1,p2,p3)) = cos (angle (p4,p5,p6)) ) ; ::_thesis: angle (p1,p2,p3) = angle (p4,p5,p6) hence angle (p1,p2,p3) = angle (p4,p5,p6) by A1, A2, SIN_COS6:61; ::_thesis: verum end; theorem Th2: :: EUCLID_6:2 for p1, p2, p3 being Point of (TOP-REAL 2) holds sin (angle (p1,p2,p3)) = - (sin (angle (p3,p2,p1))) proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: sin (angle (p1,p2,p3)) = - (sin (angle (p3,p2,p1))) percases ( angle (p1,p2,p3) = 0 or angle (p1,p2,p3) <> 0 ) ; supposeA1: angle (p1,p2,p3) = 0 ; ::_thesis: sin (angle (p1,p2,p3)) = - (sin (angle (p3,p2,p1))) then angle (p3,p2,p1) = 0 by EUCLID_3:36; hence sin (angle (p1,p2,p3)) = - (sin (angle (p3,p2,p1))) by A1, SIN_COS:31; ::_thesis: verum end; suppose angle (p1,p2,p3) <> 0 ; ::_thesis: sin (angle (p1,p2,p3)) = - (sin (angle (p3,p2,p1))) then angle (p3,p2,p1) = (2 * PI) - (angle (p1,p2,p3)) by EUCLID_3:37; then sin (angle (p1,p2,p3)) = sin ((- (angle (p3,p2,p1))) + (2 * PI)) .= sin (- (angle (p3,p2,p1))) by SIN_COS:79 .= - (sin (angle (p3,p2,p1))) by SIN_COS:31 ; hence sin (angle (p1,p2,p3)) = - (sin (angle (p3,p2,p1))) ; ::_thesis: verum end; end; end; theorem Th3: :: EUCLID_6:3 for p1, p2, p3 being Point of (TOP-REAL 2) holds cos (angle (p1,p2,p3)) = cos (angle (p3,p2,p1)) proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: cos (angle (p1,p2,p3)) = cos (angle (p3,p2,p1)) percases ( angle (p1,p2,p3) = 0 or angle (p1,p2,p3) <> 0 ) ; suppose angle (p1,p2,p3) = 0 ; ::_thesis: cos (angle (p1,p2,p3)) = cos (angle (p3,p2,p1)) hence cos (angle (p1,p2,p3)) = cos (angle (p3,p2,p1)) by EUCLID_3:36; ::_thesis: verum end; suppose angle (p1,p2,p3) <> 0 ; ::_thesis: cos (angle (p1,p2,p3)) = cos (angle (p3,p2,p1)) then angle (p3,p2,p1) = (2 * PI) - (angle (p1,p2,p3)) by EUCLID_3:37; then cos (angle (p1,p2,p3)) = cos ((- (angle (p3,p2,p1))) + (2 * PI)) .= cos (- (angle (p3,p2,p1))) by SIN_COS:79 .= cos (angle (p3,p2,p1)) by SIN_COS:31 ; hence cos (angle (p1,p2,p3)) = cos (angle (p3,p2,p1)) ; ::_thesis: verum end; end; end; Lm3: for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) holds not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) + (2 * PI) proof let p1, p2, p3, p4, p5, p6 be Point of (TOP-REAL 2); ::_thesis: not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) + (2 * PI) angle (p4,p5,p6) >= 0 by COMPLEX2:70; then A1: ((angle (p4,p5,p6)) * 2) + (2 * PI) >= 0 + (2 * PI) by XREAL_1:7; assume angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) + (2 * PI) ; ::_thesis: contradiction hence contradiction by A1, COMPLEX2:70; ::_thesis: verum end; Lm4: for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) holds not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) + (4 * PI) proof let p1, p2, p3, p4, p5, p6 be Point of (TOP-REAL 2); ::_thesis: not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) + (4 * PI) angle (p4,p5,p6) >= 0 by COMPLEX2:70; then ( 4 * PI >= 2 * PI & ((angle (p4,p5,p6)) * 2) + (4 * PI) >= 0 + (4 * PI) ) by XREAL_1:7, XREAL_1:64; then A1: ((angle (p4,p5,p6)) * 2) + (4 * PI) >= 2 * PI by XXREAL_0:2; assume angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) + (4 * PI) ; ::_thesis: contradiction hence contradiction by A1, COMPLEX2:70; ::_thesis: verum end; Lm5: for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) holds not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) - (4 * PI) proof let p1, p2, p3, p4, p5, p6 be Point of (TOP-REAL 2); ::_thesis: not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) - (4 * PI) (angle (p4,p5,p6)) * 2 < (2 * PI) * 2 by COMPLEX2:70, XREAL_1:68; then A1: ((angle (p4,p5,p6)) * 2) - (4 * PI) < (4 * PI) - (4 * PI) by XREAL_1:9; assume angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) - (4 * PI) ; ::_thesis: contradiction hence contradiction by A1, COMPLEX2:70; ::_thesis: verum end; Lm6: for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) holds not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) - (6 * PI) proof let p1, p2, p3, p4, p5, p6 be Point of (TOP-REAL 2); ::_thesis: not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) - (6 * PI) (angle (p4,p5,p6)) * 2 < (2 * PI) * 2 by COMPLEX2:70, XREAL_1:68; then A1: ( PI * (- 2) <= 0 * (- 2) & ((angle (p4,p5,p6)) * 2) - (6 * PI) < (4 * PI) - (6 * PI) ) by XREAL_1:9; assume angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) - (6 * PI) ; ::_thesis: contradiction hence contradiction by A1, COMPLEX2:70; ::_thesis: verum end; Lm7: for p1, p2, p3 being Point of (TOP-REAL 2) for c1, c2 being Element of COMPLEX st c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) holds angle (p1,p2,p3) = angle (c1,c2) proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: for c1, c2 being Element of COMPLEX st c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) holds angle (p1,p2,p3) = angle (c1,c2) let c1, c2 be Element of COMPLEX ; ::_thesis: ( c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) implies angle (p1,p2,p3) = angle (c1,c2) ) assume A1: ( c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) ) ; ::_thesis: angle (p1,p2,p3) = angle (c1,c2) thus angle (p1,p2,p3) = angle ((p1 - p2),(0. (TOP-REAL 2)),(p3 - p2)) by EUCLID_3:35 .= angle (c1,c2) by A1, COMPLEX2:73, EUCLID_3:17 ; ::_thesis: verum end; Lm8: for c1, c2 being Element of COMPLEX st c2 = 0 holds Arg (Rotate (c2,(- (Arg c1)))) = 0 proof let c1, c2 be Element of COMPLEX ; ::_thesis: ( c2 = 0 implies Arg (Rotate (c2,(- (Arg c1)))) = 0 ) assume c2 = 0 ; ::_thesis: Arg (Rotate (c2,(- (Arg c1)))) = 0 then Rotate (c2,(- (Arg c1))) = 0 by COMPLEX2:52; hence Arg (Rotate (c2,(- (Arg c1)))) = 0 by COMPTRIG:def_1; ::_thesis: verum end; Lm9: for c1, c2 being Element of COMPLEX st c2 = 0 & Arg c1 = 0 holds angle (c1,c2) = 0 proof let c1, c2 be Element of COMPLEX ; ::_thesis: ( c2 = 0 & Arg c1 = 0 implies angle (c1,c2) = 0 ) assume that A1: c2 = 0 and A2: Arg c1 = 0 ; ::_thesis: angle (c1,c2) = 0 thus angle (c1,c2) = Arg (Rotate (c2,(- (Arg c1)))) by A2, COMPLEX2:def_3 .= 0 by A1, Lm8 ; ::_thesis: verum end; Lm10: for c1, c2 being Element of COMPLEX st c2 <> 0 & (Arg c2) - (Arg c1) >= 0 holds Arg (Rotate (c2,(- (Arg c1)))) = (Arg c2) - (Arg c1) proof let c1, c2 be Element of COMPLEX ; ::_thesis: ( c2 <> 0 & (Arg c2) - (Arg c1) >= 0 implies Arg (Rotate (c2,(- (Arg c1)))) = (Arg c2) - (Arg c1) ) assume that A1: c2 <> 0 and A2: (Arg c2) - (Arg c1) >= 0 ; ::_thesis: Arg (Rotate (c2,(- (Arg c1)))) = (Arg c2) - (Arg c1) set a = (- (Arg c1)) + (Arg c2); set z = Rotate (c2,(- (Arg c1))); ( Arg c2 < 2 * PI & 0 <= Arg c1 ) by COMPTRIG:34; then (Arg c2) + 0 < (2 * PI) + (Arg c1) by XREAL_1:8; then A3: ( Rotate (c2,(- (Arg c1))) = (|.c2.| * (cos ((- (Arg c1)) + (Arg c2)))) + ((|.c2.| * (sin ((- (Arg c1)) + (Arg c2)))) * ) & (Arg c2) - (Arg c1) < ((2 * PI) + (Arg c1)) - (Arg c1) ) by COMPLEX2:def_2, XREAL_1:9; A4: |.(Rotate (c2,(- (Arg c1)))).| = |.c2.| by COMPLEX2:53; then Rotate (c2,(- (Arg c1))) <> 0 by A1, COMPLEX1:44, COMPLEX1:45; hence Arg (Rotate (c2,(- (Arg c1)))) = (Arg c2) - (Arg c1) by A2, A3, A4, COMPTRIG:def_1; ::_thesis: verum end; Lm11: for c1, c2 being Element of COMPLEX st c2 <> 0 & (Arg c2) - (Arg c1) >= 0 holds angle (c1,c2) = (Arg c2) - (Arg c1) proof let c1, c2 be Element of COMPLEX ; ::_thesis: ( c2 <> 0 & (Arg c2) - (Arg c1) >= 0 implies angle (c1,c2) = (Arg c2) - (Arg c1) ) assume that A1: c2 <> 0 and A2: (Arg c2) - (Arg c1) >= 0 ; ::_thesis: angle (c1,c2) = (Arg c2) - (Arg c1) thus angle (c1,c2) = Arg (Rotate (c2,(- (Arg c1)))) by A1, COMPLEX2:def_3 .= (Arg c2) - (Arg c1) by A1, A2, Lm10 ; ::_thesis: verum end; Lm12: for c1, c2 being Element of COMPLEX st c2 <> 0 & (Arg c2) - (Arg c1) < 0 holds Arg (Rotate (c2,(- (Arg c1)))) = ((2 * PI) - (Arg c1)) + (Arg c2) proof let c1, c2 be Element of COMPLEX ; ::_thesis: ( c2 <> 0 & (Arg c2) - (Arg c1) < 0 implies Arg (Rotate (c2,(- (Arg c1)))) = ((2 * PI) - (Arg c1)) + (Arg c2) ) assume that A1: c2 <> 0 and A2: (Arg c2) - (Arg c1) < 0 ; ::_thesis: Arg (Rotate (c2,(- (Arg c1)))) = ((2 * PI) - (Arg c1)) + (Arg c2) set a = (- (Arg c1)) + (Arg c2); A3: ((- (Arg c1)) + (Arg c2)) + (2 * PI) < 0 + (2 * PI) by A2, XREAL_1:6; set z = Rotate (c2,(- (Arg c1))); Rotate (c2,(- (Arg c1))) = (|.c2.| * (cos ((- (Arg c1)) + (Arg c2)))) + ((|.c2.| * (sin ((- (Arg c1)) + (Arg c2)))) * ) by COMPLEX2:def_2; then A4: Rotate (c2,(- (Arg c1))) = (|.c2.| * (cos (((2 * PI) * 1) + ((- (Arg c1)) + (Arg c2))))) + ((|.c2.| * (sin ((- (Arg c1)) + (Arg c2)))) * ) by COMPLEX2:9 .= (|.c2.| * (cos ((2 * PI) + ((- (Arg c1)) + (Arg c2))))) + ((|.c2.| * (sin (((2 * PI) * 1) + ((- (Arg c1)) + (Arg c2))))) * ) by COMPLEX2:8 ; ( 0 <= Arg c2 & Arg c1 <= 2 * PI ) by COMPTRIG:34; then (Arg c1) + 0 <= (2 * PI) + (Arg c2) by XREAL_1:7; then A5: (Arg c1) - (Arg c1) <= ((2 * PI) + (Arg c2)) - (Arg c1) by XREAL_1:9; A6: |.(Rotate (c2,(- (Arg c1)))).| = |.c2.| by COMPLEX2:53; then Rotate (c2,(- (Arg c1))) <> 0 by A1, COMPLEX1:44, COMPLEX1:45; hence Arg (Rotate (c2,(- (Arg c1)))) = ((2 * PI) - (Arg c1)) + (Arg c2) by A4, A5, A3, A6, COMPTRIG:def_1; ::_thesis: verum end; Lm13: for c1, c2 being Element of COMPLEX st c2 <> 0 & (Arg c2) - (Arg c1) < 0 holds angle (c1,c2) = ((2 * PI) - (Arg c1)) + (Arg c2) proof let c1, c2 be Element of COMPLEX ; ::_thesis: ( c2 <> 0 & (Arg c2) - (Arg c1) < 0 implies angle (c1,c2) = ((2 * PI) - (Arg c1)) + (Arg c2) ) assume that A1: c2 <> 0 and A2: (Arg c2) - (Arg c1) < 0 ; ::_thesis: angle (c1,c2) = ((2 * PI) - (Arg c1)) + (Arg c2) thus angle (c1,c2) = Arg (Rotate (c2,(- (Arg c1)))) by A1, COMPLEX2:def_3 .= ((2 * PI) - (Arg c1)) + (Arg c2) by A1, A2, Lm12 ; ::_thesis: verum end; Lm14: for c1, c2, c3 being Element of COMPLEX holds ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) proof let c1, c2, c3 be Element of COMPLEX ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( ( c2 = 0 & c3 = 0 ) or ( c2 <> 0 & c3 = 0 ) or ( c2 = 0 & c3 <> 0 ) or ( c2 <> 0 & c3 <> 0 ) ) ; supposeA1: ( c2 = 0 & c3 = 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then A2: Arg c2 = 0 by COMPTRIG:def_1; percases ( Arg c1 = 0 or Arg c1 <> 0 ) ; suppose Arg c1 = 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = 0 + (angle (c2,c3)) by A1, Lm9; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A1, A2, Lm9; ::_thesis: verum end; supposeA3: Arg c1 <> 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = ((2 * PI) - (Arg c1)) + (angle (c2,c3)) by A1, COMPLEX2:def_3 .= ((2 * PI) - (Arg c1)) + 0 by A1, A2, Lm9 ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A1, A3, COMPLEX2:def_3; ::_thesis: verum end; end; end; supposeA4: ( c2 <> 0 & c3 = 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( ( Arg c1 = 0 & Arg c2 = 0 ) or ( Arg c1 <> 0 & Arg c2 = 0 ) or ( Arg c1 = 0 & Arg c2 <> 0 ) or ( Arg c1 <> 0 & Arg c2 <> 0 ) ) ; supposeA5: ( Arg c1 = 0 & Arg c2 = 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( (Arg c2) - (Arg c1) < 0 or (Arg c2) - (Arg c1) >= 0 ) ; suppose (Arg c2) - (Arg c1) < 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A5; ::_thesis: verum end; suppose (Arg c2) - (Arg c1) >= 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = ((Arg c2) - (Arg c1)) + (angle (c2,c3)) by A4, Lm11 .= 0 by A4, A5, Lm9 ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A4, A5, Lm9; ::_thesis: verum end; end; end; supposeA6: ( Arg c1 <> 0 & Arg c2 = 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( (Arg c2) - (Arg c1) < 0 or (Arg c2) - (Arg c1) >= 0 ) ; suppose (Arg c2) - (Arg c1) < 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = (((2 * PI) - (Arg c1)) + (Arg c2)) + (angle (c2,c3)) by A4, Lm13 .= (2 * PI) - (Arg c1) by A4, A6, Lm9 ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A4, A6, COMPLEX2:def_3; ::_thesis: verum end; suppose (Arg c2) - (Arg c1) >= 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then - (- (Arg c1)) <= - 0 by A6; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A6, COMPTRIG:34; ::_thesis: verum end; end; end; supposeA7: ( Arg c1 = 0 & Arg c2 <> 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( (Arg c2) - (Arg c1) < 0 or (Arg c2) - (Arg c1) >= 0 ) ; suppose (Arg c2) - (Arg c1) < 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A7, COMPTRIG:34; ::_thesis: verum end; supposeA8: (Arg c2) - (Arg c1) >= 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) A9: angle (c1,c3) = 0 by A4, A7, Lm9; (angle (c1,c2)) + (angle (c2,c3)) = ((Arg c2) - (Arg c1)) + (angle (c2,c3)) by A4, A8, Lm11 .= (Arg c2) + ((2 * PI) - (Arg c2)) by A4, A7, COMPLEX2:def_3 ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A9; ::_thesis: verum end; end; end; supposeA10: ( Arg c1 <> 0 & Arg c2 <> 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( (Arg c2) - (Arg c1) < 0 or (Arg c2) - (Arg c1) >= 0 ) ; supposeA11: (Arg c2) - (Arg c1) < 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) A12: angle (c1,c3) = (2 * PI) - (Arg c1) by A4, A10, COMPLEX2:def_3; (angle (c1,c2)) + (angle (c2,c3)) = (((2 * PI) - (Arg c1)) + (Arg c2)) + (angle (c2,c3)) by A4, A11, Lm13 .= (((2 * PI) - (Arg c1)) + (Arg c2)) + ((2 * PI) - (Arg c2)) by A4, A10, COMPLEX2:def_3 .= ((2 * PI) + (2 * PI)) - (Arg c1) ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A12; ::_thesis: verum end; supposeA13: (Arg c2) - (Arg c1) >= 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) A14: angle (c1,c3) = (2 * PI) - (Arg c1) by A4, A10, COMPLEX2:def_3; (angle (c1,c2)) + (angle (c2,c3)) = ((Arg c2) - (Arg c1)) + (angle (c2,c3)) by A4, A13, Lm11 .= ((Arg c2) - (Arg c1)) + ((2 * PI) - (Arg c2)) by A4, A10, COMPLEX2:def_3 ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A14; ::_thesis: verum end; end; end; end; end; supposeA15: ( c2 = 0 & c3 <> 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( ( (Arg c3) - (Arg c2) < 0 & (Arg c3) - (Arg c1) < 0 ) or ( (Arg c3) - (Arg c2) >= 0 & (Arg c3) - (Arg c1) < 0 ) or ( (Arg c3) - (Arg c2) < 0 & (Arg c3) - (Arg c1) >= 0 ) or ( (Arg c3) - (Arg c2) >= 0 & (Arg c3) - (Arg c1) >= 0 ) ) ; suppose ( (Arg c3) - (Arg c2) < 0 & (Arg c3) - (Arg c1) < 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (Arg c3) - 0 < 0 by A15, COMPTRIG:def_1; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by COMPTRIG:34; ::_thesis: verum end; supposeA16: ( (Arg c3) - (Arg c2) >= 0 & (Arg c3) - (Arg c1) < 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( Arg c1 = 0 or Arg c1 <> 0 ) ; suppose Arg c1 = 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A16, COMPTRIG:34; ::_thesis: verum end; suppose Arg c1 <> 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = ((2 * PI) - (Arg c1)) + (angle (c2,c3)) by A15, COMPLEX2:def_3 .= ((2 * PI) - (Arg c1)) + ((Arg c3) - (Arg c2)) by A15, A16, Lm11 .= ((2 * PI) - (Arg c1)) + ((Arg c3) - 0) by A15, COMPTRIG:def_1 .= ((2 * PI) - (Arg c1)) + (Arg c3) ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A15, A16, Lm13; ::_thesis: verum end; end; end; suppose ( (Arg c3) - (Arg c2) < 0 & (Arg c3) - (Arg c1) >= 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (Arg c3) - 0 < 0 by A15, COMPTRIG:def_1; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by COMPTRIG:34; ::_thesis: verum end; supposeA17: ( (Arg c3) - (Arg c2) >= 0 & (Arg c3) - (Arg c1) >= 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( Arg c1 = 0 or Arg c1 <> 0 ) ; supposeA18: Arg c1 = 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = 0 + (angle (c2,c3)) by A15, Lm9 .= 0 + ((Arg c3) - (Arg c2)) by A15, A17, Lm11 .= 0 + ((Arg c3) - 0) by A15, COMPTRIG:def_1 ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A15, A17, A18, Lm11; ::_thesis: verum end; supposeA19: Arg c1 <> 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) A20: angle (c1,c3) = (Arg c3) - (Arg c1) by A15, A17, Lm11; (angle (c1,c2)) + (angle (c2,c3)) = ((2 * PI) - (Arg c1)) + (angle (c2,c3)) by A15, A19, COMPLEX2:def_3 .= ((2 * PI) - (Arg c1)) + ((Arg c3) - (Arg c2)) by A15, A17, Lm11 .= ((2 * PI) - (Arg c1)) + ((Arg c3) - 0) by A15, COMPTRIG:def_1 ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A20; ::_thesis: verum end; end; end; end; end; supposeA21: ( c2 <> 0 & c3 <> 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( ( (Arg c3) - (Arg c2) < 0 & (Arg c3) - (Arg c1) < 0 ) or ( (Arg c3) - (Arg c2) >= 0 & (Arg c3) - (Arg c1) < 0 ) or ( (Arg c3) - (Arg c2) < 0 & (Arg c3) - (Arg c1) >= 0 ) or ( (Arg c3) - (Arg c2) >= 0 & (Arg c3) - (Arg c1) >= 0 ) ) ; supposeA22: ( (Arg c3) - (Arg c2) < 0 & (Arg c3) - (Arg c1) < 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( (Arg c2) - (Arg c1) < 0 or (Arg c2) - (Arg c1) >= 0 ) ; supposeA23: (Arg c2) - (Arg c1) < 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) A24: angle (c1,c3) = ((2 * PI) - (Arg c1)) + (Arg c3) by A21, A22, Lm13; (angle (c1,c2)) + (angle (c2,c3)) = (((2 * PI) - (Arg c1)) + (Arg c2)) + (angle (c2,c3)) by A21, A23, Lm13 .= (((2 * PI) - (Arg c1)) + (Arg c2)) + (((2 * PI) - (Arg c2)) + (Arg c3)) by A21, A22, Lm13 .= (((2 * PI) + (2 * PI)) - (Arg c1)) + (Arg c3) ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A24; ::_thesis: verum end; suppose (Arg c2) - (Arg c1) >= 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = ((Arg c2) - (Arg c1)) + (angle (c2,c3)) by A21, Lm11 .= ((Arg c2) - (Arg c1)) + (((2 * PI) - (Arg c2)) + (Arg c3)) by A21, A22, Lm13 .= ((2 * PI) - (Arg c1)) + (Arg c3) ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A21, A22, Lm13; ::_thesis: verum end; end; end; supposeA25: ( (Arg c3) - (Arg c2) >= 0 & (Arg c3) - (Arg c1) < 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( (Arg c2) - (Arg c1) < 0 or (Arg c2) - (Arg c1) >= 0 ) ; suppose (Arg c2) - (Arg c1) < 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = (((2 * PI) - (Arg c1)) + (Arg c2)) + (angle (c2,c3)) by A21, Lm13 .= (((2 * PI) - (Arg c1)) + (Arg c2)) + ((Arg c3) - (Arg c2)) by A21, A25, Lm11 .= ((2 * PI) - (Arg c1)) + (Arg c3) ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A21, A25, Lm13; ::_thesis: verum end; suppose (Arg c2) - (Arg c1) >= 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then ((Arg c2) - (Arg c1)) + ((Arg c3) - (Arg c2)) >= 0 + 0 by A25; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A25; ::_thesis: verum end; end; end; supposeA26: ( (Arg c3) - (Arg c2) < 0 & (Arg c3) - (Arg c1) >= 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( (Arg c2) - (Arg c1) < 0 or (Arg c2) - (Arg c1) >= 0 ) ; suppose (Arg c2) - (Arg c1) < 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then ((Arg c2) - (Arg c1)) + ((Arg c3) - (Arg c2)) < 0 + 0 by A26; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A26; ::_thesis: verum end; supposeA27: (Arg c2) - (Arg c1) >= 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) A28: angle (c1,c3) = (Arg c3) - (Arg c1) by A21, A26, Lm11; (angle (c1,c2)) + (angle (c2,c3)) = ((Arg c2) - (Arg c1)) + (angle (c2,c3)) by A21, A27, Lm11 .= ((Arg c2) - (Arg c1)) + (((2 * PI) - (Arg c2)) + (Arg c3)) by A21, A26, Lm13 .= ((2 * PI) - (Arg c1)) + (Arg c3) ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A28; ::_thesis: verum end; end; end; supposeA29: ( (Arg c3) - (Arg c2) >= 0 & (Arg c3) - (Arg c1) >= 0 ) ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) percases ( (Arg c2) - (Arg c1) < 0 or (Arg c2) - (Arg c1) >= 0 ) ; supposeA30: (Arg c2) - (Arg c1) < 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) A31: angle (c1,c3) = (Arg c3) - (Arg c1) by A21, A29, Lm11; (angle (c1,c2)) + (angle (c2,c3)) = (((2 * PI) - (Arg c1)) + (Arg c2)) + (angle (c2,c3)) by A21, A30, Lm13 .= (((2 * PI) + (Arg c2)) - (Arg c1)) + ((Arg c3) - (Arg c2)) by A21, A29, Lm11 .= ((2 * PI) - (Arg c1)) + (Arg c3) ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A31; ::_thesis: verum end; suppose (Arg c2) - (Arg c1) >= 0 ; ::_thesis: ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) then (angle (c1,c2)) + (angle (c2,c3)) = ((Arg c2) - (Arg c1)) + (angle (c2,c3)) by A21, Lm11 .= ((Arg c2) - (Arg c1)) + ((Arg c3) - (Arg c2)) by A21, A29, Lm11 .= (- (Arg c1)) + (Arg c3) ; hence ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by A21, A29, Lm11; ::_thesis: verum end; end; end; end; end; end; end; theorem Th4: :: EUCLID_6:4 for p1, p4, p2, p3 being Point of (TOP-REAL 2) holds ( (angle (p1,p4,p2)) + (angle (p2,p4,p3)) = angle (p1,p4,p3) or (angle (p1,p4,p2)) + (angle (p2,p4,p3)) = (angle (p1,p4,p3)) + (2 * PI) ) proof let p1, p4, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( (angle (p1,p4,p2)) + (angle (p2,p4,p3)) = angle (p1,p4,p3) or (angle (p1,p4,p2)) + (angle (p2,p4,p3)) = (angle (p1,p4,p3)) + (2 * PI) ) set c1 = euc2cpx (p1 - p4); set c2 = euc2cpx (p2 - p4); set c3 = euc2cpx (p3 - p4); A1: ( (angle ((euc2cpx (p1 - p4)),(euc2cpx (p2 - p4)))) + (angle ((euc2cpx (p2 - p4)),(euc2cpx (p3 - p4)))) = angle ((euc2cpx (p1 - p4)),(euc2cpx (p3 - p4))) or (angle ((euc2cpx (p1 - p4)),(euc2cpx (p2 - p4)))) + (angle ((euc2cpx (p2 - p4)),(euc2cpx (p3 - p4)))) = (angle ((euc2cpx (p1 - p4)),(euc2cpx (p3 - p4)))) + (2 * PI) ) by Lm14; (angle (p1,p4,p2)) + (angle (p2,p4,p3)) = (angle ((euc2cpx (p1 - p4)),(euc2cpx (p2 - p4)))) + (angle (p2,p4,p3)) by Lm7 .= (angle ((euc2cpx (p1 - p4)),(euc2cpx (p2 - p4)))) + (angle ((euc2cpx (p2 - p4)),(euc2cpx (p3 - p4)))) by Lm7 ; hence ( (angle (p1,p4,p2)) + (angle (p2,p4,p3)) = angle (p1,p4,p3) or (angle (p1,p4,p2)) + (angle (p2,p4,p3)) = (angle (p1,p4,p3)) + (2 * PI) ) by A1, Lm7; ::_thesis: verum end; Lm15: for p1, p2 being Point of (TOP-REAL 2) holds ( (p1 - p2) `1 = (p1 `1) - (p2 `1) & (p1 - p2) `2 = (p1 `2) - (p2 `2) ) proof let p1, p2 be Point of (TOP-REAL 2); ::_thesis: ( (p1 - p2) `1 = (p1 `1) - (p2 `1) & (p1 - p2) `2 = (p1 `2) - (p2 `2) ) reconsider pp = p2 as Element of REAL 2 by EUCLID:22; A1: (- p2) `1 = (- pp) . 1 .= - (pp . 1) by VALUED_1:8 .= - (p2 `1) ; A2: euc2cpx (p1 - p2) = (euc2cpx p1) - (euc2cpx p2) by EUCLID_3:15 .= (euc2cpx p1) + (- (euc2cpx p2)) .= (euc2cpx p1) + (euc2cpx (- p2)) by EUCLID_3:13 ; hence (p1 - p2) `1 = Re ((euc2cpx p1) + (euc2cpx (- p2))) by COMPLEX1:12 .= (Re (euc2cpx p1)) + (Re (euc2cpx (- p2))) by COMPLEX1:8 .= (p1 `1) + (Re (euc2cpx (- p2))) by COMPLEX1:12 .= (p1 `1) + ((- p2) `1) by COMPLEX1:12 .= (p1 `1) - (p2 `1) by A1 ; ::_thesis: (p1 - p2) `2 = (p1 `2) - (p2 `2) A3: (- p2) `2 = (- pp) . 2 .= - (pp . 2) by VALUED_1:8 .= - (p2 `2) ; thus (p1 - p2) `2 = Im ((euc2cpx p1) + (euc2cpx (- p2))) by A2, COMPLEX1:12 .= (Im (euc2cpx p1)) + (Im (euc2cpx (- p2))) by COMPLEX1:8 .= (p1 `2) + (Im (euc2cpx (- p2))) by COMPLEX1:12 .= (p1 `2) + ((- p2) `2) by COMPLEX1:12 .= (p1 `2) - (p2 `2) by A3 ; ::_thesis: verum end; Lm16: for p1, p2, p3 being Point of (TOP-REAL 2) for c1, c2 being Element of COMPLEX st c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) holds ( Re (c1 .|. c2) = (((p1 `1) - (p2 `1)) * ((p3 `1) - (p2 `1))) + (((p1 `2) - (p2 `2)) * ((p3 `2) - (p2 `2))) & Im (c1 .|. c2) = (- (((p1 `1) - (p2 `1)) * ((p3 `2) - (p2 `2)))) + (((p1 `2) - (p2 `2)) * ((p3 `1) - (p2 `1))) & |.c1.| = sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 `2) - (p2 `2)) ^2)) & |.(p1 - p2).| = |.c1.| ) proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: for c1, c2 being Element of COMPLEX st c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) holds ( Re (c1 .|. c2) = (((p1 `1) - (p2 `1)) * ((p3 `1) - (p2 `1))) + (((p1 `2) - (p2 `2)) * ((p3 `2) - (p2 `2))) & Im (c1 .|. c2) = (- (((p1 `1) - (p2 `1)) * ((p3 `2) - (p2 `2)))) + (((p1 `2) - (p2 `2)) * ((p3 `1) - (p2 `1))) & |.c1.| = sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 `2) - (p2 `2)) ^2)) & |.(p1 - p2).| = |.c1.| ) let c1, c2 be Element of COMPLEX ; ::_thesis: ( c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) implies ( Re (c1 .|. c2) = (((p1 `1) - (p2 `1)) * ((p3 `1) - (p2 `1))) + (((p1 `2) - (p2 `2)) * ((p3 `2) - (p2 `2))) & Im (c1 .|. c2) = (- (((p1 `1) - (p2 `1)) * ((p3 `2) - (p2 `2)))) + (((p1 `2) - (p2 `2)) * ((p3 `1) - (p2 `1))) & |.c1.| = sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 `2) - (p2 `2)) ^2)) & |.(p1 - p2).| = |.c1.| ) ) assume that A1: c1 = euc2cpx (p1 - p2) and A2: c2 = euc2cpx (p3 - p2) ; ::_thesis: ( Re (c1 .|. c2) = (((p1 `1) - (p2 `1)) * ((p3 `1) - (p2 `1))) + (((p1 `2) - (p2 `2)) * ((p3 `2) - (p2 `2))) & Im (c1 .|. c2) = (- (((p1 `1) - (p2 `1)) * ((p3 `2) - (p2 `2)))) + (((p1 `2) - (p2 `2)) * ((p3 `1) - (p2 `1))) & |.c1.| = sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 `2) - (p2 `2)) ^2)) & |.(p1 - p2).| = |.c1.| ) A3: Re c2 = (p3 - p2) `1 by A2, COMPLEX1:12 .= (p3 `1) - (p2 `1) by Lm15 ; A4: Im c2 = (p3 - p2) `2 by A2, COMPLEX1:12 .= (p3 `2) - (p2 `2) by Lm15 ; A5: Im c1 = (p1 - p2) `2 by A1, COMPLEX1:12 .= (p1 `2) - (p2 `2) by Lm15 ; A6: Re c1 = (p1 - p2) `1 by A1, COMPLEX1:12 .= (p1 `1) - (p2 `1) by Lm15 ; hence Re (c1 .|. c2) = (((p1 `1) - (p2 `1)) * ((p3 `1) - (p2 `1))) + (((p1 `2) - (p2 `2)) * ((p3 `2) - (p2 `2))) by A3, A5, A4, EUCLID_3:39; ::_thesis: ( Im (c1 .|. c2) = (- (((p1 `1) - (p2 `1)) * ((p3 `2) - (p2 `2)))) + (((p1 `2) - (p2 `2)) * ((p3 `1) - (p2 `1))) & |.c1.| = sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 `2) - (p2 `2)) ^2)) & |.(p1 - p2).| = |.c1.| ) thus Im (c1 .|. c2) = (- (((p1 `1) - (p2 `1)) * ((p3 `2) - (p2 `2)))) + (((p1 `2) - (p2 `2)) * ((p3 `1) - (p2 `1))) by A6, A3, A5, A4, EUCLID_3:40; ::_thesis: ( |.c1.| = sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 `2) - (p2 `2)) ^2)) & |.(p1 - p2).| = |.c1.| ) thus |.c1.| = sqrt ((((p1 - p2) `1) ^2) + ((Im c1) ^2)) by A1, COMPLEX1:12 .= sqrt ((((p1 - p2) `1) ^2) + (((p1 - p2) `2) ^2)) by A1, COMPLEX1:12 .= sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 - p2) `2) ^2)) by Lm15 .= sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 `2) - (p2 `2)) ^2)) by Lm15 ; ::_thesis: |.(p1 - p2).| = |.c1.| thus |.(p1 - p2).| = |.c1.| by A1, EUCLID_3:25; ::_thesis: verum end; definition let p1, p2, p3 be Point of (TOP-REAL 2); func the_area_of_polygon3 (p1,p2,p3) -> real number equals :: EUCLID_6:def 1 (((((p1 `1) * (p2 `2)) - ((p2 `1) * (p1 `2))) + (((p2 `1) * (p3 `2)) - ((p3 `1) * (p2 `2)))) + (((p3 `1) * (p1 `2)) - ((p1 `1) * (p3 `2)))) / 2; correctness coherence (((((p1 `1) * (p2 `2)) - ((p2 `1) * (p1 `2))) + (((p2 `1) * (p3 `2)) - ((p3 `1) * (p2 `2)))) + (((p3 `1) * (p1 `2)) - ((p1 `1) * (p3 `2)))) / 2 is real number ; ; end; :: deftheorem defines the_area_of_polygon3 EUCLID_6:def_1_:_ for p1, p2, p3 being Point of (TOP-REAL 2) holds the_area_of_polygon3 (p1,p2,p3) = (((((p1 `1) * (p2 `2)) - ((p2 `1) * (p1 `2))) + (((p2 `1) * (p3 `2)) - ((p3 `1) * (p2 `2)))) + (((p3 `1) * (p1 `2)) - ((p1 `1) * (p3 `2)))) / 2; definition let p1, p2, p3 be Point of (TOP-REAL 2); func the_perimeter_of_polygon3 (p1,p2,p3) -> real number equals :: EUCLID_6:def 2 (|.(p2 - p1).| + |.(p3 - p2).|) + |.(p1 - p3).|; correctness coherence (|.(p2 - p1).| + |.(p3 - p2).|) + |.(p1 - p3).| is real number ; ; end; :: deftheorem defines the_perimeter_of_polygon3 EUCLID_6:def_2_:_ for p1, p2, p3 being Point of (TOP-REAL 2) holds the_perimeter_of_polygon3 (p1,p2,p3) = (|.(p2 - p1).| + |.(p3 - p2).|) + |.(p1 - p3).|; theorem Th5: :: EUCLID_6:5 for p1, p2, p3 being Point of (TOP-REAL 2) holds the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 percases ( p1 = p2 or p1 <> p2 ) ; supposeA1: p1 = p2 ; ::_thesis: the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 then |.(p1 - p2).| = |.(0. (TOP-REAL 2)).| by EUCLID:42 .= 0 by EUCLID_2:39 ; hence the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 by A1; ::_thesis: verum end; supposeA2: p1 <> p2 ; ::_thesis: the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 percases ( p2 = p3 or p2 <> p3 ) ; supposeA3: p2 = p3 ; ::_thesis: the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 then |.(p3 - p2).| = |.(0. (TOP-REAL 2)).| by EUCLID:42 .= 0 by EUCLID_2:39 ; hence the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 by A3; ::_thesis: verum end; supposeA4: p2 <> p3 ; ::_thesis: the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 set b = euc2cpx (p3 - p2); set a = euc2cpx (p1 - p2); A5: now__::_thesis:_(_not_euc2cpx_(p1_-_p2)_=_0_&_not_euc2cpx_(p3_-_p2)_=_0_) assume A6: ( euc2cpx (p1 - p2) = 0 or euc2cpx (p3 - p2) = 0 ) ; ::_thesis: contradiction percases ( euc2cpx (p1 - p2) = 0 or euc2cpx (p3 - p2) = 0 ) by A6; suppose euc2cpx (p1 - p2) = 0 ; ::_thesis: contradiction hence contradiction by A2, EUCLID:43, EUCLID_3:18; ::_thesis: verum end; suppose euc2cpx (p3 - p2) = 0 ; ::_thesis: contradiction hence contradiction by A4, EUCLID:43, EUCLID_3:18; ::_thesis: verum end; end; end; A7: now__::_thesis:_not_|.(euc2cpx_(p1_-_p2)).|_*_|.(euc2cpx_(p3_-_p2)).|_=_0 assume A8: |.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).| = 0 ; ::_thesis: contradiction percases ( |.(euc2cpx (p1 - p2)).| = 0 or |.(euc2cpx (p3 - p2)).| = 0 ) by A8; suppose |.(euc2cpx (p1 - p2)).| = 0 ; ::_thesis: contradiction hence contradiction by A5, COMPLEX1:45; ::_thesis: verum end; suppose |.(euc2cpx (p3 - p2)).| = 0 ; ::_thesis: contradiction hence contradiction by A5, COMPLEX1:45; ::_thesis: verum end; end; end; ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 = ((|.(p1 - p2).| * |.(p3 - p2).|) * (- (sin (angle (p1,p2,p3))))) / 2 by Th2 .= ((|.(p1 - p2).| * |.(p3 - p2).|) * (- (sin (angle ((euc2cpx (p1 - p2)),(euc2cpx (p3 - p2))))))) / 2 by Lm7 .= ((|.(p1 - p2).| * |.(p3 - p2).|) * (- (- ((Im ((euc2cpx (p1 - p2)) .|. (euc2cpx (p3 - p2)))) / (|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|))))) / 2 by A5, COMPLEX2:69 .= ((|.(euc2cpx (p1 - p2)).| * |.(p3 - p2).|) * ((Im ((euc2cpx (p1 - p2)) .|. (euc2cpx (p3 - p2)))) / (|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|))) / 2 by Lm16 .= ((|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|) * ((Im ((euc2cpx (p1 - p2)) .|. (euc2cpx (p3 - p2)))) / (|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|))) / 2 by Lm16 .= ((Im ((euc2cpx (p1 - p2)) .|. (euc2cpx (p3 - p2)))) / ((|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|) / (|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|))) / 2 by XCMPLX_1:81 .= ((Im ((euc2cpx (p1 - p2)) .|. (euc2cpx (p3 - p2)))) / 1) / 2 by A7, XCMPLX_1:60 .= ((- (((p1 `1) - (p2 `1)) * ((p3 `2) - (p2 `2)))) + (((p1 `2) - (p2 `2)) * ((p3 `1) - (p2 `1)))) / 2 by Lm16 .= (((((p1 `1) * (p2 `2)) - ((p2 `1) * (p1 `2))) + (((p2 `1) * (p3 `2)) - ((p3 `1) * (p2 `2)))) + (((p3 `1) * (p1 `2)) - ((p1 `1) * (p3 `2)))) / 2 ; hence the_area_of_polygon3 (p1,p2,p3) = ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 ; ::_thesis: verum end; end; end; end; end; theorem Th6: :: EUCLID_6:6 for p2, p1, p3 being Point of (TOP-REAL 2) st p2 <> p1 holds |.(p3 - p2).| * (sin (angle (p3,p2,p1))) = |.(p3 - p1).| * (sin (angle (p2,p1,p3))) proof let p2, p1, p3 be Point of (TOP-REAL 2); ::_thesis: ( p2 <> p1 implies |.(p3 - p2).| * (sin (angle (p3,p2,p1))) = |.(p3 - p1).| * (sin (angle (p2,p1,p3))) ) the_area_of_polygon3 (p1,p2,p3) = the_area_of_polygon3 (p3,p1,p2) ; then ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 = the_area_of_polygon3 (p3,p1,p2) by Th5; then ((|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1)))) / 2 = ((|.(p3 - p1).| * |.(p2 - p1).|) * (sin (angle (p2,p1,p3)))) / 2 by Th5; then (|.(p1 - p2).| * |.(p3 - p2).|) * (sin (angle (p3,p2,p1))) = (|.(p3 - p1).| * |.(p1 - p2).|) * (sin (angle (p2,p1,p3))) by Lm2; then A1: (|.(p3 - p2).| * (sin (angle (p3,p2,p1)))) * |.(p1 - p2).| = (|.(p3 - p1).| * (sin (angle (p2,p1,p3)))) * |.(p1 - p2).| ; assume p2 <> p1 ; ::_thesis: |.(p3 - p2).| * (sin (angle (p3,p2,p1))) = |.(p3 - p1).| * (sin (angle (p2,p1,p3))) then |.(p1 - p2).| <> 0 by Lm1; hence |.(p3 - p2).| * (sin (angle (p3,p2,p1))) = |.(p3 - p1).| * (sin (angle (p2,p1,p3))) by A1, XCMPLX_1:5; ::_thesis: verum end; theorem Th7: :: EUCLID_6:7 for p1, p2, p3 being Point of (TOP-REAL 2) for a, b, c being real number st a = |.(p1 - p2).| & b = |.(p3 - p2).| & c = |.(p3 - p1).| holds c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: for a, b, c being real number st a = |.(p1 - p2).| & b = |.(p3 - p2).| & c = |.(p3 - p1).| holds c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) let a, b, c be real number ; ::_thesis: ( a = |.(p1 - p2).| & b = |.(p3 - p2).| & c = |.(p3 - p1).| implies c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) ) assume that A1: ( a = |.(p1 - p2).| & b = |.(p3 - p2).| ) and A2: c = |.(p3 - p1).| ; ::_thesis: c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) percases ( p1 = p2 or p1 <> p2 ) ; supposeA3: p1 = p2 ; ::_thesis: c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) then |.(p1 - p2).| = |.(0. (TOP-REAL 2)).| by EUCLID:42 .= 0 by EUCLID_2:39 ; hence c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) by A1, A2, A3; ::_thesis: verum end; supposeA4: p1 <> p2 ; ::_thesis: c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) percases ( p2 = p3 or p2 <> p3 ) ; supposeA5: p2 = p3 ; ::_thesis: c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) then |.(p3 - p2).| = |.(0. (TOP-REAL 2)).| by EUCLID:42 .= 0 by EUCLID_2:39 ; then ((|.(p1 - p2).| ^2) + (|.(p3 - p2).| ^2)) - (((2 * |.(p1 - p2).|) * |.(p3 - p2).|) * (cos (angle (p1,p2,p3)))) = |.(- (p1 - p2)).| ^2 by EUCLID:71 .= |.(p2 - p1).| ^2 by EUCLID:44 ; hence c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) by A1, A2, A5; ::_thesis: verum end; supposeA6: p2 <> p3 ; ::_thesis: c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) set c2 = euc2cpx (p3 - p2); set c1 = euc2cpx (p1 - p2); A7: now__::_thesis:_(_not_euc2cpx_(p1_-_p2)_=_0_&_not_euc2cpx_(p3_-_p2)_=_0_) assume A8: ( euc2cpx (p1 - p2) = 0 or euc2cpx (p3 - p2) = 0 ) ; ::_thesis: contradiction percases ( euc2cpx (p1 - p2) = 0 or euc2cpx (p3 - p2) = 0 ) by A8; suppose euc2cpx (p1 - p2) = 0 ; ::_thesis: contradiction hence contradiction by A4, EUCLID:43, EUCLID_3:18; ::_thesis: verum end; suppose euc2cpx (p3 - p2) = 0 ; ::_thesis: contradiction hence contradiction by A6, EUCLID:43, EUCLID_3:18; ::_thesis: verum end; end; end; A9: now__::_thesis:_not_|.(euc2cpx_(p1_-_p2)).|_*_|.(euc2cpx_(p3_-_p2)).|_=_0 assume A10: |.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).| = 0 ; ::_thesis: contradiction percases ( |.(euc2cpx (p1 - p2)).| = 0 or |.(euc2cpx (p3 - p2)).| = 0 ) by A10; suppose |.(euc2cpx (p1 - p2)).| = 0 ; ::_thesis: contradiction hence contradiction by A7, COMPLEX1:45; ::_thesis: verum end; suppose |.(euc2cpx (p3 - p2)).| = 0 ; ::_thesis: contradiction hence contradiction by A7, COMPLEX1:45; ::_thesis: verum end; end; end; A11: ((a ^2) + (b ^2)) - (c ^2) = ((((|.p1.| ^2) - (2 * |(p2,p1)|)) + (|.p2.| ^2)) + (|.(p3 - p2).| ^2)) - (|.(p3 - p1).| ^2) by A1, A2, EUCLID_2:46 .= ((((|.p1.| ^2) - (2 * |(p2,p1)|)) + (|.p2.| ^2)) + (|.(p3 - p2).| ^2)) - (((|.p3.| ^2) - (2 * |(p1,p3)|)) + (|.p1.| ^2)) by EUCLID_2:46 .= ((((- (2 * |(p2,p1)|)) + (|.p2.| ^2)) + (|.(p3 - p2).| ^2)) - (|.p3.| ^2)) + (2 * |(p1,p3)|) .= ((((- (2 * |(p2,p1)|)) + (|.p2.| ^2)) + (((|.p3.| ^2) - (2 * |(p2,p3)|)) + (|.p2.| ^2))) - (|.p3.| ^2)) + (2 * |(p1,p3)|) by EUCLID_2:46 .= 2 * ((((- |(p2,p1)|) + (|.p2.| ^2)) - |(p2,p3)|) + |(p1,p3)|) ; (|.(p1 - p2).| * |.(p3 - p2).|) * (cos (angle (p1,p2,p3))) = (|.(p1 - p2).| * |.(p3 - p2).|) * (cos (angle ((euc2cpx (p1 - p2)),(euc2cpx (p3 - p2))))) by Lm7 .= (|.(euc2cpx (p1 - p2)).| * |.(p3 - p2).|) * (cos (angle ((euc2cpx (p1 - p2)),(euc2cpx (p3 - p2))))) by Lm16 .= (|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|) * (cos (angle ((euc2cpx (p1 - p2)),(euc2cpx (p3 - p2))))) by Lm16 .= (|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|) * ((Re ((euc2cpx (p1 - p2)) .|. (euc2cpx (p3 - p2)))) / (|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|)) by A7, COMPLEX2:69 .= (Re ((euc2cpx (p1 - p2)) .|. (euc2cpx (p3 - p2)))) / ((|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|) / (|.(euc2cpx (p1 - p2)).| * |.(euc2cpx (p3 - p2)).|)) by XCMPLX_1:81 .= (Re ((euc2cpx (p1 - p2)) .|. (euc2cpx (p3 - p2)))) / 1 by A9, XCMPLX_1:60 .= (((p1 `1) - (p2 `1)) * ((p3 `1) - (p2 `1))) + (((p1 `2) - (p2 `2)) * ((p3 `2) - (p2 `2))) by Lm16 .= ((((((p1 `1) * (p3 `1)) + ((p1 `2) * (p3 `2))) - ((p1 `1) * (p2 `1))) - ((p2 `1) * (p3 `1))) + ((p2 `1) * (p2 `1))) + (((- ((p1 `2) * (p2 `2))) - ((p2 `2) * (p3 `2))) + ((p2 `2) * (p2 `2))) .= (((|(p1,p3)| - ((p1 `1) * (p2 `1))) - ((p2 `1) * (p3 `1))) + ((p2 `1) * (p2 `1))) + (((- ((p1 `2) * (p2 `2))) - ((p2 `2) * (p3 `2))) + ((p2 `2) * (p2 `2))) by EUCLID_3:41 .= (((|(p1,p3)| - (((p1 `1) * (p2 `1)) + ((p1 `2) * (p2 `2)))) - ((p2 `1) * (p3 `1))) + ((p2 `1) * (p2 `1))) + ((- ((p2 `2) * (p3 `2))) + ((p2 `2) * (p2 `2))) .= (((|(p1,p3)| - |(p1,p2)|) - ((p2 `1) * (p3 `1))) + ((p2 `1) * (p2 `1))) + ((- ((p2 `2) * (p3 `2))) + ((p2 `2) * (p2 `2))) by EUCLID_3:41 .= (((|(p1,p3)| - |(p1,p2)|) - (((p2 `1) * (p3 `1)) + ((p2 `2) * (p3 `2)))) + ((p2 `1) * (p2 `1))) + ((p2 `2) * (p2 `2)) .= (((|(p1,p3)| - |(p1,p2)|) - |(p2,p3)|) + ((p2 `1) * (p2 `1))) + ((p2 `2) * (p2 `2)) by EUCLID_3:41 .= ((|(p1,p3)| - |(p1,p2)|) - |(p2,p3)|) + (((p2 `1) * (p2 `1)) + ((p2 `2) * (p2 `2))) .= ((|(p1,p3)| - |(p1,p2)|) - |(p2,p3)|) + |(p2,p2)| by EUCLID_3:41 .= ((|(p1,p3)| - |(p1,p2)|) - |(p2,p3)|) + (|.p2.| ^2) by EUCLID_2:36 ; hence c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) by A1, A11; ::_thesis: verum end; end; end; end; end; begin theorem Th8: :: EUCLID_6:8 for p, p1, p2 being Point of (TOP-REAL 2) st p in LSeg (p1,p2) & p <> p1 & p <> p2 holds angle (p1,p,p2) = PI proof let p, p1, p2 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p2) & p <> p1 & p <> p2 implies angle (p1,p,p2) = PI ) set c1 = euc2cpx (p1 - p); set c2 = euc2cpx (p2 - p); assume p in LSeg (p1,p2) ; ::_thesis: ( not p <> p1 or not p <> p2 or angle (p1,p,p2) = PI ) then consider l being Real such that A1: p = ((1 - l) * p1) + (l * p2) and A2: 0 <= l and A3: l <= 1 ; A4: p2 - p = p2 - (((1 + (- l)) * p1) + (l * p2)) by A1 .= p2 - (((1 * p1) + ((- l) * p1)) + (l * p2)) by EUCLID:33 .= p2 + ((- 1) * (((1 * p1) + ((- l) * p1)) + (l * p2))) .= p2 + (((- 1) * ((1 * p1) + ((- l) * p1))) + ((- 1) * (l * p2))) by EUCLID:32 .= p2 + (((- 1) * (p1 + ((- l) * p1))) + ((- 1) * (l * p2))) by EUCLID:29 .= p2 + (((- 1) * (p1 + ((- l) * p1))) + (((- 1) * l) * p2)) by EUCLID:30 .= p2 + ((((- 1) * p1) + ((- 1) * ((- l) * p1))) + ((- l) * p2)) by EUCLID:32 .= p2 + ((((- 1) * p1) + (((- 1) * (- l)) * p1)) + ((- l) * p2)) by EUCLID:30 .= p2 + (((- 1) * p1) + ((l * p1) + ((- l) * p2))) by EUCLID:26 .= p2 + ((- p1) + ((l * p1) + ((- l) * p2))) .= ((- p1) + p2) + ((l * p1) + ((- l) * p2)) by EUCLID:26 .= ((- p1) + p2) + ((l * (- (- p1))) + ((- l) * p2)) .= ((- p1) + p2) + ((l * ((- 1) * (- p1))) + ((- l) * p2)) .= ((- p1) + p2) + (((l * (- 1)) * (- p1)) + ((- l) * p2)) by EUCLID:30 .= ((- p1) + p2) + ((- l) * ((- p1) + p2)) by EUCLID:32 .= (1 * ((- p1) + p2)) + ((- l) * ((- p1) + p2)) by EUCLID:29 .= (1 + (- l)) * ((- p1) + p2) by EUCLID:33 .= (1 - l) * ((- p1) + p2) ; assume A5: p <> p1 ; ::_thesis: ( not p <> p2 or angle (p1,p,p2) = PI ) A6: l <> 0 proof assume l = 0 ; ::_thesis: contradiction then p = (1 * p1) + (0. (TOP-REAL 2)) by A1, EUCLID:29 .= 1 * p1 by EUCLID:27 .= p1 by EUCLID:29 ; hence contradiction by A5; ::_thesis: verum end; assume A7: p <> p2 ; ::_thesis: angle (p1,p,p2) = PI l <> 1 proof assume l = 1 ; ::_thesis: contradiction then p = (0. (TOP-REAL 2)) + (1 * p2) by A1, EUCLID:29 .= 1 * p2 by EUCLID:27 .= p2 by EUCLID:29 ; hence contradiction by A7; ::_thesis: verum end; then l < 1 by A3, XXREAL_0:1; then - 1 < - l by XREAL_1:24; then A8: (- 1) + 1 < (- l) + 1 by XREAL_1:6; A9: - (euc2cpx (p2 - p)) <> 0 proof assume - (euc2cpx (p2 - p)) = 0 ; ::_thesis: contradiction then |.(p2 - p).| = 0 by COMPLEX1:44, EUCLID_3:25; then p2 - p = 0. (TOP-REAL 2) by EUCLID_2:42; hence contradiction by A7, EUCLID:43; ::_thesis: verum end; set r = - (l / (1 - l)); A10: p1 - p = p1 - (((1 + (- l)) * p1) + (l * p2)) by A1 .= p1 - (((1 * p1) + ((- l) * p1)) + (l * p2)) by EUCLID:33 .= p1 + ((- 1) * (((1 * p1) + ((- l) * p1)) + (l * p2))) .= p1 + (((- 1) * ((1 * p1) + ((- l) * p1))) + ((- 1) * (l * p2))) by EUCLID:32 .= p1 + (((- 1) * (p1 + ((- l) * p1))) + ((- 1) * (l * p2))) by EUCLID:29 .= p1 + (((- 1) * (p1 + ((- l) * p1))) + (((- 1) * l) * p2)) by EUCLID:30 .= p1 + ((((- 1) * p1) + ((- 1) * ((- l) * p1))) + ((- l) * p2)) by EUCLID:32 .= p1 + ((((- 1) * p1) + (((- 1) * (- l)) * p1)) + ((- l) * p2)) by EUCLID:30 .= p1 + (((- 1) * p1) + ((l * p1) + ((- l) * p2))) by EUCLID:26 .= p1 + ((- p1) + ((l * p1) + ((- l) * p2))) .= (p1 + (- p1)) + ((l * p1) + ((- l) * p2)) by EUCLID:26 .= (0. (TOP-REAL 2)) + ((l * p1) + ((- l) * p2)) by EUCLID:36 .= (l * p1) + ((l * (- 1)) * p2) by EUCLID:27 .= (l * p1) + (l * ((- 1) * p2)) by EUCLID:30 .= (l * p1) + (l * (- p2)) .= l * (p1 - p2) by EUCLID:32 ; cpx2euc ((euc2cpx (p2 - p)) * (- (l / (1 - l)))) = (- (l / (1 - l))) * (cpx2euc (euc2cpx (p2 - p))) by EUCLID_3:19 .= (- (l / (1 - l))) * ((1 - l) * ((- p1) + p2)) by A4, EUCLID_3:2 .= ((- (l / (1 - l))) * (1 - l)) * ((- p1) + p2) by EUCLID:30 .= (((- l) / (1 - l)) * (1 - l)) * ((- p1) + p2) by XCMPLX_1:187 .= (((1 - l) / (1 - l)) * (- l)) * ((- p1) + p2) by XCMPLX_1:75 .= (1 * (- l)) * ((- p1) + p2) by A8, XCMPLX_1:60 .= (l * (- 1)) * ((- p1) + p2) .= l * ((- 1) * ((- p1) + p2)) by EUCLID:30 .= l * (((- 1) * (- p1)) + ((- 1) * p2)) by EUCLID:32 .= l * ((- (- p1)) + ((- 1) * p2)) .= l * ((- (- p1)) + (- p2)) .= l * ((- (- p1)) + (- p2)) .= l * (p1 + (- p2)) .= cpx2euc (euc2cpx (p1 - p)) by A10, EUCLID_3:2 ; then euc2cpx (p1 - p) = (euc2cpx (p2 - p)) * (- (l / (1 - l))) by EUCLID_3:3; then A11: Arg (- (euc2cpx (p2 - p))) = Arg (euc2cpx (p1 - p)) by A2, A6, A8, COMPLEX2:28; angle ((euc2cpx (p1 - p)),(- (euc2cpx (p2 - p)))) = 0 proof percases ( (Arg (- (euc2cpx (p2 - p)))) - (Arg (euc2cpx (p1 - p))) < 0 or (Arg (- (euc2cpx (p2 - p)))) - (Arg (euc2cpx (p1 - p))) >= 0 ) ; suppose (Arg (- (euc2cpx (p2 - p)))) - (Arg (euc2cpx (p1 - p))) < 0 ; ::_thesis: angle ((euc2cpx (p1 - p)),(- (euc2cpx (p2 - p)))) = 0 hence angle ((euc2cpx (p1 - p)),(- (euc2cpx (p2 - p)))) = 0 by A11; ::_thesis: verum end; suppose (Arg (- (euc2cpx (p2 - p)))) - (Arg (euc2cpx (p1 - p))) >= 0 ; ::_thesis: angle ((euc2cpx (p1 - p)),(- (euc2cpx (p2 - p)))) = 0 hence angle ((euc2cpx (p1 - p)),(- (euc2cpx (p2 - p)))) = 0 by A11, A9, Lm11; ::_thesis: verum end; end; end; then angle ((euc2cpx (p1 - p)),(- (- (euc2cpx (p2 - p))))) = PI by A9, COMPLEX2:68; hence angle (p1,p,p2) = PI by Lm7; ::_thesis: verum end; theorem Th9: :: EUCLID_6:9 for p, p2, p3, p1 being Point of (TOP-REAL 2) st p in LSeg (p2,p3) & p <> p2 holds angle (p3,p2,p1) = angle (p,p2,p1) proof let p, p2, p3, p1 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p2,p3) & p <> p2 implies angle (p3,p2,p1) = angle (p,p2,p1) ) set c = euc2cpx (p - p2); set c1 = euc2cpx (p1 - p2); set c3 = euc2cpx (p3 - p2); assume p in LSeg (p2,p3) ; ::_thesis: ( not p <> p2 or angle (p3,p2,p1) = angle (p,p2,p1) ) then consider l being Real such that A1: p = ((1 - l) * p2) + (l * p3) and A2: 0 <= l and l <= 1 ; A3: p - p2 = (((1 + (- l)) * p2) + (l * p3)) - p2 by A1 .= (((1 * p2) + ((- l) * p2)) + (l * p3)) - p2 by EUCLID:33 .= ((p2 + ((- l) * p2)) + (l * p3)) - p2 by EUCLID:29 .= (p2 + ((- l) * p2)) + ((l * p3) + (- p2)) by EUCLID:26 .= p2 + (((- l) * p2) + ((l * p3) + (- p2))) by EUCLID:26 .= p2 + ((- p2) + (((- l) * p2) + (l * p3))) by EUCLID:26 .= (p2 + (- p2)) + (((- l) * p2) + (l * p3)) by EUCLID:26 .= (0. (TOP-REAL 2)) + (((- l) * p2) + (l * p3)) by EUCLID:36 .= ((l * (- 1)) * p2) + (l * p3) by EUCLID:27 .= (l * ((- 1) * p2)) + (l * p3) by EUCLID:30 .= (l * (- p2)) + (l * p3) .= l * (p3 - p2) by EUCLID:32 ; assume A4: p <> p2 ; ::_thesis: angle (p3,p2,p1) = angle (p,p2,p1) A5: l <> 0 proof assume l = 0 ; ::_thesis: contradiction then p = (1 * p2) + (0. (TOP-REAL 2)) by A1, EUCLID:29 .= 1 * p2 by EUCLID:27 .= p2 by EUCLID:29 ; hence contradiction by A4; ::_thesis: verum end; cpx2euc ((euc2cpx (p3 - p2)) * l) = l * (cpx2euc (euc2cpx (p3 - p2))) by EUCLID_3:19 .= l * (p3 - p2) by EUCLID_3:2 .= cpx2euc (euc2cpx (p - p2)) by A3, EUCLID_3:2 ; then euc2cpx (p - p2) = (euc2cpx (p3 - p2)) * l by EUCLID_3:3; then A6: Arg (euc2cpx (p - p2)) = Arg (euc2cpx (p3 - p2)) by A2, A5, COMPLEX2:27; angle ((euc2cpx (p3 - p2)),(euc2cpx (p1 - p2))) = angle ((euc2cpx (p - p2)),(euc2cpx (p1 - p2))) proof percases ( Arg (euc2cpx (p3 - p2)) = 0 or euc2cpx (p1 - p2) <> 0 or ( not Arg (euc2cpx (p3 - p2)) = 0 & not euc2cpx (p1 - p2) <> 0 ) ) ; supposeA7: ( Arg (euc2cpx (p3 - p2)) = 0 or euc2cpx (p1 - p2) <> 0 ) ; ::_thesis: angle ((euc2cpx (p3 - p2)),(euc2cpx (p1 - p2))) = angle ((euc2cpx (p - p2)),(euc2cpx (p1 - p2))) then angle ((euc2cpx (p3 - p2)),(euc2cpx (p1 - p2))) = Arg (Rotate ((euc2cpx (p1 - p2)),(- (Arg (euc2cpx (p3 - p2)))))) by COMPLEX2:def_3 .= angle ((euc2cpx (p - p2)),(euc2cpx (p1 - p2))) by A6, A7, COMPLEX2:def_3 ; hence angle ((euc2cpx (p3 - p2)),(euc2cpx (p1 - p2))) = angle ((euc2cpx (p - p2)),(euc2cpx (p1 - p2))) ; ::_thesis: verum end; supposeA8: ( not Arg (euc2cpx (p3 - p2)) = 0 & not euc2cpx (p1 - p2) <> 0 ) ; ::_thesis: angle ((euc2cpx (p3 - p2)),(euc2cpx (p1 - p2))) = angle ((euc2cpx (p - p2)),(euc2cpx (p1 - p2))) then angle ((euc2cpx (p3 - p2)),(euc2cpx (p1 - p2))) = (2 * PI) - (Arg (euc2cpx (p3 - p2))) by COMPLEX2:def_3 .= angle ((euc2cpx (p - p2)),(euc2cpx (p1 - p2))) by A6, A8, COMPLEX2:def_3 ; hence angle ((euc2cpx (p3 - p2)),(euc2cpx (p1 - p2))) = angle ((euc2cpx (p - p2)),(euc2cpx (p1 - p2))) ; ::_thesis: verum end; end; end; hence angle (p3,p2,p1) = angle ((euc2cpx (p - p2)),(euc2cpx (p1 - p2))) by Lm7 .= angle (p,p2,p1) by Lm7 ; ::_thesis: verum end; theorem Th10: :: EUCLID_6:10 for p, p2, p3, p1 being Point of (TOP-REAL 2) st p in LSeg (p2,p3) & p <> p2 holds angle (p1,p2,p3) = angle (p1,p2,p) proof let p, p2, p3, p1 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p2,p3) & p <> p2 implies angle (p1,p2,p3) = angle (p1,p2,p) ) assume A1: p in LSeg (p2,p3) ; ::_thesis: ( not p <> p2 or angle (p1,p2,p3) = angle (p1,p2,p) ) assume A2: p <> p2 ; ::_thesis: angle (p1,p2,p3) = angle (p1,p2,p) then A3: angle (p3,p2,p1) = angle (p,p2,p1) by A1, Th9; percases ( angle (p1,p2,p3) = 0 or angle (p1,p2,p3) <> 0 ) ; supposeA4: angle (p1,p2,p3) = 0 ; ::_thesis: angle (p1,p2,p3) = angle (p1,p2,p) then angle (p3,p2,p1) = 0 by EUCLID_3:36; then A5: angle (p,p2,p1) = 0 by A1, A2, Th9; thus angle (p1,p2,p3) = angle (p3,p2,p1) by A4, EUCLID_3:36 .= angle (p,p2,p1) by A1, A2, Th9 .= angle (p1,p2,p) by A5, EUCLID_3:36 ; ::_thesis: verum end; supposeA6: angle (p1,p2,p3) <> 0 ; ::_thesis: angle (p1,p2,p3) = angle (p1,p2,p) then A7: angle (p,p2,p1) <> 0 by A3, EUCLID_3:36; thus angle (p1,p2,p3) = (2 * PI) - (angle (p3,p2,p1)) by A6, EUCLID_3:38 .= (2 * PI) - (angle (p,p2,p1)) by A1, A2, Th9 .= angle (p1,p2,p) by A7, EUCLID_3:37 ; ::_thesis: verum end; end; end; Lm17: for p1, p2 being Point of (TOP-REAL 2) for a, b, r being real number st p1 in inside_of_circle (a,b,r) & p2 in outside_of_circle (a,b,r) holds ex p being Point of (TOP-REAL 2) st p in (LSeg (p1,p2)) /\ (circle (a,b,r)) proof let p1, p2 be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in inside_of_circle (a,b,r) & p2 in outside_of_circle (a,b,r) holds ex p being Point of (TOP-REAL 2) st p in (LSeg (p1,p2)) /\ (circle (a,b,r)) let a, b, r be real number ; ::_thesis: ( p1 in inside_of_circle (a,b,r) & p2 in outside_of_circle (a,b,r) implies ex p being Point of (TOP-REAL 2) st p in (LSeg (p1,p2)) /\ (circle (a,b,r)) ) set pc1 = p1 - |[a,b]|; set pc2 = p2 - |[a,b]|; reconsider r9 = r as Real by XREAL_0:def_1; assume p1 in inside_of_circle (a,b,r) ; ::_thesis: ( not p2 in outside_of_circle (a,b,r) or ex p being Point of (TOP-REAL 2) st p in (LSeg (p1,p2)) /\ (circle (a,b,r)) ) then p1 in { p where p is Point of (TOP-REAL 2) : |.(p - |[a,b]|).| < r } by JGRAPH_6:def_6; then A1: ex p19 being Point of (TOP-REAL 2) st ( p1 = p19 & |.(p19 - |[a,b]|).| < r ) ; assume p2 in outside_of_circle (a,b,r) ; ::_thesis: ex p being Point of (TOP-REAL 2) st p in (LSeg (p1,p2)) /\ (circle (a,b,r)) then p2 in { p where p is Point of (TOP-REAL 2) : |.(p - |[a,b]|).| > r } by JGRAPH_6:def_8; then A2: ex p29 being Point of (TOP-REAL 2) st ( p2 = p29 & |.(p29 - |[a,b]|).| > r ) ; then consider f being Function of I[01],((TOP-REAL 2) | (LSeg ((p1 - |[a,b]|),(p2 - |[a,b]|)))) such that A3: for x being Real st x in [.0,1.] holds f . x = ((1 - x) * (p1 - |[a,b]|)) + (x * (p2 - |[a,b]|)) and A4: f is being_homeomorphism and A5: f . 0 = p1 - |[a,b]| and A6: f . 1 = p2 - |[a,b]| by A1, JORDAN5A:3; reconsider g = f as Function of I[01],(TOP-REAL 2) by JORDAN6:3; 0 in the carrier of I[01] by BORSUK_1:40, XXREAL_1:1; then 0 in dom g by FUNCT_2:def_1; then A7: g /. 0 = p1 - |[a,b]| by A5, PARTFUN1:def_6; 1 in the carrier of I[01] by BORSUK_1:40, XXREAL_1:1; then 1 in dom g by FUNCT_2:def_1; then A8: g /. 1 = p2 - |[a,b]| by A6, PARTFUN1:def_6; f is continuous by A4, TOPS_2:def_5; then consider s being Point of I[01] such that A9: |.(g /. s).| = r9 by A1, A2, A7, A8, JORDAN2C:86, JORDAN6:3; A10: s in the carrier of I[01] ; s in [.0,1.] by BORSUK_1:40; then s in { s9 where s9 is Element of ExtREAL : ( 0 <= s9 & s9 <= 1 ) } by XXREAL_1:def_1; then A11: ex s9 being Element of ExtREAL st ( s = s9 & 0 <= s9 & s9 <= 1 ) ; then reconsider s = s as Real by XXREAL_0:45; set p9 = f . s; s in dom g by A10, FUNCT_2:def_1; then ( rng g c= the carrier of (TOP-REAL 2) & g . s in rng g ) by FUNCT_1:3, RELAT_1:def_19; then reconsider p9 = f . s as Point of (TOP-REAL 2) ; set p = p9 + |[a,b]|; take p9 + |[a,b]| ; ::_thesis: p9 + |[a,b]| in (LSeg (p1,p2)) /\ (circle (a,b,r)) f . s = ((1 - s) * (p1 - |[a,b]|)) + (s * (p2 - |[a,b]|)) by A3, BORSUK_1:40 .= (((1 - s) * p1) - ((1 - s) * |[a,b]|)) + (s * (p2 - |[a,b]|)) by EUCLID:49 .= (((1 - s) * p1) - ((1 - s) * |[a,b]|)) + ((s * p2) - (s * |[a,b]|)) by EUCLID:49 .= (((1 - s) * p1) + ((- (1 - s)) * |[a,b]|)) + ((s * p2) - (s * |[a,b]|)) by EUCLID:40 .= (((1 - s) * p1) + (((- 1) + s) * |[a,b]|)) + ((s * p2) - (s * |[a,b]|)) .= (((1 - s) * p1) + (((- 1) * |[a,b]|) + (s * |[a,b]|))) + ((s * p2) - (s * |[a,b]|)) by EUCLID:33 .= ((((1 - s) * p1) + ((- 1) * |[a,b]|)) + (s * |[a,b]|)) + ((s * p2) + (- (s * |[a,b]|))) by EUCLID:26 .= (((1 - s) * p1) + ((- 1) * |[a,b]|)) + ((s * |[a,b]|) + ((s * p2) + (- (s * |[a,b]|)))) by EUCLID:26 .= (((1 - s) * p1) + ((- 1) * |[a,b]|)) + (((s * |[a,b]|) + (- (s * |[a,b]|))) + (s * p2)) by EUCLID:26 .= (((1 - s) * p1) + ((- 1) * |[a,b]|)) + (((s * |[a,b]|) + ((- s) * |[a,b]|)) + (s * p2)) by EUCLID:40 .= (((1 - s) * p1) + ((- 1) * |[a,b]|)) + (((s + (- s)) * |[a,b]|) + (s * p2)) by EUCLID:33 .= (((1 - s) * p1) + ((- 1) * |[a,b]|)) + ((0. (TOP-REAL 2)) + (s * p2)) by EUCLID:29 .= (((1 - s) * p1) + ((- 1) * |[a,b]|)) + (s * p2) by EUCLID:27 .= (((1 - s) * p1) + (s * p2)) + ((- 1) * |[a,b]|) by EUCLID:26 ; then A12: p9 + |[a,b]| = ((((1 - s) * p1) + (s * p2)) + ((- 1) * |[a,b]|)) + |[a,b]| .= ((((1 - s) * p1) + (s * p2)) + (- |[a,b]|)) + |[a,b]| .= (((1 - s) * p1) + (s * p2)) + ((- |[a,b]|) + |[a,b]|) by EUCLID:26 .= (((1 - s) * p1) + (s * p2)) + (0. (TOP-REAL 2)) by EUCLID:36 .= ((1 - s) * p1) + (s * p2) by EUCLID:27 ; r = |.(p9 + (0. (TOP-REAL 2))).| by A9, EUCLID:27 .= |.(p9 + (|[a,b]| - |[a,b]|)).| by EUCLID:42 .= |.((p9 + |[a,b]|) + (- |[a,b]|)).| by EUCLID:26 .= |.((p9 + |[a,b]|) - |[a,b]|).| ; then p9 + |[a,b]| in { p99 where p99 is Point of (TOP-REAL 2) : |.(p99 - |[a,b]|).| = r } ; then A13: p9 + |[a,b]| in circle (a,b,r) by JGRAPH_6:def_5; ((1 - s) * p1) + (s * p2) in LSeg (p1,p2) by A11; hence p9 + |[a,b]| in (LSeg (p1,p2)) /\ (circle (a,b,r)) by A12, A13, XBOOLE_0:def_4; ::_thesis: verum end; theorem Th11: :: EUCLID_6:11 for p1, p, p2 being Point of (TOP-REAL 2) st angle (p1,p,p2) = PI holds p in LSeg (p1,p2) proof let p1, p, p2 be Point of (TOP-REAL 2); ::_thesis: ( angle (p1,p,p2) = PI implies p in LSeg (p1,p2) ) assume A1: angle (p1,p,p2) = PI ; ::_thesis: p in LSeg (p1,p2) set r = |.(p - p1).|; set b = p1 `2 ; set a = p1 `1 ; A2: p1 = |[(p1 `1),(p1 `2)]| by EUCLID:53; percases ( p = p1 or p = p2 or ( p <> p1 & p <> p2 ) ) ; suppose ( p = p1 or p = p2 ) ; ::_thesis: p in LSeg (p1,p2) hence p in LSeg (p1,p2) by RLTOPSP1:68; ::_thesis: verum end; supposeA3: ( p <> p1 & p <> p2 ) ; ::_thesis: p in LSeg (p1,p2) A4: |.(p2 - p1).| ^2 = ((|.(p1 - p).| ^2) + (|.(p2 - p).| ^2)) - (((2 * |.(p1 - p).|) * |.(p2 - p).|) * (- 1)) by A1, Th7, SIN_COS:77 .= (|.(p1 - p).| + |.(p2 - p).|) ^2 ; |.(p2 - p1).| > |.(p - p1).| proof assume |.(p2 - p1).| <= |.(p - p1).| ; ::_thesis: contradiction then |.(p2 - p1).| ^2 <= |.(p - p1).| ^2 by SQUARE_1:15; then (|.(p - p1).| + |.(p2 - p).|) ^2 <= |.(p - p1).| ^2 by A4, Lm2; then (((|.(p - p1).| ^2) + ((2 * |.(p - p1).|) * |.(p2 - p).|)) + (|.(p2 - p).| ^2)) - (|.(p - p1).| ^2) <= (|.(p - p1).| ^2) - (|.(p - p1).| ^2) by XREAL_1:9; then A5: ((2 * |.(p - p1).|) + |.(p2 - p).|) * |.(p2 - p).| <= 0 ; |.(p2 - p).| <> 0 by A3, Lm1; hence contradiction by A5; ::_thesis: verum end; then p2 in { p4 where p4 is Point of (TOP-REAL 2) : |.(p4 - |[(p1 `1),(p1 `2)]|).| > |.(p - p1).| } by A2; then A6: p2 in outside_of_circle ((p1 `1),(p1 `2),|.(p - p1).|) by JGRAPH_6:def_8; A7: |.(p1 - |[(p1 `1),(p1 `2)]|).| = 0 by A2, Lm1; |.(p - p1).| <> 0 by A3, Lm1; then p1 in { p4 where p4 is Point of (TOP-REAL 2) : |.(p4 - |[(p1 `1),(p1 `2)]|).| < |.(p - p1).| } by A7; then p1 in inside_of_circle ((p1 `1),(p1 `2),|.(p - p1).|) by JGRAPH_6:def_6; then consider p3 being Point of (TOP-REAL 2) such that A8: p3 in (LSeg (p1,p2)) /\ (circle ((p1 `1),(p1 `2),|.(p - p1).|)) by A6, Lm17; A9: euc2cpx p1 <> euc2cpx p2 by A1, COMPLEX2:79; A10: ( euc2cpx p <> euc2cpx p1 & euc2cpx p <> euc2cpx p2 ) by A3, EUCLID_3:4; A11: angle (p,p1,p2) = 0 proof assume angle (p,p1,p2) <> 0 ; ::_thesis: contradiction then A12: angle (p,p1,p2) > 0 by COMPLEX2:70; A13: angle (p,p1,p2) < 2 * PI by COMPLEX2:70; percases ( ((angle (p,p1,p2)) + (angle (p1,p2,p))) + (angle (p2,p,p1)) = PI or ((angle (p,p1,p2)) + (angle (p1,p2,p))) + (angle (p2,p,p1)) = 5 * PI ) by A10, A9, COMPLEX2:88; supposeA14: ((angle (p,p1,p2)) + (angle (p1,p2,p))) + (angle (p2,p,p1)) = PI ; ::_thesis: contradiction A15: angle (p1,p2,p) >= 0 by COMPLEX2:70; ((angle (p,p1,p2)) + (angle (p1,p2,p))) + PI = PI by A1, A14, COMPLEX2:82; hence contradiction by A12, A15; ::_thesis: verum end; supposeA16: ((angle (p,p1,p2)) + (angle (p1,p2,p))) + (angle (p2,p,p1)) = 5 * PI ; ::_thesis: contradiction angle (p1,p2,p) < 2 * PI by COMPLEX2:70; then A17: (angle (p,p1,p2)) + (angle (p1,p2,p)) < (2 * PI) + (2 * PI) by A13, XREAL_1:8; ((angle (p,p1,p2)) + (angle (p1,p2,p))) + PI = 5 * PI by A1, A16, COMPLEX2:82; hence contradiction by A17; ::_thesis: verum end; end; end; p3 in circle ((p1 `1),(p1 `2),|.(p - p1).|) by A8, XBOOLE_0:def_4; then p3 in { p4 where p4 is Point of (TOP-REAL 2) : |.(p4 - |[(p1 `1),(p1 `2)]|).| = |.(p - p1).| } by JGRAPH_6:def_5; then A18: ex p4 being Point of (TOP-REAL 2) st ( p3 = p4 & |.(p4 - |[(p1 `1),(p1 `2)]|).| = |.(p - p1).| ) ; then A19: |.(p3 - p1).| = |.(p - p1).| by EUCLID:53; |.(p - p1).| <> 0 by A3, Lm1; then A20: p3 <> p1 by A2, A18, Lm1; A21: p3 in LSeg (p1,p2) by A8, XBOOLE_0:def_4; |.(p3 - p).| ^2 = ((|.(p - p1).| ^2) + (|.(p3 - p1).| ^2)) - (((2 * |.(p - p1).|) * |.(p3 - p1).|) * (cos (angle (p,p1,p3)))) by Th7 .= ((|.(p - p1).| ^2) + (|.(p - p1).| ^2)) - (((2 * |.(p - p1).|) * |.(p - p1).|) * (cos 0)) by A21, A19, A20, A11, Th10 .= 0 by SIN_COS:31 ; then |.(p3 - p).| = 0 ; hence p in LSeg (p1,p2) by A21, Lm1; ::_thesis: verum end; end; end; theorem Th12: :: EUCLID_6:12 for p, p1, p3, p4 being Point of (TOP-REAL 2) st p in LSeg (p1,p3) & p in LSeg (p1,p4) & p3 <> p4 & p <> p1 & not p3 in LSeg (p1,p4) holds p4 in LSeg (p1,p3) proof let p, p1, p3, p4 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p3) & p in LSeg (p1,p4) & p3 <> p4 & p <> p1 & not p3 in LSeg (p1,p4) implies p4 in LSeg (p1,p3) ) assume p in LSeg (p1,p3) ; ::_thesis: ( not p in LSeg (p1,p4) or not p3 <> p4 or not p <> p1 or p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) then consider l1 being Real such that A1: p = ((1 - l1) * p1) + (l1 * p3) and A2: 0 <= l1 and l1 <= 1 ; assume p in LSeg (p1,p4) ; ::_thesis: ( not p3 <> p4 or not p <> p1 or p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) then consider l2 being Real such that A3: p = ((1 - l2) * p1) + (l2 * p4) and A4: 0 <= l2 and l2 <= 1 ; ((1 + (- l1)) * p1) + (l1 * p3) = ((1 + (- l2)) * p1) + (l2 * p4) by A1, A3; then ((1 * p1) + ((- l1) * p1)) + (l1 * p3) = ((1 + (- l2)) * p1) + (l2 * p4) by EUCLID:33; then ((1 * p1) + ((- l1) * p1)) + (l1 * p3) = ((1 * p1) + ((- l2) * p1)) + (l2 * p4) by EUCLID:33; then (p1 + ((- l1) * p1)) + (l1 * p3) = ((1 * p1) + ((- l2) * p1)) + (l2 * p4) by EUCLID:29; then (p1 + ((- l1) * p1)) + (l1 * p3) = (p1 + ((- l2) * p1)) + (l2 * p4) by EUCLID:29; then (- p1) + (p1 + (((- l1) * p1) + (l1 * p3))) = (- p1) + ((p1 + ((- l2) * p1)) + (l2 * p4)) by EUCLID:26; then ((- p1) + p1) + (((- l1) * p1) + (l1 * p3)) = (- p1) + ((p1 + ((- l2) * p1)) + (l2 * p4)) by EUCLID:26; then (0. (TOP-REAL 2)) + (((- l1) * p1) + (l1 * p3)) = (- p1) + ((p1 + ((- l2) * p1)) + (l2 * p4)) by EUCLID:36; then ((- l1) * p1) + (l1 * p3) = (- p1) + ((p1 + ((- l2) * p1)) + (l2 * p4)) by EUCLID:27; then ((- l1) * p1) + (l1 * p3) = (- p1) + (p1 + (((- l2) * p1) + (l2 * p4))) by EUCLID:26; then ((- l1) * p1) + (l1 * p3) = ((- p1) + p1) + (((- l2) * p1) + (l2 * p4)) by EUCLID:26; then ((- l1) * p1) + (l1 * p3) = (0. (TOP-REAL 2)) + (((- l2) * p1) + (l2 * p4)) by EUCLID:36; then A5: ((- l1) * p1) + (l1 * p3) = ((- l2) * p1) + (l2 * p4) by EUCLID:27; assume that A6: p3 <> p4 and A7: p <> p1 ; ::_thesis: ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) percases ( l1 <= l2 or l1 > l2 ) ; supposeA8: l1 <= l2 ; ::_thesis: ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) percases ( l1 < l2 or l1 = l2 ) by A8, XXREAL_0:1; supposeA9: l1 < l2 ; ::_thesis: ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) ((1 / l2) * ((- l1) * p1)) + ((1 / l2) * (l1 * p3)) = (1 / l2) * (((- l2) * p1) + (l2 * p4)) by A5, EUCLID:32; then (((1 / l2) * (- l1)) * p1) + ((1 / l2) * (l1 * p3)) = (1 / l2) * (((- l2) * p1) + (l2 * p4)) by EUCLID:30; then (((- 1) * ((1 / l2) * l1)) * p1) + (((1 / l2) * l1) * p3) = (1 / l2) * (((- l2) * p1) + (l2 * p4)) by EUCLID:30; then (((- 1) * ((l1 / l2) * 1)) * p1) + (((1 / l2) * l1) * p3) = (1 / l2) * (((- l2) * p1) + (l2 * p4)) by XCMPLX_1:75; then ((- (l1 / l2)) * p1) + (((l1 / l2) * 1) * p3) = (1 / l2) * (((- l2) * p1) + (l2 * p4)) by XCMPLX_1:75; then ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = ((1 / l2) * ((- l2) * p1)) + ((1 / l2) * (l2 * p4)) by EUCLID:32; then ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = (((1 / l2) * (- l2)) * p1) + ((1 / l2) * (l2 * p4)) by EUCLID:30; then ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = (((- 1) * ((1 / l2) * l2)) * p1) + (((1 / l2) * l2) * p4) by EUCLID:30; then ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = (((- 1) * ((l2 / l2) * 1)) * p1) + (((1 / l2) * l2) * p4) by XCMPLX_1:75; then ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = (((- 1) * (l2 / l2)) * p1) + (((l2 / l2) * 1) * p4) by XCMPLX_1:75; then ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = (((- 1) * 1) * p1) + ((l2 / l2) * p4) by A2, A9, XCMPLX_1:60; then ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = ((- 1) * p1) + (1 * p4) by A2, A9, XCMPLX_1:60; then ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = (- p1) + (1 * p4) ; then A10: ((- (l1 / l2)) * p1) + ((l1 / l2) * p3) = p4 + (- p1) by EUCLID:29; l1 / l2 < l2 / l2 by A2, A9, XREAL_1:74; then A11: l1 / l2 < 1 by A2, A9, XCMPLX_1:60; p4 = (p4 - p1) + p1 by EUCLID:48 .= (p1 + ((- (l1 / l2)) * p1)) + ((l1 / l2) * p3) by A10, EUCLID:26 .= ((1 * p1) + ((- (l1 / l2)) * p1)) + ((l1 / l2) * p3) by EUCLID:29 .= ((1 + (- (l1 / l2))) * p1) + ((l1 / l2) * p3) by EUCLID:33 .= ((1 - (l1 / l2)) * p1) + ((l1 / l2) * p3) ; hence ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) by A2, A4, A11; ::_thesis: verum end; suppose l1 = l2 ; ::_thesis: ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) then ((l1 * p1) + ((- l1) * p1)) + (l1 * p3) = (l1 * p1) + (((- l1) * p1) + (l1 * p4)) by A5, EUCLID:26; then ((l1 + (- l1)) * p1) + (l1 * p3) = (l1 * p1) + (((- l1) * p1) + (l1 * p4)) by EUCLID:33; then (0. (TOP-REAL 2)) + (l1 * p3) = (l1 * p1) + (((- l1) * p1) + (l1 * p4)) by EUCLID:29; then l1 * p3 = (l1 * p1) + (((- l1) * p1) + (l1 * p4)) by EUCLID:27; then l1 * p3 = ((l1 * p1) + ((- l1) * p1)) + (l1 * p4) by EUCLID:26; then l1 * p3 = ((l1 + (- l1)) * p1) + (l1 * p4) by EUCLID:33; then l1 * p3 = (0. (TOP-REAL 2)) + (l1 * p4) by EUCLID:29; then A12: l1 * p3 = l1 * p4 by EUCLID:27; percases ( l1 = 0 or p3 = p4 ) by A12, EUCLID:34; suppose l1 = 0 ; ::_thesis: ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) then p = p1 + (0 * p3) by A1, EUCLID:29 .= p1 + (0. (TOP-REAL 2)) by EUCLID:29 .= p1 by EUCLID:27 ; hence ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) by A7; ::_thesis: verum end; suppose p3 = p4 ; ::_thesis: ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) hence ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) by A6; ::_thesis: verum end; end; end; end; end; supposeA13: l1 > l2 ; ::_thesis: ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) ((1 / l1) * ((- l1) * p1)) + ((1 / l1) * (l1 * p3)) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) by A5, EUCLID:32; then (((1 / l1) * (- l1)) * p1) + ((1 / l1) * (l1 * p3)) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) by EUCLID:30; then (((- 1) * ((1 / l1) * l1)) * p1) + (((1 / l1) * l1) * p3) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) by EUCLID:30; then (((- 1) * ((l1 / l1) * 1)) * p1) + (((1 / l1) * l1) * p3) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) by XCMPLX_1:75; then ((- (l1 / l1)) * p1) + (((l1 / l1) * 1) * p3) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) by XCMPLX_1:75; then ((- 1) * p1) + (((l1 / l1) * 1) * p3) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) by A4, A13, XCMPLX_1:60; then (1 * p3) + ((- 1) * p1) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) by A4, A13, XCMPLX_1:60; then (1 * p3) + (- p1) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) ; then p3 + (- p1) = (1 / l1) * (((- l2) * p1) + (l2 * p4)) by EUCLID:29; then p3 - p1 = ((1 / l1) * ((- l2) * p1)) + ((1 / l1) * (l2 * p4)) by EUCLID:32; then p3 - p1 = (((1 / l1) * (- l2)) * p1) + ((1 / l1) * (l2 * p4)) by EUCLID:30; then p3 - p1 = (((- 1) * ((1 / l1) * l2)) * p1) + (((1 / l1) * l2) * p4) by EUCLID:30; then A14: p3 - p1 = (((- 1) * ((l2 / l1) * 1)) * p1) + (((1 / l1) * l2) * p4) by XCMPLX_1:75; l2 / l1 < l1 / l1 by A4, A13, XREAL_1:74; then A15: l2 / l1 < 1 by A4, A13, XCMPLX_1:60; p3 = (p3 - p1) + p1 by EUCLID:48 .= (((- (l2 / l1)) * p1) + ((l2 / l1) * p4)) + p1 by A14, XCMPLX_1:75 .= (p1 + ((- (l2 / l1)) * p1)) + ((l2 / l1) * p4) by EUCLID:26 .= ((1 * p1) + ((- (l2 / l1)) * p1)) + ((l2 / l1) * p4) by EUCLID:29 .= ((1 + (- (l2 / l1))) * p1) + ((l2 / l1) * p4) by EUCLID:33 .= ((1 - (l2 / l1)) * p1) + ((l2 / l1) * p4) ; hence ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) by A2, A4, A15; ::_thesis: verum end; end; end; theorem Th13: :: EUCLID_6:13 for p, p1, p3, p2 being Point of (TOP-REAL 2) st p in LSeg (p1,p3) & p <> p1 & p <> p3 & not (angle (p1,p,p2)) + (angle (p2,p,p3)) = PI holds (angle (p1,p,p2)) + (angle (p2,p,p3)) = 3 * PI proof let p, p1, p3, p2 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p3) & p <> p1 & p <> p3 & not (angle (p1,p,p2)) + (angle (p2,p,p3)) = PI implies (angle (p1,p,p2)) + (angle (p2,p,p3)) = 3 * PI ) assume ( p in LSeg (p1,p3) & p <> p1 & p <> p3 ) ; ::_thesis: ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = PI or (angle (p1,p,p2)) + (angle (p2,p,p3)) = 3 * PI ) then A1: angle (p1,p,p3) = PI by Th8; ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = angle (p1,p,p3) or (angle (p1,p,p2)) + (angle (p2,p,p3)) = (angle (p1,p,p3)) + (2 * PI) ) by Th4; hence ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = PI or (angle (p1,p,p2)) + (angle (p2,p,p3)) = 3 * PI ) by A1; ::_thesis: verum end; theorem Th14: :: EUCLID_6:14 for p, p1, p2, p3 being Point of (TOP-REAL 2) st p in LSeg (p1,p2) & p <> p1 & p <> p2 & ( angle (p3,p,p1) = PI / 2 or angle (p3,p,p1) = (3 / 2) * PI ) holds angle (p1,p,p3) = angle (p3,p,p2) proof let p, p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p2) & p <> p1 & p <> p2 & ( angle (p3,p,p1) = PI / 2 or angle (p3,p,p1) = (3 / 2) * PI ) implies angle (p1,p,p3) = angle (p3,p,p2) ) assume A1: ( p in LSeg (p1,p2) & p <> p1 & p <> p2 ) ; ::_thesis: ( ( not angle (p3,p,p1) = PI / 2 & not angle (p3,p,p1) = (3 / 2) * PI ) or angle (p1,p,p3) = angle (p3,p,p2) ) assume A2: ( angle (p3,p,p1) = PI / 2 or angle (p3,p,p1) = (3 / 2) * PI ) ; ::_thesis: angle (p1,p,p3) = angle (p3,p,p2) A3: angle (p3,p,p1) = angle (p2,p,p3) proof percases ( ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & angle (p3,p,p1) = PI / 2 ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & angle (p3,p,p1) = (3 / 2) * PI ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & angle (p3,p,p1) = (3 / 2) * PI ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & angle (p3,p,p1) = PI / 2 ) ) by A1, A2, Th13; suppose ( ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & angle (p3,p,p1) = PI / 2 ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & angle (p3,p,p1) = (3 / 2) * PI ) ) ; ::_thesis: angle (p3,p,p1) = angle (p2,p,p3) hence angle (p3,p,p1) = angle (p2,p,p3) ; ::_thesis: verum end; supposeA4: ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & angle (p3,p,p1) = (3 / 2) * PI ) ; ::_thesis: angle (p3,p,p1) = angle (p2,p,p3) (- PI) / 2 < 0 / 2 ; hence angle (p3,p,p1) = angle (p2,p,p3) by A4, COMPLEX2:70; ::_thesis: verum end; supposeA5: ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & angle (p3,p,p1) = PI / 2 ) ; ::_thesis: angle (p3,p,p1) = angle (p2,p,p3) 0 + (2 * PI) < (PI / 2) + (2 * PI) by XREAL_1:6; hence angle (p3,p,p1) = angle (p2,p,p3) by A5, COMPLEX2:70; ::_thesis: verum end; end; end; percases ( angle (p3,p,p1) = 0 or angle (p3,p,p1) <> 0 ) ; supposeA6: angle (p3,p,p1) = 0 ; ::_thesis: angle (p1,p,p3) = angle (p3,p,p2) then angle (p1,p,p3) = 0 by EUCLID_3:36; hence angle (p1,p,p3) = angle (p3,p,p2) by A3, A6, EUCLID_3:36; ::_thesis: verum end; supposeA7: angle (p3,p,p1) <> 0 ; ::_thesis: angle (p1,p,p3) = angle (p3,p,p2) then angle (p1,p,p3) = (2 * PI) - (angle (p3,p,p1)) by EUCLID_3:37; hence angle (p1,p,p3) = angle (p3,p,p2) by A3, A7, EUCLID_3:37; ::_thesis: verum end; end; end; theorem Th15: :: EUCLID_6:15 for p, p1, p3, p2, p4 being Point of (TOP-REAL 2) st p in LSeg (p1,p3) & p in LSeg (p2,p4) & p <> p1 & p <> p2 & p <> p3 & p <> p4 holds angle (p1,p,p2) = angle (p3,p,p4) proof let p, p1, p3, p2, p4 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p3) & p in LSeg (p2,p4) & p <> p1 & p <> p2 & p <> p3 & p <> p4 implies angle (p1,p,p2) = angle (p3,p,p4) ) assume A1: p in LSeg (p1,p3) ; ::_thesis: ( not p in LSeg (p2,p4) or not p <> p1 or not p <> p2 or not p <> p3 or not p <> p4 or angle (p1,p,p2) = angle (p3,p,p4) ) assume A2: p in LSeg (p2,p4) ; ::_thesis: ( not p <> p1 or not p <> p2 or not p <> p3 or not p <> p4 or angle (p1,p,p2) = angle (p3,p,p4) ) assume A3: p <> p1 ; ::_thesis: ( not p <> p2 or not p <> p3 or not p <> p4 or angle (p1,p,p2) = angle (p3,p,p4) ) assume A4: p <> p2 ; ::_thesis: ( not p <> p3 or not p <> p4 or angle (p1,p,p2) = angle (p3,p,p4) ) assume A5: p <> p3 ; ::_thesis: ( not p <> p4 or angle (p1,p,p2) = angle (p3,p,p4) ) assume A6: p <> p4 ; ::_thesis: angle (p1,p,p2) = angle (p3,p,p4) percases ( ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = PI & (angle (p2,p,p3)) + (angle (p3,p,p4)) = PI ) or ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = 3 * PI & (angle (p2,p,p3)) + (angle (p3,p,p4)) = PI ) or ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = PI & (angle (p2,p,p3)) + (angle (p3,p,p4)) = 3 * PI ) or ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = 3 * PI & (angle (p2,p,p3)) + (angle (p3,p,p4)) = 3 * PI ) ) by A1, A2, A3, A4, A5, A6, Th13; suppose ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = PI & (angle (p2,p,p3)) + (angle (p3,p,p4)) = PI ) ; ::_thesis: angle (p1,p,p2) = angle (p3,p,p4) hence angle (p1,p,p2) = angle (p3,p,p4) ; ::_thesis: verum end; supposeA7: ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = 3 * PI & (angle (p2,p,p3)) + (angle (p3,p,p4)) = PI ) ; ::_thesis: angle (p1,p,p2) = angle (p3,p,p4) angle (p3,p,p4) >= 0 by COMPLEX2:70; then (angle (p3,p,p4)) + (2 * PI) >= 0 + (2 * PI) by XREAL_1:6; hence angle (p1,p,p2) = angle (p3,p,p4) by A7, COMPLEX2:70; ::_thesis: verum end; supposeA8: ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = PI & (angle (p2,p,p3)) + (angle (p3,p,p4)) = 3 * PI ) ; ::_thesis: angle (p1,p,p2) = angle (p3,p,p4) angle (p3,p,p4) < 2 * PI by COMPLEX2:70; then (angle (p3,p,p4)) - (2 * PI) < (2 * PI) - (2 * PI) by XREAL_1:9; hence angle (p1,p,p2) = angle (p3,p,p4) by A8, COMPLEX2:70; ::_thesis: verum end; suppose ( (angle (p1,p,p2)) + (angle (p2,p,p3)) = 3 * PI & (angle (p2,p,p3)) + (angle (p3,p,p4)) = 3 * PI ) ; ::_thesis: angle (p1,p,p2) = angle (p3,p,p4) hence angle (p1,p,p2) = angle (p3,p,p4) ; ::_thesis: verum end; end; end; theorem Th16: :: EUCLID_6:16 for p3, p1, p2 being Point of (TOP-REAL 2) st |.(p3 - p1).| = |.(p2 - p3).| & p1 <> p2 holds angle (p3,p1,p2) = angle (p1,p2,p3) proof let p3, p1, p2 be Point of (TOP-REAL 2); ::_thesis: ( |.(p3 - p1).| = |.(p2 - p3).| & p1 <> p2 implies angle (p3,p1,p2) = angle (p1,p2,p3) ) assume A1: |.(p3 - p1).| = |.(p2 - p3).| ; ::_thesis: ( not p1 <> p2 or angle (p3,p1,p2) = angle (p1,p2,p3) ) assume A2: p1 <> p2 ; ::_thesis: angle (p3,p1,p2) = angle (p1,p2,p3) percases ( p1,p2,p3 are_mutually_different or not p1,p2,p3 are_mutually_different ) ; supposeA3: p1,p2,p3 are_mutually_different ; ::_thesis: angle (p3,p1,p2) = angle (p1,p2,p3) |.(p3 - p1).| ^2 = ((|.(p1 - p2).| ^2) + (|.(p3 - p2).| ^2)) - (((2 * |.(p1 - p2).|) * |.(p3 - p2).|) * (cos (angle (p1,p2,p3)))) by Th7; then ((|.(p1 - p2).| ^2) + (|.(p3 - p2).| ^2)) - (((2 * |.(p1 - p2).|) * |.(p3 - p2).|) * (cos (angle (p1,p2,p3)))) = ((|.(p3 - p1).| ^2) + (|.(p2 - p1).| ^2)) - (((2 * |.(p3 - p1).|) * |.(p2 - p1).|) * (cos (angle (p3,p1,p2)))) by A1, Th7; then ((|.(p3 - p2).| ^2) - (((2 * |.(p1 - p2).|) * |.(p3 - p2).|) * (cos (angle (p1,p2,p3))))) + (|.(p1 - p2).| ^2) = ((|.(p3 - p1).| ^2) - (((2 * |.(p3 - p1).|) * |.(p2 - p1).|) * (cos (angle (p3,p1,p2))))) + (|.(p2 - p1).| ^2) ; then ((|.(p3 - p2).| ^2) - (((2 * |.(p1 - p2).|) * |.(p3 - p2).|) * (cos (angle (p1,p2,p3))))) + (|.(p1 - p2).| ^2) = ((|.(p3 - p1).| ^2) - (((2 * |.(p3 - p1).|) * |.(p2 - p1).|) * (cos (angle (p3,p1,p2))))) + (|.(p1 - p2).| ^2) by Lm2; then (- (((2 * |.(p1 - p2).|) * |.(p3 - p2).|) * (cos (angle (p1,p2,p3))))) + (|.(p3 - p2).| ^2) = (- (((2 * |.(p2 - p3).|) * |.(p2 - p1).|) * (cos (angle (p3,p1,p2))))) + (|.(p2 - p3).| ^2) by A1; then (- (((2 * |.(p1 - p2).|) * |.(p3 - p2).|) * (cos (angle (p1,p2,p3))))) + (|.(p3 - p2).| ^2) = (- (((2 * |.(p2 - p3).|) * |.(p2 - p1).|) * (cos (angle (p3,p1,p2))))) + (|.(p3 - p2).| ^2) by Lm2; then (|.(p1 - p2).| * |.(p3 - p2).|) * (cos (angle (p1,p2,p3))) = (|.(p2 - p3).| * |.(p2 - p1).|) * (cos (angle (p3,p1,p2))) ; then (|.(p1 - p2).| * |.(p3 - p2).|) * (cos (angle (p1,p2,p3))) = (|.(p2 - p3).| * |.(p1 - p2).|) * (cos (angle (p3,p1,p2))) by Lm2; then A4: (|.(p3 - p2).| * (cos (angle (p1,p2,p3)))) * |.(p1 - p2).| = (|.(p2 - p3).| * (cos (angle (p3,p1,p2)))) * |.(p1 - p2).| ; p1 <> p2 by A3, ZFMISC_1:def_5; then |.(p1 - p2).| <> 0 by Lm1; then |.(p3 - p2).| * (cos (angle (p1,p2,p3))) = |.(p2 - p3).| * (cos (angle (p3,p1,p2))) by A4, XCMPLX_1:5; then A5: |.(p2 - p3).| * (cos (angle (p1,p2,p3))) = |.(p2 - p3).| * (cos (angle (p3,p1,p2))) by Lm2; p1 <> p3 by A3, ZFMISC_1:def_5; then A6: |.(p3 - p1).| <> 0 by Lm1; |.(p3 - p1).| * (sin (angle (p3,p1,p2))) = |.(p3 - p2).| * (sin (angle (p1,p2,p3))) by A2, Th6 .= |.(p3 - p1).| * (sin (angle (p1,p2,p3))) by A1, Lm2 ; then A7: sin (angle (p3,p1,p2)) = sin (angle (p1,p2,p3)) by A6, XCMPLX_1:5; p2 <> p3 by A3, ZFMISC_1:def_5; then |.(p2 - p3).| <> 0 by Lm1; then cos (angle (p1,p2,p3)) = cos (angle (p3,p1,p2)) by A5, XCMPLX_1:5; hence angle (p3,p1,p2) = angle (p1,p2,p3) by A7, Th1; ::_thesis: verum end; supposeA8: not p1,p2,p3 are_mutually_different ; ::_thesis: angle (p3,p1,p2) = angle (p1,p2,p3) percases ( p1 = p2 or p1 = p3 or p2 = p3 ) by A8, ZFMISC_1:def_5; suppose p1 = p2 ; ::_thesis: angle (p3,p1,p2) = angle (p1,p2,p3) hence angle (p3,p1,p2) = angle (p1,p2,p3) by A2; ::_thesis: verum end; supposeA9: p1 = p3 ; ::_thesis: angle (p3,p1,p2) = angle (p1,p2,p3) then |.(p2 - p3).| = 0 by A1, Lm1; then p2 = p3 by Lm1; hence angle (p3,p1,p2) = angle (p1,p2,p3) by A9; ::_thesis: verum end; supposeA10: p2 = p3 ; ::_thesis: angle (p3,p1,p2) = angle (p1,p2,p3) then |.(p3 - p1).| = 0 by A1, Lm1; then p3 = p1 by Lm1; hence angle (p3,p1,p2) = angle (p1,p2,p3) by A10; ::_thesis: verum end; end; end; end; end; theorem Th17: :: EUCLID_6:17 for p1, p2, p3, p being Point of (TOP-REAL 2) st p in LSeg (p1,p2) & p <> p2 holds ( |((p3 - p),(p2 - p1))| = 0 iff |((p3 - p),(p2 - p))| = 0 ) proof let p1, p2, p3, p be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p2) & p <> p2 implies ( |((p3 - p),(p2 - p1))| = 0 iff |((p3 - p),(p2 - p))| = 0 ) ) assume p in LSeg (p1,p2) ; ::_thesis: ( not p <> p2 or ( |((p3 - p),(p2 - p1))| = 0 iff |((p3 - p),(p2 - p))| = 0 ) ) then p in LSeg (p2,p1) ; then consider l being Real such that A1: p = ((1 - l) * p2) + (l * p1) and 0 <= l and l <= 1 ; assume A2: p <> p2 ; ::_thesis: ( |((p3 - p),(p2 - p1))| = 0 iff |((p3 - p),(p2 - p))| = 0 ) A3: p2 - p = (p2 - ((1 - l) * p2)) - (l * p1) by A1, EUCLID:46 .= (p2 - ((1 * p2) - (l * p2))) - (l * p1) by EUCLID:50 .= (p2 - (p2 - (l * p2))) - (l * p1) by EUCLID:29 .= ((p2 - p2) + (l * p2)) - (l * p1) by EUCLID:47 .= ((0. (TOP-REAL 2)) + (l * p2)) - (l * p1) by EUCLID:42 .= (l * p2) - (l * p1) by EUCLID:27 .= l * (p2 - p1) by EUCLID:49 ; hereby ::_thesis: ( |((p3 - p),(p2 - p))| = 0 implies |((p3 - p),(p2 - p1))| = 0 ) assume A4: |((p3 - p),(p2 - p1))| = 0 ; ::_thesis: |((p3 - p),(p2 - p))| = 0 thus |((p3 - p),(p2 - p))| = l * |((p3 - p),(p2 - p1))| by A3, EUCLID_2:20 .= 0 by A4 ; ::_thesis: verum end; assume |((p3 - p),(p2 - p))| = 0 ; ::_thesis: |((p3 - p),(p2 - p1))| = 0 then A5: l * |((p3 - p),(p2 - p1))| = 0 by A3, EUCLID_2:20; percases ( l = 0 or |((p3 - p),(p2 - p1))| = 0 ) by A5; suppose l = 0 ; ::_thesis: |((p3 - p),(p2 - p1))| = 0 then p = (1 * p2) + (0. (TOP-REAL 2)) by A1, EUCLID:29 .= 1 * p2 by EUCLID:27 .= p2 by EUCLID:29 ; hence |((p3 - p),(p2 - p1))| = 0 by A2; ::_thesis: verum end; suppose |((p3 - p),(p2 - p1))| = 0 ; ::_thesis: |((p3 - p),(p2 - p1))| = 0 hence |((p3 - p),(p2 - p1))| = 0 ; ::_thesis: verum end; end; end; theorem Th18: :: EUCLID_6:18 for p1, p3, p2, p being Point of (TOP-REAL 2) st |.(p1 - p3).| = |.(p2 - p3).| & p in LSeg (p1,p2) & p <> p3 & p <> p1 & ( angle (p3,p,p1) = PI / 2 or angle (p3,p,p1) = (3 / 2) * PI ) holds angle (p1,p3,p) = angle (p,p3,p2) proof let p1, p3, p2, p be Point of (TOP-REAL 2); ::_thesis: ( |.(p1 - p3).| = |.(p2 - p3).| & p in LSeg (p1,p2) & p <> p3 & p <> p1 & ( angle (p3,p,p1) = PI / 2 or angle (p3,p,p1) = (3 / 2) * PI ) implies angle (p1,p3,p) = angle (p,p3,p2) ) assume A1: |.(p1 - p3).| = |.(p2 - p3).| ; ::_thesis: ( not p in LSeg (p1,p2) or not p <> p3 or not p <> p1 or ( not angle (p3,p,p1) = PI / 2 & not angle (p3,p,p1) = (3 / 2) * PI ) or angle (p1,p3,p) = angle (p,p3,p2) ) then A2: |.(p3 - p1).| = |.(p2 - p3).| by Lm2; assume A3: p in LSeg (p1,p2) ; ::_thesis: ( not p <> p3 or not p <> p1 or ( not angle (p3,p,p1) = PI / 2 & not angle (p3,p,p1) = (3 / 2) * PI ) or angle (p1,p3,p) = angle (p,p3,p2) ) assume that A4: p <> p3 and A5: p <> p1 ; ::_thesis: ( ( not angle (p3,p,p1) = PI / 2 & not angle (p3,p,p1) = (3 / 2) * PI ) or angle (p1,p3,p) = angle (p,p3,p2) ) assume A6: ( angle (p3,p,p1) = PI / 2 or angle (p3,p,p1) = (3 / 2) * PI ) ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) percases ( p1 = p2 or p1 <> p2 ) ; supposeA7: p1 = p2 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then LSeg (p1,p2) = {p1} by RLTOPSP1:70; then p = p1 by A3, TARSKI:def_1; hence angle (p1,p3,p) = angle (p,p3,p2) by A7; ::_thesis: verum end; supposeA8: p1 <> p2 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) percases ( p <> p2 or p = p2 ) ; supposeA9: p <> p2 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) p2 <> p3 proof assume A10: p2 = p3 ; ::_thesis: contradiction then |.(p3 - p1).| = 0 by A2, Lm1; hence contradiction by A8, A10, Lm1; ::_thesis: verum end; then A11: euc2cpx p2 <> euc2cpx p3 by EUCLID_3:4; p1 <> p3 proof assume A12: p1 = p3 ; ::_thesis: contradiction then |.(p2 - p3).| = 0 by A1, Lm1; hence contradiction by A8, A12, Lm1; ::_thesis: verum end; then A13: euc2cpx p1 <> euc2cpx p3 by EUCLID_3:4; A14: ( euc2cpx p <> euc2cpx p1 & euc2cpx p <> euc2cpx p3 ) by A4, A5, EUCLID_3:4; A15: ( angle (p1,p,p3) = angle (p3,p,p2) & euc2cpx p <> euc2cpx p2 ) by A3, A5, A6, A9, Th14, EUCLID_3:4; A16: angle (p3,p1,p) = angle (p3,p1,p2) by A3, A5, Th10 .= angle (p1,p2,p3) by A2, A8, Th16 .= angle (p,p2,p3) by A3, A9, Th9 ; A17: angle (p,p3,p1) = angle (p2,p3,p) proof percases ( ( ((angle (p,p2,p3)) + (angle (p,p3,p1))) + (angle (p3,p,p2)) = PI & ((angle (p,p2,p3)) + (angle (p2,p3,p))) + (angle (p3,p,p2)) = PI ) or ( ((angle (p,p2,p3)) + (angle (p,p3,p1))) + (angle (p3,p,p2)) = 5 * PI & ((angle (p,p2,p3)) + (angle (p2,p3,p))) + (angle (p3,p,p2)) = 5 * PI ) or ( ((angle (p,p2,p3)) + (angle (p,p3,p1))) + (angle (p3,p,p2)) = PI & ((angle (p,p2,p3)) + (angle (p2,p3,p))) + (angle (p3,p,p2)) = 5 * PI ) or ( ((angle (p,p2,p3)) + (angle (p,p3,p1))) + (angle (p3,p,p2)) = 5 * PI & ((angle (p,p2,p3)) + (angle (p2,p3,p))) + (angle (p3,p,p2)) = PI ) ) by A16, A14, A13, A11, A15, COMPLEX2:88; suppose ( ( ((angle (p,p2,p3)) + (angle (p,p3,p1))) + (angle (p3,p,p2)) = PI & ((angle (p,p2,p3)) + (angle (p2,p3,p))) + (angle (p3,p,p2)) = PI ) or ( ((angle (p,p2,p3)) + (angle (p,p3,p1))) + (angle (p3,p,p2)) = 5 * PI & ((angle (p,p2,p3)) + (angle (p2,p3,p))) + (angle (p3,p,p2)) = 5 * PI ) ) ; ::_thesis: angle (p,p3,p1) = angle (p2,p3,p) hence angle (p,p3,p1) = angle (p2,p3,p) ; ::_thesis: verum end; supposeA18: ( ((angle (p,p2,p3)) + (angle (p,p3,p1))) + (angle (p3,p,p2)) = PI & ((angle (p,p2,p3)) + (angle (p2,p3,p))) + (angle (p3,p,p2)) = 5 * PI ) ; ::_thesis: angle (p,p3,p1) = angle (p2,p3,p) ( angle (p2,p3,p) < 2 * PI & angle (p,p3,p1) >= 0 ) by COMPLEX2:70; then A19: (angle (p2,p3,p)) - (angle (p,p3,p1)) < (2 * PI) - 0 by XREAL_1:14; (angle (p2,p3,p)) - (angle (p,p3,p1)) = 4 * PI by A18; hence angle (p,p3,p1) = angle (p2,p3,p) by A19, XREAL_1:64; ::_thesis: verum end; supposeA20: ( ((angle (p,p2,p3)) + (angle (p,p3,p1))) + (angle (p3,p,p2)) = 5 * PI & ((angle (p,p2,p3)) + (angle (p2,p3,p))) + (angle (p3,p,p2)) = PI ) ; ::_thesis: angle (p,p3,p1) = angle (p2,p3,p) ( angle (p,p3,p1) < 2 * PI & angle (p2,p3,p) >= 0 ) by COMPLEX2:70; then A21: (angle (p,p3,p1)) - (angle (p2,p3,p)) < (2 * PI) - 0 by XREAL_1:14; (angle (p,p3,p1)) - (angle (p2,p3,p)) = 4 * PI by A20; hence angle (p,p3,p1) = angle (p2,p3,p) by A21, XREAL_1:64; ::_thesis: verum end; end; end; percases ( angle (p,p3,p1) = 0 or angle (p,p3,p1) <> 0 ) ; supposeA22: angle (p,p3,p1) = 0 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then angle (p1,p3,p) = 0 by EUCLID_3:36; hence angle (p1,p3,p) = angle (p,p3,p2) by A17, A22, EUCLID_3:36; ::_thesis: verum end; supposeA23: angle (p,p3,p1) <> 0 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then angle (p1,p3,p) = (2 * PI) - (angle (p,p3,p1)) by EUCLID_3:37; hence angle (p1,p3,p) = angle (p,p3,p2) by A17, A23, EUCLID_3:37; ::_thesis: verum end; end; end; supposeA24: p = p2 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then |.(p3 - p1).| = |.(p - p3).| by A1, Lm2 .= |.(p3 - p).| by Lm2 ; then (|.(p3 - p1).| ^2) + (|.(p1 - p).| ^2) = |.(p3 - p1).| ^2 by A4, A5, A6, EUCLID_3:46; then |.(p1 - p).| = 0 ; hence angle (p1,p3,p) = angle (p,p3,p2) by A24, Lm1; ::_thesis: verum end; end; end; end; end; theorem :: EUCLID_6:19 for p1, p2, p3, p being Point of (TOP-REAL 2) st |.(p1 - p3).| = |.(p2 - p3).| & p in LSeg (p1,p2) & p <> p3 holds ( ( angle (p1,p3,p) = angle (p,p3,p2) implies |.(p1 - p).| = |.(p - p2).| ) & ( |.(p1 - p).| = |.(p - p2).| implies |((p3 - p),(p2 - p1))| = 0 ) & ( |((p3 - p),(p2 - p1))| = 0 implies angle (p1,p3,p) = angle (p,p3,p2) ) ) proof let p1, p2, p3, p be Point of (TOP-REAL 2); ::_thesis: ( |.(p1 - p3).| = |.(p2 - p3).| & p in LSeg (p1,p2) & p <> p3 implies ( ( angle (p1,p3,p) = angle (p,p3,p2) implies |.(p1 - p).| = |.(p - p2).| ) & ( |.(p1 - p).| = |.(p - p2).| implies |((p3 - p),(p2 - p1))| = 0 ) & ( |((p3 - p),(p2 - p1))| = 0 implies angle (p1,p3,p) = angle (p,p3,p2) ) ) ) assume A1: |.(p1 - p3).| = |.(p2 - p3).| ; ::_thesis: ( not p in LSeg (p1,p2) or not p <> p3 or ( ( angle (p1,p3,p) = angle (p,p3,p2) implies |.(p1 - p).| = |.(p - p2).| ) & ( |.(p1 - p).| = |.(p - p2).| implies |((p3 - p),(p2 - p1))| = 0 ) & ( |((p3 - p),(p2 - p1))| = 0 implies angle (p1,p3,p) = angle (p,p3,p2) ) ) ) assume A2: p in LSeg (p1,p2) ; ::_thesis: ( not p <> p3 or ( ( angle (p1,p3,p) = angle (p,p3,p2) implies |.(p1 - p).| = |.(p - p2).| ) & ( |.(p1 - p).| = |.(p - p2).| implies |((p3 - p),(p2 - p1))| = 0 ) & ( |((p3 - p),(p2 - p1))| = 0 implies angle (p1,p3,p) = angle (p,p3,p2) ) ) ) assume A3: p <> p3 ; ::_thesis: ( ( angle (p1,p3,p) = angle (p,p3,p2) implies |.(p1 - p).| = |.(p - p2).| ) & ( |.(p1 - p).| = |.(p - p2).| implies |((p3 - p),(p2 - p1))| = 0 ) & ( |((p3 - p),(p2 - p1))| = 0 implies angle (p1,p3,p) = angle (p,p3,p2) ) ) thus ( angle (p1,p3,p) = angle (p,p3,p2) implies |.(p1 - p).| = |.(p - p2).| ) ::_thesis: ( ( |.(p1 - p).| = |.(p - p2).| implies |((p3 - p),(p2 - p1))| = 0 ) & ( |((p3 - p),(p2 - p1))| = 0 implies angle (p1,p3,p) = angle (p,p3,p2) ) ) proof assume A4: angle (p1,p3,p) = angle (p,p3,p2) ; ::_thesis: |.(p1 - p).| = |.(p - p2).| A5: |.(p - p1).| ^2 = ((|.(p1 - p3).| ^2) + (|.(p - p3).| ^2)) - (((2 * |.(p1 - p3).|) * |.(p - p3).|) * (cos (angle (p1,p3,p)))) by Th7 .= ((|.(p - p3).| ^2) + (|.(p2 - p3).| ^2)) - (((2 * |.(p - p3).|) * |.(p2 - p3).|) * (cos (angle (p,p3,p2)))) by A1, A4 .= |.(p2 - p).| ^2 by Th7 ; thus |.(p1 - p).| = |.(p - p1).| by Lm2 .= sqrt (|.(p2 - p).| ^2) by A5, SQUARE_1:22 .= |.(p2 - p).| by SQUARE_1:22 .= |.(p - p2).| by Lm2 ; ::_thesis: verum end; thus ( |.(p1 - p).| = |.(p - p2).| implies |((p3 - p),(p2 - p1))| = 0 ) ::_thesis: ( |((p3 - p),(p2 - p1))| = 0 implies angle (p1,p3,p) = angle (p,p3,p2) ) proof assume A6: |.(p1 - p).| = |.(p - p2).| ; ::_thesis: |((p3 - p),(p2 - p1))| = 0 percases ( p = p2 or p <> p2 ) ; supposeA7: p = p2 ; ::_thesis: |((p3 - p),(p2 - p1))| = 0 then |.(p1 - p).| = 0 by A6, Lm1; hence |((p3 - p),(p2 - p1))| = |((p3 - p),(p - p))| by A7, Lm1 .= |((p3 - p),(0. (TOP-REAL 2)))| by EUCLID:42 .= 0 by EUCLID_2:32 ; ::_thesis: verum end; supposeA8: p <> p2 ; ::_thesis: |((p3 - p),(p2 - p1))| = 0 then |.(p1 - p).| <> 0 by A6, Lm1; then A9: p <> p1 by Lm1; A10: cos (angle (p1,p,p3)) = - (cos (angle (p3,p,p2))) proof percases ( (angle (p1,p,p3)) + (angle (p3,p,p2)) = PI or (angle (p1,p,p3)) + (angle (p3,p,p2)) = 3 * PI ) by A2, A8, A9, Th13; suppose (angle (p1,p,p3)) + (angle (p3,p,p2)) = PI ; ::_thesis: cos (angle (p1,p,p3)) = - (cos (angle (p3,p,p2))) hence cos (angle (p1,p,p3)) = cos (PI + (- (angle (p3,p,p2)))) .= - (cos (- (angle (p3,p,p2)))) by SIN_COS:79 .= - (cos (angle (p3,p,p2))) by SIN_COS:31 ; ::_thesis: verum end; suppose (angle (p1,p,p3)) + (angle (p3,p,p2)) = 3 * PI ; ::_thesis: cos (angle (p1,p,p3)) = - (cos (angle (p3,p,p2))) hence cos (angle (p1,p,p3)) = cos ((PI - (angle (p3,p,p2))) + (2 * PI)) .= cos (PI + (- (angle (p3,p,p2)))) by SIN_COS:79 .= - (cos (- (angle (p3,p,p2)))) by SIN_COS:79 .= - (cos (angle (p3,p,p2))) by SIN_COS:31 ; ::_thesis: verum end; end; end; A11: ( |.(p3 - p1).| ^2 = ((|.(p1 - p).| ^2) + (|.(p3 - p).| ^2)) - (((2 * |.(p1 - p).|) * |.(p3 - p).|) * (cos (angle (p1,p,p3)))) & |.(p2 - p3).| ^2 = ((|.(p3 - p).| ^2) + (|.(p2 - p).| ^2)) - (((2 * |.(p3 - p).|) * |.(p2 - p).|) * (cos (angle (p3,p,p2)))) ) by Th7; A12: |.(p1 - p).| = |.(p2 - p).| by A6, Lm2; A13: |.(p2 - p).| <> 0 by A8, Lm1; A14: |.(p3 - p).| <> 0 by A3, Lm1; |.(p3 - p1).| = |.(p2 - p3).| by A1, Lm2; then ((2 * |.(p1 - p).|) * (cos (angle (p1,p,p3)))) * |.(p3 - p).| = ((2 * |.(p2 - p).|) * (cos (angle (p3,p,p2)))) * |.(p3 - p).| by A11, A12; then (2 * (cos (angle (p1,p,p3)))) * |.(p2 - p).| = (2 * (cos (angle (p3,p,p2)))) * |.(p2 - p).| by A14, A12, XCMPLX_1:5; then A15: 2 * (cos (angle (p1,p,p3))) = 2 * (cos (angle (p3,p,p2))) by A13, XCMPLX_1:5; ( 0 <= angle (p3,p,p2) & angle (p3,p,p2) < 2 * PI ) by COMPLEX2:70; then ( angle (p3,p,p2) = PI / 2 or angle (p3,p,p2) = (3 / 2) * PI ) by A15, A10, COMPTRIG:18; then |((p3 - p),(p2 - p))| = 0 by A3, A8, EUCLID_3:45; hence |((p3 - p),(p2 - p1))| = 0 by A2, A8, Th17; ::_thesis: verum end; end; end; thus ( |((p3 - p),(p2 - p1))| = 0 implies angle (p1,p3,p) = angle (p,p3,p2) ) ::_thesis: verum proof assume A16: |((p3 - p),(p2 - p1))| = 0 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then A17: 0 = - |((p3 - p),(p2 - p1))| .= |((p3 - p),(- (p2 - p1)))| by EUCLID_2:22 .= |((p3 - p),(p1 - p2))| by EUCLID:44 ; percases ( ( p2 = p & p1 = p ) or p1 <> p or p2 <> p ) ; suppose ( p2 = p & p1 = p ) ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) hence angle (p1,p3,p) = angle (p,p3,p2) ; ::_thesis: verum end; supposeA18: p1 <> p ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then |((p3 - p),(p1 - p))| = 0 by A2, A17, Th17; then ( angle (p3,p,p1) = PI / 2 or angle (p3,p,p1) = (3 / 2) * PI ) by A3, A18, EUCLID_3:45; hence angle (p1,p3,p) = angle (p,p3,p2) by A1, A2, A3, A18, Th18; ::_thesis: verum end; supposeA19: p2 <> p ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then |((p3 - p),(p2 - p))| = 0 by A2, A16, Th17; then ( angle (p3,p,p2) = PI / 2 or angle (p3,p,p2) = (3 / 2) * PI ) by A3, A19, EUCLID_3:45; then A20: angle (p2,p3,p) = angle (p,p3,p1) by A1, A2, A3, A19, Th18; percases ( angle (p2,p3,p) = 0 or angle (p2,p3,p) <> 0 ) ; supposeA21: angle (p2,p3,p) = 0 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then angle (p,p3,p2) = 0 by EUCLID_3:36; hence angle (p1,p3,p) = angle (p,p3,p2) by A20, A21, EUCLID_3:36; ::_thesis: verum end; supposeA22: angle (p2,p3,p) <> 0 ; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) then angle (p,p3,p2) = (2 * PI) - (angle (p2,p3,p)) by EUCLID_3:37; hence angle (p1,p3,p) = angle (p,p3,p2) by A20, A22, EUCLID_3:37; ::_thesis: verum end; end; end; end; end; end; definition let p1, p2, p3 be Point of (TOP-REAL 2); predp1,p2,p3 is_collinear means :Def3: :: EUCLID_6:def 3 ( p1 in LSeg (p2,p3) or p2 in LSeg (p3,p1) or p3 in LSeg (p1,p2) ); end; :: deftheorem Def3 defines is_collinear EUCLID_6:def_3_:_ for p1, p2, p3 being Point of (TOP-REAL 2) holds ( p1,p2,p3 is_collinear iff ( p1 in LSeg (p2,p3) or p2 in LSeg (p3,p1) or p3 in LSeg (p1,p2) ) ); notation let p1, p2, p3 be Point of (TOP-REAL 2); antonym p1,p2,p3 is_a_triangle for p1,p2,p3 is_collinear ; end; theorem Th20: :: EUCLID_6:20 for p1, p2, p3 being Point of (TOP-REAL 2) holds ( p1,p2,p3 is_a_triangle iff ( p1,p2,p3 are_mutually_different & angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI ) ) proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( p1,p2,p3 is_a_triangle iff ( p1,p2,p3 are_mutually_different & angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI ) ) hereby ::_thesis: ( p1,p2,p3 are_mutually_different & angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI implies p1,p2,p3 is_a_triangle ) assume A1: p1,p2,p3 is_a_triangle ; ::_thesis: ( p1,p2,p3 are_mutually_different & angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI ) then A2: not p2 in LSeg (p3,p1) by Def3; then A3: p2 <> p3 by RLTOPSP1:68; A4: not p1 in LSeg (p2,p3) by A1, Def3; then ( p1 <> p2 & p1 <> p3 ) by RLTOPSP1:68; hence p1,p2,p3 are_mutually_different by A3, ZFMISC_1:def_5; ::_thesis: ( angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI ) not p3 in LSeg (p1,p2) by A1, Def3; hence ( angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI ) by A4, A2, Th11; ::_thesis: verum end; assume A5: p1,p2,p3 are_mutually_different ; ::_thesis: ( not angle (p1,p2,p3) <> PI or not angle (p2,p3,p1) <> PI or not angle (p3,p1,p2) <> PI or p1,p2,p3 is_a_triangle ) then A6: p1 <> p2 by ZFMISC_1:def_5; assume A7: angle (p1,p2,p3) <> PI ; ::_thesis: ( not angle (p2,p3,p1) <> PI or not angle (p3,p1,p2) <> PI or p1,p2,p3 is_a_triangle ) A8: p1 <> p3 by A5, ZFMISC_1:def_5; A9: p2 <> p3 by A5, ZFMISC_1:def_5; assume angle (p2,p3,p1) <> PI ; ::_thesis: ( not angle (p3,p1,p2) <> PI or p1,p2,p3 is_a_triangle ) then A10: not p3 in LSeg (p2,p1) by A8, A9, Th8; assume angle (p3,p1,p2) <> PI ; ::_thesis: p1,p2,p3 is_a_triangle then A11: not p1 in LSeg (p3,p2) by A6, A8, Th8; not p2 in LSeg (p1,p3) by A6, A9, A7, Th8; hence p1,p2,p3 is_a_triangle by A10, A11, Def3; ::_thesis: verum end; Lm18: for p3, p2, p1, p5, p6, p4 being Point of (TOP-REAL 2) st p3 <> p2 & p3 <> p1 & p2 <> p1 & p5 <> p6 & p5 <> p4 & p6 <> p4 & angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI & angle (p4,p5,p6) <> PI & angle (p5,p6,p4) <> PI & angle (p6,p4,p5) <> PI & angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p6,p4,p5) holds |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| proof let p3, p2, p1, p5, p6, p4 be Point of (TOP-REAL 2); ::_thesis: ( p3 <> p2 & p3 <> p1 & p2 <> p1 & p5 <> p6 & p5 <> p4 & p6 <> p4 & angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI & angle (p4,p5,p6) <> PI & angle (p5,p6,p4) <> PI & angle (p6,p4,p5) <> PI & angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p6,p4,p5) implies |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| ) assume that A1: ( p3 <> p2 & p3 <> p1 ) and A2: p2 <> p1 ; ::_thesis: ( not p5 <> p6 or not p5 <> p4 or not p6 <> p4 or not angle (p1,p2,p3) <> PI or not angle (p2,p3,p1) <> PI or not angle (p3,p1,p2) <> PI or not angle (p4,p5,p6) <> PI or not angle (p5,p6,p4) <> PI or not angle (p6,p4,p5) <> PI or not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p6,p4,p5) or |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| ) A3: ( euc2cpx p3 <> euc2cpx p2 & euc2cpx p3 <> euc2cpx p1 ) by A1, EUCLID_3:4; A4: euc2cpx p2 <> euc2cpx p1 by A2, EUCLID_3:4; assume that A5: p5 <> p6 and A6: p5 <> p4 and A7: p6 <> p4 ; ::_thesis: ( not angle (p1,p2,p3) <> PI or not angle (p2,p3,p1) <> PI or not angle (p3,p1,p2) <> PI or not angle (p4,p5,p6) <> PI or not angle (p5,p6,p4) <> PI or not angle (p6,p4,p5) <> PI or not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p6,p4,p5) or |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| ) A8: ( euc2cpx p5 <> euc2cpx p6 & euc2cpx p5 <> euc2cpx p4 ) by A5, A6, EUCLID_3:4; A9: euc2cpx p6 <> euc2cpx p4 by A7, EUCLID_3:4; assume A10: ( angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI ) ; ::_thesis: ( not angle (p4,p5,p6) <> PI or not angle (p5,p6,p4) <> PI or not angle (p6,p4,p5) <> PI or not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p6,p4,p5) or |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| ) assume A11: ( angle (p4,p5,p6) <> PI & angle (p5,p6,p4) <> PI & angle (p6,p4,p5) <> PI ) ; ::_thesis: ( not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p6,p4,p5) or |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| ) assume that A12: angle (p1,p2,p3) = angle (p4,p5,p6) and A13: angle (p3,p1,p2) = angle (p6,p4,p5) ; ::_thesis: |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| A14: (sin (angle (p2,p1,p3))) * (sin (angle (p6,p5,p4))) = (sin (angle (p2,p1,p3))) * (- (sin (angle (p1,p2,p3)))) by A12, Th2 .= (- (sin (angle (p6,p4,p5)))) * (- (sin (angle (p1,p2,p3)))) by A13, Th2 .= (sin (angle (p5,p4,p6))) * (- (sin (angle (p1,p2,p3)))) by Th2 .= (sin (angle (p3,p2,p1))) * (sin (angle (p5,p4,p6))) by Th2 ; percases ( (sin (angle (p3,p2,p1))) * (sin (angle (p5,p4,p6))) <> 0 or (sin (angle (p3,p2,p1))) * (sin (angle (p5,p4,p6))) = 0 ) ; supposeA15: (sin (angle (p3,p2,p1))) * (sin (angle (p5,p4,p6))) <> 0 ; ::_thesis: |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| A16: ((|.(p3 - p2).| * |.(p4 - p6).|) * (sin (angle (p3,p2,p1)))) * (sin (angle (p5,p4,p6))) = (|.(p3 - p2).| * (sin (angle (p3,p2,p1)))) * (|.(p4 - p6).| * (sin (angle (p5,p4,p6)))) .= (|.(p3 - p1).| * (sin (angle (p2,p1,p3)))) * (|.(p4 - p6).| * (sin (angle (p5,p4,p6)))) by A2, Th6 .= (|.(p3 - p1).| * (sin (angle (p2,p1,p3)))) * (|.(p6 - p4).| * (sin (angle (p5,p4,p6)))) by Lm2 .= (|.(p3 - p1).| * (sin (angle (p2,p1,p3)))) * (|.(p6 - p5).| * (sin (angle (p6,p5,p4)))) by A6, Th6 .= ((|.(p3 - p1).| * |.(p6 - p5).|) * (sin (angle (p2,p1,p3)))) * (sin (angle (p6,p5,p4))) ; thus |.(p3 - p2).| * |.(p4 - p6).| = ((|.(p3 - p2).| * |.(p4 - p6).|) * ((sin (angle (p3,p2,p1))) * (sin (angle (p5,p4,p6))))) / ((sin (angle (p3,p2,p1))) * (sin (angle (p5,p4,p6)))) by A15, XCMPLX_1:89 .= ((|.(p3 - p1).| * |.(p6 - p5).|) * ((sin (angle (p2,p1,p3))) * (sin (angle (p6,p5,p4))))) / ((sin (angle (p3,p2,p1))) * (sin (angle (p5,p4,p6)))) by A16 .= |.(p3 - p1).| * |.(p6 - p5).| by A14, A15, XCMPLX_1:89 .= |.(p1 - p3).| * |.(p6 - p5).| by Lm2 ; ::_thesis: verum end; supposeA17: (sin (angle (p3,p2,p1))) * (sin (angle (p5,p4,p6))) = 0 ; ::_thesis: |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| percases ( sin (angle (p3,p2,p1)) = 0 or sin (angle (p5,p4,p6)) = 0 ) by A17; supposeA18: sin (angle (p3,p2,p1)) = 0 ; ::_thesis: |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| A19: ( (2 * PI) * 0 <= angle (p1,p2,p3) & angle (p1,p2,p3) < (2 * PI) + ((2 * PI) * 0) ) by COMPLEX2:70; - (sin (angle (p1,p2,p3))) = 0 by A18, Th2; then ( angle (p1,p2,p3) = (2 * PI) * 0 or angle (p1,p2,p3) = PI + ((2 * PI) * 0) ) by A19, SIN_COS6:21; hence |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| by A3, A4, A10, COMPLEX2:87; ::_thesis: verum end; supposeA20: sin (angle (p5,p4,p6)) = 0 ; ::_thesis: |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| A21: ( (2 * PI) * 0 <= angle (p6,p4,p5) & angle (p6,p4,p5) < (2 * PI) + ((2 * PI) * 0) ) by COMPLEX2:70; - (sin (angle (p6,p4,p5))) = 0 by A20, Th2; then ( angle (p6,p4,p5) = (2 * PI) * 0 or angle (p6,p4,p5) = PI + ((2 * PI) * 0) ) by A21, SIN_COS6:21; hence |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| by A8, A9, A11, COMPLEX2:87; ::_thesis: verum end; end; end; end; end; theorem Th21: :: EUCLID_6:21 for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) st p1,p2,p3 is_a_triangle & p4,p5,p6 is_a_triangle & angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p6,p4,p5) holds ( |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| & |.(p3 - p2).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p6 - p5).| & |.(p1 - p3).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p4 - p6).| ) proof let p1, p2, p3, p4, p5, p6 be Point of (TOP-REAL 2); ::_thesis: ( p1,p2,p3 is_a_triangle & p4,p5,p6 is_a_triangle & angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p6,p4,p5) implies ( |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| & |.(p3 - p2).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p6 - p5).| & |.(p1 - p3).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p4 - p6).| ) ) assume p1,p2,p3 is_a_triangle ; ::_thesis: ( not p4,p5,p6 is_a_triangle or not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p6,p4,p5) or ( |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| & |.(p3 - p2).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p6 - p5).| & |.(p1 - p3).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p4 - p6).| ) ) then A1: p1,p2,p3 are_mutually_different by Th20; then A2: p3 <> p2 by ZFMISC_1:def_5; A3: p2 <> p1 by A1, ZFMISC_1:def_5; then A4: euc2cpx p2 <> euc2cpx p1 by EUCLID_3:4; A5: p3 <> p1 by A1, ZFMISC_1:def_5; then A6: euc2cpx p3 <> euc2cpx p1 by EUCLID_3:4; assume A7: p4,p5,p6 is_a_triangle ; ::_thesis: ( not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p6,p4,p5) or ( |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| & |.(p3 - p2).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p6 - p5).| & |.(p1 - p3).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p4 - p6).| ) ) then A8: ( angle (p4,p5,p6) <> PI & angle (p5,p6,p4) <> PI ) by Th20; A9: p4,p5,p6 are_mutually_different by A7, Th20; then A10: p5 <> p6 by ZFMISC_1:def_5; then A11: euc2cpx p5 <> euc2cpx p6 by EUCLID_3:4; A12: p6 <> p4 by A9, ZFMISC_1:def_5; then A13: euc2cpx p6 <> euc2cpx p4 by EUCLID_3:4; A14: p5 <> p4 by A9, ZFMISC_1:def_5; then A15: euc2cpx p5 <> euc2cpx p4 by EUCLID_3:4; assume A16: ( angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p6,p4,p5) ) ; ::_thesis: ( |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| & |.(p3 - p2).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p6 - p5).| & |.(p1 - p3).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p4 - p6).| ) A17: euc2cpx p3 <> euc2cpx p2 by A2, EUCLID_3:4; A18: angle (p2,p3,p1) = angle (p5,p6,p4) proof percases ( ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = PI & ((angle (p6,p4,p5)) + (angle (p4,p5,p6))) + (angle (p5,p6,p4)) = PI ) or ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = 5 * PI & ((angle (p6,p4,p5)) + (angle (p4,p5,p6))) + (angle (p5,p6,p4)) = 5 * PI ) or ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = PI & ((angle (p6,p4,p5)) + (angle (p4,p5,p6))) + (angle (p5,p6,p4)) = 5 * PI ) or ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = 5 * PI & ((angle (p6,p4,p5)) + (angle (p4,p5,p6))) + (angle (p5,p6,p4)) = PI ) ) by A17, A6, A4, A11, A15, A13, COMPLEX2:88; suppose ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = PI & ((angle (p6,p4,p5)) + (angle (p4,p5,p6))) + (angle (p5,p6,p4)) = PI ) ; ::_thesis: angle (p2,p3,p1) = angle (p5,p6,p4) hence angle (p2,p3,p1) = angle (p5,p6,p4) by A16; ::_thesis: verum end; suppose ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = 5 * PI & ((angle (p6,p4,p5)) + (angle (p4,p5,p6))) + (angle (p5,p6,p4)) = 5 * PI ) ; ::_thesis: angle (p2,p3,p1) = angle (p5,p6,p4) hence angle (p2,p3,p1) = angle (p5,p6,p4) by A16; ::_thesis: verum end; supposeA19: ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = PI & ((angle (p6,p4,p5)) + (angle (p4,p5,p6))) + (angle (p5,p6,p4)) = 5 * PI ) ; ::_thesis: angle (p2,p3,p1) = angle (p5,p6,p4) ( angle (p2,p3,p1) >= 0 & - (angle (p5,p6,p4)) > - (2 * PI) ) by COMPLEX2:70, XREAL_1:24; then A20: (angle (p2,p3,p1)) + (- (angle (p5,p6,p4))) > 0 + (- (2 * PI)) by XREAL_1:8; (angle (p2,p3,p1)) - (angle (p5,p6,p4)) = - (4 * PI) by A16, A19; then 4 * PI < 2 * PI by A20, XREAL_1:24; then (4 * PI) / PI < (2 * PI) / PI by XREAL_1:74; then 4 < (2 * PI) / PI by XCMPLX_1:89; then 4 < 2 by XCMPLX_1:89; hence angle (p2,p3,p1) = angle (p5,p6,p4) ; ::_thesis: verum end; supposeA21: ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = 5 * PI & ((angle (p6,p4,p5)) + (angle (p4,p5,p6))) + (angle (p5,p6,p4)) = PI ) ; ::_thesis: angle (p2,p3,p1) = angle (p5,p6,p4) ( angle (p2,p3,p1) < 2 * PI & angle (p5,p6,p4) >= 0 ) by COMPLEX2:70; then (angle (p2,p3,p1)) + (- (angle (p5,p6,p4))) < (2 * PI) + (- 0) by XREAL_1:8; then (4 * PI) / PI < (2 * PI) / PI by A16, A21, XREAL_1:74; then 4 < (2 * PI) / PI by XCMPLX_1:89; then 4 < 2 by XCMPLX_1:89; hence angle (p2,p3,p1) = angle (p5,p6,p4) ; ::_thesis: verum end; end; end; A22: angle (p6,p4,p5) <> PI by A7, Th20; hence |.(p3 - p2).| * |.(p4 - p6).| = |.(p1 - p3).| * |.(p6 - p5).| by A2, A5, A3, A8, A10, A14, A12, A16, A18, Lm18; ::_thesis: ( |.(p3 - p2).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p6 - p5).| & |.(p1 - p3).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p4 - p6).| ) thus |.(p3 - p2).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p6 - p5).| by A2, A5, A3, A8, A22, A10, A14, A12, A16, A18, Lm18; ::_thesis: |.(p1 - p3).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p4 - p6).| thus |.(p1 - p3).| * |.(p5 - p4).| = |.(p2 - p1).| * |.(p4 - p6).| by A2, A5, A3, A8, A22, A10, A14, A12, A16, A18, Lm18; ::_thesis: verum end; Lm19: for p3, p2, p1, p4, p5, p6 being Point of (TOP-REAL 2) st p3 <> p2 & p3 <> p1 & p2 <> p1 & p4 <> p5 & p4 <> p6 & p5 <> p6 & angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI & angle (p4,p5,p6) <> PI & angle (p5,p6,p4) <> PI & angle (p6,p4,p5) <> PI & angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p5,p6,p4) holds |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| proof let p3, p2, p1, p4, p5, p6 be Point of (TOP-REAL 2); ::_thesis: ( p3 <> p2 & p3 <> p1 & p2 <> p1 & p4 <> p5 & p4 <> p6 & p5 <> p6 & angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI & angle (p4,p5,p6) <> PI & angle (p5,p6,p4) <> PI & angle (p6,p4,p5) <> PI & angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p5,p6,p4) implies |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| ) assume that A1: ( p3 <> p2 & p3 <> p1 ) and A2: p2 <> p1 ; ::_thesis: ( not p4 <> p5 or not p4 <> p6 or not p5 <> p6 or not angle (p1,p2,p3) <> PI or not angle (p2,p3,p1) <> PI or not angle (p3,p1,p2) <> PI or not angle (p4,p5,p6) <> PI or not angle (p5,p6,p4) <> PI or not angle (p6,p4,p5) <> PI or not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p5,p6,p4) or |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| ) A3: ( euc2cpx p3 <> euc2cpx p2 & euc2cpx p3 <> euc2cpx p1 ) by A1, EUCLID_3:4; A4: euc2cpx p2 <> euc2cpx p1 by A2, EUCLID_3:4; assume that A5: ( p4 <> p5 & p4 <> p6 ) and A6: p5 <> p6 ; ::_thesis: ( not angle (p1,p2,p3) <> PI or not angle (p2,p3,p1) <> PI or not angle (p3,p1,p2) <> PI or not angle (p4,p5,p6) <> PI or not angle (p5,p6,p4) <> PI or not angle (p6,p4,p5) <> PI or not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p5,p6,p4) or |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| ) A7: ( euc2cpx p4 <> euc2cpx p5 & euc2cpx p4 <> euc2cpx p6 ) by A5, EUCLID_3:4; A8: euc2cpx p5 <> euc2cpx p6 by A6, EUCLID_3:4; assume A9: ( angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI & angle (p3,p1,p2) <> PI ) ; ::_thesis: ( not angle (p4,p5,p6) <> PI or not angle (p5,p6,p4) <> PI or not angle (p6,p4,p5) <> PI or not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p5,p6,p4) or |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| ) assume that A10: angle (p4,p5,p6) <> PI and A11: angle (p5,p6,p4) <> PI and A12: angle (p6,p4,p5) <> PI ; ::_thesis: ( not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p5,p6,p4) or |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| ) assume that A13: angle (p1,p2,p3) = angle (p4,p5,p6) and A14: angle (p3,p1,p2) = angle (p5,p6,p4) ; ::_thesis: |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| A15: (sin (angle (p1,p2,p3))) * (sin (angle (p4,p6,p5))) = (sin (angle (p4,p5,p6))) * (- (sin (angle (p5,p6,p4)))) by A13, Th2 .= (- (sin (angle (p6,p5,p4)))) * (- (sin (angle (p3,p1,p2)))) by A14, Th2 .= (sin (angle (p6,p5,p4))) * (sin (angle (p3,p1,p2))) ; percases ( (sin (angle (p1,p2,p3))) * (sin (angle (p4,p6,p5))) <> 0 or (sin (angle (p1,p2,p3))) * (sin (angle (p4,p6,p5))) = 0 ) ; supposeA16: (sin (angle (p1,p2,p3))) * (sin (angle (p4,p6,p5))) <> 0 ; ::_thesis: |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| A17: |.(p4 - p5).| * (sin (angle (p6,p5,p4))) = |.(p4 - p6).| * (sin (angle (p4,p6,p5))) by A6, Th6; A18: ((|.(p3 - p2).| * |.(p4 - p6).|) * (sin (angle (p1,p2,p3)))) * (sin (angle (p4,p6,p5))) = (|.(p3 - p2).| * (sin (angle (p1,p2,p3)))) * (|.(p4 - p6).| * (sin (angle (p4,p6,p5)))) .= (|.(p3 - p1).| * (sin (angle (p3,p1,p2)))) * (|.(p4 - p5).| * (sin (angle (p6,p5,p4)))) by A2, A17, Th6 .= ((|.(p3 - p1).| * |.(p4 - p5).|) * (sin (angle (p6,p5,p4)))) * (sin (angle (p3,p1,p2))) ; thus |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p2).| * |.(p4 - p6).| by Lm2 .= ((|.(p3 - p2).| * |.(p4 - p6).|) * ((sin (angle (p1,p2,p3))) * (sin (angle (p4,p6,p5))))) / ((sin (angle (p1,p2,p3))) * (sin (angle (p4,p6,p5)))) by A16, XCMPLX_1:89 .= ((|.(p3 - p1).| * |.(p4 - p5).|) * ((sin (angle (p6,p5,p4))) * (sin (angle (p3,p1,p2))))) / ((sin (angle (p6,p5,p4))) * (sin (angle (p3,p1,p2)))) by A15, A18 .= |.(p3 - p1).| * |.(p4 - p5).| by A15, A16, XCMPLX_1:89 .= |.(p3 - p1).| * |.(p5 - p4).| by Lm2 ; ::_thesis: verum end; supposeA19: (sin (angle (p1,p2,p3))) * (sin (angle (p4,p6,p5))) = 0 ; ::_thesis: |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| percases ( sin (angle (p1,p2,p3)) = 0 or sin (angle (p4,p6,p5)) = 0 ) by A19; supposeA20: sin (angle (p1,p2,p3)) = 0 ; ::_thesis: |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| ( (2 * PI) * 0 <= angle (p1,p2,p3) & angle (p1,p2,p3) < (2 * PI) + ((2 * PI) * 0) ) by COMPLEX2:70; then ( angle (p1,p2,p3) = (2 * PI) * 0 or angle (p1,p2,p3) = PI + ((2 * PI) * 0) ) by A20, SIN_COS6:21; hence |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| by A3, A4, A9, COMPLEX2:87; ::_thesis: verum end; supposeA21: sin (angle (p4,p6,p5)) = 0 ; ::_thesis: |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| ( (2 * PI) * 0 <= angle (p4,p6,p5) & angle (p4,p6,p5) < (2 * PI) + ((2 * PI) * 0) ) by COMPLEX2:70; then ( angle (p4,p6,p5) = (2 * PI) * 0 or angle (p4,p6,p5) = PI + ((2 * PI) * 0) ) by A21, SIN_COS6:21; then ( ( angle (p6,p5,p4) = 0 & angle (p5,p4,p6) = PI ) or ( angle (p6,p5,p4) = PI & angle (p5,p4,p6) = 0 ) ) by A7, A8, A11, COMPLEX2:82, COMPLEX2:87; hence |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| by A10, A12, COMPLEX2:82; ::_thesis: verum end; end; end; end; end; theorem Th22: :: EUCLID_6:22 for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) st p1,p2,p3 is_a_triangle & p4,p5,p6 is_a_triangle & angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p5,p6,p4) holds ( |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| & |.(p2 - p3).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p5 - p4).| & |.(p3 - p1).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p4 - p6).| ) proof let p1, p2, p3, p4, p5, p6 be Point of (TOP-REAL 2); ::_thesis: ( p1,p2,p3 is_a_triangle & p4,p5,p6 is_a_triangle & angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p5,p6,p4) implies ( |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| & |.(p2 - p3).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p5 - p4).| & |.(p3 - p1).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p4 - p6).| ) ) assume A1: p1,p2,p3 is_a_triangle ; ::_thesis: ( not p4,p5,p6 is_a_triangle or not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p5,p6,p4) or ( |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| & |.(p2 - p3).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p5 - p4).| & |.(p3 - p1).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p4 - p6).| ) ) then A2: p1,p2,p3 are_mutually_different by Th20; then A3: p3 <> p2 by ZFMISC_1:def_5; A4: angle (p3,p1,p2) <> PI by A1, Th20; A5: p3 <> p1 by A2, ZFMISC_1:def_5; then A6: euc2cpx p3 <> euc2cpx p1 by EUCLID_3:4; A7: p2 <> p1 by A2, ZFMISC_1:def_5; then A8: euc2cpx p2 <> euc2cpx p1 by EUCLID_3:4; assume A9: p4,p5,p6 is_a_triangle ; ::_thesis: ( not angle (p1,p2,p3) = angle (p4,p5,p6) or not angle (p3,p1,p2) = angle (p5,p6,p4) or ( |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| & |.(p2 - p3).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p5 - p4).| & |.(p3 - p1).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p4 - p6).| ) ) then A10: p4,p5,p6 are_mutually_different by Th20; then A11: p4 <> p5 by ZFMISC_1:def_5; then A12: euc2cpx p4 <> euc2cpx p5 by EUCLID_3:4; A13: p5 <> p6 by A10, ZFMISC_1:def_5; then A14: euc2cpx p5 <> euc2cpx p6 by EUCLID_3:4; A15: angle (p6,p4,p5) <> PI by A9, Th20; A16: p4 <> p6 by A10, ZFMISC_1:def_5; then A17: euc2cpx p4 <> euc2cpx p6 by EUCLID_3:4; assume A18: ( angle (p1,p2,p3) = angle (p4,p5,p6) & angle (p3,p1,p2) = angle (p5,p6,p4) ) ; ::_thesis: ( |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| & |.(p2 - p3).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p5 - p4).| & |.(p3 - p1).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p4 - p6).| ) A19: euc2cpx p3 <> euc2cpx p2 by A3, EUCLID_3:4; A20: angle (p2,p3,p1) = angle (p6,p4,p5) proof percases ( ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = PI & ((angle (p5,p6,p4)) + (angle (p6,p4,p5))) + (angle (p4,p5,p6)) = PI ) or ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = 5 * PI & ((angle (p5,p6,p4)) + (angle (p6,p4,p5))) + (angle (p4,p5,p6)) = 5 * PI ) or ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = PI & ((angle (p5,p6,p4)) + (angle (p6,p4,p5))) + (angle (p4,p5,p6)) = 5 * PI ) or ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = 5 * PI & ((angle (p5,p6,p4)) + (angle (p6,p4,p5))) + (angle (p4,p5,p6)) = PI ) ) by A19, A6, A8, A12, A17, A14, COMPLEX2:88; suppose ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = PI & ((angle (p5,p6,p4)) + (angle (p6,p4,p5))) + (angle (p4,p5,p6)) = PI ) ; ::_thesis: angle (p2,p3,p1) = angle (p6,p4,p5) hence angle (p2,p3,p1) = angle (p6,p4,p5) by A18; ::_thesis: verum end; suppose ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = 5 * PI & ((angle (p5,p6,p4)) + (angle (p6,p4,p5))) + (angle (p4,p5,p6)) = 5 * PI ) ; ::_thesis: angle (p2,p3,p1) = angle (p6,p4,p5) hence angle (p2,p3,p1) = angle (p6,p4,p5) by A18; ::_thesis: verum end; supposeA21: ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = PI & ((angle (p5,p6,p4)) + (angle (p6,p4,p5))) + (angle (p4,p5,p6)) = 5 * PI ) ; ::_thesis: angle (p2,p3,p1) = angle (p6,p4,p5) ( angle (p2,p3,p1) >= 0 & - (angle (p6,p4,p5)) > - (2 * PI) ) by COMPLEX2:70, XREAL_1:24; then A22: (angle (p2,p3,p1)) + (- (angle (p6,p4,p5))) > 0 + (- (2 * PI)) by XREAL_1:8; (angle (p2,p3,p1)) - (angle (p6,p4,p5)) = - (4 * PI) by A18, A21; then 4 * PI < 2 * PI by A22, XREAL_1:24; then (4 * PI) / PI < (2 * PI) / PI by XREAL_1:74; then 4 < (2 * PI) / PI by XCMPLX_1:89; then 4 < 2 by XCMPLX_1:89; hence angle (p2,p3,p1) = angle (p6,p4,p5) ; ::_thesis: verum end; supposeA23: ( ((angle (p3,p1,p2)) + (angle (p1,p2,p3))) + (angle (p2,p3,p1)) = 5 * PI & ((angle (p5,p6,p4)) + (angle (p6,p4,p5))) + (angle (p4,p5,p6)) = PI ) ; ::_thesis: angle (p2,p3,p1) = angle (p6,p4,p5) ( angle (p2,p3,p1) < 2 * PI & angle (p6,p4,p5) >= 0 ) by COMPLEX2:70; then (angle (p2,p3,p1)) + (- (angle (p6,p4,p5))) < (2 * PI) + (- 0) by XREAL_1:8; then (4 * PI) / PI < (2 * PI) / PI by A18, A23, XREAL_1:74; then 4 < (2 * PI) / PI by XCMPLX_1:89; then 4 < 2 by XCMPLX_1:89; hence angle (p2,p3,p1) = angle (p6,p4,p5) ; ::_thesis: verum end; end; end; ( angle (p1,p2,p3) <> PI & angle (p2,p3,p1) <> PI ) by A1, Th20; hence |.(p2 - p3).| * |.(p4 - p6).| = |.(p3 - p1).| * |.(p5 - p4).| by A4, A3, A5, A7, A15, A11, A16, A13, A18, Lm19; ::_thesis: ( |.(p2 - p3).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p5 - p4).| & |.(p3 - p1).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p4 - p6).| ) A24: ( angle (p4,p5,p6) <> PI & angle (p5,p6,p4) <> PI ) by A9, Th20; hence |.(p2 - p3).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p5 - p4).| by A3, A5, A7, A15, A11, A16, A13, A18, A20, Lm19; ::_thesis: |.(p3 - p1).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p4 - p6).| thus |.(p3 - p1).| * |.(p6 - p5).| = |.(p1 - p2).| * |.(p4 - p6).| by A3, A5, A7, A24, A15, A11, A16, A13, A18, A20, Lm19; ::_thesis: verum end; theorem Th23: :: EUCLID_6:23 for p1, p2, p3 being Point of (TOP-REAL 2) st p1,p2,p3 are_mutually_different & angle (p1,p2,p3) <= PI holds ( angle (p2,p3,p1) <= PI & angle (p3,p1,p2) <= PI ) proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( p1,p2,p3 are_mutually_different & angle (p1,p2,p3) <= PI implies ( angle (p2,p3,p1) <= PI & angle (p3,p1,p2) <= PI ) ) A1: angle (p1,p2,p3) >= 0 by COMPLEX2:70; assume A2: p1,p2,p3 are_mutually_different ; ::_thesis: ( not angle (p1,p2,p3) <= PI or ( angle (p2,p3,p1) <= PI & angle (p3,p1,p2) <= PI ) ) then p1 <> p3 by ZFMISC_1:def_5; then A3: euc2cpx p1 <> euc2cpx p3 by EUCLID_3:4; p2 <> p3 by A2, ZFMISC_1:def_5; then A4: euc2cpx p2 <> euc2cpx p3 by EUCLID_3:4; p1 <> p2 by A2, ZFMISC_1:def_5; then euc2cpx p1 <> euc2cpx p2 by EUCLID_3:4; then A5: ( ((angle (p1,p2,p3)) + (angle (p2,p3,p1))) + (angle (p3,p1,p2)) = PI or ((angle (p1,p2,p3)) + (angle (p2,p3,p1))) + (angle (p3,p1,p2)) = 5 * PI ) by A3, A4, COMPLEX2:88; ( angle (p2,p3,p1) < 2 * PI & angle (p3,p1,p2) < 2 * PI ) by COMPLEX2:70; then A6: (angle (p2,p3,p1)) + (angle (p3,p1,p2)) < (2 * PI) + (2 * PI) by XREAL_1:8; assume angle (p1,p2,p3) <= PI ; ::_thesis: ( angle (p2,p3,p1) <= PI & angle (p3,p1,p2) <= PI ) then A7: (angle (p1,p2,p3)) + ((angle (p2,p3,p1)) + (angle (p3,p1,p2))) < PI + (4 * PI) by A6, XREAL_1:8; A8: angle (p3,p1,p2) >= 0 by COMPLEX2:70; thus angle (p2,p3,p1) <= PI ::_thesis: angle (p3,p1,p2) <= PI proof assume angle (p2,p3,p1) > PI ; ::_thesis: contradiction then (angle (p1,p2,p3)) + (angle (p2,p3,p1)) > 0 + PI by A1, XREAL_1:8; hence contradiction by A5, A7, A8, XREAL_1:8; ::_thesis: verum end; A9: angle (p2,p3,p1) >= 0 by COMPLEX2:70; thus angle (p3,p1,p2) <= PI ::_thesis: verum proof assume angle (p3,p1,p2) > PI ; ::_thesis: contradiction then (angle (p2,p3,p1)) + (angle (p3,p1,p2)) > 0 + PI by A9, XREAL_1:8; hence contradiction by A5, A7, A1, XREAL_1:8; ::_thesis: verum end; end; theorem Th24: :: EUCLID_6:24 for p1, p2, p3 being Point of (TOP-REAL 2) st p1,p2,p3 are_mutually_different & angle (p1,p2,p3) > PI holds ( angle (p2,p3,p1) > PI & angle (p3,p1,p2) > PI ) proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( p1,p2,p3 are_mutually_different & angle (p1,p2,p3) > PI implies ( angle (p2,p3,p1) > PI & angle (p3,p1,p2) > PI ) ) assume A1: p1,p2,p3 are_mutually_different ; ::_thesis: ( not angle (p1,p2,p3) > PI or ( angle (p2,p3,p1) > PI & angle (p3,p1,p2) > PI ) ) then A2: ( p1 <> p2 & p1 <> p3 ) by ZFMISC_1:def_5; assume A3: angle (p1,p2,p3) > PI ; ::_thesis: ( angle (p2,p3,p1) > PI & angle (p3,p1,p2) > PI ) A4: p2 <> p3 by A1, ZFMISC_1:def_5; then p2,p3,p1 are_mutually_different by A2, ZFMISC_1:def_5; hence angle (p2,p3,p1) > PI by A3, Th23; ::_thesis: angle (p3,p1,p2) > PI p3,p1,p2 are_mutually_different by A2, A4, ZFMISC_1:def_5; hence angle (p3,p1,p2) > PI by A3, Th23; ::_thesis: verum end; Lm20: for n being Element of NAT for q1 being Point of (TOP-REAL n) for f being Function of (TOP-REAL n),R^1 st ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) holds f is continuous proof let n be Element of NAT ; ::_thesis: for q1 being Point of (TOP-REAL n) for f being Function of (TOP-REAL n),R^1 st ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) holds f is continuous let q1 be Point of (TOP-REAL n); ::_thesis: for f being Function of (TOP-REAL n),R^1 st ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) holds f is continuous let f be Function of (TOP-REAL n),R^1; ::_thesis: ( ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) implies f is continuous ) A1: TopStruct(# the carrier of (TOP-REAL n), the topology of (TOP-REAL n) #) = TopSpaceMetr (Euclid n) by EUCLID:def_8; then reconsider f1 = f as Function of (TopSpaceMetr (Euclid n)),(TopSpaceMetr RealSpace) by TOPMETR:def_6; assume A2: for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ; ::_thesis: f is continuous now__::_thesis:_for_r_being_real_number_ for_u_being_Element_of_(Euclid_n) for_u1_being_Element_of_RealSpace_st_r_>_0_&_u1_=_f1_._u_holds_ ex_s_being_real_number_st_ (_s_>_0_&_(_for_w_being_Element_of_(Euclid_n) for_w1_being_Element_of_RealSpace_st_w1_=_f1_._w_&_dist_(u,w)_<_s_holds_ dist_(u1,w1)_<_r_)_) let r be real number ; ::_thesis: for u being Element of (Euclid n) for u1 being Element of RealSpace st r > 0 & u1 = f1 . u holds ex s being real number st ( s > 0 & ( for w being Element of (Euclid n) for w1 being Element of RealSpace st w1 = f1 . w & dist (u,w) < s holds dist (u1,w1) < r ) ) let u be Element of (Euclid n); ::_thesis: for u1 being Element of RealSpace st r > 0 & u1 = f1 . u holds ex s being real number st ( s > 0 & ( for w being Element of (Euclid n) for w1 being Element of RealSpace st w1 = f1 . w & dist (u,w) < s holds dist (u1,w1) < r ) ) let u1 be Element of RealSpace; ::_thesis: ( r > 0 & u1 = f1 . u implies ex s being real number st ( s > 0 & ( for w being Element of (Euclid n) for w1 being Element of RealSpace st w1 = f1 . w & dist (u,w) < s holds dist (u1,w1) < r ) ) ) assume that A3: r > 0 and A4: u1 = f1 . u ; ::_thesis: ex s being real number st ( s > 0 & ( for w being Element of (Euclid n) for w1 being Element of RealSpace st w1 = f1 . w & dist (u,w) < s holds dist (u1,w1) < r ) ) set s1 = r; for w being Element of (Euclid n) for w1 being Element of RealSpace st w1 = f1 . w & dist (u,w) < r holds dist (u1,w1) < r proof let w be Element of (Euclid n); ::_thesis: for w1 being Element of RealSpace st w1 = f1 . w & dist (u,w) < r holds dist (u1,w1) < r let w1 be Element of RealSpace; ::_thesis: ( w1 = f1 . w & dist (u,w) < r implies dist (u1,w1) < r ) assume that A5: w1 = f1 . w and A6: dist (u,w) < r ; ::_thesis: dist (u1,w1) < r reconsider tu = u1, tw = w1 as Real by METRIC_1:def_13; reconsider qw = w, qu = u as Point of (TOP-REAL n) by TOPREAL3:8; A7: dist (u1,w1) = the distance of RealSpace . (u1,w1) by METRIC_1:def_1 .= abs (tu - tw) by METRIC_1:def_12, METRIC_1:def_13 ; A8: tu = |.(qu - q1).| by A2, A4; A9: |.((qu - q1) - (qw - q1)).| = |.((qu - q1) - ((- q1) + qw)).| .= |.(((qu - q1) - (- q1)) - qw).| by EUCLID:46 .= |.(((qu + (- q1)) + q1) - qw).| .= |.((qu + (q1 - q1)) - qw).| by EUCLID:26 .= |.((qu + (0. (TOP-REAL n))) - qw).| by EUCLID:42 .= |.(qu - qw).| by EUCLID:27 ; w1 = |.(qw - q1).| by A2, A5; then ( dist (u,w) = |.(qu - qw).| & dist (u1,w1) <= |.((qu - q1) - (qw - q1)).| ) by A7, A8, JGRAPH_1:28, JORDAN2C:9; hence dist (u1,w1) < r by A6, A9, XXREAL_0:2; ::_thesis: verum end; hence ex s being real number st ( s > 0 & ( for w being Element of (Euclid n) for w1 being Element of RealSpace st w1 = f1 . w & dist (u,w) < s holds dist (u1,w1) < r ) ) by A3; ::_thesis: verum end; then f1 is continuous by UNIFORM1:3; hence f is continuous by A1, PRE_TOPC:32, TOPMETR:def_6; ::_thesis: verum end; Lm21: for n being Element of NAT for q1 being Point of (TOP-REAL n) ex f being Function of (TOP-REAL n),R^1 st ( ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) & f is continuous ) proof let n be Element of NAT ; ::_thesis: for q1 being Point of (TOP-REAL n) ex f being Function of (TOP-REAL n),R^1 st ( ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) & f is continuous ) let q1 be Point of (TOP-REAL n); ::_thesis: ex f being Function of (TOP-REAL n),R^1 st ( ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) & f is continuous ) defpred S1[ set , set ] means ex q being Point of (TOP-REAL n) st ( q = $1 & $2 = |.(q - q1).| ); A1: for x being set st x in the carrier of (TOP-REAL n) holds ex y being set st S1[x,y] proof let x be set ; ::_thesis: ( x in the carrier of (TOP-REAL n) implies ex y being set st S1[x,y] ) assume x in the carrier of (TOP-REAL n) ; ::_thesis: ex y being set st S1[x,y] then reconsider q3 = x as Point of (TOP-REAL n) ; take |.(q3 - q1).| ; ::_thesis: S1[x,|.(q3 - q1).|] thus S1[x,|.(q3 - q1).|] ; ::_thesis: verum end; consider f1 being Function such that A2: ( dom f1 = the carrier of (TOP-REAL n) & ( for x being set st x in the carrier of (TOP-REAL n) holds S1[x,f1 . x] ) ) from CLASSES1:sch_1(A1); rng f1 c= the carrier of R^1 proof let z be set ; :: according to TARSKI:def_3 ::_thesis: ( not z in rng f1 or z in the carrier of R^1 ) assume z in rng f1 ; ::_thesis: z in the carrier of R^1 then consider xz being set such that A3: xz in dom f1 and A4: z = f1 . xz by FUNCT_1:def_3; ex q4 being Point of (TOP-REAL n) st ( q4 = xz & f1 . xz = |.(q4 - q1).| ) by A2, A3; hence z in the carrier of R^1 by A4, TOPMETR:17; ::_thesis: verum end; then reconsider f2 = f1 as Function of (TOP-REAL n),R^1 by A2, FUNCT_2:def_1, RELSET_1:4; A5: for q being Point of (TOP-REAL n) holds f1 . q = |.(q - q1).| proof let q be Point of (TOP-REAL n); ::_thesis: f1 . q = |.(q - q1).| ex q2 being Point of (TOP-REAL n) st ( q2 = q & f1 . q = |.(q2 - q1).| ) by A2; hence f1 . q = |.(q - q1).| ; ::_thesis: verum end; then f2 is continuous by Lm20; hence ex f being Function of (TOP-REAL n),R^1 st ( ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) & f is continuous ) by A5; ::_thesis: verum end; theorem Th25: :: EUCLID_6:25 for p, p1, p2, p3 being Point of (TOP-REAL 2) st p in LSeg (p1,p2) & p1,p2,p3 is_a_triangle & angle (p1,p3,p2) = angle (p,p3,p2) holds p = p1 proof let p, p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p2) & p1,p2,p3 is_a_triangle & angle (p1,p3,p2) = angle (p,p3,p2) implies p = p1 ) assume A1: p in LSeg (p1,p2) ; ::_thesis: ( not p1,p2,p3 is_a_triangle or not angle (p1,p3,p2) = angle (p,p3,p2) or p = p1 ) assume A2: p1,p2,p3 is_a_triangle ; ::_thesis: ( not angle (p1,p3,p2) = angle (p,p3,p2) or p = p1 ) then A3: angle (p3,p1,p2) <> PI by Th20; A4: p1,p2,p3 are_mutually_different by A2, Th20; then p1 <> p2 by ZFMISC_1:def_5; then A5: euc2cpx p2 <> euc2cpx p1 by EUCLID_3:4; A6: not p3 in LSeg (p1,p2) by A2, Def3; ( not p1 in LSeg (p2,p3) & not p2 in LSeg (p3,p1) ) by A2, Def3; then A7: p1,p3,p2 is_a_triangle by A6, Def3; p2 <> p3 by A4, ZFMISC_1:def_5; then A8: |.(p2 - p3).| <> 0 by Lm1; A9: p2 <> p3 by A4, ZFMISC_1:def_5; then A10: euc2cpx p3 <> euc2cpx p2 by EUCLID_3:4; assume A11: angle (p1,p3,p2) = angle (p,p3,p2) ; ::_thesis: p = p1 angle (p2,p3,p1) <> PI by A2, Th20; then A12: angle (p,p3,p2) <> PI by A11, COMPLEX2:82; A13: p <> p3 by A1, A2, Def3; then A14: euc2cpx p <> euc2cpx p3 by EUCLID_3:4; p1 <> p3 by A4, ZFMISC_1:def_5; then A15: euc2cpx p3 <> euc2cpx p1 by EUCLID_3:4; A16: angle (p1,p2,p3) <> PI by A2, Th20; A17: p <> p2 proof assume p = p2 ; ::_thesis: contradiction then angle (p1,p3,p2) = 0 by A11, COMPLEX2:79; then ( ( angle (p3,p2,p1) = 0 & angle (p2,p1,p3) = PI ) or ( angle (p3,p2,p1) = PI & angle (p2,p1,p3) = 0 ) ) by A10, A15, A5, COMPLEX2:87; hence contradiction by A16, A3, COMPLEX2:82; ::_thesis: verum end; then A18: angle (p3,p2,p1) = angle (p3,p2,p) by A1, Th10; then A19: angle (p3,p2,p) <> PI by A16, COMPLEX2:82; A20: p,p3,p2 are_mutually_different by A9, A17, A13, ZFMISC_1:def_5; A21: euc2cpx p <> euc2cpx p2 by A17, EUCLID_3:4; A22: angle (p2,p1,p3) = angle (p2,p,p3) proof percases ( ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ) by A10, A15, A5, A14, A21, COMPLEX2:88; suppose ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ; ::_thesis: angle (p2,p1,p3) = angle (p2,p,p3) hence angle (p2,p1,p3) = angle (p2,p,p3) by A11, A18; ::_thesis: verum end; suppose ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) ; ::_thesis: angle (p2,p1,p3) = angle (p2,p,p3) hence angle (p2,p1,p3) = angle (p2,p,p3) by A11, A18; ::_thesis: verum end; supposeA23: ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) ; ::_thesis: angle (p2,p1,p3) = angle (p2,p,p3) ( angle (p2,p1,p3) >= 0 & - (angle (p2,p,p3)) > - (2 * PI) ) by COMPLEX2:70, XREAL_1:24; then A24: (angle (p2,p1,p3)) + (- (angle (p2,p,p3))) > 0 + (- (2 * PI)) by XREAL_1:8; (angle (p2,p1,p3)) - (angle (p2,p,p3)) = - (4 * PI) by A11, A18, A23; then 4 * PI < 2 * PI by A24, XREAL_1:24; then (4 * PI) / PI < (2 * PI) / PI by XREAL_1:74; then 4 < (2 * PI) / PI by XCMPLX_1:89; then 4 < 2 by XCMPLX_1:89; hence angle (p2,p1,p3) = angle (p2,p,p3) ; ::_thesis: verum end; supposeA25: ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ; ::_thesis: angle (p2,p1,p3) = angle (p2,p,p3) ( angle (p2,p1,p3) < 2 * PI & angle (p2,p,p3) >= 0 ) by COMPLEX2:70; then (angle (p2,p1,p3)) + (- (angle (p2,p,p3))) < (2 * PI) + (- 0) by XREAL_1:8; then (4 * PI) / PI < (2 * PI) / PI by A11, A18, A25, XREAL_1:74; then 4 < (2 * PI) / PI by XCMPLX_1:89; then 4 < 2 by XCMPLX_1:89; hence angle (p2,p1,p3) = angle (p2,p,p3) ; ::_thesis: verum end; end; end; then angle (p2,p,p3) <> PI by A3, COMPLEX2:82; then p,p3,p2 is_a_triangle by A20, A12, A19, Th20; then |.(p2 - p3).| * |.(p - p2).| = |.(p1 - p2).| * |.(p2 - p3).| by A7, A11, A22, Th21; then |.(p - p2).| = |.(p1 - p2).| by A8, XCMPLX_1:5; then A26: |.(p2 - p).| = |.(p1 - p2).| by Lm2 .= |.(p2 - p1).| by Lm2 ; assume A27: p1 <> p ; ::_thesis: contradiction A28: |.(p2 - p1).| ^2 = ((|.(p1 - p).| ^2) + (|.(p2 - p).| ^2)) - (((2 * |.(p1 - p).|) * |.(p2 - p).|) * (cos (angle (p1,p,p2)))) by Th7 .= ((|.(p1 - p).| ^2) + (|.(p2 - p).| ^2)) - (((2 * |.(p1 - p).|) * |.(p2 - p).|) * (- 1)) by A1, A27, A17, Th8, SIN_COS:77 ; percases ( |.(p1 - p).| = 0 or |.(p1 - p).| + (2 * |.(p2 - p).|) = 0 ) by A26, A28; suppose |.(p1 - p).| = 0 ; ::_thesis: contradiction hence contradiction by A27, Lm1; ::_thesis: verum end; suppose |.(p1 - p).| + (2 * |.(p2 - p).|) = 0 ; ::_thesis: contradiction then |.(p1 - p).| = 0 ; hence contradiction by A27, Lm1; ::_thesis: verum end; end; end; theorem Th26: :: EUCLID_6:26 for p, p1, p2, p3 being Point of (TOP-REAL 2) st p in LSeg (p1,p2) & not p3 in LSeg (p1,p2) & angle (p1,p3,p2) <= PI holds angle (p,p3,p2) <= angle (p1,p3,p2) proof let p, p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p2) & not p3 in LSeg (p1,p2) & angle (p1,p3,p2) <= PI implies angle (p,p3,p2) <= angle (p1,p3,p2) ) assume A1: p in LSeg (p1,p2) ; ::_thesis: ( p3 in LSeg (p1,p2) or not angle (p1,p3,p2) <= PI or angle (p,p3,p2) <= angle (p1,p3,p2) ) assume A2: not p3 in LSeg (p1,p2) ; ::_thesis: ( not angle (p1,p3,p2) <= PI or angle (p,p3,p2) <= angle (p1,p3,p2) ) assume A3: angle (p1,p3,p2) <= PI ; ::_thesis: angle (p,p3,p2) <= angle (p1,p3,p2) assume A4: angle (p,p3,p2) > angle (p1,p3,p2) ; ::_thesis: contradiction percases ( p = p1 or p = p2 or p1 = p2 or ( p <> p2 & p1 <> p2 & p <> p1 ) ) ; suppose p = p1 ; ::_thesis: contradiction hence contradiction by A4; ::_thesis: verum end; suppose p = p2 ; ::_thesis: contradiction then angle (p,p3,p2) = 0 by COMPLEX2:79; hence contradiction by A4, COMPLEX2:70; ::_thesis: verum end; supposeA5: p1 = p2 ; ::_thesis: contradiction then p in {p2} by A1, RLTOPSP1:70; hence contradiction by A4, A5, TARSKI:def_1; ::_thesis: verum end; supposeA6: ( p <> p2 & p1 <> p2 & p <> p1 ) ; ::_thesis: contradiction then A7: euc2cpx p <> euc2cpx p1 by EUCLID_3:4; A8: p3 <> p1 by A2, RLTOPSP1:68; then A9: euc2cpx p3 <> euc2cpx p1 by EUCLID_3:4; A10: ( euc2cpx p2 <> euc2cpx p1 & euc2cpx p <> euc2cpx p2 ) by A6, EUCLID_3:4; A11: euc2cpx p <> euc2cpx p3 by A1, A2, EUCLID_3:4; A12: angle (p3,p2,p1) = angle (p3,p2,p) by A1, A6, Th10; A13: p3 <> p2 by A2, RLTOPSP1:68; then A14: euc2cpx p3 <> euc2cpx p2 by EUCLID_3:4; (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) proof percases ( ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ) by A14, A9, A11, A10, COMPLEX2:88; suppose ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ; ::_thesis: (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) hence (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) by A12; ::_thesis: verum end; suppose ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) ; ::_thesis: (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) hence (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) by A12; ::_thesis: verum end; supposeA15: ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) ; ::_thesis: (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) A16: ( angle (p1,p3,p2) >= 0 & angle (p2,p1,p3) >= 0 ) by COMPLEX2:70; angle (p2,p,p3) < 2 * PI by COMPLEX2:70; then A17: - (angle (p2,p,p3)) > - (2 * PI) by XREAL_1:24; angle (p,p3,p2) < 2 * PI by COMPLEX2:70; then - (angle (p,p3,p2)) > - (2 * PI) by XREAL_1:24; then (- (angle (p,p3,p2))) + (- (angle (p2,p,p3))) > (- (2 * PI)) + (- (2 * PI)) by A17, XREAL_1:8; then ((angle (p1,p3,p2)) + (angle (p2,p1,p3))) + ((- (angle (p,p3,p2))) - (angle (p2,p,p3))) > (0 + 0) + ((- (2 * PI)) - (2 * PI)) by A16, XREAL_1:8; hence (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) by A12, A15; ::_thesis: verum end; supposeA18: ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ; ::_thesis: (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) ( angle (p2,p1,p3) < 2 * PI & angle (p1,p3,p2) < 2 * PI ) by COMPLEX2:70; then A19: (angle (p2,p1,p3)) + (angle (p1,p3,p2)) < (2 * PI) + (2 * PI) by XREAL_1:8; ( angle (p,p3,p2) >= 0 & angle (p2,p,p3) >= 0 ) by COMPLEX2:70; then ((angle (p2,p1,p3)) + (angle (p1,p3,p2))) + ((- (angle (p,p3,p2))) - (angle (p2,p,p3))) < ((2 * PI) + (2 * PI)) + (0 + 0) by A19, XREAL_1:8; hence (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) by A12, A18; ::_thesis: verum end; end; end; then A20: angle (p2,p1,p3) > angle (p2,p,p3) by A4, XREAL_1:8; percases ( ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = PI ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = PI ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = 5 * PI ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = 5 * PI ) ) by A1, A6, A9, A11, A7, Th13, COMPLEX2:88; suppose ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = PI ) ; ::_thesis: contradiction then (angle (p1,p3,p)) + (angle (p,p1,p3)) < 0 + (angle (p,p1,p3)) by A1, A20, Th9; then angle (p1,p3,p) < 0 by XREAL_1:6; hence contradiction by COMPLEX2:70; ::_thesis: verum end; supposeA21: ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = PI ) ; ::_thesis: contradiction A22: ( angle (p,p1,p3) >= 0 & angle (p1,p3,p) >= 0 ) by COMPLEX2:70; angle (p2,p,p3) = ((angle (p,p1,p3)) + (angle (p1,p3,p))) + (2 * PI) by A21; then angle (p2,p,p3) >= 0 + (2 * PI) by A22, XREAL_1:6; hence contradiction by COMPLEX2:70; ::_thesis: verum end; supposeA23: ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = 5 * PI ) ; ::_thesis: contradiction ( angle (p,p1,p3) < 2 * PI & angle (p1,p3,p) < 2 * PI ) by COMPLEX2:70; then (angle (p,p1,p3)) + (angle (p1,p3,p)) < (2 * PI) + (2 * PI) by XREAL_1:8; then (angle (p2,p,p3)) + (4 * PI) < 0 + (4 * PI) by A23; then angle (p2,p,p3) < 0 by XREAL_1:6; hence contradiction by COMPLEX2:70; ::_thesis: verum end; supposeA24: ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = 5 * PI ) ; ::_thesis: contradiction p1,p3,p2 are_mutually_different by A6, A8, A13, ZFMISC_1:def_5; then angle (p2,p1,p3) <= PI by A3, Th23; then A25: angle (p,p1,p3) <= PI by A1, A6, Th9; p,p1,p3 are_mutually_different by A1, A2, A6, A8, ZFMISC_1:def_5; then ( angle (p1,p3,p) <= PI & angle (p3,p,p1) <= PI ) by A25, Th23; then (angle (p3,p,p1)) + (angle (p1,p3,p)) <= PI + PI by XREAL_1:7; then ((angle (p3,p,p1)) + (angle (p1,p3,p))) + (angle (p,p1,p3)) <= (2 * PI) + PI by A25, XREAL_1:7; hence contradiction by A24, XREAL_1:68; ::_thesis: verum end; end; end; end; end; theorem Th27: :: EUCLID_6:27 for p, p1, p2, p3 being Point of (TOP-REAL 2) st p in LSeg (p1,p2) & not p3 in LSeg (p1,p2) & angle (p1,p3,p2) > PI & p <> p2 holds angle (p,p3,p2) >= angle (p1,p3,p2) proof let p, p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p2) & not p3 in LSeg (p1,p2) & angle (p1,p3,p2) > PI & p <> p2 implies angle (p,p3,p2) >= angle (p1,p3,p2) ) assume A1: p in LSeg (p1,p2) ; ::_thesis: ( p3 in LSeg (p1,p2) or not angle (p1,p3,p2) > PI or not p <> p2 or angle (p,p3,p2) >= angle (p1,p3,p2) ) assume A2: not p3 in LSeg (p1,p2) ; ::_thesis: ( not angle (p1,p3,p2) > PI or not p <> p2 or angle (p,p3,p2) >= angle (p1,p3,p2) ) assume A3: angle (p1,p3,p2) > PI ; ::_thesis: ( not p <> p2 or angle (p,p3,p2) >= angle (p1,p3,p2) ) assume A4: p <> p2 ; ::_thesis: angle (p,p3,p2) >= angle (p1,p3,p2) assume A5: angle (p,p3,p2) < angle (p1,p3,p2) ; ::_thesis: contradiction percases ( p = p1 or p1 = p2 or ( p1 <> p2 & p <> p1 ) ) ; suppose p = p1 ; ::_thesis: contradiction hence contradiction by A5; ::_thesis: verum end; supposeA6: p1 = p2 ; ::_thesis: contradiction then p in {p2} by A1, RLTOPSP1:70; hence contradiction by A5, A6, TARSKI:def_1; ::_thesis: verum end; supposeA7: ( p1 <> p2 & p <> p1 ) ; ::_thesis: contradiction then A8: euc2cpx p2 <> euc2cpx p1 by EUCLID_3:4; A9: euc2cpx p <> euc2cpx p2 by A4, EUCLID_3:4; A10: angle (p3,p2,p1) = angle (p3,p2,p) by A1, A4, Th10; A11: euc2cpx p <> euc2cpx p1 by A7, EUCLID_3:4; A12: euc2cpx p <> euc2cpx p3 by A1, A2, EUCLID_3:4; A13: p3 <> p1 by A2, RLTOPSP1:68; then A14: euc2cpx p3 <> euc2cpx p1 by EUCLID_3:4; A15: p3 <> p2 by A2, RLTOPSP1:68; then A16: euc2cpx p3 <> euc2cpx p2 by EUCLID_3:4; (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) proof percases ( ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) or ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ) by A16, A14, A8, A12, A9, COMPLEX2:88; suppose ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ; ::_thesis: (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) hence (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) by A10; ::_thesis: verum end; suppose ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) ; ::_thesis: (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) hence (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) by A10; ::_thesis: verum end; supposeA17: ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = 5 * PI ) ; ::_thesis: (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) A18: ( angle (p1,p3,p2) >= 0 & angle (p2,p1,p3) >= 0 ) by COMPLEX2:70; angle (p2,p,p3) < 2 * PI by COMPLEX2:70; then A19: - (angle (p2,p,p3)) > - (2 * PI) by XREAL_1:24; angle (p,p3,p2) < 2 * PI by COMPLEX2:70; then - (angle (p,p3,p2)) > - (2 * PI) by XREAL_1:24; then (- (angle (p,p3,p2))) + (- (angle (p2,p,p3))) > (- (2 * PI)) + (- (2 * PI)) by A19, XREAL_1:8; then ((angle (p1,p3,p2)) + (angle (p2,p1,p3))) + ((- (angle (p,p3,p2))) - (angle (p2,p,p3))) > (0 + 0) + ((- (2 * PI)) - (2 * PI)) by A18, XREAL_1:8; hence (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) by A10, A17; ::_thesis: verum end; supposeA20: ( ((angle (p1,p3,p2)) + (angle (p3,p2,p1))) + (angle (p2,p1,p3)) = 5 * PI & ((angle (p,p3,p2)) + (angle (p3,p2,p))) + (angle (p2,p,p3)) = PI ) ; ::_thesis: (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) ( angle (p2,p1,p3) < 2 * PI & angle (p1,p3,p2) < 2 * PI ) by COMPLEX2:70; then A21: (angle (p2,p1,p3)) + (angle (p1,p3,p2)) < (2 * PI) + (2 * PI) by XREAL_1:8; ( angle (p,p3,p2) >= 0 & angle (p2,p,p3) >= 0 ) by COMPLEX2:70; then ((angle (p2,p1,p3)) + (angle (p1,p3,p2))) + ((- (angle (p,p3,p2))) - (angle (p2,p,p3))) < ((2 * PI) + (2 * PI)) + (0 + 0) by A21, XREAL_1:8; hence (angle (p1,p3,p2)) + (angle (p2,p1,p3)) = (angle (p,p3,p2)) + (angle (p2,p,p3)) by A10, A20; ::_thesis: verum end; end; end; then angle (p2,p1,p3) < angle (p2,p,p3) by A5, XREAL_1:8; then A22: angle (p,p1,p3) < angle (p2,p,p3) by A1, Th9; percases ( ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = PI ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = PI ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = 5 * PI ) or ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = 5 * PI ) ) by A1, A4, A14, A12, A11, Th13, COMPLEX2:88; supposeA23: ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = PI ) ; ::_thesis: contradiction p1,p3,p2 are_mutually_different by A7, A13, A15, ZFMISC_1:def_5; then angle (p2,p1,p3) > PI by A3, Th24; then A24: angle (p,p1,p3) > PI by A1, A7, Th9; p,p1,p3 are_mutually_different by A1, A2, A7, A13, ZFMISC_1:def_5; then ( angle (p1,p3,p) > PI & angle (p3,p,p1) > PI ) by A24, Th24; then (angle (p3,p,p1)) + (angle (p1,p3,p)) > PI + PI by XREAL_1:8; then A25: ((angle (p3,p,p1)) + (angle (p1,p3,p))) + (angle (p,p1,p3)) > (2 * PI) + PI by A24, XREAL_1:8; 1 * PI < 3 * PI by XREAL_1:68; hence contradiction by A23, A25; ::_thesis: verum end; supposeA26: ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = PI ) ; ::_thesis: contradiction A27: ( angle (p,p1,p3) >= 0 & angle (p1,p3,p) >= 0 ) by COMPLEX2:70; angle (p2,p,p3) = ((angle (p,p1,p3)) + (angle (p1,p3,p))) + (2 * PI) by A26; then angle (p2,p,p3) >= 0 + (2 * PI) by A27, XREAL_1:6; hence contradiction by COMPLEX2:70; ::_thesis: verum end; supposeA28: ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = 5 * PI ) ; ::_thesis: contradiction ( angle (p,p1,p3) < 2 * PI & angle (p1,p3,p) < 2 * PI ) by COMPLEX2:70; then (angle (p,p1,p3)) + (angle (p1,p3,p)) < (2 * PI) + (2 * PI) by XREAL_1:8; then (angle (p2,p,p3)) + (4 * PI) < 0 + (4 * PI) by A28; then angle (p2,p,p3) < 0 by XREAL_1:6; hence contradiction by COMPLEX2:70; ::_thesis: verum end; suppose ( (angle (p2,p,p3)) + (angle (p3,p,p1)) = 3 * PI & ((angle (p3,p,p1)) + (angle (p,p1,p3))) + (angle (p1,p3,p)) = 5 * PI ) ; ::_thesis: contradiction then (angle (p2,p,p3)) + (2 * PI) = (angle (p,p1,p3)) + (angle (p1,p3,p)) ; then (angle (p2,p,p3)) + (2 * PI) < (angle (p2,p,p3)) + (angle (p1,p3,p)) by A22, XREAL_1:6; then 2 * PI < angle (p1,p3,p) by XREAL_1:6; hence contradiction by COMPLEX2:70; ::_thesis: verum end; end; end; end; end; theorem Th28: :: EUCLID_6:28 for p, p1, p2, p3 being Point of (TOP-REAL 2) st p in LSeg (p1,p2) & not p3 in LSeg (p1,p2) holds ex p4 being Point of (TOP-REAL 2) st ( p4 in LSeg (p1,p2) & angle (p1,p3,p4) = angle (p,p3,p2) ) proof let p, p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: ( p in LSeg (p1,p2) & not p3 in LSeg (p1,p2) implies ex p4 being Point of (TOP-REAL 2) st ( p4 in LSeg (p1,p2) & angle (p1,p3,p4) = angle (p,p3,p2) ) ) assume A1: p in LSeg (p1,p2) ; ::_thesis: ( p3 in LSeg (p1,p2) or ex p4 being Point of (TOP-REAL 2) st ( p4 in LSeg (p1,p2) & angle (p1,p3,p4) = angle (p,p3,p2) ) ) assume A2: not p3 in LSeg (p1,p2) ; ::_thesis: ex p4 being Point of (TOP-REAL 2) st ( p4 in LSeg (p1,p2) & angle (p1,p3,p4) = angle (p,p3,p2) ) percases ( p1 = p2 or p = p2 or p1 in LSeg (p2,p3) or p = p1 or p2 in LSeg (p1,p3) or ( p1 <> p2 & p <> p1 & p <> p2 & not p1 in LSeg (p2,p3) & not p2 in LSeg (p1,p3) ) ) ; supposeA3: p1 = p2 ; ::_thesis: ex p4 being Point of (TOP-REAL 2) st ( p4 in LSeg (p1,p2) & angle (p1,p3,p4) = angle (p,p3,p2) ) set p4 = p; take p ; ::_thesis: ( p in LSeg (p1,p2) & angle (p1,p3,p) = angle (p,p3,p2) ) thus p in LSeg (p1,p2) by A1; ::_thesis: angle (p1,p3,p) = angle (p,p3,p2) LSeg (p1,p2) = {p1} by A3, RLTOPSP1:70; then p = p1 by A1, TARSKI:def_1; hence angle (p1,p3,p) = angle (p,p3,p2) by A3; ::_thesis: verum end; supposeA4: ( p = p2 or p1 in LSeg (p2,p3) ) ; ::_thesis: ex p4 being Point of (TOP-REAL 2) st ( p4 in LSeg (p1,p2) & angle (p1,p3,p4) = angle (p,p3,p2) ) set p4 = p1; take p1 ; ::_thesis: ( p1 in LSeg (p1,p2) & angle (p1,p3,p1) = angle (p,p3,p2) ) thus p1 in LSeg (p1,p2) by RLTOPSP1:68; ::_thesis: angle (p1,p3,p1) = angle (p,p3,p2) percases ( p = p2 or p1 in LSeg (p2,p3) ) by A4; supposeA5: p = p2 ; ::_thesis: angle (p1,p3,p1) = angle (p,p3,p2) thus angle (p1,p3,p1) = 0 by COMPLEX2:79 .= angle (p,p3,p2) by A5, COMPLEX2:79 ; ::_thesis: verum end; supposeA6: p1 in LSeg (p2,p3) ; ::_thesis: angle (p1,p3,p1) = angle (p,p3,p2) p2 in LSeg (p3,p2) by RLTOPSP1:68; then A7: LSeg (p1,p2) c= LSeg (p3,p2) by A6, TOPREAL1:6; thus angle (p1,p3,p1) = 0 by COMPLEX2:79 .= angle (p2,p3,p2) by COMPLEX2:79 .= angle (p,p3,p2) by A1, A2, A7, Th9 ; ::_thesis: verum end; end; end; supposeA8: ( p = p1 or p2 in LSeg (p1,p3) ) ; ::_thesis: ex p4 being Point of (TOP-REAL 2) st ( p4 in LSeg (p1,p2) & angle (p1,p3,p4) = angle (p,p3,p2) ) set p4 = p2; take p2 ; ::_thesis: ( p2 in LSeg (p1,p2) & angle (p1,p3,p2) = angle (p,p3,p2) ) thus p2 in LSeg (p1,p2) by RLTOPSP1:68; ::_thesis: angle (p1,p3,p2) = angle (p,p3,p2) percases ( p = p1 or p2 in LSeg (p1,p3) ) by A8; suppose p = p1 ; ::_thesis: angle (p1,p3,p2) = angle (p,p3,p2) hence angle (p1,p3,p2) = angle (p,p3,p2) ; ::_thesis: verum end; supposeA9: p2 in LSeg (p1,p3) ; ::_thesis: angle (p1,p3,p2) = angle (p,p3,p2) p1 in LSeg (p1,p3) by RLTOPSP1:68; then LSeg (p1,p2) c= LSeg (p1,p3) by A9, TOPREAL1:6; hence angle (p1,p3,p2) = angle (p,p3,p2) by A1, A2, Th9; ::_thesis: verum end; end; end; supposeA10: ( p1 <> p2 & p <> p1 & p <> p2 & not p1 in LSeg (p2,p3) & not p2 in LSeg (p1,p3) ) ; ::_thesis: ex p4 being Point of (TOP-REAL 2) st ( p4 in LSeg (p1,p2) & angle (p1,p3,p4) = angle (p,p3,p2) ) p1 in LSeg (p1,p2) by RLTOPSP1:68; then reconsider q1 = p1 as Point of ((TOP-REAL 2) | (LSeg (p1,p2))) by PRE_TOPC:8; A11: 1 * (- 2) <= (cos (angle (p,p3,p2))) * (- 2) by SIN_COS6:6, XREAL_1:65; consider f1 being Function of (TOP-REAL 2),R^1 such that A12: for q being Point of (TOP-REAL 2) holds f1 . q = |.(q - p1).| and A13: f1 is continuous by Lm21; consider f12 being Function of (TOP-REAL 2),R^1 such that A14: for q being Point of (TOP-REAL 2) for r1, r2 being real number st f1 . q = r1 & f1 . q = r2 holds f12 . q = r1 * r2 and A15: f12 is continuous by A13, JGRAPH_2:25; consider f3 being Function of (TOP-REAL 2),R^1 such that A16: for q being Point of (TOP-REAL 2) holds f3 . q = |.(q - p3).| and A17: f3 is continuous by Lm21; consider f32 being Function of (TOP-REAL 2),R^1 such that A18: for q being Point of (TOP-REAL 2) for r1, r2 being real number st f3 . q = r1 & f3 . q = r2 holds f32 . q = r1 * r2 and A19: f32 is continuous by A17, JGRAPH_2:25; A20: |.(p2 - p1).| ^2 = ((|.(p1 - p3).| ^2) + (|.(p2 - p3).| ^2)) - (((2 * |.(p1 - p3).|) * |.(p2 - p3).|) * (cos (angle (p1,p3,p2)))) by Th7; A21: p2 <> p3 by A2, RLTOPSP1:68; then A22: |.(p2 - p3).| <> 0 by Lm1; p2 in LSeg (p1,p2) by RLTOPSP1:68; then reconsider q2 = p2 as Point of ((TOP-REAL 2) | (LSeg (p1,p2))) by PRE_TOPC:8; consider f0 being Function of ((TOP-REAL 2) | (LSeg (p1,p2))),(TOP-REAL 2) such that A23: for q being Point of ((TOP-REAL 2) | (LSeg (p1,p2))) holds f0 . q = q and A24: f0 is continuous by JGRAPH_6:6; set d = (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|); consider f2 being Function of (TOP-REAL 2),R^1 such that A25: for q being Point of (TOP-REAL 2) holds f2 . q = |.(p1 - p3).| and A26: f2 is continuous by JGRAPH_2:20; A27: p1 <> p3 by A2, RLTOPSP1:68; then A28: |.(p1 - p3).| <> 0 by Lm1; A29: cos (angle (p,p3,p2)) <> 1 proof A30: ( 0 <= angle (p,p3,p2) & angle (p,p3,p2) < 2 * PI ) by COMPLEX2:70; assume cos (angle (p,p3,p2)) = 1 ; ::_thesis: contradiction then A31: angle (p,p3,p2) = 0 by A30, COMPTRIG:61; A32: ( euc2cpx p <> euc2cpx p3 & euc2cpx p <> euc2cpx p2 ) by A1, A2, A10, EUCLID_3:4; A33: euc2cpx p3 <> euc2cpx p2 by A21, EUCLID_3:4; percases ( ( angle (p3,p2,p) = 0 & angle (p2,p,p3) = PI ) or ( angle (p3,p2,p) = PI & angle (p2,p,p3) = 0 ) ) by A31, A32, A33, COMPLEX2:87; suppose ( angle (p3,p2,p) = 0 & angle (p2,p,p3) = PI ) ; ::_thesis: contradiction then p in LSeg (p2,p3) by Th11; hence contradiction by A1, A2, A10, A27, Th12; ::_thesis: verum end; suppose ( angle (p3,p2,p) = PI & angle (p2,p,p3) = 0 ) ; ::_thesis: contradiction then angle (p3,p2,p1) = PI by A1, A10, Th10; hence contradiction by A10, Th11; ::_thesis: verum end; end; end; A34: for q being Point of ((TOP-REAL 2) | (LSeg (p1,p2))) holds ( q is Point of (TOP-REAL 2) & q in LSeg (p1,p2) ) proof let q be Point of ((TOP-REAL 2) | (LSeg (p1,p2))); ::_thesis: ( q is Point of (TOP-REAL 2) & q in LSeg (p1,p2) ) A35: q in the carrier of ((TOP-REAL 2) | (LSeg (p1,p2))) ; then q in LSeg (p1,p2) by PRE_TOPC:8; hence q is Point of (TOP-REAL 2) ; ::_thesis: q in LSeg (p1,p2) thus q in LSeg (p1,p2) by A35, PRE_TOPC:8; ::_thesis: verum end; consider f6 being Function of (TOP-REAL 2),R^1 such that A36: for q being Point of (TOP-REAL 2) for r1, r2 being real number st f2 . q = r1 & f3 . q = r2 holds f6 . q = r1 * r2 and A37: f6 is continuous by A26, A17, JGRAPH_2:25; reconsider f8 = f6 * f0 as continuous Function of ((TOP-REAL 2) | (LSeg (p1,p2))),R^1 by A24, A37; consider f22 being Function of (TOP-REAL 2),R^1 such that A38: for q being Point of (TOP-REAL 2) for r1, r2 being real number st f2 . q = r1 & f2 . q = r2 holds f22 . q = r1 * r2 and A39: f22 is continuous by A26, JGRAPH_2:25; consider f4 being Function of (TOP-REAL 2),R^1 such that A40: for q being Point of (TOP-REAL 2) for r1, r2 being real number st f12 . q = r1 & f22 . q = r2 holds f4 . q = r1 - r2 and A41: f4 is continuous by A15, A39, JGRAPH_2:21; consider f5 being Function of (TOP-REAL 2),R^1 such that A42: for q being Point of (TOP-REAL 2) for r1, r2 being real number st f4 . q = r1 & f32 . q = r2 holds f5 . q = r1 - r2 and A43: f5 is continuous by A19, A41, JGRAPH_2:21; A44: |.(p - p3).| <> 0 by A1, A2, Lm1; reconsider f7 = f5 * f0 as continuous Function of ((TOP-REAL 2) | (LSeg (p1,p2))),R^1 by A24, A43; A45: for q being Point of ((TOP-REAL 2) | (LSeg (p1,p2))) for q1 being Point of (TOP-REAL 2) st q = q1 holds f8 . q = |.(p1 - p3).| * |.(q1 - p3).| proof let q be Point of ((TOP-REAL 2) | (LSeg (p1,p2))); ::_thesis: for q1 being Point of (TOP-REAL 2) st q = q1 holds f8 . q = |.(p1 - p3).| * |.(q1 - p3).| let q1 be Point of (TOP-REAL 2); ::_thesis: ( q = q1 implies f8 . q = |.(p1 - p3).| * |.(q1 - p3).| ) dom f8 = the carrier of ((TOP-REAL 2) | (LSeg (p1,p2))) by FUNCT_2:def_1; then A46: f8 . q = f6 . (f0 . q) by FUNCT_1:12 .= f6 . q by A23 ; assume A47: q = q1 ; ::_thesis: f8 . q = |.(p1 - p3).| * |.(q1 - p3).| then ( f6 . q = (f2 . q) * (f3 . q) & f2 . q = |.(p1 - p3).| ) by A25, A36; hence f8 . q = |.(p1 - p3).| * |.(q1 - p3).| by A16, A47, A46; ::_thesis: verum end; for q being Point of ((TOP-REAL 2) | (LSeg (p1,p2))) holds f8 . q <> 0 proof let q be Point of ((TOP-REAL 2) | (LSeg (p1,p2))); ::_thesis: f8 . q <> 0 reconsider q1 = q as Point of (TOP-REAL 2) by A34; A48: f8 . q = |.(p1 - p3).| * |.(q1 - p3).| by A45; assume A49: f8 . q = 0 ; ::_thesis: contradiction percases ( |.(p1 - p3).| = 0 or |.(q1 - p3).| = 0 ) by A48, A49; suppose |.(p1 - p3).| = 0 ; ::_thesis: contradiction hence contradiction by A27, Lm1; ::_thesis: verum end; suppose |.(q1 - p3).| = 0 ; ::_thesis: contradiction then q = p3 by Lm1; hence contradiction by A2, A34; ::_thesis: verum end; end; end; then consider f9 being Function of ((TOP-REAL 2) | (LSeg (p1,p2))),R^1 such that A50: for q being Point of ((TOP-REAL 2) | (LSeg (p1,p2))) for r1, r2 being real number st f7 . q = r1 & f8 . q = r2 holds f9 . q = r1 / r2 and A51: f9 is continuous by JGRAPH_2:27; consider f being Function of I[01],((TOP-REAL 2) | (LSeg (p1,p2))) such that A52: for x being Real st x in [.0,1.] holds f . x = ((1 - x) * p1) + (x * p2) and A53: f is being_homeomorphism and A54: f . 0 = p1 and A55: f . 1 = p2 by A10, JORDAN5A:3; f is continuous by A53, TOPS_2:def_5; then reconsider g = f9 * f as continuous Function of (Closed-Interval-TSpace (0,1)),R^1 by A51, TOPMETR:20; A56: dom g = [.0,1.] by BORSUK_1:40, FUNCT_2:def_1; set b = g . 1; 1 in { r where r is Real : ( 0 <= r & r <= 1 ) } ; then 1 in dom g by A56, RCOMP_1:def_1; then A57: g . 1 = f9 . p2 by A55, FUNCT_1:12; |.(p2 - p).| ^2 = ((|.(p - p3).| ^2) + (|.(p2 - p3).| ^2)) - (((2 * |.(p - p3).|) * |.(p2 - p3).|) * (cos (angle (p,p3,p2)))) by Th7; then A58: (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) = ((- 2) * ((|.(p - p3).| * |.(p2 - p3).|) * (cos (angle (p,p3,p2))))) / (|.(p - p3).| * |.(p2 - p3).|) .= (- 2) * (((|.(p - p3).| * |.(p2 - p3).|) * (cos (angle (p,p3,p2)))) / (|.(p - p3).| * |.(p2 - p3).|)) by XCMPLX_1:74 .= (- 2) * (cos (angle (p,p3,p2))) by A22, A44, XCMPLX_1:89 ; A59: for q being Point of ((TOP-REAL 2) | (LSeg (p1,p2))) for q1 being Point of (TOP-REAL 2) st q = q1 holds f9 . q = (((|.(q1 - p1).| ^2) - (|.(p1 - p3).| ^2)) - (|.(q1 - p3).| ^2)) / (|.(p1 - p3).| * |.(q1 - p3).|) proof let q be Point of ((TOP-REAL 2) | (LSeg (p1,p2))); ::_thesis: for q1 being Point of (TOP-REAL 2) st q = q1 holds f9 . q = (((|.(q1 - p1).| ^2) - (|.(p1 - p3).| ^2)) - (|.(q1 - p3).| ^2)) / (|.(p1 - p3).| * |.(q1 - p3).|) let q1 be Point of (TOP-REAL 2); ::_thesis: ( q = q1 implies f9 . q = (((|.(q1 - p1).| ^2) - (|.(p1 - p3).| ^2)) - (|.(q1 - p3).| ^2)) / (|.(p1 - p3).| * |.(q1 - p3).|) ) A60: q is Point of (TOP-REAL 2) by A34; dom f7 = the carrier of ((TOP-REAL 2) | (LSeg (p1,p2))) by FUNCT_2:def_1; then A61: f7 . q = f5 . (f0 . q) by FUNCT_1:12 .= f5 . q by A23 .= (f4 . q) - (f32 . q) by A42, A60 .= ((f12 . q) - (f22 . q)) - (f32 . q) by A40, A60 .= ((f12 . q) - (f22 . q)) - ((f3 . q) * (f3 . q)) by A18, A60 .= (((f1 . q) * (f1 . q)) - (f22 . q)) - ((f3 . q) * (f3 . q)) by A14, A60 .= (((f1 . q) * (f1 . q)) - ((f2 . q) * (f2 . q))) - ((f3 . q) * (f3 . q)) by A38, A60 ; A62: f9 . q = (f7 . q) / (f8 . q) by A50; assume A63: q = q1 ; ::_thesis: f9 . q = (((|.(q1 - p1).| ^2) - (|.(p1 - p3).| ^2)) - (|.(q1 - p3).| ^2)) / (|.(p1 - p3).| * |.(q1 - p3).|) then A64: f3 . q = |.(q1 - p3).| by A16; ( f1 . q = |.(q1 - p1).| & f2 . q = |.(p1 - p3).| ) by A12, A25, A63; hence f9 . q = (((|.(q1 - p1).| ^2) - (|.(p1 - p3).| ^2)) - (|.(q1 - p3).| ^2)) / (|.(p1 - p3).| * |.(q1 - p3).|) by A45, A63, A62, A61, A64; ::_thesis: verum end; then f9 . q2 = (((|.(p2 - p1).| ^2) - (|.(p1 - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p1 - p3).| * |.(p2 - p3).|) ; then A65: f9 . q2 = ((- 2) * ((|.(p1 - p3).| * |.(p2 - p3).|) * (cos (angle (p1,p3,p2))))) / (|.(p1 - p3).| * |.(p2 - p3).|) by A20 .= (- 2) * (((|.(p1 - p3).| * |.(p2 - p3).|) * (cos (angle (p1,p3,p2)))) / (|.(p1 - p3).| * |.(p2 - p3).|)) by XCMPLX_1:74 .= (- 2) * (cos (angle (p1,p3,p2))) by A28, A22, XCMPLX_1:89 ; A66: (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) < g . 1 proof percases ( angle (p1,p3,p2) <= PI or angle (p1,p3,p2) > PI ) ; supposeA67: angle (p1,p3,p2) <= PI ; ::_thesis: (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) < g . 1 A68: [.0,PI.] /\ (dom cos) = [.0,PI.] by SIN_COS:24, XBOOLE_1:28; 0 <= angle (p1,p3,p2) by COMPLEX2:70; then A69: angle (p1,p3,p2) in [.0,PI.] /\ (dom cos) by A67, A68, XXREAL_1:1; A70: ( cos . (angle (p1,p3,p2)) = cos (angle (p1,p3,p2)) & cos . (angle (p,p3,p2)) = cos (angle (p,p3,p2)) ) by SIN_COS:def_19; A71: angle (p,p3,p2) <= angle (p1,p3,p2) by A1, A2, A67, Th26; then ( 0 <= angle (p,p3,p2) & angle (p,p3,p2) <= PI ) by A67, COMPLEX2:70, XXREAL_0:2; then A72: angle (p,p3,p2) in [.0,PI.] /\ (dom cos) by A68, XXREAL_1:1; p1,p2,p3 is_a_triangle by A2, A10, Def3; then A73: angle (p,p3,p2) < angle (p1,p3,p2) by A1, A10, A71, Th25, XXREAL_0:1; cos | [.((2 * PI) * 0),(PI + ((2 * PI) * 0)).] is decreasing by SIN_COS6:55; then cos . (angle (p1,p3,p2)) < cos . (angle (p,p3,p2)) by A73, A72, A69, RFUNCT_2:21; hence (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) < g . 1 by A57, A65, A58, A70, XREAL_1:69; ::_thesis: verum end; supposeA74: angle (p1,p3,p2) > PI ; ::_thesis: (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) < g . 1 A75: [.PI,(2 * PI).] /\ (dom cos) = [.PI,(2 * PI).] by SIN_COS:24, XBOOLE_1:28; A76: angle (p,p3,p2) <= 2 * PI by COMPLEX2:70; A77: angle (p,p3,p2) >= angle (p1,p3,p2) by A1, A2, A10, A74, Th27; then PI <= angle (p,p3,p2) by A74, XXREAL_0:2; then A78: angle (p,p3,p2) in [.PI,(2 * PI).] /\ (dom cos) by A75, A76, XXREAL_1:1; angle (p1,p3,p2) <= 2 * PI by COMPLEX2:70; then A79: angle (p1,p3,p2) in [.PI,(2 * PI).] /\ (dom cos) by A74, A75, XXREAL_1:1; A80: ( cos . (angle (p1,p3,p2)) = cos (angle (p1,p3,p2)) & cos . (angle (p,p3,p2)) = cos (angle (p,p3,p2)) ) by SIN_COS:def_19; p1,p2,p3 is_a_triangle by A2, A10, Def3; then A81: angle (p,p3,p2) > angle (p1,p3,p2) by A1, A10, A77, Th25, XXREAL_0:1; cos | [.(PI + ((2 * PI) * 0)),((2 * PI) + ((2 * PI) * 0)).] is increasing by SIN_COS6:56; then cos . (angle (p1,p3,p2)) < cos . (angle (p,p3,p2)) by A81, A78, A79, RFUNCT_2:20; hence (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) < g . 1 by A57, A65, A58, A80, XREAL_1:69; ::_thesis: verum end; end; end; set a = g . 0; 0 in { r where r is Real : ( 0 <= r & r <= 1 ) } ; then 0 in dom g by A56, RCOMP_1:def_1; then A82: g . 0 = f9 . p1 by A54, FUNCT_1:12; A83: f9 . q1 = (((|.(p1 - p1).| ^2) - (|.(p1 - p3).| ^2)) - (|.(p1 - p3).| ^2)) / (|.(p1 - p3).| * |.(p1 - p3).|) by A59 .= (((0 ^2) - (|.(p1 - p3).| ^2)) - (|.(p1 - p3).| ^2)) / (|.(p1 - p3).| * |.(p1 - p3).|) by Lm1 .= ((- 2) * (|.(p1 - p3).| ^2)) / (|.(p1 - p3).| * |.(p1 - p3).|) .= - 2 by A28, XCMPLX_1:89 ; then g . 0 <> (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) by A82, A58, A29; then g . 0 < (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) by A82, A83, A58, A11, XXREAL_0:1; then consider rc being Element of REAL such that A84: g . rc = (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) and A85: ( 0 < rc & rc < 1 ) by A66, TOPREAL5:6; rc in { r where r is Real : ( 0 <= r & r <= 1 ) } by A85; then A86: rc in dom g by A56, RCOMP_1:def_1; then A87: f . rc = ((1 - rc) * p1) + (rc * p2) by A52, A56; set p4 = ((1 - rc) * p1) + (rc * p2); take ((1 - rc) * p1) + (rc * p2) ; ::_thesis: ( ((1 - rc) * p1) + (rc * p2) in LSeg (p1,p2) & angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) = angle (p,p3,p2) ) thus A88: ((1 - rc) * p1) + (rc * p2) in LSeg (p1,p2) by A85; ::_thesis: angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) = angle (p,p3,p2) then reconsider q = ((1 - rc) * p1) + (rc * p2) as Point of ((TOP-REAL 2) | (LSeg (p1,p2))) by PRE_TOPC:8; A89: |.((((1 - rc) * p1) + (rc * p2)) - p3).| <> 0 by A2, A88, Lm1; set r2 = |.(p1 - p3).| * |.((((1 - rc) * p1) + (rc * p2)) - p3).|; A90: |.((((1 - rc) * p1) + (rc * p2)) - p1).| ^2 = ((|.(p1 - p3).| ^2) + (|.((((1 - rc) * p1) + (rc * p2)) - p3).| ^2)) - (((2 * |.(p1 - p3).|) * |.((((1 - rc) * p1) + (rc * p2)) - p3).|) * (cos (angle (p1,p3,(((1 - rc) * p1) + (rc * p2)))))) by Th7; f9 . q = (((|.((((1 - rc) * p1) + (rc * p2)) - p1).| ^2) - (|.(p1 - p3).| ^2)) - (|.((((1 - rc) * p1) + (rc * p2)) - p3).| ^2)) / (|.(p1 - p3).| * |.((((1 - rc) * p1) + (rc * p2)) - p3).|) by A59; then A91: (((|.(p2 - p).| ^2) - (|.(p - p3).| ^2)) - (|.(p2 - p3).| ^2)) / (|.(p - p3).| * |.(p2 - p3).|) = ((- 2) * ((|.(p1 - p3).| * |.((((1 - rc) * p1) + (rc * p2)) - p3).|) * (cos (angle (p1,p3,(((1 - rc) * p1) + (rc * p2))))))) / (|.(p1 - p3).| * |.((((1 - rc) * p1) + (rc * p2)) - p3).|) by A84, A86, A87, A90, FUNCT_1:12 .= (- 2) * (((|.(p1 - p3).| * |.((((1 - rc) * p1) + (rc * p2)) - p3).|) * (cos (angle (p1,p3,(((1 - rc) * p1) + (rc * p2)))))) / (|.(p1 - p3).| * |.((((1 - rc) * p1) + (rc * p2)) - p3).|)) by XCMPLX_1:74 .= (- 2) * (cos (angle (p1,p3,(((1 - rc) * p1) + (rc * p2))))) by A28, A89, XCMPLX_1:89 ; A92: p1 <> ((1 - rc) * p1) + (rc * p2) proof A93: |.(p1 - p3).| <> 0 by A27, Lm1; assume A94: p1 = ((1 - rc) * p1) + (rc * p2) ; ::_thesis: contradiction 0 = 0 * |.(p1 - p1).| .= ((2 * |.(p1 - p3).|) * |.(p1 - p3).|) - (((2 * |.(p1 - p3).|) * |.(p1 - p3).|) * (cos (angle (p1,p3,(((1 - rc) * p1) + (rc * p2)))))) by A90, A94, Lm1 ; hence contradiction by A58, A29, A91, A93, XCMPLX_1:7; ::_thesis: verum end; A95: p3 <> ((1 - rc) * p1) + (rc * p2) by A2, A85; percases ( angle (p,p3,p2) <= PI or angle (p,p3,p2) > PI ) ; supposeA96: angle (p,p3,p2) <= PI ; ::_thesis: angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) = angle (p,p3,p2) p,p3,p2 are_mutually_different by A1, A2, A10, A21, ZFMISC_1:def_5; then angle (p3,p2,p) <= PI by A96, Th23; then A97: angle (p3,p2,p1) <= PI by A1, A10, Th10; p3,p2,p1 are_mutually_different by A10, A27, A21, ZFMISC_1:def_5; then angle (p2,p1,p3) <= PI by A97, Th23; then A98: angle ((((1 - rc) * p1) + (rc * p2)),p1,p3) <= PI by A88, A92, Th9; ((1 - rc) * p1) + (rc * p2),p1,p3 are_mutually_different by A27, A92, A95, ZFMISC_1:def_5; then angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) <= PI by A98, Th23; hence angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) = arccos (cos (angle (p1,p3,(((1 - rc) * p1) + (rc * p2))))) by COMPLEX2:70, SIN_COS6:92 .= angle (p,p3,p2) by A58, A91, A96, COMPLEX2:70, SIN_COS6:92 ; ::_thesis: verum end; supposeA99: angle (p,p3,p2) > PI ; ::_thesis: angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) = angle (p,p3,p2) p,p3,p2 are_mutually_different by A1, A2, A10, A21, ZFMISC_1:def_5; then angle (p3,p2,p) > PI by A99, Th24; then A100: angle (p3,p2,p1) > PI by A1, A10, Th10; p3,p2,p1 are_mutually_different by A10, A27, A21, ZFMISC_1:def_5; then angle (p2,p1,p3) > PI by A100, Th24; then A101: angle ((((1 - rc) * p1) + (rc * p2)),p1,p3) > PI by A88, A92, Th9; ((1 - rc) * p1) + (rc * p2),p1,p3 are_mutually_different by A27, A92, A95, ZFMISC_1:def_5; then angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) > PI by A101, Th24; then - (angle (p1,p3,(((1 - rc) * p1) + (rc * p2)))) < - PI by XREAL_1:24; then A102: (- (angle (p1,p3,(((1 - rc) * p1) + (rc * p2))))) + (2 * PI) < (- PI) + (2 * PI) by XREAL_1:6; A103: cos ((2 * PI) - (angle (p1,p3,(((1 - rc) * p1) + (rc * p2))))) = cos . ((- (angle (p1,p3,(((1 - rc) * p1) + (rc * p2))))) + ((2 * PI) * 1)) by SIN_COS:def_19 .= cos . (- (angle (p1,p3,(((1 - rc) * p1) + (rc * p2))))) by SIN_COS6:10 .= cos . (angle (p1,p3,(((1 - rc) * p1) + (rc * p2)))) by SIN_COS:30 .= cos (angle (p,p3,p2)) by A58, A91, SIN_COS:def_19 .= cos . (angle (p,p3,p2)) by SIN_COS:def_19 .= cos . (- (angle (p,p3,p2))) by SIN_COS:30 .= cos . ((- (angle (p,p3,p2))) + ((2 * PI) * 1)) by SIN_COS6:10 .= cos ((2 * PI) - (angle (p,p3,p2))) by SIN_COS:def_19 ; - (angle (p,p3,p2)) < - PI by A99, XREAL_1:24; then A104: (- (angle (p,p3,p2))) + (2 * PI) < (- PI) + (2 * PI) by XREAL_1:6; angle (p,p3,p2) < 2 * PI by COMPLEX2:70; then - (angle (p,p3,p2)) > - (2 * PI) by XREAL_1:24; then A105: (- (angle (p,p3,p2))) + (2 * PI) > (- (2 * PI)) + (2 * PI) by XREAL_1:6; angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) < 2 * PI by COMPLEX2:70; then - (angle (p1,p3,(((1 - rc) * p1) + (rc * p2)))) > - (2 * PI) by XREAL_1:24; then (- (angle (p1,p3,(((1 - rc) * p1) + (rc * p2))))) + (2 * PI) > (- (2 * PI)) + (2 * PI) by XREAL_1:6; then (2 * PI) - (angle (p1,p3,(((1 - rc) * p1) + (rc * p2)))) = arccos (cos ((2 * PI) - (angle (p1,p3,(((1 - rc) * p1) + (rc * p2)))))) by A102, SIN_COS6:92 .= (2 * PI) - (angle (p,p3,p2)) by A104, A103, A105, SIN_COS6:92 ; hence angle (p1,p3,(((1 - rc) * p1) + (rc * p2))) = angle (p,p3,p2) ; ::_thesis: verum end; end; end; end; end; theorem :: EUCLID_6:29 for p1, p2 being Point of (TOP-REAL 2) for a, b, r being real number st p1 in inside_of_circle (a,b,r) & p2 in outside_of_circle (a,b,r) holds ex p being Point of (TOP-REAL 2) st p in (LSeg (p1,p2)) /\ (circle (a,b,r)) by Lm17; theorem Th30: :: EUCLID_6:30 for p1, p3, p4, p being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p1,p4) & p3 <> p4 holds p = p1 proof let p1, p3, p4, p be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p1,p4) & p3 <> p4 holds p = p1 let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p1,p4) & p3 <> p4 implies p = p1 ) assume A1: p1 in circle (a,b,r) ; ::_thesis: ( not p3 in circle (a,b,r) or not p4 in circle (a,b,r) or not p in LSeg (p1,p3) or not p in LSeg (p1,p4) or not p3 <> p4 or p = p1 ) assume A2: p3 in circle (a,b,r) ; ::_thesis: ( not p4 in circle (a,b,r) or not p in LSeg (p1,p3) or not p in LSeg (p1,p4) or not p3 <> p4 or p = p1 ) assume A3: p4 in circle (a,b,r) ; ::_thesis: ( not p in LSeg (p1,p3) or not p in LSeg (p1,p4) or not p3 <> p4 or p = p1 ) assume A4: p in LSeg (p1,p3) ; ::_thesis: ( not p in LSeg (p1,p4) or not p3 <> p4 or p = p1 ) assume A5: p in LSeg (p1,p4) ; ::_thesis: ( not p3 <> p4 or p = p1 ) assume A6: p3 <> p4 ; ::_thesis: p = p1 percases ( p1 = p3 or p1 = p4 or ( p1 <> p3 & p1 <> p4 ) ) ; supposeA7: ( p1 = p3 or p1 = p4 ) ; ::_thesis: p = p1 percases ( p1 = p3 or p1 = p4 ) by A7; suppose p1 = p3 ; ::_thesis: p = p1 then p in {p1} by A4, RLTOPSP1:70; hence p = p1 by TARSKI:def_1; ::_thesis: verum end; suppose p1 = p4 ; ::_thesis: p = p1 then p in {p1} by A5, RLTOPSP1:70; hence p = p1 by TARSKI:def_1; ::_thesis: verum end; end; end; supposeA8: ( p1 <> p3 & p1 <> p4 ) ; ::_thesis: p = p1 percases ( p <> p1 or p = p1 ) ; supposeA9: p <> p1 ; ::_thesis: p = p1 A10: inside_of_circle (a,b,r) misses circle (a,b,r) by TOPREAL9:54; percases ( p3 in LSeg (p1,p4) or p4 in LSeg (p1,p3) ) by A4, A5, A6, A9, Th12; supposeA11: p3 in LSeg (p1,p4) ; ::_thesis: p = p1 not p3 in {p1,p4} by A6, A8, TARSKI:def_2; then A12: p3 in (LSeg (p1,p4)) \ {p1,p4} by A11, XBOOLE_0:def_5; (LSeg (p1,p4)) \ {p1,p4} c= inside_of_circle (a,b,r) by A1, A3, TOPREAL9:60; then p3 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A2, A12, XBOOLE_0:def_4; hence p = p1 by A10, XBOOLE_0:def_7; ::_thesis: verum end; supposeA13: p4 in LSeg (p1,p3) ; ::_thesis: p = p1 not p4 in {p1,p3} by A6, A8, TARSKI:def_2; then A14: p4 in (LSeg (p1,p3)) \ {p1,p3} by A13, XBOOLE_0:def_5; (LSeg (p1,p3)) \ {p1,p3} c= inside_of_circle (a,b,r) by A1, A2, TOPREAL9:60; then p4 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A3, A14, XBOOLE_0:def_4; hence p = p1 by A10, XBOOLE_0:def_7; ::_thesis: verum end; end; end; suppose p = p1 ; ::_thesis: p = p1 hence p = p1 ; ::_thesis: verum end; end; end; end; end; theorem Th31: :: EUCLID_6:31 for p1, p2, p, pc being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p in circle (a,b,r) & pc = |[a,b]| & pc in LSeg (p,p2) & p1 <> p & not 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) holds 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) proof let p1, p2, p, pc be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p in circle (a,b,r) & pc = |[a,b]| & pc in LSeg (p,p2) & p1 <> p & not 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) holds 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p in circle (a,b,r) & pc = |[a,b]| & pc in LSeg (p,p2) & p1 <> p & not 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) implies 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume A1: p1 in circle (a,b,r) ; ::_thesis: ( not p2 in circle (a,b,r) or not p in circle (a,b,r) or not pc = |[a,b]| or not pc in LSeg (p,p2) or not p1 <> p or 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume A2: p2 in circle (a,b,r) ; ::_thesis: ( not p in circle (a,b,r) or not pc = |[a,b]| or not pc in LSeg (p,p2) or not p1 <> p or 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume A3: p in circle (a,b,r) ; ::_thesis: ( not pc = |[a,b]| or not pc in LSeg (p,p2) or not p1 <> p or 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume that A4: pc = |[a,b]| and A5: pc in LSeg (p,p2) ; ::_thesis: ( not p1 <> p or 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume A6: p1 <> p ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) percases ( r = 0 or r <> 0 ) ; supposeA7: r = 0 ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then |.(p1 - pc).| = 0 by A1, A4, TOPREAL9:43; then A8: p1 = pc by Lm1; A9: |.(p2 - pc).| = 0 by A2, A4, A7, TOPREAL9:43; then p2 = pc by Lm1; then 2 * (angle (p1,p,p2)) = 2 * 0 by A8, COMPLEX2:79 .= angle (pc,pc,pc) by COMPLEX2:79 ; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A9, A8, Lm1; ::_thesis: verum end; supposeA10: r <> 0 ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) |.(p2 - pc).| = r by A2, A4, TOPREAL9:43; then A11: pc <> p2 by A10, Lm1; A12: euc2cpx p1 <> euc2cpx p by A6, EUCLID_3:4; A13: |.(p1 - pc).| = r by A1, A4, TOPREAL9:43; then pc <> p1 by A10, Lm1; then A14: euc2cpx pc <> euc2cpx p1 by EUCLID_3:4; A15: |.(p - pc).| = r by A3, A4, TOPREAL9:43; then A16: pc <> p by A10, Lm1; then A17: angle (p1,p,p2) = angle (p1,p,pc) by A5, Th10; |.(pc - p1).| = |.(p - pc).| by A13, A15, Lm2; then A18: angle (pc,p1,p) = angle (p1,p,pc) by A6, Th16; euc2cpx pc <> euc2cpx p by A16, EUCLID_3:4; then A19: ( ((angle (pc,p1,p)) + (angle (p1,p,pc))) + (angle (p,pc,p1)) = PI or ((angle (pc,p1,p)) + (angle (p1,p,pc))) + (angle (p,pc,p1)) = 5 * PI ) by A14, A12, COMPLEX2:88; percases ( ( (angle (p,pc,p1)) + (angle (p1,pc,p2)) = PI & (2 * (angle (p1,p,p2))) + (angle (p,pc,p1)) = PI ) or ( (angle (p,pc,p1)) + (angle (p1,pc,p2)) = 3 * PI & (2 * (angle (p1,p,p2))) + (angle (p,pc,p1)) = PI ) or ( (angle (p,pc,p1)) + (angle (p1,pc,p2)) = PI & (2 * (angle (p1,p,p2))) + (angle (p,pc,p1)) = 5 * PI ) or ( (angle (p,pc,p1)) + (angle (p1,pc,p2)) = 3 * PI & (2 * (angle (p1,p,p2))) + (angle (p,pc,p1)) = 5 * PI ) ) by A5, A16, A11, A19, A18, A17, Th13; suppose ( (angle (p,pc,p1)) + (angle (p1,pc,p2)) = PI & (2 * (angle (p1,p,p2))) + (angle (p,pc,p1)) = PI ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) ; ::_thesis: verum end; supposeA20: ( (angle (p,pc,p1)) + (angle (p1,pc,p2)) = 3 * PI & (2 * (angle (p1,p,p2))) + (angle (p,pc,p1)) = PI ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) ( angle (p1,pc,p2) < 2 * PI & angle (p1,p,p2) >= 0 ) by COMPLEX2:70; then (- (2 * (angle (p1,p,p2)))) + (angle (p1,pc,p2)) < 0 + (2 * PI) by XREAL_1:8; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A20; ::_thesis: verum end; supposeA21: ( (angle (p,pc,p1)) + (angle (p1,pc,p2)) = PI & (2 * (angle (p1,p,p2))) + (angle (p,pc,p1)) = 5 * PI ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) ( angle (p1,pc,p2) >= 0 & (angle (p1,p,p2)) * 2 < (2 * PI) * 2 ) by COMPLEX2:70, XREAL_1:68; then (2 * (angle (p1,p,p2))) + (- (angle (p1,pc,p2))) < ((2 * PI) * 2) + 0 by XREAL_1:8; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A21; ::_thesis: verum end; suppose ( (angle (p,pc,p1)) + (angle (p1,pc,p2)) = 3 * PI & (2 * (angle (p1,p,p2))) + (angle (p,pc,p1)) = 5 * PI ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) ; ::_thesis: verum end; end; end; end; end; theorem Th32: :: EUCLID_6:32 for p1 being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & r > 0 holds ex p2 being Point of (TOP-REAL 2) st ( p1 <> p2 & p2 in circle (a,b,r) & |[a,b]| in LSeg (p1,p2) ) proof let p1 be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & r > 0 holds ex p2 being Point of (TOP-REAL 2) st ( p1 <> p2 & p2 in circle (a,b,r) & |[a,b]| in LSeg (p1,p2) ) let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & r > 0 implies ex p2 being Point of (TOP-REAL 2) st ( p1 <> p2 & p2 in circle (a,b,r) & |[a,b]| in LSeg (p1,p2) ) ) set pc = |[a,b]|; set p2 = (2 * |[a,b]|) - p1; assume A1: p1 in circle (a,b,r) ; ::_thesis: ( not r > 0 or ex p2 being Point of (TOP-REAL 2) st ( p1 <> p2 & p2 in circle (a,b,r) & |[a,b]| in LSeg (p1,p2) ) ) then A2: |.(p1 - |[a,b]|).| = r by TOPREAL9:43; assume A3: r > 0 ; ::_thesis: ex p2 being Point of (TOP-REAL 2) st ( p1 <> p2 & p2 in circle (a,b,r) & |[a,b]| in LSeg (p1,p2) ) take (2 * |[a,b]|) - p1 ; ::_thesis: ( p1 <> (2 * |[a,b]|) - p1 & (2 * |[a,b]|) - p1 in circle (a,b,r) & |[a,b]| in LSeg (p1,((2 * |[a,b]|) - p1)) ) thus p1 <> (2 * |[a,b]|) - p1 ::_thesis: ( (2 * |[a,b]|) - p1 in circle (a,b,r) & |[a,b]| in LSeg (p1,((2 * |[a,b]|) - p1)) ) proof assume p1 = (2 * |[a,b]|) - p1 ; ::_thesis: contradiction then (1 * p1) + p1 = ((2 * |[a,b]|) - p1) + p1 by EUCLID:29; then (1 * p1) + (1 * p1) = ((2 * |[a,b]|) - p1) + p1 by EUCLID:29; then (1 + 1) * p1 = ((2 * |[a,b]|) - p1) + p1 by EUCLID:33; then 2 * p1 = (2 * |[a,b]|) - (p1 - p1) by EUCLID:47; then 2 * p1 = (2 * |[a,b]|) - (0. (TOP-REAL 2)) by EUCLID:42; then 2 * p1 = (2 * |[a,b]|) + (0. (TOP-REAL 2)) by RLVECT_1:12; then 2 * p1 = 2 * |[a,b]| by EUCLID:27; then p1 = |[a,b]| by EUCLID:34; then |.(|[a,b]| - |[a,b]|).| = r by A1, TOPREAL9:43; hence contradiction by A3, Lm1; ::_thesis: verum end; |.(((2 * |[a,b]|) - p1) - |[a,b]|).| = |.(((2 * |[a,b]|) - p1) - |[a,b]|).| .= |.(((2 * |[a,b]|) + (- p1)) - |[a,b]|).| .= |.(((2 * |[a,b]|) + (- |[a,b]|)) + (- p1)).| by EUCLID:26 .= |.(((2 * |[a,b]|) + ((- 1) * |[a,b]|)) + (- p1)).| .= |.(((2 + (- 1)) * |[a,b]|) + (- p1)).| by EUCLID:33 .= |.(|[a,b]| - p1).| by EUCLID:29 .= r by A2, Lm2 ; hence (2 * |[a,b]|) - p1 in circle (a,b,r) by TOPREAL9:43; ::_thesis: |[a,b]| in LSeg (p1,((2 * |[a,b]|) - p1)) ((1 - (1 / 2)) * p1) + ((1 / 2) * ((2 * |[a,b]|) - p1)) = (1 / 2) * (p1 + ((2 * |[a,b]|) - p1)) by EUCLID:32 .= (1 / 2) * ((p1 + (- p1)) + (2 * |[a,b]|)) by EUCLID:26 .= (1 / 2) * ((0. (TOP-REAL 2)) + (2 * |[a,b]|)) by EUCLID:36 .= (1 / 2) * (2 * |[a,b]|) by EUCLID:27 .= ((1 / 2) * 2) * |[a,b]| by EUCLID:30 .= |[a,b]| by EUCLID:29 ; hence |[a,b]| in LSeg (p1,((2 * |[a,b]|) - p1)) ; ::_thesis: verum end; theorem Th33: :: EUCLID_6:33 for p1, p2, p, pc being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p in circle (a,b,r) & pc = |[a,b]| & p1 <> p & p2 <> p & not 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) holds 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) proof let p1, p2, p, pc be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p in circle (a,b,r) & pc = |[a,b]| & p1 <> p & p2 <> p & not 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) holds 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p in circle (a,b,r) & pc = |[a,b]| & p1 <> p & p2 <> p & not 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) implies 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume A1: p1 in circle (a,b,r) ; ::_thesis: ( not p2 in circle (a,b,r) or not p in circle (a,b,r) or not pc = |[a,b]| or not p1 <> p or not p2 <> p or 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume A2: p2 in circle (a,b,r) ; ::_thesis: ( not p in circle (a,b,r) or not pc = |[a,b]| or not p1 <> p or not p2 <> p or 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume A3: p in circle (a,b,r) ; ::_thesis: ( not pc = |[a,b]| or not p1 <> p or not p2 <> p or 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume A4: pc = |[a,b]| ; ::_thesis: ( not p1 <> p or not p2 <> p or 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) assume that A5: p1 <> p and A6: p2 <> p ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) percases ( r = 0 or r <> 0 ) ; supposeA7: r = 0 ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then |.(p1 - pc).| = 0 by A1, A4, TOPREAL9:43; then A8: p1 = pc by Lm1; A9: |.(p2 - pc).| = 0 by A2, A4, A7, TOPREAL9:43; then p2 = pc by Lm1; then 2 * (angle (p1,p,p2)) = 2 * 0 by A8, COMPLEX2:79 .= angle (pc,pc,pc) by COMPLEX2:79 ; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A9, A8, Lm1; ::_thesis: verum end; supposeA10: r <> 0 ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) A11: |.(p2 - pc).| = r by A2, A4, TOPREAL9:43; |.(p1 - pc).| >= 0 ; then r > 0 by A1, A4, A10, TOPREAL9:43; then consider p3 being Point of (TOP-REAL 2) such that p <> p3 and A12: p3 in circle (a,b,r) and A13: |[a,b]| in LSeg (p,p3) by A3, Th32; percases ( p2 = p3 or p2 <> p3 ) ; suppose p2 = p3 ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A1, A3, A4, A5, A12, A13, Th31; ::_thesis: verum end; supposeA14: p2 <> p3 ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) A15: angle (p2,pc,p3) <> 0 proof set z3 = euc2cpx (p3 - pc); set z2 = euc2cpx (p2 - pc); assume angle (p2,pc,p3) = 0 ; ::_thesis: contradiction then A16: Arg (p2 - pc) = Arg (p3 - pc) by EUCLID_3:36; A17: |.(p2 - pc).| = |.(p3 - pc).| by A4, A11, A12, TOPREAL9:43; A18: |.(euc2cpx (p2 - pc)).| = |.(p2 - pc).| by EUCLID_3:25 .= |.(euc2cpx (p3 - pc)).| by A17, EUCLID_3:25 ; A19: euc2cpx (p2 - pc) = (|.(euc2cpx (p2 - pc)).| * (cos (Arg (euc2cpx (p2 - pc))))) + ((|.(euc2cpx (p2 - pc)).| * (sin (Arg (euc2cpx (p2 - pc))))) * ) by COMPLEX2:12 .= euc2cpx (p3 - pc) by A16, A18, COMPLEX2:12 ; p2 = p2 + (0. (TOP-REAL 2)) by EUCLID:27 .= p2 + (pc + (- pc)) by EUCLID:36 .= (p2 + (- pc)) + pc by EUCLID:26 .= (p3 - pc) + pc by A19, EUCLID_3:4 .= p3 + (pc + (- pc)) by EUCLID:26 .= p3 + (0. (TOP-REAL 2)) by EUCLID:36 .= p3 by EUCLID:27 ; hence contradiction by A14; ::_thesis: verum end; ( 2 * (angle (p2,p,p3)) = angle (p2,pc,p3) or 2 * ((angle (p2,p,p3)) - PI) = angle (p2,pc,p3) ) by A2, A3, A4, A6, A12, A13, Th31; then A20: angle (p2,p,p3) <> 0 by A15, COMPLEX2:70; A21: ( 2 * ((angle (p2,p,p3)) - PI) = angle (p2,pc,p3) implies 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) proof assume A22: 2 * ((angle (p2,p,p3)) - PI) = angle (p2,pc,p3) ; ::_thesis: 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) thus 2 * (angle (p3,p,p2)) = 2 * ((2 * PI) - (angle (p2,p,p3))) by A20, EUCLID_3:37 .= (2 * PI) - (2 * ((angle (p2,p,p3)) - PI)) .= angle (p3,pc,p2) by A15, A22, EUCLID_3:37 ; ::_thesis: verum end; A23: angle (p3,p,p2) = (2 * PI) - (angle (p2,p,p3)) by A20, EUCLID_3:37; A24: ( 2 * (angle (p2,p,p3)) = angle (p2,pc,p3) implies 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) proof assume 2 * (angle (p2,p,p3)) = angle (p2,pc,p3) ; ::_thesis: 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) hence 2 * ((angle (p3,p,p2)) - PI) = (2 * PI) - (angle (p2,pc,p3)) by A23 .= angle (p3,pc,p2) by A15, EUCLID_3:37 ; ::_thesis: verum end; A25: ( angle (p1,p,p2) = (angle (p1,p,p3)) + (angle (p3,p,p2)) or (angle (p1,p,p2)) + (2 * PI) = (angle (p1,p,p3)) + (angle (p3,p,p2)) ) by Th4; percases ( angle (p1,pc,p2) = (angle (p1,pc,p3)) + (angle (p3,pc,p2)) or (angle (p1,pc,p2)) + (2 * PI) = (angle (p1,pc,p3)) + (angle (p3,pc,p2)) ) by Th4; supposeA26: angle (p1,pc,p2) = (angle (p1,pc,p3)) + (angle (p3,pc,p2)) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) percases ( ( 2 * (angle (p1,p,p3)) = angle (p1,pc,p3) & 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) or ( 2 * (angle (p1,p,p3)) = angle (p1,pc,p3) & 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) or ( 2 * ((angle (p1,p,p3)) - PI) = angle (p1,pc,p3) & 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) or ( 2 * ((angle (p1,p,p3)) - PI) = angle (p1,pc,p3) & 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) ) by A1, A2, A3, A4, A5, A6, A12, A13, A24, A21, Th31; suppose ( 2 * (angle (p1,p,p3)) = angle (p1,pc,p3) & 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then ( angle (p1,pc,p2) = (2 * (angle (p1,p,p2))) - (2 * PI) or angle (p1,pc,p2) = (2 * (angle (p1,p,p2))) + (2 * PI) ) by A25, A26; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by Lm3; ::_thesis: verum end; suppose ( 2 * (angle (p1,p,p3)) = angle (p1,pc,p3) & 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then ( angle (p1,pc,p2) = 2 * (angle (p1,p,p2)) or angle (p1,pc,p2) = (2 * (angle (p1,p,p2))) + (4 * PI) ) by A25, A26; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by Lm4; ::_thesis: verum end; suppose ( 2 * ((angle (p1,p,p3)) - PI) = angle (p1,pc,p3) & 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then angle (p1,pc,p2) = (2 * ((angle (p1,p,p3)) + (angle (p3,p,p2)))) - (4 * PI) by A26; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A25, Lm5; ::_thesis: verum end; suppose ( 2 * ((angle (p1,p,p3)) - PI) = angle (p1,pc,p3) & 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then ( angle (p1,pc,p2) = (2 * (angle (p1,p,p2))) - (2 * PI) or angle (p1,pc,p2) = (2 * (angle (p1,p,p2))) + (2 * PI) ) by A25, A26; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by Lm3; ::_thesis: verum end; end; end; supposeA27: (angle (p1,pc,p2)) + (2 * PI) = (angle (p1,pc,p3)) + (angle (p3,pc,p2)) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) percases ( ( 2 * (angle (p1,p,p3)) = angle (p1,pc,p3) & 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) or ( 2 * (angle (p1,p,p3)) = angle (p1,pc,p3) & 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) or ( 2 * ((angle (p1,p,p3)) - PI) = angle (p1,pc,p3) & 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) or ( 2 * ((angle (p1,p,p3)) - PI) = angle (p1,pc,p3) & 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) ) by A1, A2, A3, A4, A5, A6, A12, A13, A24, A21, Th31; suppose ( 2 * (angle (p1,p,p3)) = angle (p1,pc,p3) & 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then angle (p1,pc,p2) = (2 * ((angle (p1,p,p3)) + (angle (p3,p,p2)))) - (4 * PI) by A27; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A25, Lm5; ::_thesis: verum end; suppose ( 2 * (angle (p1,p,p3)) = angle (p1,pc,p3) & 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then ( angle (p1,pc,p2) = (2 * (angle (p1,p,p2))) - (2 * PI) or angle (p1,pc,p2) = (2 * (angle (p1,p,p2))) + (2 * PI) ) by A25, A27; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by Lm3; ::_thesis: verum end; suppose ( 2 * ((angle (p1,p,p3)) - PI) = angle (p1,pc,p3) & 2 * ((angle (p3,p,p2)) - PI) = angle (p3,pc,p2) ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then angle (p1,pc,p2) = (2 * ((angle (p1,p,p3)) + (angle (p3,p,p2)))) - (6 * PI) by A27; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A25, Lm6; ::_thesis: verum end; suppose ( 2 * ((angle (p1,p,p3)) - PI) = angle (p1,pc,p3) & 2 * (angle (p3,p,p2)) = angle (p3,pc,p2) ) ; ::_thesis: ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) then angle (p1,pc,p2) = (2 * ((angle (p1,p,p3)) + (angle (p3,p,p2)))) - (4 * PI) by A27; hence ( 2 * (angle (p1,p,p2)) = angle (p1,pc,p2) or 2 * ((angle (p1,p,p2)) - PI) = angle (p1,pc,p2) ) by A25, Lm5; ::_thesis: verum end; end; end; end; end; end; end; end; end; theorem Th34: :: EUCLID_6:34 for p1, p2, p3, p4 being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p1 <> p3 & p1 <> p4 & p2 <> p3 & p2 <> p4 & not angle (p1,p3,p2) = angle (p1,p4,p2) & not angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI holds angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI proof let p1, p2, p3, p4 be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p1 <> p3 & p1 <> p4 & p2 <> p3 & p2 <> p4 & not angle (p1,p3,p2) = angle (p1,p4,p2) & not angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI holds angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p1 <> p3 & p1 <> p4 & p2 <> p3 & p2 <> p4 & not angle (p1,p3,p2) = angle (p1,p4,p2) & not angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI implies angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) assume A1: p1 in circle (a,b,r) ; ::_thesis: ( not p2 in circle (a,b,r) or not p3 in circle (a,b,r) or not p4 in circle (a,b,r) or not p1 <> p3 or not p1 <> p4 or not p2 <> p3 or not p2 <> p4 or angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) set pc = |[a,b]|; assume A2: p2 in circle (a,b,r) ; ::_thesis: ( not p3 in circle (a,b,r) or not p4 in circle (a,b,r) or not p1 <> p3 or not p1 <> p4 or not p2 <> p3 or not p2 <> p4 or angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) assume A3: p3 in circle (a,b,r) ; ::_thesis: ( not p4 in circle (a,b,r) or not p1 <> p3 or not p1 <> p4 or not p2 <> p3 or not p2 <> p4 or angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) assume A4: p4 in circle (a,b,r) ; ::_thesis: ( not p1 <> p3 or not p1 <> p4 or not p2 <> p3 or not p2 <> p4 or angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) assume that A5: p1 <> p3 and A6: p1 <> p4 and A7: p2 <> p3 and A8: p2 <> p4 ; ::_thesis: ( angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) percases ( 2 * (angle (p1,p3,p2)) = angle (p1,|[a,b]|,p2) or 2 * ((angle (p1,p3,p2)) - PI) = angle (p1,|[a,b]|,p2) ) by A1, A2, A3, A5, A7, Th33; suppose 2 * (angle (p1,p3,p2)) = angle (p1,|[a,b]|,p2) ; ::_thesis: ( angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) then ( 2 * (angle (p1,p4,p2)) = 2 * (angle (p1,p3,p2)) or 2 * ((angle (p1,p4,p2)) - PI) = 2 * (angle (p1,p3,p2)) ) by A1, A2, A4, A6, A8, Th33; hence ( angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) ; ::_thesis: verum end; suppose 2 * ((angle (p1,p3,p2)) - PI) = angle (p1,|[a,b]|,p2) ; ::_thesis: ( angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) then ( 2 * (angle (p1,p4,p2)) = 2 * ((angle (p1,p3,p2)) - PI) or 2 * ((angle (p1,p4,p2)) - PI) = 2 * ((angle (p1,p3,p2)) - PI) ) by A1, A2, A4, A6, A8, Th33; hence ( angle (p1,p3,p2) = angle (p1,p4,p2) or angle (p1,p3,p2) = (angle (p1,p4,p2)) - PI or angle (p1,p3,p2) = (angle (p1,p4,p2)) + PI ) ; ::_thesis: verum end; end; end; theorem Th35: :: EUCLID_6:35 for p1, p2, p3 being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p1 <> p2 & p2 <> p3 holds angle (p1,p2,p3) <> PI proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p1 <> p2 & p2 <> p3 holds angle (p1,p2,p3) <> PI let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p1 <> p2 & p2 <> p3 implies angle (p1,p2,p3) <> PI ) assume A1: p1 in circle (a,b,r) ; ::_thesis: ( not p2 in circle (a,b,r) or not p3 in circle (a,b,r) or not p1 <> p2 or not p2 <> p3 or angle (p1,p2,p3) <> PI ) assume A2: p2 in circle (a,b,r) ; ::_thesis: ( not p3 in circle (a,b,r) or not p1 <> p2 or not p2 <> p3 or angle (p1,p2,p3) <> PI ) assume p3 in circle (a,b,r) ; ::_thesis: ( not p1 <> p2 or not p2 <> p3 or angle (p1,p2,p3) <> PI ) then A3: (LSeg (p1,p3)) \ {p1,p3} c= inside_of_circle (a,b,r) by A1, TOPREAL9:60; assume ( p1 <> p2 & p2 <> p3 ) ; ::_thesis: angle (p1,p2,p3) <> PI then A4: not p2 in {p1,p3} by TARSKI:def_2; inside_of_circle (a,b,r) misses circle (a,b,r) by TOPREAL9:54; then A5: (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) = {} by XBOOLE_0:def_7; assume angle (p1,p2,p3) = PI ; ::_thesis: contradiction then p2 in LSeg (p1,p3) by Th11; then p2 in (LSeg (p1,p3)) \ {p1,p3} by A4, XBOOLE_0:def_5; hence contradiction by A2, A3, A5, XBOOLE_0:def_4; ::_thesis: verum end; Lm22: for p1, p3, p4, p being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p1,p4) holds |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| proof let p1, p3, p4, p be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p1,p4) holds |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p1,p4) implies |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| ) assume A1: ( p1 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) ) ; ::_thesis: ( not p in LSeg (p1,p3) or not p in LSeg (p1,p4) or |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| ) assume A2: ( p in LSeg (p1,p3) & p in LSeg (p1,p4) ) ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| percases ( p3 <> p4 or p3 = p4 ) ; suppose p3 <> p4 ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| then p = p1 by A1, A2, Th30; then |.(p1 - p).| = |.(0. (TOP-REAL 2)).| by EUCLID:42 .= 0 by EUCLID_2:39 ; hence |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| ; ::_thesis: verum end; suppose p3 = p4 ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| hence |.(p1 - p).| * |.(p - p3).| = |.(p1 - p).| * |.(p - p4).| ; ::_thesis: verum end; end; end; Lm23: for p1, p2, p4, p being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p1) & p in LSeg (p2,p4) holds |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| proof let p1, p2, p4, p be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p1) & p in LSeg (p2,p4) holds |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p1) & p in LSeg (p2,p4) implies |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| ) assume that A1: p1 in circle (a,b,r) and A2: ( p2 in circle (a,b,r) & p4 in circle (a,b,r) ) ; ::_thesis: ( not p in LSeg (p1,p1) or not p in LSeg (p2,p4) or |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| ) A3: (LSeg (p2,p4)) \ {p2,p4} c= inside_of_circle (a,b,r) by A2, TOPREAL9:60; A4: inside_of_circle (a,b,r) misses circle (a,b,r) by TOPREAL9:54; assume p in LSeg (p1,p1) ; ::_thesis: ( not p in LSeg (p2,p4) or |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| ) then A5: p in {p1} by RLTOPSP1:70; then A6: |.(p1 - p).| = |.(p - p).| by TARSKI:def_1 .= |.(0. (TOP-REAL 2)).| by EUCLID:42 .= |.(0* 2).| by EUCLID:70 .= 0 by EUCLID:7 ; assume p in LSeg (p2,p4) ; ::_thesis: |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| then A7: p1 in LSeg (p2,p4) by A5, TARSKI:def_1; percases ( ( p1 <> p2 & p1 <> p4 ) or not p1 <> p2 or not p1 <> p4 ) ; suppose ( p1 <> p2 & p1 <> p4 ) ; ::_thesis: |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| then not p1 in {p2,p4} by TARSKI:def_2; then p1 in (LSeg (p2,p4)) \ {p2,p4} by A7, XBOOLE_0:def_5; then p1 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A1, A3, XBOOLE_0:def_4; hence |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| by A4, XBOOLE_0:def_7; ::_thesis: verum end; supposeA8: ( not p1 <> p2 or not p1 <> p4 ) ; ::_thesis: |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| percases ( p1 = p2 or p1 = p4 ) by A8; suppose p1 = p2 ; ::_thesis: |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| then |.(p2 - p).| = |.(p1 - p1).| by A5, TARSKI:def_1 .= |.(0. (TOP-REAL 2)).| by EUCLID:42 .= |.(0* 2).| by EUCLID:70 .= 0 by EUCLID:7 ; hence |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| by A6; ::_thesis: verum end; suppose p1 = p4 ; ::_thesis: |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| then |.(p - p4).| = |.(p1 - p1).| by A5, TARSKI:def_1 .= |.(0. (TOP-REAL 2)).| by EUCLID:42 .= |.(0* 2).| by EUCLID:70 .= 0 by EUCLID:7 ; hence |.(p1 - p).| * |.(p - p1).| = |.(p2 - p).| * |.(p - p4).| by A6; ::_thesis: verum end; end; end; end; end; theorem Th36: :: EUCLID_6:36 for p1, p2, p3, p4, p being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) & p1,p2,p3,p4 are_mutually_different holds angle (p1,p4,p2) = angle (p1,p3,p2) proof let p1, p2, p3, p4, p be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) & p1,p2,p3,p4 are_mutually_different holds angle (p1,p4,p2) = angle (p1,p3,p2) let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) & p1,p2,p3,p4 are_mutually_different implies angle (p1,p4,p2) = angle (p1,p3,p2) ) assume that A1: p1 in circle (a,b,r) and A2: p2 in circle (a,b,r) and A3: p3 in circle (a,b,r) and A4: p4 in circle (a,b,r) ; ::_thesis: ( not p in LSeg (p1,p3) or not p in LSeg (p2,p4) or not p1,p2,p3,p4 are_mutually_different or angle (p1,p4,p2) = angle (p1,p3,p2) ) A5: (LSeg (p1,p3)) \ {p1,p3} c= inside_of_circle (a,b,r) by A1, A3, TOPREAL9:60; assume that A6: p in LSeg (p1,p3) and A7: p in LSeg (p2,p4) ; ::_thesis: ( not p1,p2,p3,p4 are_mutually_different or angle (p1,p4,p2) = angle (p1,p3,p2) ) assume A8: p1,p2,p3,p4 are_mutually_different ; ::_thesis: angle (p1,p4,p2) = angle (p1,p3,p2) then A9: p1 <> p2 by ZFMISC_1:def_6; A10: p3 <> p4 by A8, ZFMISC_1:def_6; A11: p1 <> p4 by A8, ZFMISC_1:def_6; A12: p2 <> p4 by A8, ZFMISC_1:def_6; A13: p1 <> p3 by A8, ZFMISC_1:def_6; A14: inside_of_circle (a,b,r) misses circle (a,b,r) by TOPREAL9:54; A15: (LSeg (p2,p4)) \ {p2,p4} c= inside_of_circle (a,b,r) by A2, A4, TOPREAL9:60; A16: ( p <> p1 & p <> p4 ) proof assume A17: ( p = p1 or p = p4 ) ; ::_thesis: contradiction percases ( p = p1 or p = p4 ) by A17; supposeA18: p = p1 ; ::_thesis: contradiction not p1 in {p2,p4} by A9, A11, TARSKI:def_2; then p1 in (LSeg (p2,p4)) \ {p2,p4} by A7, A18, XBOOLE_0:def_5; then p1 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A1, A15, XBOOLE_0:def_4; hence contradiction by A14, XBOOLE_0:def_7; ::_thesis: verum end; supposeA19: p = p4 ; ::_thesis: contradiction not p4 in {p1,p3} by A11, A10, TARSKI:def_2; then p4 in (LSeg (p1,p3)) \ {p1,p3} by A6, A19, XBOOLE_0:def_5; then p4 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A4, A5, XBOOLE_0:def_4; hence contradiction by A14, XBOOLE_0:def_7; ::_thesis: verum end; end; end; then A20: p1,p4,p are_mutually_different by A11, ZFMISC_1:def_5; A21: p4,p,p1 are_mutually_different by A11, A16, ZFMISC_1:def_5; A22: angle (p1,p4,p) = angle (p1,p4,p2) by A7, A16, Th10; A23: p2 <> p3 by A8, ZFMISC_1:def_6; A24: ( p <> p2 & p <> p3 ) proof assume A25: ( p = p2 or p = p3 ) ; ::_thesis: contradiction percases ( p = p3 or p = p2 ) by A25; supposeA26: p = p3 ; ::_thesis: contradiction not p3 in {p2,p4} by A23, A10, TARSKI:def_2; then p3 in (LSeg (p2,p4)) \ {p2,p4} by A7, A26, XBOOLE_0:def_5; then p3 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A3, A15, XBOOLE_0:def_4; hence contradiction by A14, XBOOLE_0:def_7; ::_thesis: verum end; supposeA27: p = p2 ; ::_thesis: contradiction not p2 in {p1,p3} by A9, A23, TARSKI:def_2; then p2 in (LSeg (p1,p3)) \ {p1,p3} by A6, A27, XBOOLE_0:def_5; then p2 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A2, A5, XBOOLE_0:def_4; hence contradiction by A14, XBOOLE_0:def_7; ::_thesis: verum end; end; end; then A28: angle (p4,p,p1) = angle (p2,p,p3) by A6, A7, A16, Th15; A29: p,p3,p2 are_mutually_different by A23, A24, ZFMISC_1:def_5; A30: p2,p,p3 are_mutually_different by A23, A24, ZFMISC_1:def_5; A31: angle (p,p3,p2) = angle (p1,p3,p2) by A6, A24, Th9; percases ( angle (p1,p4,p2) = angle (p1,p3,p2) or angle (p1,p4,p2) = (angle (p1,p3,p2)) - PI or angle (p1,p4,p2) = (angle (p1,p3,p2)) + PI ) by A1, A2, A3, A4, A13, A11, A23, A12, Th34; suppose angle (p1,p4,p2) = angle (p1,p3,p2) ; ::_thesis: angle (p1,p4,p2) = angle (p1,p3,p2) hence angle (p1,p4,p2) = angle (p1,p3,p2) ; ::_thesis: verum end; supposeA32: angle (p1,p4,p2) = (angle (p1,p3,p2)) - PI ; ::_thesis: angle (p1,p4,p2) = angle (p1,p3,p2) angle (p1,p3,p2) < 2 * PI by COMPLEX2:70; then (angle (p1,p3,p2)) - PI < (2 * PI) - PI by XREAL_1:9; then angle (p2,p,p3) <= PI by A22, A28, A20, A32, Th23; then A33: angle (p1,p3,p2) <= PI by A31, A30, Th23; A34: not p3 in {p1,p2} by A13, A23, TARSKI:def_2; angle (p1,p4,p2) >= 0 by COMPLEX2:70; then ((angle (p1,p3,p2)) - PI) + PI >= 0 + PI by A32, XREAL_1:6; then p3 in LSeg (p1,p2) by A33, Th11, XXREAL_0:1; then A35: p3 in (LSeg (p1,p2)) \ {p1,p2} by A34, XBOOLE_0:def_5; (LSeg (p1,p2)) \ {p1,p2} c= inside_of_circle (a,b,r) by A1, A2, TOPREAL9:60; then ( inside_of_circle (a,b,r) misses circle (a,b,r) & p3 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) ) by A3, A35, TOPREAL9:54, XBOOLE_0:def_4; hence angle (p1,p4,p2) = angle (p1,p3,p2) by XBOOLE_0:def_7; ::_thesis: verum end; supposeA36: angle (p1,p4,p2) = (angle (p1,p3,p2)) + PI ; ::_thesis: angle (p1,p4,p2) = angle (p1,p3,p2) angle (p1,p4,p2) < 2 * PI by COMPLEX2:70; then (angle (p1,p4,p2)) - PI < (2 * PI) - PI by XREAL_1:9; then angle (p4,p,p1) <= PI by A31, A28, A29, A36, Th23; then A37: angle (p1,p4,p2) <= PI by A22, A21, Th23; A38: not p4 in {p1,p2} by A11, A12, TARSKI:def_2; angle (p1,p3,p2) >= 0 by COMPLEX2:70; then ((angle (p1,p4,p2)) - PI) + PI >= 0 + PI by A36, XREAL_1:6; then p4 in LSeg (p1,p2) by A37, Th11, XXREAL_0:1; then A39: p4 in (LSeg (p1,p2)) \ {p1,p2} by A38, XBOOLE_0:def_5; (LSeg (p1,p2)) \ {p1,p2} c= inside_of_circle (a,b,r) by A1, A2, TOPREAL9:60; then ( inside_of_circle (a,b,r) misses circle (a,b,r) & p4 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) ) by A4, A39, TOPREAL9:54, XBOOLE_0:def_4; hence angle (p1,p4,p2) = angle (p1,p3,p2) by XBOOLE_0:def_7; ::_thesis: verum end; end; end; theorem Th37: :: EUCLID_6:37 for p1, p2, p3 being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & angle (p1,p2,p3) = 0 & p1 <> p2 & p2 <> p3 holds p1 = p3 proof let p1, p2, p3 be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & angle (p1,p2,p3) = 0 & p1 <> p2 & p2 <> p3 holds p1 = p3 let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & angle (p1,p2,p3) = 0 & p1 <> p2 & p2 <> p3 implies p1 = p3 ) assume A1: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) ) ; ::_thesis: ( not angle (p1,p2,p3) = 0 or not p1 <> p2 or not p2 <> p3 or p1 = p3 ) assume A2: angle (p1,p2,p3) = 0 ; ::_thesis: ( not p1 <> p2 or not p2 <> p3 or p1 = p3 ) assume A3: ( p1 <> p2 & p2 <> p3 ) ; ::_thesis: p1 = p3 then A4: ( euc2cpx p1 <> euc2cpx p2 & euc2cpx p2 <> euc2cpx p3 ) by EUCLID_3:4; assume A5: p1 <> p3 ; ::_thesis: contradiction then euc2cpx p1 <> euc2cpx p3 by EUCLID_3:4; then ( ( angle (p2,p3,p1) = 0 & angle (p3,p1,p2) = PI ) or ( angle (p2,p3,p1) = PI & angle (p3,p1,p2) = 0 ) ) by A2, A4, COMPLEX2:87; hence contradiction by A1, A3, A5, Th35; ::_thesis: verum end; theorem :: EUCLID_6:38 for p1, p2, p3, p4, p being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) holds |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| proof let p1, p2, p3, p4, p be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) holds |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) implies |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| ) assume that A1: p1 in circle (a,b,r) and A2: p2 in circle (a,b,r) and A3: p3 in circle (a,b,r) and A4: p4 in circle (a,b,r) ; ::_thesis: ( not p in LSeg (p1,p3) or not p in LSeg (p2,p4) or |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| ) A5: |.(p1 - p).| = |.(p - p1).| by Lm2; A6: |.(p3 - p).| = |.(p - p3).| by Lm2; A7: ( |.(p2 - p).| = |.(p - p2).| & |.(p4 - p).| = |.(p - p4).| ) by Lm2; assume that A8: p in LSeg (p1,p3) and A9: p in LSeg (p2,p4) ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| percases ( not p1,p2,p3,p4 are_mutually_different or p1,p2,p3,p4 are_mutually_different ) ; supposeA10: not p1,p2,p3,p4 are_mutually_different ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| percases ( p1 = p2 or p1 = p3 or p1 = p4 or p2 = p3 or p2 = p4 or p3 = p4 ) by A10, ZFMISC_1:def_6; suppose p1 = p2 ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| hence |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| by A1, A3, A4, A8, A9, Lm22; ::_thesis: verum end; suppose p1 = p3 ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| hence |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| by A1, A2, A4, A8, A9, Lm23; ::_thesis: verum end; suppose p1 = p4 ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| hence |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| by A1, A2, A3, A8, A9, A7, Lm22; ::_thesis: verum end; suppose p2 = p3 ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| hence |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| by A1, A2, A4, A8, A9, A5, A6, Lm22; ::_thesis: verum end; suppose p2 = p4 ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| hence |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| by A1, A2, A3, A8, A9, Lm23; ::_thesis: verum end; suppose p3 = p4 ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| hence |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| by A1, A2, A3, A8, A9, A5, A7, Lm22; ::_thesis: verum end; end; end; supposeA11: p1,p2,p3,p4 are_mutually_different ; ::_thesis: |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| then A12: p3 <> p4 by ZFMISC_1:def_6; A13: p1 <> p2 by A11, ZFMISC_1:def_6; A14: p2 <> p3 by A11, ZFMISC_1:def_6; A15: (LSeg (p1,p3)) \ {p1,p3} c= inside_of_circle (a,b,r) by A1, A3, TOPREAL9:60; A16: inside_of_circle (a,b,r) misses circle (a,b,r) by TOPREAL9:54; A17: (LSeg (p2,p4)) \ {p2,p4} c= inside_of_circle (a,b,r) by A2, A4, TOPREAL9:60; A18: ( p <> p2 & p <> p3 ) proof assume A19: ( p = p2 or p = p3 ) ; ::_thesis: contradiction percases ( p = p3 or p = p2 ) by A19; supposeA20: p = p3 ; ::_thesis: contradiction not p3 in {p2,p4} by A14, A12, TARSKI:def_2; then p3 in (LSeg (p2,p4)) \ {p2,p4} by A9, A20, XBOOLE_0:def_5; then p3 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A3, A17, XBOOLE_0:def_4; hence contradiction by A16, XBOOLE_0:def_7; ::_thesis: verum end; supposeA21: p = p2 ; ::_thesis: contradiction not p2 in {p1,p3} by A13, A14, TARSKI:def_2; then p2 in (LSeg (p1,p3)) \ {p1,p3} by A8, A21, XBOOLE_0:def_5; then p2 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A2, A15, XBOOLE_0:def_4; hence contradiction by A16, XBOOLE_0:def_7; ::_thesis: verum end; end; end; then A22: p2,p,p3 are_mutually_different by A14, ZFMISC_1:def_5; A23: p1 <> p4 by A11, ZFMISC_1:def_6; A24: ( p <> p1 & p <> p4 ) proof assume A25: ( p = p1 or p = p4 ) ; ::_thesis: contradiction percases ( p = p1 or p = p4 ) by A25; supposeA26: p = p1 ; ::_thesis: contradiction not p1 in {p2,p4} by A13, A23, TARSKI:def_2; then p1 in (LSeg (p2,p4)) \ {p2,p4} by A9, A26, XBOOLE_0:def_5; then p1 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A1, A17, XBOOLE_0:def_4; hence contradiction by A16, XBOOLE_0:def_7; ::_thesis: verum end; supposeA27: p = p4 ; ::_thesis: contradiction not p4 in {p1,p3} by A23, A12, TARSKI:def_2; then p4 in (LSeg (p1,p3)) \ {p1,p3} by A8, A27, XBOOLE_0:def_5; then p4 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) by A4, A15, XBOOLE_0:def_4; hence contradiction by A16, XBOOLE_0:def_7; ::_thesis: verum end; end; end; then A28: angle (p4,p,p1) = angle (p2,p,p3) by A8, A9, A18, Th15; A29: p2 <> p4 by A11, ZFMISC_1:def_6; A30: angle (p3,p2,p) <> PI proof assume angle (p3,p2,p) = PI ; ::_thesis: contradiction then angle (p3,p2,p4) = PI by A9, A18, Th10; hence contradiction by A2, A3, A4, A14, A29, Th35; ::_thesis: verum end; A31: p1 <> p3 by A11, ZFMISC_1:def_6; A32: angle (p,p3,p2) <> PI proof assume angle (p,p3,p2) = PI ; ::_thesis: contradiction then angle (p1,p3,p2) = PI by A8, A18, Th9; hence contradiction by A1, A2, A3, A31, A14, Th35; ::_thesis: verum end; A33: angle (p,p1,p4) <> PI proof assume angle (p,p1,p4) = PI ; ::_thesis: contradiction then angle (p3,p1,p4) = PI by A8, A24, Th9; hence contradiction by A1, A3, A4, A31, A23, Th35; ::_thesis: verum end; A34: angle (p,p3,p2) = angle (p1,p3,p2) by A8, A18, Th9; A35: angle (p1,p4,p) = angle (p1,p4,p2) by A9, A24, Th10; A36: angle (p4,p,p1) <> PI proof assume angle (p4,p,p1) = PI ; ::_thesis: contradiction then p in LSeg (p1,p4) by Th11; hence contradiction by A1, A2, A4, A9, A13, A24, Th30; ::_thesis: verum end; then angle (p2,p,p3) <> PI by A8, A9, A24, A18, Th15; then A37: p2,p,p3 is_a_triangle by A22, A32, A30, Th20; A38: angle (p1,p4,p) <> PI proof assume angle (p1,p4,p) = PI ; ::_thesis: contradiction then angle (p1,p4,p2) = PI by A9, A24, Th10; hence contradiction by A1, A2, A4, A23, A29, Th35; ::_thesis: verum end; p4,p,p1 are_mutually_different by A23, A24, ZFMISC_1:def_5; then A39: p4,p,p1 is_a_triangle by A36, A33, A38, Th20; angle (p1,p4,p2) = angle (p1,p3,p2) by A1, A2, A3, A4, A8, A9, A11, Th36; hence |.(p1 - p).| * |.(p - p3).| = |.(p2 - p).| * |.(p - p4).| by A5, A6, A7, A35, A34, A28, A39, A37, Th22; ::_thesis: verum end; end; end; begin theorem :: EUCLID_6:39 for p2, p1, p3 being Point of (TOP-REAL 2) for a, b, c, s being real number st a = |.(p2 - p1).| & b = |.(p3 - p2).| & c = |.(p1 - p3).| & s = (the_perimeter_of_polygon3 (p1,p2,p3)) / 2 holds abs (the_area_of_polygon3 (p1,p2,p3)) = sqrt (((s * (s - a)) * (s - b)) * (s - c)) proof let p2, p1, p3 be Point of (TOP-REAL 2); ::_thesis: for a, b, c, s being real number st a = |.(p2 - p1).| & b = |.(p3 - p2).| & c = |.(p1 - p3).| & s = (the_perimeter_of_polygon3 (p1,p2,p3)) / 2 holds abs (the_area_of_polygon3 (p1,p2,p3)) = sqrt (((s * (s - a)) * (s - b)) * (s - c)) let a, b, c, s be real number ; ::_thesis: ( a = |.(p2 - p1).| & b = |.(p3 - p2).| & c = |.(p1 - p3).| & s = (the_perimeter_of_polygon3 (p1,p2,p3)) / 2 implies abs (the_area_of_polygon3 (p1,p2,p3)) = sqrt (((s * (s - a)) * (s - b)) * (s - c)) ) assume that A1: a = |.(p2 - p1).| and A2: b = |.(p3 - p2).| and A3: c = |.(p1 - p3).| ; ::_thesis: ( not s = (the_perimeter_of_polygon3 (p1,p2,p3)) / 2 or abs (the_area_of_polygon3 (p1,p2,p3)) = sqrt (((s * (s - a)) * (s - b)) * (s - c)) ) A4: a = |.(p1 - p2).| by A1, Lm2; c = |.(p3 - p1).| by A3, Lm2; then A5: c ^2 = ((a ^2) + (b ^2)) - (((2 * a) * b) * (cos (angle (p1,p2,p3)))) by A2, A4, Th7; assume A6: s = (the_perimeter_of_polygon3 (p1,p2,p3)) / 2 ; ::_thesis: abs (the_area_of_polygon3 (p1,p2,p3)) = sqrt (((s * (s - a)) * (s - b)) * (s - c)) A7: ((sin (angle (p3,p2,p1))) ^2) + ((cos (angle (p3,p2,p1))) ^2) = 1 by SIN_COS:29; (the_area_of_polygon3 (p1,p2,p3)) ^2 = (((a * b) * (sin (angle (p3,p2,p1)))) / 2) ^2 by A2, A4, Th5 .= (((a * b) * (sin (angle (p3,p2,p1)))) ^2) * ((1 / 2) ^2) .= (((a * b) ^2) * (1 - ((cos (angle (p3,p2,p1))) ^2))) * ((1 / 2) ^2) by A7, SQUARE_1:9 .= (((((a * b) ^2) - (((a * b) ^2) * ((cos (angle (p3,p2,p1))) ^2))) * (2 ^2)) / (2 ^2)) * ((1 / 2) ^2) by XCMPLX_1:89 .= ((((2 ^2) * ((a * b) ^2)) - ((((2 * a) * b) * (cos (angle (p3,p2,p1)))) ^2)) / (2 ^2)) * ((1 / 2) ^2) .= ((((2 ^2) * ((a * b) ^2)) - ((((- (c ^2)) + (a ^2)) + (b ^2)) ^2)) / (2 ^2)) * ((1 / 2) ^2) by A5, Th3 .= ((((16 * (s - a)) * (s - b)) * ((s - c) * s)) / (2 * 2)) * ((1 / 2) ^2) by A1, A2, A3, A6 .= ((s * (s - a)) * (s - b)) * (s - c) ; hence abs (the_area_of_polygon3 (p1,p2,p3)) = sqrt (((s * (s - a)) * (s - b)) * (s - c)) by COMPLEX1:72; ::_thesis: verum end; theorem :: EUCLID_6:40 for p1, p2, p3, p4, p being Point of (TOP-REAL 2) for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) holds |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) proof let p1, p2, p3, p4, p be Point of (TOP-REAL 2); ::_thesis: for a, b, r being real number st p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) holds |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) let a, b, r be real number ; ::_thesis: ( p1 in circle (a,b,r) & p2 in circle (a,b,r) & p3 in circle (a,b,r) & p4 in circle (a,b,r) & p in LSeg (p1,p3) & p in LSeg (p2,p4) implies |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) ) assume that A1: p1 in circle (a,b,r) and A2: p2 in circle (a,b,r) and A3: p3 in circle (a,b,r) and A4: p4 in circle (a,b,r) ; ::_thesis: ( not p in LSeg (p1,p3) or not p in LSeg (p2,p4) or |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) ) A5: |.(p3 - p1).| = |.(p1 - p3).| by Lm2; assume that A6: p in LSeg (p1,p3) and A7: p in LSeg (p2,p4) ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) percases ( not p1,p2,p3,p4 are_mutually_different or p1,p2,p3,p4 are_mutually_different ) ; supposeA8: not p1,p2,p3,p4 are_mutually_different ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) percases ( p1 = p2 or p1 = p3 or p1 = p4 or p2 = p3 or p2 = p4 or p3 = p4 ) by A8, ZFMISC_1:def_6; supposeA9: p1 = p2 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then |.(p2 - p1).| = 0 by Lm1; hence |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) by A9; ::_thesis: verum end; suppose p1 = p3 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then A10: p in {p1} by A6, RLTOPSP1:70; then p in circle (a,b,r) by A1, TARSKI:def_1; then p in (LSeg (p2,p4)) /\ (circle (a,b,r)) by A7, XBOOLE_0:def_4; then p in {p2,p4} by A2, A4, TOPREAL9:61; then A11: ( p = p2 or p = p4 ) by TARSKI:def_2; percases ( p1 = p2 or p1 = p4 ) by A10, A11, TARSKI:def_1; supposeA12: p1 = p2 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then |.(p2 - p1).| = 0 by Lm1; hence |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) by A12; ::_thesis: verum end; supposeA13: p1 = p4 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then |.(p4 - p1).| = 0 by Lm1; hence |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) by A5, A13, Lm2; ::_thesis: verum end; end; end; supposeA14: p1 = p4 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then |.(p4 - p1).| = 0 by Lm1; hence |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) by A5, A14, Lm2; ::_thesis: verum end; supposeA15: p2 = p3 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then |.(p3 - p2).| = 0 by Lm1; hence |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) by A15; ::_thesis: verum end; suppose p2 = p4 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then A16: p in {p2} by A7, RLTOPSP1:70; then p in circle (a,b,r) by A2, TARSKI:def_1; then p in (LSeg (p1,p3)) /\ (circle (a,b,r)) by A6, XBOOLE_0:def_4; then p in {p1,p3} by A1, A3, TOPREAL9:61; then A17: ( p = p1 or p = p3 ) by TARSKI:def_2; percases ( p1 = p2 or p2 = p3 ) by A16, A17, TARSKI:def_1; supposeA18: p1 = p2 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then |.(p2 - p1).| = 0 by Lm1; hence |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) by A18; ::_thesis: verum end; supposeA19: p2 = p3 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then |.(p3 - p2).| = 0 by Lm1; hence |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) by A19; ::_thesis: verum end; end; end; supposeA20: p3 = p4 ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then |.(p4 - p3).| = 0 by Lm1; hence |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) by A20; ::_thesis: verum end; end; end; supposeA21: p1,p2,p3,p4 are_mutually_different ; ::_thesis: |.(p3 - p1).| * |.(p4 - p2).| = (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) then A22: p3 <> p4 by ZFMISC_1:def_6; then A23: euc2cpx p3 <> euc2cpx p4 by EUCLID_3:4; A24: p2 <> p4 by A21, ZFMISC_1:def_6; then A25: angle (p3,p4,p2) <> PI by A2, A3, A4, A22, Th35; A26: p1 <> p2 by A21, ZFMISC_1:def_6; then A27: angle (p1,p2,p4) <> PI by A1, A2, A4, A24, Th35; A28: p1 <> p4 by A21, ZFMISC_1:def_6; then A29: angle (p4,p1,p2) <> PI by A1, A2, A4, A26, Th35; A30: angle (p2,p4,p1) <> PI by A1, A2, A4, A28, A24, Th35; p2,p4,p1 are_mutually_different by A26, A28, A24, ZFMISC_1:def_5; then A31: p2,p4,p1 is_a_triangle by A30, A29, A27, Th20; A32: p2 <> p3 by A21, ZFMISC_1:def_6; then A33: euc2cpx p2 <> euc2cpx p3 by EUCLID_3:4; A34: angle (p2,p3,p4) <> PI by A2, A3, A4, A32, A22, Th35; A35: not p2 in LSeg (p1,p3) proof assume A36: p2 in LSeg (p1,p3) ; ::_thesis: contradiction not p2 in {p1,p3} by A26, A32, TARSKI:def_2; then A37: p2 in (LSeg (p1,p3)) \ {p1,p3} by A36, XBOOLE_0:def_5; (LSeg (p1,p3)) \ {p1,p3} c= inside_of_circle (a,b,r) by A1, A3, TOPREAL9:60; then ( inside_of_circle (a,b,r) misses circle (a,b,r) & p2 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) ) by A2, A37, TOPREAL9:54, XBOOLE_0:def_4; hence contradiction by XBOOLE_0:def_7; ::_thesis: verum end; then consider p5 being Point of (TOP-REAL 2) such that A38: p5 in LSeg (p1,p3) and A39: angle (p1,p2,p5) = angle (p,p2,p3) by A6, Th28; A40: angle (p4,p2,p3) <> PI by A2, A3, A4, A32, A24, Th35; then A41: angle (p1,p2,p5) <> PI by A6, A7, A35, A39, Th9; A42: euc2cpx p2 <> euc2cpx p4 by A24, EUCLID_3:4; A43: p5 <> p1 proof assume p5 = p1 ; ::_thesis: contradiction then angle (p4,p2,p3) = angle (p1,p2,p1) by A6, A7, A35, A39, Th9 .= 0 by COMPLEX2:79 ; hence contradiction by A34, A25, A33, A42, A23, COMPLEX2:87; ::_thesis: verum end; A44: p5 <> p3 proof ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = angle (p4,p2,p4) or (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = (angle (p4,p2,p4)) + (2 * PI) ) by Th4; then A45: ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 0 or (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 0 + (2 * PI) ) by COMPLEX2:79; assume p5 = p3 ; ::_thesis: contradiction then A46: angle (p4,p2,p3) = angle (p1,p2,p3) by A6, A7, A35, A39, Th9; percases ( ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 0 & (angle (p1,p2,p3)) + (angle (p3,p2,p4)) = angle (p1,p2,p4) ) or ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 2 * PI & (angle (p1,p2,p3)) + (angle (p3,p2,p4)) = (angle (p1,p2,p4)) + (2 * PI) ) or ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 2 * PI & (angle (p1,p2,p3)) + (angle (p3,p2,p4)) = angle (p1,p2,p4) ) or ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 0 & (angle (p1,p2,p3)) + (angle (p3,p2,p4)) = (angle (p1,p2,p4)) + (2 * PI) ) ) by A45, Th4; suppose ( ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 0 & (angle (p1,p2,p3)) + (angle (p3,p2,p4)) = angle (p1,p2,p4) ) or ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 2 * PI & (angle (p1,p2,p3)) + (angle (p3,p2,p4)) = (angle (p1,p2,p4)) + (2 * PI) ) ) ; ::_thesis: contradiction hence contradiction by A1, A2, A4, A26, A28, A24, A46, Th37; ::_thesis: verum end; suppose ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 2 * PI & (angle (p1,p2,p3)) + (angle (p3,p2,p4)) = angle (p1,p2,p4) ) ; ::_thesis: contradiction hence contradiction by A46, COMPLEX2:70; ::_thesis: verum end; suppose ( (angle (p4,p2,p3)) + (angle (p3,p2,p4)) = 0 & (angle (p1,p2,p3)) + (angle (p3,p2,p4)) = (angle (p1,p2,p4)) + (2 * PI) ) ; ::_thesis: contradiction then angle (p1,p2,p4) = - (2 * PI) by A46; hence contradiction by COMPLEX2:70; ::_thesis: verum end; end; end; A47: angle (p,p2,p3) = angle (p4,p2,p3) by A6, A7, A35, Th9; A48: angle (p5,p2,p3) = angle (p1,p2,p4) proof percases ( ( angle (p5,p2,p3) = (angle (p5,p2,p4)) + (angle (p4,p2,p3)) & angle (p1,p2,p4) = (angle (p4,p2,p3)) + (angle (p5,p2,p4)) ) or ( (angle (p5,p2,p3)) + (2 * PI) = (angle (p5,p2,p4)) + (angle (p4,p2,p3)) & (angle (p1,p2,p4)) + (2 * PI) = (angle (p4,p2,p3)) + (angle (p5,p2,p4)) ) or ( (angle (p5,p2,p3)) + (2 * PI) = (angle (p5,p2,p4)) + (angle (p4,p2,p3)) & angle (p1,p2,p4) = (angle (p4,p2,p3)) + (angle (p5,p2,p4)) ) or ( angle (p5,p2,p3) = (angle (p5,p2,p4)) + (angle (p4,p2,p3)) & (angle (p1,p2,p4)) + (2 * PI) = (angle (p4,p2,p3)) + (angle (p5,p2,p4)) ) ) by A47, A39, Th4; suppose ( ( angle (p5,p2,p3) = (angle (p5,p2,p4)) + (angle (p4,p2,p3)) & angle (p1,p2,p4) = (angle (p4,p2,p3)) + (angle (p5,p2,p4)) ) or ( (angle (p5,p2,p3)) + (2 * PI) = (angle (p5,p2,p4)) + (angle (p4,p2,p3)) & (angle (p1,p2,p4)) + (2 * PI) = (angle (p4,p2,p3)) + (angle (p5,p2,p4)) ) ) ; ::_thesis: angle (p5,p2,p3) = angle (p1,p2,p4) hence angle (p5,p2,p3) = angle (p1,p2,p4) ; ::_thesis: verum end; supposeA49: ( (angle (p5,p2,p3)) + (2 * PI) = (angle (p5,p2,p4)) + (angle (p4,p2,p3)) & angle (p1,p2,p4) = (angle (p4,p2,p3)) + (angle (p5,p2,p4)) ) ; ::_thesis: angle (p5,p2,p3) = angle (p1,p2,p4) angle (p5,p2,p3) >= 0 by COMPLEX2:70; then (angle (p5,p2,p3)) + (2 * PI) >= 0 + (2 * PI) by XREAL_1:6; hence angle (p5,p2,p3) = angle (p1,p2,p4) by A49, COMPLEX2:70; ::_thesis: verum end; supposeA50: ( angle (p5,p2,p3) = (angle (p5,p2,p4)) + (angle (p4,p2,p3)) & (angle (p1,p2,p4)) + (2 * PI) = (angle (p4,p2,p3)) + (angle (p5,p2,p4)) ) ; ::_thesis: angle (p5,p2,p3) = angle (p1,p2,p4) angle (p1,p2,p4) >= 0 by COMPLEX2:70; then (angle (p1,p2,p4)) + (2 * PI) >= 0 + (2 * PI) by XREAL_1:6; hence angle (p5,p2,p3) = angle (p1,p2,p4) by A50, COMPLEX2:70; ::_thesis: verum end; end; end; A51: p5 <> p2 proof A52: (LSeg (p1,p3)) \ {p1,p3} c= inside_of_circle (a,b,r) by A1, A3, TOPREAL9:60; assume A53: p5 = p2 ; ::_thesis: contradiction not p2 in {p1,p3} by A26, A32, TARSKI:def_2; then p2 in (LSeg (p1,p3)) \ {p1,p3} by A38, A53, XBOOLE_0:def_5; then ( inside_of_circle (a,b,r) misses circle (a,b,r) & p2 in (inside_of_circle (a,b,r)) /\ (circle (a,b,r)) ) by A2, A52, TOPREAL9:54, XBOOLE_0:def_4; hence contradiction by XBOOLE_0:def_7; ::_thesis: verum end; then A54: p1,p2,p5 are_mutually_different by A26, A43, ZFMISC_1:def_5; p1 <> p3 by A21, ZFMISC_1:def_6; then p2,p3,p4,p1 are_mutually_different by A26, A28, A32, A24, A22, ZFMISC_1:def_6; then A55: angle (p2,p1,p3) = angle (p2,p4,p3) by A1, A2, A3, A4, A6, A7, Th36; A56: angle (p3,p1,p2) = angle (p3,p4,p2) proof percases ( angle (p2,p1,p3) = 0 or angle (p2,p1,p3) <> 0 ) ; supposeA57: angle (p2,p1,p3) = 0 ; ::_thesis: angle (p3,p1,p2) = angle (p3,p4,p2) then angle (p3,p1,p2) = 0 by EUCLID_3:36; hence angle (p3,p1,p2) = angle (p3,p4,p2) by A55, A57, EUCLID_3:36; ::_thesis: verum end; supposeA58: angle (p2,p1,p3) <> 0 ; ::_thesis: angle (p3,p1,p2) = angle (p3,p4,p2) then angle (p3,p1,p2) = (2 * PI) - (angle (p2,p1,p3)) by EUCLID_3:37; hence angle (p3,p1,p2) = angle (p3,p4,p2) by A55, A58, EUCLID_3:37; ::_thesis: verum end; end; end; then A59: angle (p5,p1,p2) = angle (p3,p4,p2) by A38, A43, Th9; A60: angle (p2,p3,p4) = angle (p2,p5,p1) proof A61: ( euc2cpx p2 <> euc2cpx p5 & euc2cpx p2 <> euc2cpx p1 ) by A26, A51, EUCLID_3:4; A62: euc2cpx p5 <> euc2cpx p1 by A43, EUCLID_3:4; percases ( ( ((angle (p2,p3,p4)) + (angle (p3,p4,p2))) + (angle (p4,p2,p3)) = PI & ((angle (p2,p5,p1)) + (angle (p5,p1,p2))) + (angle (p1,p2,p5)) = PI ) or ( ((angle (p2,p3,p4)) + (angle (p3,p4,p2))) + (angle (p4,p2,p3)) = 5 * PI & ((angle (p2,p5,p1)) + (angle (p5,p1,p2))) + (angle (p1,p2,p5)) = 5 * PI ) or ( ((angle (p2,p3,p4)) + (angle (p3,p4,p2))) + (angle (p4,p2,p3)) = 5 * PI & ((angle (p2,p5,p1)) + (angle (p5,p1,p2))) + (angle (p1,p2,p5)) = PI ) or ( ((angle (p2,p3,p4)) + (angle (p3,p4,p2))) + (angle (p4,p2,p3)) = PI & ((angle (p2,p5,p1)) + (angle (p5,p1,p2))) + (angle (p1,p2,p5)) = 5 * PI ) ) by A33, A42, A23, A61, A62, COMPLEX2:88; suppose ( ( ((angle (p2,p3,p4)) + (angle (p3,p4,p2))) + (angle (p4,p2,p3)) = PI & ((angle (p2,p5,p1)) + (angle (p5,p1,p2))) + (angle (p1,p2,p5)) = PI ) or ( ((angle (p2,p3,p4)) + (angle (p3,p4,p2))) + (angle (p4,p2,p3)) = 5 * PI & ((angle (p2,p5,p1)) + (angle (p5,p1,p2))) + (angle (p1,p2,p5)) = 5 * PI ) ) ; ::_thesis: angle (p2,p3,p4) = angle (p2,p5,p1) hence angle (p2,p3,p4) = angle (p2,p5,p1) by A47, A39, A59; ::_thesis: verum end; supposeA63: ( ((angle (p2,p3,p4)) + (angle (p3,p4,p2))) + (angle (p4,p2,p3)) = 5 * PI & ((angle (p2,p5,p1)) + (angle (p5,p1,p2))) + (angle (p1,p2,p5)) = PI ) ; ::_thesis: angle (p2,p3,p4) = angle (p2,p5,p1) ( angle (p2,p3,p4) < 2 * PI & angle (p2,p5,p1) >= 0 ) by COMPLEX2:70; then A64: (angle (p2,p3,p4)) - (angle (p2,p5,p1)) < (2 * PI) - 0 by XREAL_1:14; (angle (p2,p3,p4)) - (angle (p2,p5,p1)) = 4 * PI by A47, A39, A59, A63; hence angle (p2,p3,p4) = angle (p2,p5,p1) by A64, XREAL_1:64; ::_thesis: verum end; supposeA65: ( ((angle (p2,p3,p4)) + (angle (p3,p4,p2))) + (angle (p4,p2,p3)) = PI & ((angle (p2,p5,p1)) + (angle (p5,p1,p2))) + (angle (p1,p2,p5)) = 5 * PI ) ; ::_thesis: angle (p2,p3,p4) = angle (p2,p5,p1) ( angle (p2,p5,p1) < 2 * PI & angle (p2,p3,p4) >= 0 ) by COMPLEX2:70; then A66: (angle (p2,p5,p1)) - (angle (p2,p3,p4)) < (2 * PI) - 0 by XREAL_1:14; (angle (p2,p5,p1)) - (angle (p2,p3,p4)) = 4 * PI by A47, A39, A59, A65; hence angle (p2,p3,p4) = angle (p2,p5,p1) by A66, XREAL_1:64; ::_thesis: verum end; end; end; A67: angle (p1,p4,p2) = angle (p1,p3,p2) by A1, A2, A3, A4, A6, A7, A21, Th36; angle (p2,p4,p1) = angle (p2,p3,p1) proof percases ( angle (p1,p4,p2) = 0 or angle (p1,p4,p2) <> 0 ) ; supposeA68: angle (p1,p4,p2) = 0 ; ::_thesis: angle (p2,p4,p1) = angle (p2,p3,p1) then angle (p2,p4,p1) = 0 by EUCLID_3:36; hence angle (p2,p4,p1) = angle (p2,p3,p1) by A67, A68, EUCLID_3:36; ::_thesis: verum end; supposeA69: angle (p1,p4,p2) <> 0 ; ::_thesis: angle (p2,p4,p1) = angle (p2,p3,p1) then angle (p2,p4,p1) = (2 * PI) - (angle (p1,p4,p2)) by EUCLID_3:37; hence angle (p2,p4,p1) = angle (p2,p3,p1) by A67, A69, EUCLID_3:37; ::_thesis: verum end; end; end; then A70: angle (p2,p4,p1) = angle (p2,p3,p5) by A38, A44, Th10; A71: angle (p4,p1,p2) = angle (p3,p5,p2) proof A72: ( euc2cpx p2 <> euc2cpx p5 & euc2cpx p3 <> euc2cpx p5 ) by A44, A51, EUCLID_3:4; A73: ( euc2cpx p4 <> euc2cpx p1 & euc2cpx p2 <> euc2cpx p3 ) by A28, A32, EUCLID_3:4; A74: ( euc2cpx p2 <> euc2cpx p4 & euc2cpx p2 <> euc2cpx p1 ) by A26, A24, EUCLID_3:4; percases ( ( ((angle (p2,p4,p1)) + (angle (p4,p1,p2))) + (angle (p1,p2,p4)) = PI & ((angle (p2,p3,p5)) + (angle (p3,p5,p2))) + (angle (p5,p2,p3)) = PI ) or ( ((angle (p2,p4,p1)) + (angle (p4,p1,p2))) + (angle (p1,p2,p4)) = 5 * PI & ((angle (p2,p3,p5)) + (angle (p3,p5,p2))) + (angle (p5,p2,p3)) = 5 * PI ) or ( ((angle (p2,p4,p1)) + (angle (p4,p1,p2))) + (angle (p1,p2,p4)) = 5 * PI & ((angle (p2,p3,p5)) + (angle (p3,p5,p2))) + (angle (p5,p2,p3)) = PI ) or ( ((angle (p2,p4,p1)) + (angle (p4,p1,p2))) + (angle (p1,p2,p4)) = PI & ((angle (p2,p3,p5)) + (angle (p3,p5,p2))) + (angle (p5,p2,p3)) = 5 * PI ) ) by A74, A73, A72, COMPLEX2:88; suppose ( ( ((angle (p2,p4,p1)) + (angle (p4,p1,p2))) + (angle (p1,p2,p4)) = PI & ((angle (p2,p3,p5)) + (angle (p3,p5,p2))) + (angle (p5,p2,p3)) = PI ) or ( ((angle (p2,p4,p1)) + (angle (p4,p1,p2))) + (angle (p1,p2,p4)) = 5 * PI & ((angle (p2,p3,p5)) + (angle (p3,p5,p2))) + (angle (p5,p2,p3)) = 5 * PI ) ) ; ::_thesis: angle (p4,p1,p2) = angle (p3,p5,p2) hence angle (p4,p1,p2) = angle (p3,p5,p2) by A70, A48; ::_thesis: verum end; supposeA75: ( ((angle (p2,p4,p1)) + (angle (p4,p1,p2))) + (angle (p1,p2,p4)) = 5 * PI & ((angle (p2,p3,p5)) + (angle (p3,p5,p2))) + (angle (p5,p2,p3)) = PI ) ; ::_thesis: angle (p4,p1,p2) = angle (p3,p5,p2) ( angle (p4,p1,p2) < 2 * PI & angle (p3,p5,p2) >= 0 ) by COMPLEX2:70; then A76: (angle (p4,p1,p2)) - (angle (p3,p5,p2)) < (2 * PI) - 0 by XREAL_1:14; (angle (p4,p1,p2)) - (angle (p3,p5,p2)) = 4 * PI by A70, A48, A75; hence angle (p4,p1,p2) = angle (p3,p5,p2) by A76, XREAL_1:64; ::_thesis: verum end; supposeA77: ( ((angle (p2,p4,p1)) + (angle (p4,p1,p2))) + (angle (p1,p2,p4)) = PI & ((angle (p2,p3,p5)) + (angle (p3,p5,p2))) + (angle (p5,p2,p3)) = 5 * PI ) ; ::_thesis: angle (p4,p1,p2) = angle (p3,p5,p2) ( angle (p3,p5,p2) < 2 * PI & angle (p4,p1,p2) >= 0 ) by COMPLEX2:70; then A78: (angle (p3,p5,p2)) - (angle (p4,p1,p2)) < (2 * PI) - 0 by XREAL_1:14; (angle (p3,p5,p2)) - (angle (p4,p1,p2)) = 4 * PI by A70, A48, A77; hence angle (p4,p1,p2) = angle (p3,p5,p2) by A78, XREAL_1:64; ::_thesis: verum end; end; end; p2,p3,p5 are_mutually_different by A32, A44, A51, ZFMISC_1:def_5; then p2,p3,p5 is_a_triangle by A70, A48, A71, A30, A29, A27, Th20; then |.(p5 - p3).| * |.(p4 - p2).| = |.(p3 - p2).| * |.(p1 - p4).| by A70, A48, A31, Th21; then |.(p5 - p3).| * |.(p4 - p2).| = |.(p3 - p2).| * |.(p4 - p1).| by Lm2; then A79: |.(p3 - p5).| * |.(p4 - p2).| = |.(p3 - p2).| * |.(p4 - p1).| by Lm2; p4,p2,p3 are_mutually_different by A32, A24, A22, ZFMISC_1:def_5; then A80: p4,p2,p3 is_a_triangle by A40, A34, A25, Th20; A81: |.(p3 - p1).| = sqrt (|.(p3 - p1).| ^2) by SQUARE_1:22 .= sqrt (((|.(p1 - p5).| ^2) + (|.(p3 - p5).| ^2)) - (((2 * |.(p1 - p5).|) * |.(p3 - p5).|) * (cos (angle (p1,p5,p3))))) by Th7 .= sqrt (((|.(p1 - p5).| ^2) + (|.(p3 - p5).| ^2)) - (((2 * |.(p1 - p5).|) * |.(p3 - p5).|) * (cos PI))) by A38, A43, A44, Th8 .= sqrt ((|.(p1 - p5).| + |.(p3 - p5).|) ^2) by SIN_COS:77 .= |.(p1 - p5).| + |.(p3 - p5).| by SQUARE_1:22 ; angle (p5,p1,p2) <> PI by A2, A3, A4, A24, A22, A38, A43, A56, Th9, Th35; then p1,p2,p5 is_a_triangle by A34, A60, A41, A54, Th20; then |.(p1 - p5).| * |.(p2 - p4).| = |.(p2 - p1).| * |.(p4 - p3).| by A47, A39, A59, A80, Th21; then |.(p1 - p5).| * |.(p4 - p2).| = |.(p2 - p1).| * |.(p4 - p3).| by Lm2; hence (|.(p2 - p1).| * |.(p4 - p3).|) + (|.(p3 - p2).| * |.(p4 - p1).|) = (|.(p5 - p1).| * |.(p4 - p2).|) + (|.(p3 - p5).| * |.(p4 - p2).|) by A79, Lm2 .= (|.(p5 - p1).| + |.(p3 - p5).|) * |.(p4 - p2).| .= |.(p3 - p1).| * |.(p4 - p2).| by A81, Lm2 ; ::_thesis: verum end; end; end; begin theorem :: EUCLID_6:41 for p1, p2 being Point of (TOP-REAL 2) holds ( (p1 - p2) `1 = (p1 `1) - (p2 `1) & (p1 - p2) `2 = (p1 `2) - (p2 `2) ) by Lm15; theorem :: EUCLID_6:42 for p1, p2 being Point of (TOP-REAL 2) holds ( |.(p1 - p2).| = 0 iff p1 = p2 ) by Lm1; theorem :: EUCLID_6:43 for p1, p2 being Point of (TOP-REAL 2) holds |.(p1 - p2).| = |.(p2 - p1).| by Lm2; theorem :: EUCLID_6:44 for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) holds not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) + (2 * PI) by Lm3; theorem :: EUCLID_6:45 for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) holds not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) + (4 * PI) by Lm4; theorem :: EUCLID_6:46 for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) holds not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) - (4 * PI) by Lm5; theorem :: EUCLID_6:47 for p1, p2, p3, p4, p5, p6 being Point of (TOP-REAL 2) holds not angle (p1,p2,p3) = (2 * (angle (p4,p5,p6))) - (6 * PI) by Lm6; theorem :: EUCLID_6:48 for p1, p2, p3 being Point of (TOP-REAL 2) for c1, c2 being Element of COMPLEX st c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) holds angle (p1,p2,p3) = angle (c1,c2) by Lm7; theorem :: EUCLID_6:49 for c1, c2, c3 being Element of COMPLEX holds ( (angle (c1,c2)) + (angle (c2,c3)) = angle (c1,c3) or (angle (c1,c2)) + (angle (c2,c3)) = (angle (c1,c3)) + (2 * PI) ) by Lm14; theorem :: EUCLID_6:50 for p1, p2, p3 being Point of (TOP-REAL 2) for c1, c2 being Element of COMPLEX st c1 = euc2cpx (p1 - p2) & c2 = euc2cpx (p3 - p2) holds ( Re (c1 .|. c2) = (((p1 `1) - (p2 `1)) * ((p3 `1) - (p2 `1))) + (((p1 `2) - (p2 `2)) * ((p3 `2) - (p2 `2))) & Im (c1 .|. c2) = (- (((p1 `1) - (p2 `1)) * ((p3 `2) - (p2 `2)))) + (((p1 `2) - (p2 `2)) * ((p3 `1) - (p2 `1))) & |.c1.| = sqrt ((((p1 `1) - (p2 `1)) ^2) + (((p1 `2) - (p2 `2)) ^2)) & |.(p1 - p2).| = |.c1.| ) by Lm16; theorem :: EUCLID_6:51 for n being Element of NAT for q1 being Point of (TOP-REAL n) for f being Function of (TOP-REAL n),R^1 st ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) holds f is continuous by Lm20; theorem :: EUCLID_6:52 for n being Element of NAT for q1 being Point of (TOP-REAL n) ex f being Function of (TOP-REAL n),R^1 st ( ( for q being Point of (TOP-REAL n) holds f . q = |.(q - q1).| ) & f is continuous ) by Lm21;