# Probability: random length of poles, how much is lost?

forty
Suppose the length of a pole is a random variable X, with mean m(x) and probability density function f(x). Poles are cut to obtain an exact length L. If the initial length of the pole is less than L, the entire pole is lost. If it is greater than L, the pole with be cut down to L, and the section left over is lost.

We are interested in the random variable Y, defined as the length of each piece lost.

i) Sketch the graph y (values of Y) as a function of x (values of X), and derive m(y) = E[Y] as a function of f(x) and m(x).

The graph...

y=x , x < L
y=x-L , x => L

but how do I derive the mean of Y?

Any helps as always greatly appreciated.

Billy Bob

There may be a shorter way, but here's a way that works.

If you knew the pdf f_Y for the random variable Y, you could find E[Y] by integrating y times f_Y(y) from 0 to infinity.

So, derive the pdf f_Y by finding the cdf F_Y(t)=P(Y <= t) and then taking the derivative.

If I did it right, finding F_Y(t) in terms of integrals of f_X takes a couple of steps, finding the derivative is then one step, and then finally computing E[Y] takes several steps including a change of variables in integration.

bsdz

Another suggestion but please double check.

Since y = g(x). I.e.

y = x , x < L
y = x-L , x => L

Then

$$E(y) = E(g(x)) = \int {g(x) f(x)} dx = \int_{-\infty}^{L} {x f(x)} dx + \int_{L}^{\infty} {(x-L)f(x)} dx$$

where I am saying m(x) is equivalent to E(x).

I am a bit rusty so this might be completely wrong.

Billy Bob

Definitely do it bsdz's way! My way gets to the same formula but takes six times as long.

forty

thanks guys!