:: Trigonometric Functions on Complex Space
:: by Takashi Mitsuishi , Noboru Endou and Keiji Ohkubo
::
:: Received October 10, 2002
:: Copyright (c) 2002-2011 Association of Mizar Users


begin

definition
func sin_C -> Function of COMPLEX,COMPLEX means :Def1: :: SIN_COS3:def 1
for z being Element of COMPLEX holds it . z = ((exp (<i> * z)) - (exp (- (<i> * z)))) / (2 * <i>);
existence
ex b1 being Function of COMPLEX,COMPLEX st
for z being Element of COMPLEX holds b1 . z = ((exp (<i> * z)) - (exp (- (<i> * z)))) / (2 * <i>)
proof end;
uniqueness
for b1, b2 being Function of COMPLEX,COMPLEX st ( for z being Element of COMPLEX holds b1 . z = ((exp (<i> * z)) - (exp (- (<i> * z)))) / (2 * <i>) ) & ( for z being Element of COMPLEX holds b2 . z = ((exp (<i> * z)) - (exp (- (<i> * z)))) / (2 * <i>) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def1 defines sin_C SIN_COS3:def 1 :
for b1 being Function of COMPLEX,COMPLEX holds
( b1 = sin_C iff for z being Element of COMPLEX holds b1 . z = ((exp (<i> * z)) - (exp (- (<i> * z)))) / (2 * <i>) );

definition
func cos_C -> Function of COMPLEX,COMPLEX means :Def2: :: SIN_COS3:def 2
for z being Element of COMPLEX holds it . z = ((exp (<i> * z)) + (exp (- (<i> * z)))) / 2;
existence
ex b1 being Function of COMPLEX,COMPLEX st
for z being Element of COMPLEX holds b1 . z = ((exp (<i> * z)) + (exp (- (<i> * z)))) / 2
proof end;
uniqueness
for b1, b2 being Function of COMPLEX,COMPLEX st ( for z being Element of COMPLEX holds b1 . z = ((exp (<i> * z)) + (exp (- (<i> * z)))) / 2 ) & ( for z being Element of COMPLEX holds b2 . z = ((exp (<i> * z)) + (exp (- (<i> * z)))) / 2 ) holds
b1 = b2
proof end;
end;

:: deftheorem Def2 defines cos_C SIN_COS3:def 2 :
for b1 being Function of COMPLEX,COMPLEX holds
( b1 = cos_C iff for z being Element of COMPLEX holds b1 . z = ((exp (<i> * z)) + (exp (- (<i> * z)))) / 2 );

definition
func sinh_C -> Function of COMPLEX,COMPLEX means :Def3: :: SIN_COS3:def 3
for z being Element of COMPLEX holds it . z = ((exp z) - (exp (- z))) / 2;
existence
ex b1 being Function of COMPLEX,COMPLEX st
for z being Element of COMPLEX holds b1 . z = ((exp z) - (exp (- z))) / 2
proof end;
uniqueness
for b1, b2 being Function of COMPLEX,COMPLEX st ( for z being Element of COMPLEX holds b1 . z = ((exp z) - (exp (- z))) / 2 ) & ( for z being Element of COMPLEX holds b2 . z = ((exp z) - (exp (- z))) / 2 ) holds
b1 = b2
proof end;
end;

:: deftheorem Def3 defines sinh_C SIN_COS3:def 3 :
for b1 being Function of COMPLEX,COMPLEX holds
( b1 = sinh_C iff for z being Element of COMPLEX holds b1 . z = ((exp z) - (exp (- z))) / 2 );

definition
func cosh_C -> Function of COMPLEX,COMPLEX means :Def4: :: SIN_COS3:def 4
for z being Element of COMPLEX holds it . z = ((exp z) + (exp (- z))) / 2;
existence
ex b1 being Function of COMPLEX,COMPLEX st
for z being Element of COMPLEX holds b1 . z = ((exp z) + (exp (- z))) / 2
proof end;
uniqueness
for b1, b2 being Function of COMPLEX,COMPLEX st ( for z being Element of COMPLEX holds b1 . z = ((exp z) + (exp (- z))) / 2 ) & ( for z being Element of COMPLEX holds b2 . z = ((exp z) + (exp (- z))) / 2 ) holds
b1 = b2
proof end;
end;

:: deftheorem Def4 defines cosh_C SIN_COS3:def 4 :
for b1 being Function of COMPLEX,COMPLEX holds
( b1 = cosh_C iff for z being Element of COMPLEX holds b1 . z = ((exp z) + (exp (- z))) / 2 );

Lm1: for z being complex number holds sinh_C /. z = ((exp z) - (exp (- z))) / 2
proof end;

Lm2: for z being complex number holds cosh_C /. z = ((exp z) + (exp (- z))) / 2
proof end;

Lm3: for z being Element of COMPLEX holds (exp z) * (exp (- z)) = 1
proof end;

begin

theorem :: SIN_COS3:1
for z being Element of COMPLEX holds ((sin_C /. z) * (sin_C /. z)) + ((cos_C /. z) * (cos_C /. z)) = 1
proof end;

theorem Th2: :: SIN_COS3:2
for z being complex number holds - (sin_C /. z) = sin_C /. (- z)
proof end;

theorem Th3: :: SIN_COS3:3
for z being complex number holds cos_C /. z = cos_C /. (- z)
proof end;

theorem Th4: :: SIN_COS3:4
for z1, z2 being complex number holds sin_C /. (z1 + z2) = ((sin_C /. z1) * (cos_C /. z2)) + ((cos_C /. z1) * (sin_C /. z2))
proof end;

theorem :: SIN_COS3:5
for z1, z2 being Element of COMPLEX holds sin_C /. (z1 - z2) = ((sin_C /. z1) * (cos_C /. z2)) - ((cos_C /. z1) * (sin_C /. z2))
proof end;

theorem Th6: :: SIN_COS3:6
for z1, z2 being complex number holds cos_C /. (z1 + z2) = ((cos_C /. z1) * (cos_C /. z2)) - ((sin_C /. z1) * (sin_C /. z2))
proof end;

theorem :: SIN_COS3:7
for z1, z2 being Element of COMPLEX holds cos_C /. (z1 - z2) = ((cos_C /. z1) * (cos_C /. z2)) + ((sin_C /. z1) * (sin_C /. z2))
proof end;

theorem Th8: :: SIN_COS3:8
for z being Element of COMPLEX holds ((cosh_C /. z) * (cosh_C /. z)) - ((sinh_C /. z) * (sinh_C /. z)) = 1
proof end;

theorem Th9: :: SIN_COS3:9
for z being Element of COMPLEX holds - (sinh_C /. z) = sinh_C /. (- z)
proof end;

theorem Th10: :: SIN_COS3:10
for z being Element of COMPLEX holds cosh_C /. z = cosh_C /. (- z)
proof end;

theorem Th11: :: SIN_COS3:11
for z1, z2 being Element of COMPLEX holds sinh_C /. (z1 + z2) = ((sinh_C /. z1) * (cosh_C /. z2)) + ((cosh_C /. z1) * (sinh_C /. z2))
proof end;

theorem Th12: :: SIN_COS3:12
for z1, z2 being Element of COMPLEX holds sinh_C /. (z1 - z2) = ((sinh_C /. z1) * (cosh_C /. z2)) - ((cosh_C /. z1) * (sinh_C /. z2))
proof end;

theorem Th13: :: SIN_COS3:13
for z1, z2 being Element of COMPLEX holds cosh_C /. (z1 - z2) = ((cosh_C /. z1) * (cosh_C /. z2)) - ((sinh_C /. z1) * (sinh_C /. z2))
proof end;

theorem Th14: :: SIN_COS3:14
for z1, z2 being Element of COMPLEX holds cosh_C /. (z1 + z2) = ((cosh_C /. z1) * (cosh_C /. z2)) + ((sinh_C /. z1) * (sinh_C /. z2))
proof end;

theorem Th15: :: SIN_COS3:15
for z being complex number holds sin_C /. (<i> * z) = <i> * (sinh_C /. z)
proof end;

theorem Th16: :: SIN_COS3:16
for z being complex number holds cos_C /. (<i> * z) = cosh_C /. z
proof end;

theorem Th17: :: SIN_COS3:17
for z being complex number holds sinh_C /. (<i> * z) = <i> * (sin_C /. z)
proof end;

theorem Th18: :: SIN_COS3:18
for z being complex number holds cosh_C /. (<i> * z) = cos_C /. z
proof end;

Lm4: for x, y being Element of REAL holds exp (x + (y * <i>)) = (exp_R x) * ((cos y) + ((sin y) * <i>))
proof end;

theorem Th19: :: SIN_COS3:19
for x, y being Element of REAL holds exp (x + (y * <i>)) = ((exp_R . x) * (cos . y)) + (((exp_R . x) * (sin . y)) * <i>)
proof end;

theorem :: SIN_COS3:20
exp 0c = 1 by SIN_COS:54, SIN_COS:56;

theorem Th21: :: SIN_COS3:21
sin_C /. 0c = 0
proof end;

theorem :: SIN_COS3:22
sinh_C /. 0c = 0
proof end;

theorem Th23: :: SIN_COS3:23
cos_C /. 0c = 1
proof end;

theorem :: SIN_COS3:24
cosh_C /. 0c = 1
proof end;

theorem :: SIN_COS3:25
for z being Element of COMPLEX holds exp z = (cosh_C /. z) + (sinh_C /. z)
proof end;

theorem :: SIN_COS3:26
for z being Element of COMPLEX holds exp (- z) = (cosh_C /. z) - (sinh_C /. z)
proof end;

theorem :: SIN_COS3:27
for z being Element of COMPLEX holds exp (z + ((2 * PI) * <i>)) = exp z
proof end;

theorem Th28: :: SIN_COS3:28
for n being Element of NAT holds exp (((2 * PI) * n) * <i>) = 1
proof end;

theorem Th29: :: SIN_COS3:29
for n being Element of NAT holds exp ((- ((2 * PI) * n)) * <i>) = 1
proof end;

theorem :: SIN_COS3:30
for n being Element of NAT holds exp ((((2 * n) + 1) * PI) * <i>) = - 1
proof end;

theorem :: SIN_COS3:31
for n being Element of NAT holds exp ((- (((2 * n) + 1) * PI)) * <i>) = - 1
proof end;

theorem :: SIN_COS3:32
for n being Element of NAT holds exp ((((2 * n) + (1 / 2)) * PI) * <i>) = <i>
proof end;

theorem :: SIN_COS3:33
for n being Element of NAT holds exp ((- (((2 * n) + (1 / 2)) * PI)) * <i>) = - (1 * <i>)
proof end;

definition
let z be Element of COMPLEX ;
let c be complex number ;
:: original: +
redefine func z + c -> Element of COMPLEX ;
coherence
z + c is Element of COMPLEX
by XCMPLX_0:def 2;
end;

theorem :: SIN_COS3:34
for z being Element of COMPLEX
for n being Element of NAT holds sin_C /. (z + ((2 * n) * PI)) = sin_C /. z
proof end;

theorem :: SIN_COS3:35
for z being Element of COMPLEX
for n being Element of NAT holds cos_C /. (z + ((2 * n) * PI)) = cos_C /. z
proof end;

theorem Th36: :: SIN_COS3:36
for z being complex number holds exp (<i> * z) = (cos_C /. z) + (<i> * (sin_C /. z))
proof end;

theorem Th37: :: SIN_COS3:37
for z being complex number holds exp (- (<i> * z)) = (cos_C /. z) - (<i> * (sin_C /. z))
proof end;

theorem Th38: :: SIN_COS3:38
for x being Element of REAL holds sin_C /. x = sin . x
proof end;

theorem Th39: :: SIN_COS3:39
for x being Element of REAL holds cos_C /. x = cos . x
proof end;

theorem Th40: :: SIN_COS3:40
for x being Element of REAL holds sinh_C /. x = sinh . x
proof end;

theorem Th41: :: SIN_COS3:41
for x being Element of REAL holds cosh_C /. x = cosh . x
proof end;

theorem :: SIN_COS3:42
canceled;

theorem Th43: :: SIN_COS3:43
for x, y being Element of REAL holds sin_C /. (x + (y * <i>)) = ((sin . x) * (cosh . y)) + (((cos . x) * (sinh . y)) * <i>)
proof end;

theorem Th44: :: SIN_COS3:44
for x, y being Element of REAL holds sin_C /. (x + ((- y) * <i>)) = ((sin . x) * (cosh . y)) + ((- ((cos . x) * (sinh . y))) * <i>)
proof end;

theorem Th45: :: SIN_COS3:45
for x, y being Element of REAL holds cos_C /. (x + (y * <i>)) = ((cos . x) * (cosh . y)) + ((- ((sin . x) * (sinh . y))) * <i>)
proof end;

theorem Th46: :: SIN_COS3:46
for x, y being Element of REAL holds cos_C /. (x + ((- y) * <i>)) = ((cos . x) * (cosh . y)) + (((sin . x) * (sinh . y)) * <i>)
proof end;

theorem Th47: :: SIN_COS3:47
for x, y being Element of REAL holds sinh_C /. (x + (y * <i>)) = ((sinh . x) * (cos . y)) + (((cosh . x) * (sin . y)) * <i>)
proof end;

theorem Th48: :: SIN_COS3:48
for x, y being Element of REAL holds sinh_C /. (x + ((- y) * <i>)) = ((sinh . x) * (cos . y)) + ((- ((cosh . x) * (sin . y))) * <i>)
proof end;

theorem Th49: :: SIN_COS3:49
for x, y being Element of REAL holds cosh_C /. (x + (y * <i>)) = ((cosh . x) * (cos . y)) + (((sinh . x) * (sin . y)) * <i>)
proof end;

theorem Th50: :: SIN_COS3:50
for x, y being Element of REAL holds cosh_C /. (x + ((- y) * <i>)) = ((cosh . x) * (cos . y)) + ((- ((sinh . x) * (sin . y))) * <i>)
proof end;

theorem Th51: :: SIN_COS3:51
for n being Element of NAT
for z being Element of COMPLEX holds ((cos_C /. z) + (<i> * (sin_C /. z))) #N n = (cos_C /. (n * z)) + (<i> * (sin_C /. (n * z)))
proof end;

theorem Th52: :: SIN_COS3:52
for n being Element of NAT
for z being Element of COMPLEX holds ((cos_C /. z) - (<i> * (sin_C /. z))) #N n = (cos_C /. (n * z)) - (<i> * (sin_C /. (n * z)))
proof end;

theorem :: SIN_COS3:53
for n being Element of NAT
for z being Element of COMPLEX holds exp ((<i> * n) * z) = ((cos_C /. z) + (<i> * (sin_C /. z))) #N n
proof end;

theorem :: SIN_COS3:54
for n being Element of NAT
for z being Element of COMPLEX holds exp (- ((<i> * n) * z)) = ((cos_C /. z) - (<i> * (sin_C /. z))) #N n
proof end;

theorem :: SIN_COS3:55
for x, y being Element of REAL holds (((1 + ((- 1) * <i>)) / 2) * (sinh_C /. (x + (y * <i>)))) + (((1 + <i>) / 2) * (sinh_C /. (x + ((- y) * <i>)))) = ((sinh . x) * (cos . y)) + ((cosh . x) * (sin . y))
proof end;

theorem :: SIN_COS3:56
for x, y being Element of REAL holds (((1 + ((- 1) * <i>)) / 2) * (cosh_C /. (x + (y * <i>)))) + (((1 + <i>) / 2) * (cosh_C /. (x + ((- y) * <i>)))) = ((sinh . x) * (sin . y)) + ((cosh . x) * (cos . y))
proof end;

theorem :: SIN_COS3:57
for z being Element of COMPLEX holds (sinh_C /. z) * (sinh_C /. z) = ((cosh_C /. (2 * z)) - 1) / 2
proof end;

theorem Th58: :: SIN_COS3:58
for z being Element of COMPLEX holds (cosh_C /. z) * (cosh_C /. z) = ((cosh_C /. (2 * z)) + 1) / 2
proof end;

theorem Th59: :: SIN_COS3:59
for z being Element of COMPLEX holds
( sinh_C /. (2 * z) = (2 * (sinh_C /. z)) * (cosh_C /. z) & cosh_C /. (2 * z) = ((2 * (cosh_C /. z)) * (cosh_C /. z)) - 1 )
proof end;

theorem Th60: :: SIN_COS3:60
for z1, z2 being Element of COMPLEX holds
( ((sinh_C /. z1) * (sinh_C /. z1)) - ((sinh_C /. z2) * (sinh_C /. z2)) = (sinh_C /. (z1 + z2)) * (sinh_C /. (z1 - z2)) & ((cosh_C /. z1) * (cosh_C /. z1)) - ((cosh_C /. z2) * (cosh_C /. z2)) = (sinh_C /. (z1 + z2)) * (sinh_C /. (z1 - z2)) & ((sinh_C /. z1) * (sinh_C /. z1)) - ((sinh_C /. z2) * (sinh_C /. z2)) = ((cosh_C /. z1) * (cosh_C /. z1)) - ((cosh_C /. z2) * (cosh_C /. z2)) )
proof end;

theorem Th61: :: SIN_COS3:61
for z1, z2 being Element of COMPLEX holds
( (cosh_C /. (z1 + z2)) * (cosh_C /. (z1 - z2)) = ((sinh_C /. z1) * (sinh_C /. z1)) + ((cosh_C /. z2) * (cosh_C /. z2)) & (cosh_C /. (z1 + z2)) * (cosh_C /. (z1 - z2)) = ((cosh_C /. z1) * (cosh_C /. z1)) + ((sinh_C /. z2) * (sinh_C /. z2)) & ((sinh_C /. z1) * (sinh_C /. z1)) + ((cosh_C /. z2) * (cosh_C /. z2)) = ((cosh_C /. z1) * (cosh_C /. z1)) + ((sinh_C /. z2) * (sinh_C /. z2)) )
proof end;

theorem :: SIN_COS3:62
for z1, z2 being Element of COMPLEX holds
( (sinh_C /. (2 * z1)) + (sinh_C /. (2 * z2)) = (2 * (sinh_C /. (z1 + z2))) * (cosh_C /. (z1 - z2)) & (sinh_C /. (2 * z1)) - (sinh_C /. (2 * z2)) = (2 * (sinh_C /. (z1 - z2))) * (cosh_C /. (z1 + z2)) )
proof end;

Lm5: for z1 being Element of COMPLEX holds (sinh_C /. z1) * (sinh_C /. z1) = ((cosh_C /. z1) * (cosh_C /. z1)) - 1
proof end;

theorem :: SIN_COS3:63
for z1, z2 being Element of COMPLEX holds
( (cosh_C /. (2 * z1)) + (cosh_C /. (2 * z2)) = (2 * (cosh_C /. (z1 + z2))) * (cosh_C /. (z1 - z2)) & (cosh_C /. (2 * z1)) - (cosh_C /. (2 * z2)) = (2 * (sinh_C /. (z1 + z2))) * (sinh_C /. (z1 - z2)) )
proof end;