A function which is R-integrable but does not have an antiderivative How is it possible that this function: $$ 
    f(x)=\left\{\begin{array}{ll} 0, & -1\le x < 0 \\
         1, & 0\le x \le 1\end{array}\right. 
$$
is R-integrable in $[-1,1]$ , but does not have an antiderivative there? 
From the mean value theorem for derivatives, it can not be that the derivative has a jump at 0 , so it can not have a antiderivative?
 A: One way to see that $f$ doesn't have an antiderivative, is to use Darboux's theorem which states that every derivative has the intermediate value property, even if it (the derivative) is not continuous.
A: A function does not have to be differentiable in order to be Riemann integrable.
Recall one more time Lebesgue's criterion for Riemann integrability from my previous answer: a function $f: [a, b] \longrightarrow \Bbb R$ is Riemann integrable if and only if it is bounded and continuous almost everywhere on $[a,b]$.
In the present case, $|f(x)| \leq 1$ on $[-1, 1]$. Furthermore, it is continuous everywhere except at the point $x = 0$, and the set $\{0\}$ has Lebesgue measure zero. Hence $f$ is continuous almost everywhere on $[-1,1]$.
It follows that $f$ is Riemann integrable on $[-1,1]$, and of course its integral is $1$ (the area under the graph of $f$).
A: Perhaps say it this way:  If
$$
F(x) := \int_{-1}^x f(t) dt
$$
then we may say $F$ is an indefinite integral of $f$.  Certainly $F$ exists.  But $F$ fails to be differentiable at the point $x=0$.  One of the proofs of the Fundamental Theorem of Caluculs will, indeed, show that $F'(x) = f(x)$ at every point where $f$ is continuous.  But $x=0$ escapes from that criterion.
