Evaluating the integral $\int_{0}^{1}\frac{x^n}{1 + x^n}\,\mathrm dx$. For each positive integer $n$, let $f_{n}$ be the function defined on the interval [0,1] by $$f_{n}(x) = \frac{x^n}{1 + x^n},$$ I want to find $$\int_{0}^{1}f_{n}(x)\,\mathrm dx,$$ I thought that I could add and subtract $1$ to the numerator, but then how can I integrate $\frac{1}{1 + x^n}$?, any help would be appreciated.  

As noted, it suffices to evaluate the definite integral
$$I_n=\int_0^1 \frac1{x^n+1}dx$$
Note that $x^n+1= \prod_{k=1}^n(x-x_k)$ with $x_k= e^{i\frac{(2k-1)\pi}n}$ and $$\frac1{x^n+1}=-\frac1n \sum_{k=1}^n\frac{x_k}{x-x_k}$$
Then
\begin{align}
I_n & = -\frac1n \sum_{k=1}^n\int_0^1 \frac{x_k}{x-x_k} dx
=  -\frac1n \sum_{k=1}^nx_k\ln(1-x_k^{-1})\\
 &= -\frac1n \sum_{k=1}^n x_k \left[i \frac{n-2k+1}{2n}+ \ln \left(2 \sin\frac{(2k-1)\pi}{2n}\right) \right]
\end{align}
Apply $\sum_{k=1}^nx^k=0$ along with the symmetry of $x^k$ to obtain
$$\int_0^1 \frac1{x^n+1}dx = \frac2n \sum_{k=1}^{[\frac n2]} ( \theta_k \sin2\theta_k + \cos2\theta_k \ln \cos\theta_k)$$
where $\theta_k= \frac{n-2k+1}{2n} $. The close-form
holds for any $n\ge2$ and produces
\begin{align}
& \int_0^1 \frac1{x^2+1} dx= \frac\pi4\\
 & \int_0^1 \frac1{x^3+1} dx= \frac\pi{3\sqrt3}+\frac13\ln2\\
 & \int_0^1 \frac1{x^4+1} dx= \frac\pi{4\sqrt2}+\frac1{2\sqrt2}\ln(1+\sqrt2)\\
 & \int_0^1 \frac1{x^5+1} dx= \frac\pi{5\sqrt2}\sqrt{1+\frac1{\sqrt5}}+\frac1{\sqrt5}\ln\frac{1+\sqrt5}2 +\frac15\ln2\\
 & \int_0^1 \frac1{x^6+1} dx= \frac\pi6 +\frac1{2\sqrt3}\ln(2+\sqrt3) \\
& \hspace{1cm}...
\end{align}
