Problem statement

a) Suppose f(x) is defined on 0 ≤ x ≤ 1 by the following rule:
f(x) is the first digit in the decimal expansion for x.

For example, f(1/2) = 5 and f(0.719) = 7. Sketch the graph of y = f(x) on the unit
interval with appropriate scales for x and for y. Use a graphical interpretation of the
definite integral to compute ∫_0^1▒f(x)dx.

c) Suppose the function g(x) is defined as follows:
g(x) is the second digit in the decimal expansion for x.
For example, g(0.437) = 3. Compute ∫_0^1▒g(x)dx.

Again, a graph may help

1 answer

it's just a step function, so just add up the areas of the rectangles with heights 0,1,2,...9 and width 0.1