I have this specific problem : find the integral $$\int_{-1}^3 \frac{|x|}{|x-1|+1}dx \\$$
So my first thought was to find when $|x|$ is $x \gt 0$ and $x \lt 0$ and when $x-1 \gt 0$ and $x-1 \lt 0$.It gave me back $x$ when $x \gt 0$ and $-x$ at $x \lt 0$ and the same time $x-1$ for $x \gt 1$ and $-(x-1)$ for $x \lt 1$. Then I should break up the interval and at what number $0$ or $1$, how I procced after that?
It is natural to split the integral at both $x=0$ and $x=1$, as you have pointed out. So consider the subintervals $[-1,0]$, $[0,1]$, and $[1,3]$ separately. Thus the integral equals
$$\int_{-1}^0\frac{-x}{2-x}\ dx+\int_0^1 \frac{x}{2-x}\ dx+\int_1^31\ dx$$