let r be Real; :: thesis: for f being PartFunc of REAL ,REAL st right_open_halfline r c= dom f & f is_differentiable_on right_open_halfline r & ( for x0 being Real st x0 in right_open_halfline r holds
0 <= diff f,x0 ) holds
f | (right_open_halfline r) is non-decreasing

let f be PartFunc of REAL ,REAL ; :: thesis: ( right_open_halfline r c= dom f & f is_differentiable_on right_open_halfline r & ( for x0 being Real st x0 in right_open_halfline r holds
0 <= diff f,x0 ) implies f | (right_open_halfline r) is non-decreasing )

assume A1: right_open_halfline r c= dom f ; :: thesis: ( not f is_differentiable_on right_open_halfline r or ex x0 being Real st
( x0 in right_open_halfline r & not 0 <= diff f,x0 ) or f | (right_open_halfline r) is non-decreasing )

assume that
A2: f is_differentiable_on right_open_halfline r and
A3: for x0 being Real st x0 in right_open_halfline r holds
0 <= diff f,x0 ; :: thesis: f | (right_open_halfline r) is non-decreasing
now
let r1, r2 be Real; :: thesis: ( r1 in (right_open_halfline r) /\ (dom f) & r2 in (right_open_halfline r) /\ (dom f) & r1 < r2 implies f . r1 <= f . r2 )
assume that
A4: r1 in (right_open_halfline r) /\ (dom f) and
A5: r2 in (right_open_halfline r) /\ (dom f) and
A6: r1 < r2 ; :: thesis: f . r1 <= f . r2
set rr = max r1,r2;
A7: r2 + 0 < (max r1,r2) + 1 by XREAL_1:10, XXREAL_0:25;
r2 in right_open_halfline r by A5, XBOOLE_0:def 4;
then r2 in { p where p is Real : r < p } by XXREAL_1:230;
then ex g2 being Real st
( g2 = r2 & r < g2 ) ;
then r2 in { g2 where g2 is Real : ( r < g2 & g2 < (max r1,r2) + 1 ) } by A7;
then A8: r2 in ].r,((max r1,r2) + 1).[ by RCOMP_1:def 2;
r2 in dom f by A5, XBOOLE_0:def 4;
then A9: r2 in ].r,((max r1,r2) + 1).[ /\ (dom f) by A8, XBOOLE_0:def 4;
A10: f is_differentiable_on ].r,((max r1,r2) + 1).[ by A2, FDIFF_1:34, XXREAL_1:247;
A11: ].r,((max r1,r2) + 1).[ c= right_open_halfline r by XXREAL_1:247;
then for g1 being Real st g1 in ].r,((max r1,r2) + 1).[ holds
0 <= diff f,g1 by A3;
then A12: f | ].r,((max r1,r2) + 1).[ is non-decreasing by A1, A11, A10, ROLLE:11, XBOOLE_1:1;
A13: r1 + 0 < (max r1,r2) + 1 by XREAL_1:10, XXREAL_0:25;
r1 in right_open_halfline r by A4, XBOOLE_0:def 4;
then r1 in { g where g is Real : r < g } by XXREAL_1:230;
then ex g1 being Real st
( g1 = r1 & r < g1 ) ;
then r1 in { g1 where g1 is Real : ( r < g1 & g1 < (max r1,r2) + 1 ) } by A13;
then A14: r1 in ].r,((max r1,r2) + 1).[ by RCOMP_1:def 2;
r1 in dom f by A4, XBOOLE_0:def 4;
then r1 in ].r,((max r1,r2) + 1).[ /\ (dom f) by A14, XBOOLE_0:def 4;
hence f . r1 <= f . r2 by A6, A12, A9, RFUNCT_2:45; :: thesis: verum
end;
hence f | (right_open_halfline r) is non-decreasing by RFUNCT_2:45; :: thesis: verum