The diagram shows the graph of $y = \mathrm { f } ( x )$.
The graph consists of alternating straight-line segments of gradient 1 and - 1 and continues in this way for all values of $x$.
The function g is defined as
$$\mathrm { g } ( x ) = \sum _ { r = 1 } ^ { 10 } f \left( 2 ^ { r - 1 } x \right)$$
Find the value of
$$\int _ { 0 } ^ { 1 } \mathrm {~g} ( x ) \mathrm { d } x$$
A $\frac { 1023 } { 1024 }$
B $\frac { 1023 } { 512 }$
C 5
D 10
E $\frac { 55 } { 2 }$
F 55