What is \int_{-1}^{0}h(x)\,dx equal to ?

Consider the following for the next two (02) items that follow : Let f(x)=|x-1|, g(x)=[x] and h(x)=f(x)g(x) where [.] is greatest integer function.

  1. A. -\frac{3}{2}
  2. B. -1
  3. C. 0
  4. D. \frac{1}{2}

Correct Answer: A. -\frac{3}{2}

Explanation

In the interval [-1, 0), the greatest integer function [x] = -1, so g(x) = -1. Also, x-1 \lt 0, so f(x) = |x-1| = -(x-1) = 1-x. Thus, h(x) = (1-x)(-1) = x-1. Integrating h(x) from -1 to 0: \int_{-1}^{0}(x-1)\,dx = \left[\frac{x^2}{2} - x\right]_{-1}^{0} = 0 - \left(\frac{1}{2} - (-1)\right) = -\frac{3}{2}.

Related questions on Calculus

Practice more NDA Mathematics questions