Functions that do not have an elementary antiderivative can be evaluated by generating a Taylor series, provided the function is infinitely differentiable and uniformly convergent in its domain. However, some functions do not have a simple general form for its Taylor series.
For example, take the following integral: $$ \int e^{cos(x)} dx $$
As the integral has no elementary antiderivative, we need to use a Taylor series to evaluate it.
The Maclaurin series for $ cos(x) $ is: $$ cos(x) = \sum_{n=0}^{\infty} \frac {(-1)^n x^{2n}} {(2n)!} $$
Since $ cos(0) = 1 $, we need to use the Taylor series of $ e^{x} $ centered at $ a = 1 $. $$ e^{x} = \sum_{n=0}^{\infty} \frac {e (x-1)^{n}} {n!} $$
Utilizing the property of substation in Taylor series, we can generate one for $ e^{cos(x)} $: $$ e^{cos(x)} = \sum_{n=0}^{\infty} \frac {e (cos(x)-1)^{n}} {n!} $$
Thus, the Taylor series of $ e^{cos(x)} $ is: $$ e^{cos(x)} = \sum_{n=0}^{\infty} \frac {e ((\sum_{n=0}^{\infty} \frac {(-1)^n x^{2n}} {(2n)!})-1)^{n}} {n!} $$
Clearly, this Taylor series is complex, with a series nested within in a series.
I am confused as to how to compute the following integral: $$ \int e^{cos(x)} dx = \int \sum_{n=0}^{\infty} \frac {e ((\sum_{n=0}^{\infty} \frac {(-1)^n x^{2n}} {(2n)!})-1)^{n}} {n!} dx $$
The series can be simplified as such: $$ \int e^{cos(x)} dx = \int \sum_{n=0}^{\infty} \frac {e} {n!} ((\sum_{n=0}^{\infty} \frac {(-1)^n x^{2n}} {(2n)!})-1)^{n} dx $$
$$ \int e^{cos(x)} dx = \sum_{n=0}^{\infty} \frac {e} {n!} \int (- \frac{x^{2}}{2!} + \frac{x^{4}}{4!} - \frac{x^{6}}{6!} + \: ...)^{n} dx $$
Although a Taylor series can be integrated term-by-term, how does one integrate an infinite sum raised to a power?
Is there a different approach to take, such as finding a general Maclaurin series for the function $ e^{cos(x)} $ by taking the derivatives and deciphering the pattern?
EDIT: I decided to approach the antiderivative in a different way. Since the Maclaurin series for $ e^{x} $ is: $$ e^{x} = \sum_{n=0}^{\infty} \frac {x^{n}} {n!} $$ The series for $ e^{cos(x)} $ can be expressed as: $$ e^{cos(x)} = \sum_{n=0}^{\infty} \frac {(cos(x))^{n}} {n!} $$ $$ e^{cos(x)} = \sum_{n=0}^{\infty} \frac {{cos}^{n}(x)} {n!} $$ Thus the antiderivative of $ e^{cos(x)} $ can be evaluated: $$ \int e^{cos(x)} dx = \sum_{n=0}^{\infty} \frac {1} {n!} \int {cos}^{n}(x) $$ We can apply the reduction formula for $ \int {cos}^{n}(x) dx $ : $$ \int e^{cos(x)} dx = \sum_{n=0}^{\infty} (\frac {1} {n!}) (\frac {1} {n} {cos}^{n-1}(x) sin(x) + \frac {n-1} {n} \int {cos}^{n-2}(x) dx) $$ Hence, the antiderivative of $ e^{cos(x)} $ is as follows: $$ \int e^{cos(x)} dx = \sum_{n=0}^{\infty} \frac {1} {n \cdot n!} {cos}^{n-1}(x) sin(x) + \frac {n-1} {n \cdot n!} \int {cos}^{n-2}(x) dx $$ The reduction formula is not valid for the initial term, so it must be evaluated separately. $$ \int e^{cos(x)} dx = \int {cos}^{0}(x) dx + \sum_{n=1}^{\infty} \frac {1} {n \cdot n!} {cos}^{n-1}(x) sin(x) + \frac {n-1} {n \cdot n!} \int {cos}^{n-2}(x) dx $$ $$ \int e^{cos(x)} dx = c + x + \sum_{n=1}^{\infty} \frac {1} {n \cdot n!} {cos}^{n-1}(x) sin(x) + \frac {n-1} {n \cdot n!} \int {cos}^{n-2}(x) dx $$
I still have run into a roadblock though. My answer is not a Taylor series, as it is written as a summation of a string of trigonometric terms. Thus, I do not know how to determine the interval of convergence.
If I evaluate the first few derivatives of $ e^{cos(x)} $ at the center point $ a=0 $, I can generate the following Maclaurin series: $$ e^{cos(x)} = e- \frac {e} {2} x^2 + \frac {e} {6} x^4 - \frac {31e} {720} x^6 + \ldots \: $$ Thus, the antiderivative of $ e^{cos(x)} $ can be expressed as an infinite sum: $$ \int e^{cos(x)} dx = c + ex - \frac {e} {6} x^3 + \frac {e} {30} x^5 - \frac {31e} {5040} x^7 + \ldots \: $$
Is there a general pattern to the following Maclaurin series?
If so, can a convergence test be applied to determine the interval of convergence?
If there series is not convergent across all real numbers, the Taylor series is not valid. When this is the case, are there other methods to evaluate antiderivatives that do not require generating a Taylor series?