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

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

then A2: Z c= dom (- (cot (#) sec)) by VALUED_1:8;
A3: cot (#) sec is_differentiable_on Z by A1, FDIFF_9:43;
then A4: (- 1) (#) (cot (#) sec) is_differentiable_on Z by A2, FDIFF_1:20;
for x being Real st x in Z holds
((- (cot (#) sec)) `| Z) . x = ((1 / ((sin . x) ^2)) / (cos . x)) - (((cot . x) * (sin . x)) / ((cos . x) ^2))
proof
let x be Real; :: thesis: ( x in Z implies ((- (cot (#) sec)) `| Z) . x = ((1 / ((sin . x) ^2)) / (cos . x)) - (((cot . x) * (sin . x)) / ((cos . x) ^2)) )
assume A5: x in Z ; :: thesis: ((- (cot (#) sec)) `| Z) . x = ((1 / ((sin . x) ^2)) / (cos . x)) - (((cot . x) * (sin . x)) / ((cos . x) ^2))
((- (cot (#) sec)) `| Z) . x = ((- 1) (#) ((cot (#) sec) `| Z)) . x by A3, FDIFF_2:19
.= (- 1) * (((cot (#) sec) `| Z) . x) by VALUED_1:6
.= (- 1) * ((- ((1 / ((sin . x) ^2)) / (cos . x))) + (((cot . x) * (sin . x)) / ((cos . x) ^2))) by A1, A5, FDIFF_9:43
.= ((1 / ((sin . x) ^2)) / (cos . x)) - (((cot . x) * (sin . x)) / ((cos . x) ^2)) ;
hence ((- (cot (#) sec)) `| Z) . x = ((1 / ((sin . x) ^2)) / (cos . x)) - (((cot . x) * (sin . x)) / ((cos . x) ^2)) ; :: thesis: verum
end;
hence ( - (cot (#) sec) is_differentiable_on Z & ( for x being Real st x in Z holds
((- (cot (#) sec)) `| Z) . x = ((1 / ((sin . x) ^2)) / (cos . x)) - (((cot . x) * (sin . x)) / ((cos . x) ^2)) ) ) by A4; :: thesis: verum