How to prove $f(x)=ax$ if $f(x+y)=f(x)+f(y)$ and $f$ is locally integrable Suppose $f$ is integrable on any bounded interval in $\mathbb R$, and it satisfies the equation $f(x+y)=f(x)+f(y)$ for all $x,y\in\mathbb R$. How to prove that there exists a constant $a\in\mathbb R$ such that $f(x)=ax$ for all $x\in\mathbb R$?
 A: $ \def \R {\mathbb R}
\def \d {\ \mathrm d} $
Define $ g : \R \to \R $ with
$$ g ( x ) = \int _ 0 ^ x f ( t ) \, \d t $$
for all $ x \in \R $, which can be done, since $ f $ is locally integrable. For any $ x , y \in \R $, it's easy to see that
$$ g ( x + y ) = \int _ 0 ^ { x + y } f ( t ) \d t = \int _ 0 ^ x f ( t ) \d t + \int _ x ^ { x + y } f ( t ) \d t = g ( x ) + \int _ 0 ^ y f ( x + t ) \d t \\
= g ( x ) + \int _ 0 ^ y \big( f ( x ) + f ( t ) \big) \d t = g ( x ) + \int _ 0 ^ y f ( t ) \d t + \int _ 0 ^ y f ( x ) \d t = g ( x ) + g ( y ) + y f ( x ) \text . $$
Thus
$$ y f ( x ) = g ( x + y ) - g ( x ) - g ( y ) = g ( y + x ) - g ( y ) - g ( x ) = x f ( y ) $$
for all $ x , y \in \R $. Letting $ a = f ( 1 ) $ and putting $ y = 1 $ in the last equation, we have
$$ f ( x ) = a x $$
for all $ x \in \R $.
This method has the advantage of being concise and at the same time, only focuses on the condition mentioned in the problem, without reducing the problem to another case when we have additional conditions (like continuity) on $ f $. The method used here and the one in this post are essentially the same, when looking through the lens of the fundamental theorem of calculus. Here, we used integration, and avoided differentiation which is the main tool there.
A: This is known as Cauchy's functional equation. It is easy to see that $f(0)=0$, as $f(x)=f(x+0)=f(x)+f(0)$ for all $x$. If we let $a=f(1)$, we get that $f(n)=f(\underbrace{1+1+\dots+1}_{n\text{ times}})=an$ for any $n\in\mathbb Z$ by induction, and similarly we see that
$$bf\left(\frac n b\right)=\underbrace{f\left(\frac n b\right)+\dots+f\left(\frac n b\right)}_{b\text{ times}}=f\Big(\underbrace{\frac n b+\dots+\frac n b}_{b\text{ times}}\Big)=f(n)=an$$
so $f(x)=ax$ for any rational $x$. To extend this to all real $x$ under your restrictions, I suggest you look at other solutions than $ax$ and examine how they differ near $0$, then observe that these solutions also get scaled by addition and so blow up to be very different from $ax$ away from the origin. I will let you work this part out on your own.
A: Integrate the functional equation with respect to $x$ between $0$ and $1$. The result is the equation
$$
\int_y^{y+1} f(u) du = \int_0^1 f(x) dx + f(y) \text .
$$
The integral on the left side exists and is continuous in $y$ because $f$ is locally integrable. Therefore the right side is also continuous in $y$; that is, $f$ is continuous! The rest is clear sailing.
