I wish to find the Maclaurin-series for the function $$L(x) = \int_0^x \cos(t^2)\space dt$$
Alternative 1
Set $f(t) = \cos(t)$. We have that $f'(t) = -\sin(t)$, $f''(t) = -\cos(t)$ and $f^{(3)}(t) = \sin(t)$. Setting $t = 0$, we find that the pattern $1, 0, -1, 0$ repeats itself indefinitely. The Maclaurin-series for $\cos(t)$ is therefore $P(t) = 1 - t^2/2! + t^4/4! ...$, and $P(t^2) = 1 - t^4/2! + t^8/4!...$
Therefore we have $$L(x) = \int_0^t (1 - t^4/2! + t^8/4!...)\space dt = x - x^5/(5\cdot2!) + x^9/(9\cdot4!)... = \sum_{n=0}^{\infty}(-1)^n\frac{x^{4n+1}}{(4n+1)(2n)!}$$
The answer above is correct. I dislike solving tasks that way unless I absolutely have to, and I attempted the following (more tiresome) method several times until I gave up on it and used the simplification above:
Alternative 2
Set $f(t) = \cos(t^2)$. Computing the first few derivatives, we have that
$f'(t) = -2t\sin(t^2)$
$f''(t) = -2\sin(t^2) -4t^2\cos(t^2) = -2(\sin(t^2)+2t^2\cos(t^2))$
$f^{(3)}(t) = -2(2t\cos(t^2)+4t\cos(t^2)-4t^3\sin(t^2)) = 8t^3\sin(t^2)-12t\cos(t^2)$
It follows that $f^{4}(0) = -12$. So we have a starting pattern like $1, 0, 0, 0, -12, 0 , 0, 0, C$
It looks rather hopeless, but I am unable to see how this can simply be used to find the representation. Should I acccept that the first alternative is superior, or is there a simple method I am missing in Alternative 2?
$\endgroup$ 2 Reset to default