let Z be open Subset of REAL ; :: thesis: ( Z c= dom (tan - cot ) implies ( tan - cot is_differentiable_on Z & ( for x being Real st x in Z holds
((tan - cot ) `| Z) . x = (1 / ((cos . x) ^2 )) + (1 / ((sin . x) ^2 )) ) ) )

assume A1: Z c= dom (tan - cot ) ; :: thesis: ( tan - cot is_differentiable_on Z & ( for x being Real st x in Z holds
((tan - cot ) `| Z) . x = (1 / ((cos . x) ^2 )) + (1 / ((sin . x) ^2 )) ) )

then Z c= (dom tan ) /\ (dom cot ) by VALUED_1:12;
then A2: ( Z c= dom tan & Z c= dom cot ) by XBOOLE_1:18;
for x being Real st x in Z holds
cot is_differentiable_in x
proof end;
then A3: cot is_differentiable_on Z by A2, FDIFF_1:16;
for x being Real st x in Z holds
tan is_differentiable_in x
proof end;
then A4: tan is_differentiable_on Z by A2, FDIFF_1:16;
for x being Real st x in Z holds
((tan - cot ) `| Z) . x = (1 / ((cos . x) ^2 )) + (1 / ((sin . x) ^2 ))
proof
let x be Real; :: thesis: ( x in Z implies ((tan - cot ) `| Z) . x = (1 / ((cos . x) ^2 )) + (1 / ((sin . x) ^2 )) )
assume A5: x in Z ; :: thesis: ((tan - cot ) `| Z) . x = (1 / ((cos . x) ^2 )) + (1 / ((sin . x) ^2 ))
then A6: ( sin . x <> 0 & cos . x <> 0 ) by A2, FDIFF_8:1, FDIFF_8:2;
((tan - cot ) `| Z) . x = (diff tan ,x) - (diff cot ,x) by A1, A3, A4, A5, FDIFF_1:27
.= (1 / ((cos . x) ^2 )) - (diff cot ,x) by A6, FDIFF_7:46
.= (1 / ((cos . x) ^2 )) - (- (1 / ((sin . x) ^2 ))) by A6, FDIFF_7:47
.= (1 / ((cos . x) ^2 )) + (1 / ((sin . x) ^2 )) ;
hence ((tan - cot ) `| Z) . x = (1 / ((cos . x) ^2 )) + (1 / ((sin . x) ^2 )) ; :: thesis: verum
end;
hence ( tan - cot is_differentiable_on Z & ( for x being Real st x in Z holds
((tan - cot ) `| Z) . x = (1 / ((cos . x) ^2 )) + (1 / ((sin . x) ^2 )) ) ) by A1, A3, A4, FDIFF_1:27; :: thesis: verum