- #1
Mayhem
- 307
- 196
I was bored and tried to integrate ## x^n e^{xn} ##. I seem to be on the right track, but ultimately it is not entirely correct. Here is my work:
Given is the integral
$$I = \int x^ne^{nx}dx$$
where ##n \geq 1##
We substitute ##t = nx## which gives us ## \frac{dt}{dx} = n \Rightarrow dx = \frac{1}{n}dt## and ##x = \frac{t}{n}##
Plugging that in, we obtain
$$ I = \int \left(\frac{t}{n}\right)^ne^t \frac{1}{n}dt $$
which can be reduced to
$$ I = \frac{1}{n^{n+1}} \int t^ne^t dt $$
The expression inside of the integral can be integrated by parts if we simply integrate ##n## times, letting ##dv = e^t## every single time, the degree of the t-polynomial will decrease to zero and cancel out to 1.
We may do this for the first few steps to obtain a pattern:
$$I =\frac{1}{n^{n+1}} \left( e^tt^n - \int nt^{n-1}e^t dt \right ) $$
$$=\frac{1}{n^{n+1}} \left( e^tt^n - \left (nt^{n-1}e^t - \int n(n-1)t^{n-2}e^t dt \right ) \right) $$
$$=\frac{1}{n^{n+1}} \left( e^tt^n - \left (nt^{n-1}e^t - \left ( n(n-1)t^{n-2}e^t - \int n(n-1)(n-2)t^{n-3}e^t dt \right) \right) \right)$$
Recalling that ## \int udv = uv - \int vdu##, we may create a general expression for ##n## terms. Generating the sum, it should be fairly obvious that
$$I = \frac{1}{n^{n+1}}\left(\sum_{m = 0}^{n} \frac{(-1)^mn!}{(n-m)!}t^{n-m}e^t - \int e^t dt \right)$$
Imagine that we have ##n!t^0 e^t## inside of the integral. We may factor out ##n!## and ##t^0 = 1##.
We evaluate the integral, and then factor out ##e^t##
$$ I = \frac{e^t}{n^{n+1}}\left(\sum_{m = 0}^{n} \frac{(-1)^mn!}{(n-m)!}t^{n-m} - 1 \right) + C$$
And we substitute ##t=nx## back in
$$ I = \frac{e^{nx}}{n^{n+1}}\left(\sum_{m = 0}^{n} \frac{(-1)^mn!}{(n-m)!}(nx)^{n-m} - 1 \right) + C$$
Where did I go wrong? It seems to particularly be the ##\frac{1}{n^{n+1}}## factor that messes up results. I tried manually evaluating for n = 1, 2, 3, 4 and compared to calculators.
Given is the integral
$$I = \int x^ne^{nx}dx$$
where ##n \geq 1##
We substitute ##t = nx## which gives us ## \frac{dt}{dx} = n \Rightarrow dx = \frac{1}{n}dt## and ##x = \frac{t}{n}##
Plugging that in, we obtain
$$ I = \int \left(\frac{t}{n}\right)^ne^t \frac{1}{n}dt $$
which can be reduced to
$$ I = \frac{1}{n^{n+1}} \int t^ne^t dt $$
The expression inside of the integral can be integrated by parts if we simply integrate ##n## times, letting ##dv = e^t## every single time, the degree of the t-polynomial will decrease to zero and cancel out to 1.
We may do this for the first few steps to obtain a pattern:
$$I =\frac{1}{n^{n+1}} \left( e^tt^n - \int nt^{n-1}e^t dt \right ) $$
$$=\frac{1}{n^{n+1}} \left( e^tt^n - \left (nt^{n-1}e^t - \int n(n-1)t^{n-2}e^t dt \right ) \right) $$
$$=\frac{1}{n^{n+1}} \left( e^tt^n - \left (nt^{n-1}e^t - \left ( n(n-1)t^{n-2}e^t - \int n(n-1)(n-2)t^{n-3}e^t dt \right) \right) \right)$$
Recalling that ## \int udv = uv - \int vdu##, we may create a general expression for ##n## terms. Generating the sum, it should be fairly obvious that
$$I = \frac{1}{n^{n+1}}\left(\sum_{m = 0}^{n} \frac{(-1)^mn!}{(n-m)!}t^{n-m}e^t - \int e^t dt \right)$$
Imagine that we have ##n!t^0 e^t## inside of the integral. We may factor out ##n!## and ##t^0 = 1##.
We evaluate the integral, and then factor out ##e^t##
$$ I = \frac{e^t}{n^{n+1}}\left(\sum_{m = 0}^{n} \frac{(-1)^mn!}{(n-m)!}t^{n-m} - 1 \right) + C$$
And we substitute ##t=nx## back in
$$ I = \frac{e^{nx}}{n^{n+1}}\left(\sum_{m = 0}^{n} \frac{(-1)^mn!}{(n-m)!}(nx)^{n-m} - 1 \right) + C$$
Where did I go wrong? It seems to particularly be the ##\frac{1}{n^{n+1}}## factor that messes up results. I tried manually evaluating for n = 1, 2, 3, 4 and compared to calculators.