# (Just for clarification) - Is a convex, piecewise continuous function f on an closed interval continuous?

Lets say f is defined on an Interval $I = [a,b]$. Since f is convex, one immediately knows that f is continuous on $I^°$ , however left are the points $a$ and $b$

The piecewise continuity of f states, that f is continuous on certain open intervals and that the one sided limit of the endpoints of those interval exist.(but don't have to be the same!)

In an exercise it was postulated, that f is then also continuous at the endpoints a,b of f.

However I don't see, how this holds, if just the limits of the endpoints exist due piecewise continuous.

I think, there is an error in the definition of piecewise continuous, as long as one doesn't know that the one sided limits of f'(a), f'(b) exist, f(a) and f(b) should not have to be necessarily continuous. I am a bit unsure about this and would like to have a 2th opinion..

• If a function is $0$ on $a$ and $b$ and $1$ on $(a,b)$, is it considered piecewise continuous? It kind of depends on the definition! The definition I know, is that the set of discontinuity points is finite. – Zardo Jul 20 '15 at 9:36
• @Zardo your function is concave :D – user251257 Jul 20 '15 at 9:46
• @user251257 Well, it doesn't really change much! Is it considered piecewise continuous though? – Zardo Jul 20 '15 at 9:47
• @Zardo I would. – user251257 Jul 20 '15 at 9:49

The function $f$ need not be continuous at $a$ and $b$. Consider the example $$f(x):=x^2\quad(-1<x<1),\qquad f(\pm1):=2\ .$$ This $f$ is convex on $[{-1},1]$. It should however, not be too difficult to prove that the limits $\lim_{x\to a+}f(x)$ and $\lim_{x\to b-}f(x)$ exist and are finite if $f$ is defined on all of $[a,b]$.
• yeah, but I am not sure if $f$ is piecewise continuous then, for example $f'(+1), f'(-1)$ don't exist. (Interestingly I used the same example for myself to see that convex functions don't necessarily have to be convex at the end points!) – Imago Jul 20 '15 at 9:59