Find the continuous function defined over $[0,1]$ such that $$\int_0^1 x^kf(x){\rm d}x=a^k,$$ where $k=0,1,2.$
My Thought
Indeed, the conditions imply that $$\int_0^1f(x)=1,~~~\int_0^1 xf(x){\rm d}x=a,~~~\int_0^1 x^2f(x){\rm d}x=a^2.$$ Thus, it's easy to obtain that $$\begin{align*}\int_0^1(1-x)^2f(x){\rm d}x&=\int_0^1(1-2x+x^2)f(x){\rm d}x\\&=\int_0^1f(x){\rm d}x-2\int_0^1xf(x){\rm d}x+\int_0^1 x^2f(x){\rm d}x\\&=1-2a+a^2\\&=(1-a)^2\end{align*}.$$ But how to go on with this? I'm stuck here. Please offer some help. Thanks.
There are infinitely many functions with this property. If you are trying to find one such function take $f(x)$ to be a polynomial of degree 2 and solve for the coefficients from the given conditions.