Find $\int_1^{\frac{5}{2}}\frac{|x|}{[2x-5]}dx$ Find $\int_1^{\frac{5}{2}}\frac{|x|}{[2x-5]}dx$, where $[x]$ is the greatest integer function.
First, $|x|=x$ in the interval $[1,5/2]$. Next we divide subintervals, so that 
for $[1,3/2), [2x-5]=-3$, $[3/2,2), [2x-5]=-2,$ and for $[2,5/2) [2x-5]=-1$.
Hence $$\int_1^{\frac{5}{2}}\frac{|x|}{[2x-5]}dx=-\frac{1}{3}\int_1^{3/2}xdx-\frac{1}{2}\int_{3/2}^2xdx-\int_2^{5/2}xdx\\
=-\frac{1}{3}\cdot\frac{1}{2}(9/4-1)-\frac{1}{2}\cdot\frac{1}{2}(4-9/4)-\frac{1}{2}(25/4-4)=-85/48$$
However, the answer to this problem says it should be $-157/48$. I don't understand what's wrong with my solution. I would appreciate it if anyone can help me out.
 A: Your answer is correct.
Another way to perform the calculation is to first observe as you did that $|x| = x$ for $x > 0$.  Then the function $$f(x) = \frac{|x|}{\lfloor 2x-5 \rfloor} = \begin{cases} -x/3, & 1 \le x < 3/2 \\ -x/2, & 3/2 \le x < 2 \\ -x, & 2 \le x < 5/2 \end{cases}$$ on the interval of interest, and more generally, for each $k \in \mathbb Z$, $$f(x) = \begin{cases} -x/k, & \left(\frac{k+5}{2} \le x < \frac{k+6}{2}\right) \cap (k \le -6) \\ x/k & \left(\frac{k+5}{2} \le x < \frac{k+6}{2}\right) \cap (k \ge -5, k \ne 0) \\ \text{undefined} & 5/2 \le x < 3.  \end{cases}$$ demonstrates that the integral is the sum of three trapezoidal areas, each with equal heights $$h = 5/2 - 2 = 2 - 3/2 = 3/2 - 1 = 1/2.$$  Therefore, the area is expressed as sum of the mean base length times the height of each trapezoid, or even more simply, the total mean base lengths times the height:  $$\int_{x=1}^{5/2} f(x) \, dx = \frac{1}{2}\left(f(5/4) + f(7/4) + f(9/4)\right) = -\frac{1}{2}\left(\frac{5}{12} + \frac{7}{8} + \frac{9}{4} \right) = -\frac{85}{48}.$$
