# Differentiability of convex functions except at countably many points

There is this result in Notions of Convexity, Hormander. The relevant part of it reads:

let $f$ be convex in an interval $I$ and $x$ be an interior point. Let $f_l'$ and $f_r'$ denote left derivative and right derivative respectively The following are equivalent:
(1) $f_l'$ is continuous at $x$;
(2) $f_r'$ is continuous at $x$;
(3) $f_r'(x) = f_l'(x)$, that is, $f$ is differentiable at $x$.
These conditions are fulfilled except at countably many points.

I understand the equivalence of these conditions. I don't understand the proof provided in the book for the last statement:

If $x_1<x_2$ are points in $I$, then $\sum\limits_{x_1<x<x_2}(f_r'(x)-f_l'(x))\leq f_l'(x_2)-f_r'(x_1)<\infty$

Can anyone explain what is happening here? Moreover, can we alternatively conclude by saying that $f_l'$ (or $f_r'$) is an increasing function and it has discontinuities only at countably many points ?

• Hint. (1) if $x_1<x<y<x_2$ then $f'_l(y)\ge f'_r(x)$. (2) If you take the sum of uncountably many positive numbers, then the sum is $\infty$. Indeed for some $n$ uncountably many numbers are greater that $\frac1n$. Yes, an increasing function (like $f'$) is discontinuous at most at countably many points. – Mirko Dec 12 '15 at 6:09
• We have the inequality $f_l'(x) \leq f_r'(x)$ at each $x$. So each term in the summation is a positive term. But how do we get the first inequality in the proof? – ChaPi Dec 12 '15 at 7:00
• what does the $\sum$ sign mean in this context? I assume that it is by definition the $\sup$ of all finite sums as $x$ ranges through (finitely many at a time) values between $x_1$ and $x_2$. Could you not prove the inequality for finite sums, and then deduce it for $\sup$ of these finite sums? – Mirko Dec 12 '15 at 13:19