User:Egm4313.s12.team11.sheider/R5.8: Lecture 8 p.8-16

Problem Statement
Find the integral

$$ \int x^n log(1+x)dx \!$$ for $$ n=0 \!$$ and $$ n=1 \!$$

Using integration by parts, and then with the help of of

General Binomial Theorem

$$ (x+y)^n = \sum^n_{k=0} \binom{n}{k} x^{n-k} y^k \!$$

Solution
For $$ n=0 \!$$:

$$ \int x^0 log(1+x)dx = \int log(1+x)dx \!$$

For substitution by parts, $$ u = log(1+x), du=\frac{1}{1+x}, dv=dx, v=x \!$$

$$\int log(1+x)dx = x log(1+x) - \int \frac{x}{1+x}dx \!$$

$$ \int log(1+x)dx = x log(1+x) - \int (1 - \frac{1}{1+x})dx \!$$

$$ \int log(1+x)dx = x log(1+x) - x + log(1+x) + C\!$$

Therefore:

$$ \int log(1+x)dx = (x+1) log(1+x) - x + C \!$$ Using the General Binomial Theorem:

$$ (x+y)^0 = \sum^0_{k=0} \binom{0}{k} x^{0-k} y^k = 1 \!$$

Therefore: $$ \int (1) log(1+x)dx = \int log(1+x)dx \!$$

Which we have previously found that answer as:

$$ \int log(1+x)dx = (x+1) log(1+x) - x + C \!$$

For $$ n=1 \!$$:

$$ \int x^1 log(1+x)dx = \int x log(1+x)dx \!$$

Initially we use the following substitutions: $$ t = 1+x, x = t-1, dt = dx \!$$

$$\int x log(1+x)dx = \int (t-1) log(t)dt = \int (t log(t) - \log(t))dt \!$$

First let us consider the first term: $$ \int t log(t) dt \!$$

Next, we use the integration by parts: $$ u = \log {t}, du = \frac{1}{t} dt, dv = t dt, v = \frac{1}{2}t^2 \!$$

$$ \int t log(t) dt = \frac{1}{2}t^2 log(t) - \int \frac{1}{2} t^2 (\frac{1}{t} dt) \!$$

$$ \int t log(t) dt = \frac{1}{2}t^2 log(t) - \int \frac{1}{2} t dt) \!$$

$$ \int t log(t) dt = \frac{1}{2}t^2 log(t) - \frac{1}{4} t^2 \!$$

Next let us consider the second term: $$ \int log(t) dt \!$$

Again, we will use integration by parts: $$ u = \log {t}, du = \frac{1}{t} dt, dv = dt, v = t \!$$

$$ \int t log(t) dt = t log(t) - \int t (\frac{1}{t} dt) \!$$

$$ \int t log(t) dt = t log(t) - \int dt \!$$

$$ \int t log(t) dt = t log(t) - t \!$$

Therefore:

$$ \int (t log(t) - \log(t))dt = \frac{1}{2}t^2 log(t) - \frac{1}{4} t^2 - (t log(t) - t) \!$$

$$ \int (t log(t) - \log(t))dt = \frac{1}{2}t^2 log(t) - \frac{1}{4} t^2 - t log(t) + t \!$$

Re-substituting for t:

$$ \int x log(1+x)dx = \frac{1}{2}(1+x)^2 log(1+x) - \frac{1}{4} (1+x)^2 - (1+x) log(1+x) + (1+x) + C\!$$

$$ \int x log(1+x)dx = (1+x)( \frac{1}{2}(1+x) log(1+x) - \frac{1}{4} (1+x)- log(1+x) + 1 ) + C\!$$

$$ \int x log(1+x)dx = (1+x)( \frac{1}{2} x log(1+x) - \frac{1}{2} log(1+x) - \frac{1}{4} x + \frac{3}{4}) + C\!$$

Therefore:

$$ \int x log(1+x)dx = (1+x)(\frac{1}{2} x log(1+x) - \frac{1}{2} log(1+x) - \frac{1}{4} x + \frac{3}{4} ) + C\!$$

Using the General Binomial Theorem for the integral with t substitution $$ \int (t-1) log(t)dt \!$$:

$$ (x+y)^1 = (t+(-1))^1 = (t+(-1)) = \sum^1_{k=0} \binom{1}{k} x^{1-k} y^k = \sum^1_{k=0} \binom{1}{k} t^{1-k} (-1)^k = t-1 \!$$

Therefore: $$ \int (t-1) log(t)dt = \int x log(1+x)dx \!$$

Which we have previously found that answer as:

$$ \int x log(1+x)dx = (1+x)(\frac{1}{2} x log(1+x) - \frac{1}{2} log(1+x) - \frac{1}{4} x + \frac{3}{4} ) + C\!$$