TITLE: Find all continuous functions satisfying $\int_0^x f = e^x$
QUESTION [5 upvotes]: From Spivak 

Find all continuous functions satisfying 

$\int_0^x f = e^x$
$\int_0^{x^2}f = 1-e^{2x^2}$


(They are two separate problems, not conditions to be satisfied simultaneously.) I wanted to make sure my thinking is right, because for the first one I get that there are no such functions. If there were, it would have to be such that $f(x) = e^x$ (by differentiation), but $e^x$ does not satisfy that condition.
For the second, by differentiating, I get that $f(x^2)\cdot 2x = -4xe^{2x^2}$, which for $x\neq 0$ implies that $f(x^2) = -2e^{2x^2}$, or $f: x \mapsto -2e^{2x}$ for $x>0$. The function can do anything it wants on $x<0$, so long as it stays continuous.
Any criticisms of this analysis?

REPLY [12 votes]: Looks fine to me. An easier way to proceed for the first problem, however, is to note that
$$1 = e^0 = \int_0^0 f(x) dx = 0$$
is a contradiction.