5
$\begingroup$

I have to evaluate $$\int _0^2\:\frac{x-\left[x\right]}{2x-\left[x\right]+1}dx$$

Where $[x] = floor(x)$

I tend to write it like this, but I think i'm missing the point $x = 2$

$$\int _0^2\:\frac{x-\left[x\right]}{2x-\left[x\right]+1}dx=\int _0^1\:\frac{x}{2x+1}dx+\int _1^2\:\frac{x-1}{2x}dx = 1 - \frac{1}{4} \cdot \ln 3$$

The correct answer is $1 - \frac{1}{4} \cdot \ln 12$

  • 2
    Well, you made an error on one of those integrals...2017-02-22
  • 2
    Your breakdown of the original integral into the two integrals is correct, but your evaluation of the two integrals isn't: http://www.wolframalpha.com/input/?i=integral+of+(x-1)%2F(2x)+from+1+to+2%2Bintegral+of+x%2F(2x%2B1)+from+0+to+12017-02-22
  • 0
    Oh, I actually did... sorry, didn't see that.2017-02-22

1 Answers 1

3

That's correct, the value at the extremes of the interval is irrelevant, as long as the function can be extended by continuity at the end points. There would be more relaxed conditions, but in this case this is enough.

However $$ \int_0^1\frac{x}{2x+1}\,dx=\frac{1}{2}\int_0^1\frac{2x+1-1}{2x+1}\,dx =\frac{1}{2}\Bigl[x-\frac{1}{2}\ln(2x+1)\Bigr]_0^1= \frac{1}{2}\left(1-\frac{1}{2}\ln 3\right) $$ and $$ \int_1^2\frac{x-1}{2x}\,dx= \frac{1}{2}\int_1^2\left(1-\frac{1}{x}\right)dx= \frac{1}{2}\Bigl[x-\ln x\Bigr]_1^2=\frac{1}{2}(2-\ln2-1) $$ so your integral is $$ \frac{1}{2}-\frac{1}{4}\ln3+\frac{1}{2}-\frac{1}{2}\ln2=1-\frac{1}{4}\ln12 $$