TITLE: Derivative of a bounded Integral?
QUESTION [7 upvotes]: Just revising for my advanced calculus exam and came across this question:

Consider the function $f(x)$ defined by the integral equation:
  $$
f(x) = x^2 + \int_0^x(x − t)f(t) dt.
$$
  Derive an $ODE$ and boundary conditions for $f(x)$, and solve this
  to determine $f(x)$.

I would assume you take the derivative of both sides to get:
$$
f'(x) = 2x + {d \over dx}{\int_0^x(x − t)f(t) dt}.
$$
But where do I go from here? My first guess is:
$$
f'(x) = 2x + (x-x)f(x) - x.f(0).
$$
$$
f'(x) = 2x  - x.f(0).
$$
Surely that's wrong? What am I missing?

REPLY [3 votes]: Note
$$ f(x) = x^2 + \int_0^x(x − t)f(t) dt=f(x) = x^2 + x\int_0^x f(t)dt-\int_0^x tf(t) dt.
$$
So $f(0)=0$. Taking derivative gives
$$　f'(x) = ２x + \int_0^x f(t)dt+xf(x)- xf(x)=2x+\int_0^xf(t)dt
$$
and hence $f'(0)=0$.
Taking derivative again gives
$$　f''(x) = 2+f(x). $$
So $f(x)$ satisfies the following 2nd order DE
$$ y''-y=2,y(0)=y'(0)=0 $$
whose solution is
$$ y=e^x+e^{-x}-2. $$