Calculating $\int_{0}^{1} \frac{x^{d-1}}{x^p (x+1)^p \log^{p}(1 + \frac{1}{x})} \mathrm{d}x$ arising from Sobolev Spaces theory I'm having trouble integrating the following (or at least showing the integral is finite):
$$  of$$
The full context of this comes from Evan's PDEs book, chapter 5, problem 13 (or so). It says show that $$ u(\vec{x}) := \log\left(\log\left(1+\frac{1}{|\vec{x}|}\right)\right) \in W^{1,p}(B^{d}_1(\vec{0})),  $$
where $B^d_1(\vec{0}) \subset \mathbb{R}^d $ is the unit ball.
I was able to reduce it to the above integral by use of polar coordinates. I know that there is a math stack exchange link on this problem already, but note that answer assumes that $p = d$. Any and all help is much appreciated.
 A: Ok here's what I got. Let's clear up the relationship between $n \text{ and } d$. .
If $n < d$ then by Holder's inequality $$ ||u||_{W^{1,n}(\mathbb{R}^d)} \leq C(d,p)||u||_{W^{1,d}(\mathbb{R}^d)} $$
which reduces to the case $n = d$.
If $ n > d$ then we may apply Morrey's Inequality to show that $u \notin W^{1,n}$ here. Let's look - $$ ||u||_{C^{0,\gamma}(\mathbb{R}^d)} \leq C||u||_{W^{1,n}(\mathbb{R}^d)}. $$
Recall that $$ ||u||_{C^{0,\gamma}} := ||u||_{C(B_1(0))} + [u]_{C^{0,\gamma}(B_1(0))} $$ where $$ ||u||_C := \sup_{x \in B_1(0)} |u(x)| \text{ and } [u]_{C^{0,\gamma}(B_1(0))} := \sup_{x,y} \left( \frac{|u(x)-u(y)}{|x-y|^{\gamma}}\right). $$
Clearly $$ ||u|| = +\infty $$ as $u$ is unbounded for any $\vec{x} $ near $\vec{0} \in \mathbb{R}^d$.
If $n = d$, then we get to compute some integrals. First write $$ u_{x_i} = \frac{-x_i}{\log\left(1+\frac{1}{|\vec{x}|}\right)\left(1 + \frac{1}{|\vec{x}|}\right)|\vec{x}|^3}, $$
then $$ |Du| = \frac{1}{\log\left(1+\frac{1}{|\vec{x}|}\right)\left(1 + \frac{1}{|\vec{x}|}\right)|\vec{x}|^2} = \frac{|\vec{x}|}{\log\left(1+\frac{1}{|\vec{x}|}\right)(|\vec{x}|+1)|\vec{x}|^2}. $$
Hence $$ \int_{B_1(0)} |Du|^n \mathrm{d}x = \int_{B_1(0)}\frac{1}{\log^n\left(1+\frac{1}{|\vec{x}|}\right)(|\vec{x}|+1)^n|\vec{x}|^{n}}, $$
switching to polar coordinates,  $$ \int_{B_1(0)} |Du|^n \mathrm{d}x = C \frac{\pi^{n/2}}{\Gamma(n/2)} \int_{0}^{1} \frac{r^{n-1}}{r^n(r+1)^n \log^n\left(1 + \frac{1}{r}\right)} = A \int_{0}^{1} \frac{1}{r(r+1)^n \log^n\left(1 + \frac{1}{r}\right)}   $$
$$ \leq A \int_{0}^{1} \frac{1}{r\log^n\left(1+\frac{1}{r}\right)}.$$
The last inequality follows from the fact that $1 < (r+1)^n \Rightarrow \frac{1}{(r+1)^n} < 1.$ The next trick is by realizing that the functions $\frac{1}{r} \text{ and } 1 + \frac{1}{r}$ are asymptotically the same as r goes to zero. Hence their logarithms are asymptotically equivalent, hence their logarithms raised to the nth power are asymptotically equivalent. Away from zero, we have
$$ A \int_{r \geq \frac{\delta}{2}} \frac{1}{r \log^{n}\left(1 + \frac{1}{r}\right)} < + \infty  $$
So for $r$ sufficiently close to zero we may replace $$ \log^n\left( 1 + \frac{1}{r}\right) \text{ with } \log^n\left(\frac{1}{r}\right). $$ This completes the analysis - $$ (-1)^n \int_{r < \delta} \frac{ \mathrm{d}(\log(r))}{\log^n(r)}. $$
If $ n > 1 $ then this integrates to $$(-1)^n \frac{1}{\log^{n-1}(\delta)}. $$
If $ n = 1$, then this integral diverges -
$$ - \int_{0}^{1} \frac{1}{r \log(r)} = -\log(\log(r)) |_{0} ^{ 1},$$
which is undefined.
