let a, b be Real; :: thesis: for Z being open Subset of REAL
for f being PartFunc of REAL ,REAL st Z c= dom (cosec * f) & ( for x being Real st x in Z holds
f . x = (a * x) + b ) holds
( cosec * f is_differentiable_on Z & ( for x being Real st x in Z holds
((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 )) ) )

let Z be open Subset of REAL ; :: thesis: for f being PartFunc of REAL ,REAL st Z c= dom (cosec * f) & ( for x being Real st x in Z holds
f . x = (a * x) + b ) holds
( cosec * f is_differentiable_on Z & ( for x being Real st x in Z holds
((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 )) ) )

let f be PartFunc of REAL ,REAL ; :: thesis: ( Z c= dom (cosec * f) & ( for x being Real st x in Z holds
f . x = (a * x) + b ) implies ( cosec * f is_differentiable_on Z & ( for x being Real st x in Z holds
((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 )) ) ) )

assume that
A1: Z c= dom (cosec * f) and
A2: for x being Real st x in Z holds
f . x = (a * x) + b ; :: thesis: ( cosec * f is_differentiable_on Z & ( for x being Real st x in Z holds
((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 )) ) )

dom (cosec * f) c= dom f by RELAT_1:44;
then A3: Z c= dom f by A1, XBOOLE_1:1;
then A4: f is_differentiable_on Z by A2, FDIFF_1:31;
A5: for x being Real st x in Z holds
sin . (f . x) <> 0
proof
let x be Real; :: thesis: ( x in Z implies sin . (f . x) <> 0 )
assume x in Z ; :: thesis: sin . (f . x) <> 0
then f . x in dom cosec by A1, FUNCT_1:21;
hence sin . (f . x) <> 0 by RFUNCT_1:13; :: thesis: verum
end;
A6: for x being Real st x in Z holds
cosec * f is_differentiable_in x
proof end;
then A9: cosec * f is_differentiable_on Z by A1, FDIFF_1:16;
for x being Real st x in Z holds
((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 ))
proof
let x be Real; :: thesis: ( x in Z implies ((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 )) )
assume A10: x in Z ; :: thesis: ((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 ))
then A11: f is_differentiable_in x by A4, FDIFF_1:16;
A12: sin . (f . x) <> 0 by A5, A10;
then cosec is_differentiable_in f . x by Th2;
then diff (cosec * f),x = (diff cosec ,(f . x)) * (diff f,x) by A11, FDIFF_2:13
.= (- ((cos . (f . x)) / ((sin . (f . x)) ^2 ))) * (diff f,x) by A12, Th2
.= (diff f,x) * (- ((cos . (f . x)) / ((sin . ((a * x) + b)) ^2 ))) by A2, A10
.= ((f `| Z) . x) * (- ((cos . (f . x)) / ((sin . ((a * x) + b)) ^2 ))) by A4, A10, FDIFF_1:def 8
.= a * (- ((cos . (f . x)) / ((sin . ((a * x) + b)) ^2 ))) by A2, A3, A10, FDIFF_1:31
.= a * (- ((cos . ((a * x) + b)) / ((sin . ((a * x) + b)) ^2 ))) by A2, A10 ;
hence ((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 )) by A9, A10, FDIFF_1:def 8; :: thesis: verum
end;
hence ( cosec * f is_differentiable_on Z & ( for x being Real st x in Z holds
((cosec * f) `| Z) . x = - ((a * (cos . ((a * x) + b))) / ((sin . ((a * x) + b)) ^2 )) ) ) by A1, A6, FDIFF_1:16; :: thesis: verum