Estimating integral $\int_0^{0.5} \ln(1+\frac{x^2}{4})$

146 Views Asked by At

Estimate the definite integral $\int_0^{0.5} \ln(1+\frac{x^2}{4})$ with an error of at most $10^{-4}$, using the Alternating Series Estimation Theorem.

My approach is as follows:

  1. I found the power series representation for $\ln(1+\frac{x^2}{4})$. It appears that $$\ln\bigg(1+\frac{x^2}{4}\bigg) = \sum_{n=0}^\infty \frac{(-1)^n}{n+1} \bigg(\frac{x}{2}\bigg)^{2n+2}$$
  2. Then I find the power-series representation for the indefinite integral $\int\ln(1+\frac{x^2}{4})$ $$\int\ln\bigg(1+\frac{x^2}{4}\bigg)dx = \int\bigg[\sum_{n=0}^\infty \frac{(-1)^n}{n+1} \bigg(\frac{x}{2}\bigg)^{2n+2}\bigg]dx$$ $$\int\ln\bigg(1+\frac{x^2}{4}\bigg)dx = \int\bigg(\frac{x^2}{4}-\frac{x^4}{32}+\frac{x^6}{192} + ...\bigg)dx$$ $$\int\ln\bigg(1+\frac{x^2}{4}\bigg)dx = \bigg(\frac{x^3}{3\cdot4}-\frac{x^4}{5\cdot32}+\frac{x^6}{7\cdot192} + ...\bigg)+C$$ $$\int\ln\bigg(1+\frac{x^2}{4}\bigg)dx = \sum_{n=1}^\infty \frac{(-1)^{n+1}\cdot x^{2n+1}}{(2n+1)(n \cdot 2^n)} +C$$
  3. I find an expression for $\int_0^{0.5} \ln(1+\frac{x^2}{4})$ in terms of power series. $$\int_0^{0.5}\ln\bigg(1+\frac{x^2}{4}\bigg)dx = \sum_{n=1}^\infty \frac{(-1)^{n+1}\cdot x^{2n+1}}{(2n+1)(n \cdot 2^n)} +C \ \bigg ]_0^{0.5}$$ $$\int_0^{0.5}\ln\bigg(1+\frac{x^2}{4}\bigg)dx = \sum_{n=1}^\infty \frac{(-1)^{n+1}\cdot {0.5}^{2n+1}}{(2n+1)(n \cdot 2^n)}$$ $$\int_0^{0.5}\ln\bigg(1+\frac{x^2}{4}\bigg)dx = \sum_{n=1}^\infty \frac{(-1)^{n+1}}{n(2n+1)( 2^{3n+1})}$$
  4. Apply the Alternating Series Test. Suppose $b_n = \frac{1}{n(2n+1)( 2^{3n+1})}$. It turns out that it satisfies the two conditions of the AST, that is $b_{n+1} \leq b_{n}$ and $\lim_{n \to \infty}b_n = 0$. This implies that the infinite sum $\sum_{n=1}^\infty \frac{(-1)^{n+1}}{n(2n+1)( 2^{3n+1})}$ converges.
  5. Define $S_n = \sum_{i=1}^n \frac{(-1)^{i+1}}{i(2i+1)( 2^{3i+1})}$. I want to determine the smallest integer n such that the partial sum $S_n$ is guaranteed to approximate $\sum_{n=1}^\infty \frac{(-1)^{n+1}}{n(2n+1)( 2^{3n+1})}$ with an error of at most $0.0001$. Now apply the Alternating Series Estimation Theorem, $|S - S_n| \leq b_{n+1} \leq 0.0001$. $$ \implies \frac{1}{(n+1)(2n+3)\cdot 2^{3n+4}} \leq 0.0001$$ $$ \implies (n+1)(2n+3)\cdot 2^{3n+4} \geq 10 000 \implies n \geq 1.71926$$
  6. We conclude that $n=2$ would guarantee an accuracy within $0.0001$.
  7. Now compute $$S_2 = \sum_{i=1}^2 \frac{(-1)^{i+1}}{i(2i+1)( 2^{3i+1})} \approx 0.0201$$

This suggests that $\int_0^{0.5} \ln(1+\frac{x^2}{4}) \approx 0.0201$. However, when I tried to compute the actual value of $\int_0^{0.5} \ln(1+\frac{x^2}{4})$, it gives me $\approx 0.010$. I am wondering what I did wrong in this problem. Any help would be highly appreciated.

2

There are 2 best solutions below

1
On BEST ANSWER

The first term of the expansion seems to be $$\dfrac{x^3}{3\cdot 4}.$$ But in your summation, you write $$ \sum_{n=1}^\infty \frac{(-1)^{n+1}\cdot x^{2n+1}}{(2n+1)(n \cdot 2^n)},$$ which has as first term (when $n = 1$) $$ \frac{x^3}{3\cdot1\cdot 2}.$$ So it seems like your error is in passing from the expansion to the $n$th term in the expansion.

0
On

If you start with $$\log(1+y)=\sum_{n=1}^{\infty}\frac{(-1)^{n+1}}{n}y^n$$ and replace $y$ by $\frac{x^2}{4}$, you then have $$\log(1+\frac{x^2}{4})=\sum_{n=1}^{\infty}\frac{(-1)^{n+1}}{n~4^n}x^{2n}$$ So, integrating gives $$\int\log(1+\frac{x^2}{4})=\sum_{n=1}^{\infty}\frac{(-1)^{n+1}}{(2n+1)~n~4^n}x^{2n+1}$$ Using the given bounds $$\int_0^{1/2}\log(1+\frac{x^2}{4})=\sum_{n=1}^{\infty}(-1)^{n+1}\frac{2^{-4 n-1}}{n (2 n+1)}$$ Now, you can notice that $$\frac{2^{-4 n-1}}{n (2 n+1)} \lt \frac{2^{-4 n-2}}{n^2}$$ and you can search for $n$ such that $$\frac{2^{-4 n-2}}{n^2} \lt \epsilon$$ The solution of this last equation is given by $$n \gt \frac{W\left(\frac{\log (2)}{\sqrt{\epsilon }}\right)}{2 \log (2)}$$ where appears Lambert function.

A good approximation of this function is given by $$W(a)=L_1-L_2+\frac{L_2}{L_1}$$ where $L_1=\log(a)$ and $L_2=\log(L_1)$. Applying this to the case where $\epsilon=10^{-4}$ leads to $n=2.26153$. So, three terms seem to be required and lead to a value equal to $$\frac{8797}{860160}\approx 0.0102272$$ for an exact value close to $0.0102270$.