This question already has an answer here:

Is there a function $f:\mathbb R\to\mathbb R$ such that $f(x+y)=f(x)+f(y)$ which is not continuous? I have proved that if it's continuous in one point $a\in\mathbb R$ then it's continuous on all $\mathbb R$, but I didn't find such a function which is not continuous everywhere. Therefore I tried to prove that all function of this form is continuous at $x=0$ but with no success. I think that if such a function exist it would be of the form $f(x)=...$ if $x\in\mathbb Q$ and $f(x)=...$ if $x\in\mathbb R\backslash\mathbb Q$ but I didn't find it.


marked as duplicate by Martin Sleziak, Asaf Karagila, TravisJ, user99914, muaddib Jul 21 '15 at 14:42

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.


The field $\mathbb{R}$ is a vector space over $\mathbb{Q}$. Let $\{e_\alpha\}_{\alpha \in I}$ be a basis (note that it's uncountable!).

Then any $x \in \mathbb{R}$ can be uniquely written $x = \sum a_\alpha e_\alpha$ where all but finitely many of the $a_\alpha$ are $0$. Pick your favorite index $\beta \in I$ and define $f(\sum a_\alpha e_\alpha) = a_\beta$.

Then $f$ is linear, but it can't be continuous because it's a non-constant function from $\mathbb{R}$ to $\mathbb{Q}$.

  • 3
    $\begingroup$ Probably worth noting that existence of Hamel basis depends on AC. $\endgroup$ – lisyarus Jul 21 '15 at 9:47

Yes, a discontinuous function satisfying this constraint exists.

For more, see here: Edwin Hewitt and Herbert S. Zuckerman: Remarks on the Functional Equation $f(x+y) = f(x)+f(y)$, Mathematics Magazine, Vol. 42, No. 3 (May, 1969), pp. 121-123 JSTOR, DOI: 10.2307/2689122


Not the answer you're looking for? Browse other questions tagged or ask your own question.