Taylor polynomial for an integral This is the first time encountering a Taylor expansion along with an integral, so I am wondering how I should proceed.
Question:
$Consider \space the \space function$
$$F(x) = \int_0^{x^2}e^{-{\sqrt{t}}} \space dt$$
$for \space any \space real \space number \space x. $
$Find \space the \space Taylor \space polynomial \space p_2(x) \space for \space the \space function \space F(x) \space centered \space at \space a=0.$
Should I first integrate the function itself and find the Taylor expansion of the result, or attempt to find the Taylor expansion with the integral attached?
Thank you for any help! 
 A: $F(x)=\int_0^{x^2} e^{-\sqrt{t}} dt$

METHOD $1$
$\begin{align}
F'(x)&=2xe^{-x}\\
&=2x\sum_{n=0}^{\infty} \frac{(-1)^nx^n}{n!}\\
&=2\sum_{n=0}^{\infty} \frac{(-1)^nx^{n+1}}{n!}
\end{align}$
Integrating term by term and using $F(0)=0$ we have 
$$\begin{align}
F(x)&=2\sum_{n=0}^{\infty} \frac{(-1)^nx^{n+2}}{(n+2)n!}\\
&=2\sum_{n=0}^{\infty} \frac{(-1)^n(n+1)x^{n+2}}{(n+2)!}\\
&=2\sum_{n=2}^{\infty} \frac{(-1)^n(n-1)x^{n}}{n!}\\
\end{align}$$

METHOD $2$
Find $F(x)$ by evaluating its integral form and develop the power series for $F(x)$ directly.
First substitute $y^2=t$ so that $2ydy=dt$ and the new limits of integration on $y$ extend from $0$ to $x$.  Thus, 
$$\begin{align}
F(x)&=\int_0^{x^2} e^{-\sqrt{t}} dt\\
&=2\int_0^{x} ye^{-y} dy\\
&=2-2(x+1)e^{-x}
\end{align}$$
where we used integration by parts to arrive at the last expression.
Thus, 
$$\begin{align}
F(x)&=2-2(x+1)e^{-x}\\
&=2-2(1+x)\sum_{n=0}^{\infty} \frac{(-1)^nx^n}{n!}\\
&=-2\sum_{n=1}^{\infty} \frac{(-1)^nx^n}{n!}-2\sum_{n=0}^{\infty} \frac{(-1)^nx^{n+1}}{n!}\\
&=-2\sum_{n=1}^{\infty} \frac{(-1)^nx^n}{n!}+2\sum_{n=1}^{\infty} \frac{(-1)^nx^{n}}{(n-1)!}\\
&=2\sum_{n=2}^{\infty} \frac{(-1)^n(n-1)x^{n}}{n!}
\end{align}$$
which agrees with the result using Method 1.

METHOD $3$
Develop the power series for $e^{-\sqrt{t}}$ and integrate term by term.
$$\begin{align}
F(x)&=\int_0^{x^2} e^{-\sqrt{t}} \\
&=\int_0^{x^2} \sum_{n=0}^{\infty} \frac{(-1)^nt^{n/2}}{n!}dt \\
&=2\sum_{n=0}^{\infty}\frac{(-1)^nx^{n+2}}{(n+2)n!}\\
&=2\sum_{n=2}^{\infty}\frac{(-1)^n(n-1)x^{n}}{n!}\\
\end{align}$$
which agrees with the results using Methods 1 and 2!
