Consider the following sequence of functions and their integrals on $[0,1]$. Evaluate the limit of the following integral if possible
$$\lim_{k \to \infty} \int_{0}^{1} \frac{kx^k}{1+x} dx$$
At first glance, I do not know if the limit exists or not. Wolfram alpha will not take the limit for me, but it did evaluate the integral. The result is terms of a function I do not understand, but from looking at the series expansion:
$$x^k \left(\frac{kx}{k+1} - \frac{kx^2}{k+2} + \frac{kx^3}{k+3} - \dots\right)$$ it appears as though the limit is $0$ since $x \in [0,1]$. However, I have attempted the problem two different ways, and I am getting that the result is infinity. I am curious where I maybe going wrong.
Note: I am not looking for an answer. I just want to see where my logic is wrong (mainly in my 2nd attempt) so that I can try to make the correction.
Attempt 1: I can pull the $k$ outside the integral and get
$$\lim_{k \to \infty} k \int_{0}^{1} \frac{x^k}{1 + x} dx$$.
Now, $|\frac{x^k}{1+x}| \leq \frac{1}{1+x} = g(x)$ since we are on $[0,1]$. Since $g(x)$ is integrable, and dominates $f(x)$, the dominated convergence theorem tells me I can pass the limit inside.
$$\int_{0}^{1} \lim_{k \to \infty} \frac{kx^k}{1+x} dx = \infty $$ due to the factor of $k$.
Now, outside of the fact that I have not done measure theory for quite some time, I am uncertain about this for two reasons. One, DCT refers to Lebesgue integrable functions. I am always hesitant when I use it during a discussion of Riemann integration. Secondly, while I am definitely allowed to pull the $k$ outside of the integral, I am not sure I am allowed to apply DCT on the result without $k$, and then put the $k$ back inside along with the limit. If I had to dominate $\frac{kx^k}{1 + x}$, I am not sure it would work. These uncertainties made me want to try to brute force this with Riemann integration.
Attempt 2:
I will rewrite the integral as
$$\lim_{k \to \infty} k \int_{0}^{1} \frac{x^k}{(\sqrt{1 + x})^2}dx$$ so that I can apply Trigonometric substitution. I would get
$\sec(\theta) = \sqrt{1 + x}$
$\tan(\theta) = \sqrt{x}$
$\tan^2(\theta) = x$
$2\tan(\theta)\sec^2(\theta)d\theta = dx$
Substituting,
$$\lim_{k \to \infty} k \int \frac{\tan^{2k}(\theta)}{\sec^2(\theta)} 2 \tan(\theta) \sec^2(\theta) d\theta$$
Cleaning this up,
$$\lim_{k \to \infty} 2k \int \tan^{2k+1}(\theta) d\theta$$
Now, I can pull out 2 of the tangents.
$$\lim_{k \to \infty} 2k \int \tan^{2k - 1}(\theta) \tan^2(\theta)d\theta$$
Using the identity $\tan^2(\theta) = \sec^2(\theta) - 1$,
$$\lim_{k \to \infty} 2k \int \tan^{2k-1}(\theta) \sec^2(\theta) d\theta - \lim_{k \to \infty} 2k \int \tan^{2k-1}(\theta) d\theta$$
The first integral can be done with $u$-substitution. Let $u = \tan(\theta)$. Then, $du = \sec^2(\theta) d\theta$
$$\lim_{k \to \infty} 2k \left[\frac{u^{2k}}{2k}\right] - \lim_{k \to \infty} 2k \int \tan^{2k-1}(\theta) d\theta$$
Now, I can back substitute.
$$\lim_{k \to \infty} 2k \left[\frac{\tan^{2k}(\theta)}{2k}\right] - \lim_{k \to \infty} 2k \int \tan^{2k-1}(\theta) d\theta$$
Again,
$$\lim_{k \to \infty} 2k \left[\frac{x^k}{2k}\right]_{0}^{1} - \lim_{k \to \infty} 2k \int \tan^{2k-1}(\theta) d\theta$$
Evaluating,
$$\lim_{k \to \infty} 2k \frac{1}{2k} - \lim_{k \to \infty} 2k \int \tan^{2k-1}(\theta) d\theta$$
At this point, I can say the first limit is $1$. Now, I still have an odd power of tangent in the second integral. So, I can repeat this process again
$$1 - \lim_{k \to \infty} 2k \int \tan^{2k - 3}(\theta) \sec^2(\theta) d\theta + \lim_{k \to \infty} 2k \int \tan^{2k - 3}(\theta) d\theta$$
Then,
$$1 - \lim_{k \to \infty} 2k \left[\frac{u^{2k-2}}{2k-2}\right] + \lim_{k \to \infty} \int \tan^{2k - 3}(\theta)$$
Again,
$$1 - \lim_{k \to \infty} 2k \left[\frac{\tan^{2k-2}(\theta)}{2k-2}\right] + \lim_{k \to \infty} \int \tan^{2k - 3}(\theta)$$
Then,
$$1 - \lim_{k \to \infty} 2k \left[\frac{x^{k-1}}{2k-2}\right]_{0}^{1} + \lim_{k \to \infty} \int \tan^{2k - 3}(\theta)$$
Evaluating,
$$1 - \lim_{k \to \infty} 2k \frac{1}{2k-2} + \lim_{k \to \infty} \int \tan^{2k-3}(\theta) d\theta$$
Then, this limit is also $1$
$$1 - 1 + \lim_{k \to \infty} 2k \int \tan^{2k-3}(\theta) d\theta)$$
So,
$$\int \tan^{2k-3}(\theta) d\theta)$$
Well, this is very nice. I have ended up with a single integral with an odd power of tangent. So, I can repeat these two steps over and over until I am left with.
$$\lim_{k \to \infty} 2k \int \tan(\theta) d\theta$$
after going through all of the powers. Well, this integral I know
$$\lim_{k \to \infty} 2k \left[- \ln|\cos(\theta)| \right]$$
Going back to our trig sub, we can see that
$$\cos(\theta) = \frac{1}{\sqrt{1 + x}}$$. Therefore,
$$\lim_{k \to \infty} 2k \left[ -\ln|\frac{1}{\sqrt{1+x}}|\right]_{0}^{1}$$
Evaluating,
$$\lim_{k \to \infty} -2k\ln|\frac{1}{\sqrt{2}}| = \infty$$
This matched the result I got before, and I will much better about this because I just used straight up integration rather than a sophisticated tool that I don't know very well, the dominated convergence theorem.
My uncertainty lies in that the answer does not appear to be $\infty$ based on the power series wolfram alpha gave. Does anyone see where I am going wrong?
You miss the factor $k$, if you want to use dominated convergence theorem, you have to show $|\frac{kx^k}{1+x}| \leq g(x)$ on $[0,1]$, where $g(x)$ is independent of $k$.
$$I_k=\int_{0}^{1} \frac{kx^k}{1+x} dx=\frac{k}{k+1}\int_{0}^{1} \frac{1}{1+x} dx^{k+1}=\frac{1}{2}\cdot\frac{k}{k+1}+\frac{k}{k+1}\int_{0}^{1} \frac{x^{k+1}}{(1+x)^2} dx$$
$$\lim_{k\to\infty}I_k=\frac{1}2+\lim_{k\to\infty}\int_0^1\frac{x^{k+1}}{(1+x)^2} dx$$
Since $$\frac{x^{k+1}}{(1+x)^2} \le\frac{1}{(1+x)^2}~~~\text{for}~~x\in[0,1]$$ and $\frac{1}{(1+x)^2}$ is integrable on $[0,1]$. So by dominated convergence theorem, we can interchange the limit and integration. Namely,
$$\lim_{k\to\infty}I_k=\frac{1}2+\int_0^1\lim_{k\to\infty}\frac{x^{k+1}}{(1+x)^2} dx=\frac{1}2$$