TITLE: Are there functions which are neither convex nor concave everywhere but are continuous?
QUESTION [5 upvotes]: By convex/cave I mean by the definition for an interval $(x,y)$ of $f$ is convex iff $f(\frac{a+b}{2})\geq\frac{f(a)+f(b)}{2}$ and is concave if $f(\frac{a+b}{2})\leq\frac{f(a)+f(b)}{2}$ where $a,b\in(x,y)$. This is merely so that the function does not have to be differentiable. 
If it's not possible to have a function be continuous but not convex or concave on any nonempty interval, is it possible to construct a function which is not convex or concave on any nonempty interval? Has one already been created?
If it is possible to have a function be continuous but not convex or concave on any nonempty interval, is it possible to construct it? Has one already been created?
Is it possible to have one of these functions be differentiable once?

REPLY [12 votes]: It is well known that almost every path of a Brownian motion is nowhere monotone (i.e., not monotone on any interval). Hence the primitive (antiderivative) of almost every path is continuously differentiable but nowhere convex or concave.