let a be Real; :: thesis: for Z being open Subset of REAL
for f1, f2 being PartFunc of REAL,REAL st Z c= dom (f1 - f2) & ( for x being Real st x in Z holds
f1 . x = a ^2 ) & f2 = #Z 2 holds
( f1 - f2 is_differentiable_on Z & ( for x being Real st x in Z holds
((f1 - f2) `| Z) . x = - (2 * x) ) )

let Z be open Subset of REAL; :: thesis: for f1, f2 being PartFunc of REAL,REAL st Z c= dom (f1 - f2) & ( for x being Real st x in Z holds
f1 . x = a ^2 ) & f2 = #Z 2 holds
( f1 - f2 is_differentiable_on Z & ( for x being Real st x in Z holds
((f1 - f2) `| Z) . x = - (2 * x) ) )

let f1, f2 be PartFunc of REAL,REAL; :: thesis: ( Z c= dom (f1 - f2) & ( for x being Real st x in Z holds
f1 . x = a ^2 ) & f2 = #Z 2 implies ( f1 - f2 is_differentiable_on Z & ( for x being Real st x in Z holds
((f1 - f2) `| Z) . x = - (2 * x) ) ) )

assume that
A1: Z c= dom (f1 - f2) and
A2: for x being Real st x in Z holds
f1 . x = a ^2 and
A3: f2 = #Z 2 ; :: thesis: ( f1 - f2 is_differentiable_on Z & ( for x being Real st x in Z holds
((f1 - f2) `| Z) . x = - (2 * x) ) )

A4: for x being Real st x in Z holds
f1 . x = (a ^2) + (0 * x) by A2;
for x being Real st x in Z holds
((f1 - f2) `| Z) . x = - (2 * x)
proof
let x be Real; :: thesis: ( x in Z implies ((f1 - f2) `| Z) . x = - (2 * x) )
assume x in Z ; :: thesis: ((f1 - f2) `| Z) . x = - (2 * x)
hence ((f1 - f2) `| Z) . x = 0 + ((2 * (- 1)) * x) by A1, A3, A4, FDIFF_4:12
.= - (2 * x) ;
:: thesis: verum
end;
hence ( f1 - f2 is_differentiable_on Z & ( for x being Real st x in Z holds
((f1 - f2) `| Z) . x = - (2 * x) ) ) by A1, A3, A4, FDIFF_4:12; :: thesis: verum