reserve h for non-zero 0-convergent Real_Sequence;
reserve c for constant Real_Sequence;

theorem
for f be PartFunc of REAL,REAL, Z be open Subset of REAL,
 I be non empty Interval st I c= Z & inf I < sup I &
 f is_differentiable_on Z holds f is_differentiable_on_interval I
proof
    let f be PartFunc of REAL,REAL, Z be open Subset of REAL,
    I be non empty Interval;
    assume that
A1:  I c= Z and
A2:  inf I < sup I and
A3:  f is_differentiable_on Z;
    Z c= dom f by A3; then
A4: I c= dom f by A1;
    for x be Real st x in I holds
     (x = inf I implies f|I is_right_differentiable_in x) &
     (x = sup I implies f|I is_left_differentiable_in x) &
     (x in ].inf I,sup I.[ implies f is_differentiable_in x)
    proof
     let x be Real;
     assume
A5:  x in I; then
     f is_differentiable_in x by A1,A3,FDIFF_1:9; then
A6:  f is_right_differentiable_in x & f is_left_differentiable_in x
       by FDIFF_3:22;
     hence x = inf I implies f|I is_right_differentiable_in x
      by A5,A2,Th4;
     thus x = sup I implies f|I is_left_differentiable_in x
       by A5,A6,A2,Th5;
     assume x in ].inf I,sup I.[;
     thus f is_differentiable_in x by A5,A1,A3,FDIFF_1:9;
    end;
    hence f is_differentiable_on_interval I by A4,Th11;
end;
