# Help with total expectation formula

1. Jul 29, 2008

### yevi

I need some help with "law of total expectation".

Sorry for my English, I don't know the right English expressions.

The Problem is:
People come (show in) with with Poisson rate of 10 people per hour.
There is a 0.2 chance that a person will give money to a beggar sitting in the corner.
The time that beggar is sitting is U[3,8] (continuous) hours.

Need to find the expectation E of people that will give money.

I mark:
N(t)~P(10*0.2*t) as the number of people giving money per hour.
X~U(3,8) time that beggar is sitting.

The given solution is following : E(N(X))=E(E(N(X)|X))=E(2X)=2*(3+8)/2

What I don't understand is their usage law of total expectation, according to the formula it should be like this:

E(Y)=E[E[Y|X]]=$$\int$$E[Y|X=x]*$$f_{x}$$(x)dx

And this is not what they have.....

2. Aug 1, 2008

### yevi

Well, anyone?