
theorem
for f be PartFunc of REAL,REAL, x0 be Real st
 f is_Lcontinuous_in x0 & f is_Rcontinuous_in x0
 holds f is_continuous_in x0
proof
    let f be PartFunc of REAL,REAL, x0 be Real;
    assume that
A1:  f is_Lcontinuous_in x0 and
A2:  f is_Rcontinuous_in x0;

    for e be Real st 0<e ex d be Real st 0 < d &
     for x be Real st x in dom f & |. x-x0 .| < d holds |. f.x - f.x0 .| < e
    proof
     let e be Real;
     assume
A3:   0 < e;
     consider d1 be Real such that
A4:   0 < d1 &
      for x be Real st x in dom f & x0-d1 < x & x < x0 holds
      |. f.x - f.x0 .| < e by A3,A1,Th27;
     consider d2 be Real such that
A5:   0 < d2 &
      for x be Real st x in dom f & x0 < x & x < x0+d2 holds
      |. f.x - f.x0 .| < e by A3,A2,Th28;
     take d = min(d1,d2);
     thus 0 < d by A4,A5,XXREAL_0:21;
     thus for x be Real st x in dom f & |. x-x0 .| < d
      holds |. f.x - f.x0 .| < e
     proof
      let x be Real;
      assume that
A6:   x in dom f and
A7:   |. x-x0 .| < d;
A8:  -d < -|. x-x0 .| by A7,XREAL_1:24;
      -|. x-x0 .| <= x-x0 & x-x0 <= |. x-x0 .| by ABSVALUE:4; then
A9:  -d < x-x0 & x-x0 < d by A7,A8,XXREAL_0:2;
      per cases by XXREAL_0:1;
      suppose x = x0;
       hence |. f.x - f.x0 .| < e by A3,COMPLEX1:44;
      end;
      suppose
A10:   x < x0;
A11:   x0-d < x by A9,XREAL_1:20;
       x0-d1 <= x0-d by XXREAL_0:17,XREAL_1:10; then
       x0-d1 < x by A11,XXREAL_0:2;
       hence |. f.x - f.x0 .| < e by A4,A6,A10;
      end;
      suppose
A12:   x0 < x;
A13:   x < x0+d by A9,XREAL_1:19;
       x0+d <= x0+d2 by XXREAL_0:17,XREAL_1:6; then
       x < x0+d2 by A13,XXREAL_0:2;
       hence |. f.x - f.x0 .| < e by A5,A6,A12;
      end;
     end;
    end;
    hence f is_continuous_in x0 by FCONT_1:3;
end;
