# Help on calculation of expectation

Let $X_1, \cdots, X_m$ be i.i.d. random variables with each $X_i$ has the following distribution, let $k$ be a stopping parameter:

$$\text{P}(X_i = j) = \begin{cases} p(1-p)^{j -1}, & (j \in [1, k - 1] )\\ (1-p)^{k - 1}, & (j = k) \end{cases}$$

And another random variable $M = \max_{i=1}^m X_i$, could you please help me on the precise form of $\mathbb{E}(X_i)$ and $\mathbb{E}(M)$.

I can get: $\mathbb{E}(X_i) = \sum_{j = 1}^{k - 1}j\cdot p(1-p)^{j - 1} + k\cdot (1-p)^{k - 1}$
and
$\text{P}(M \le l) = \text{P}(X_i \le l)^m$

But I can not simplify it more. I want to know the relation between $\mathbb{E}(M)$ and $k$, how $\mathbb{E}(M)$ changes with respect to $k$.

-
What have you tried? Where are you stuck? Did you try to apply to this setting the techniques you learned thanks to the answers to your numerous similar questions on the site? –  Did Apr 1 '12 at 13:05
This distribution looks very much like a Geometric distribution, which suggests the use of a Geometric series to calculate the expected value... –  TMM Apr 1 '12 at 13:36
@Didier I have updated. –  Fan Zhang Apr 1 '12 at 13:48
See here for a similar question. In your case the number of trials is bounded by $k$, but a similar proof strategy should work. –  TMM Apr 1 '12 at 13:59
Also "$P(M \leq \ell) = P(X_i)^m$" makes no sense. You probably mean $P(M \leq \ell) = P(X_1 \leq \ell)^m$. –  TMM Apr 1 '12 at 14:04
show 1 more comment

The random variable $X$ satisfies $\mathbb{P}(X>x)=(1-p)^x$ for $x=0,1,\dots, k-1$ and $\mathbb{P}(X>x)=0$ for $x\geq k$. Therefore its expectation is $$\mathbb{E}(X)=\sum_{x=0}^{k-1} (1-p)^x= {1\over p}-{(1-p)^k\over p}.$$
For the maximum $M$ of $m$ of these, we have for $x=0,1,\dots, k-1$ $$\begin{eqnarray*} \mathbb{P}(M>x)&=&1-\mathbb{P}(M\leq x)\\&=& 1-(1-\mathbb{P}(X>x))^m\\&=&1-(1-(1-p)^x)^m. \end{eqnarray*}$$
The expectation is $$\mathbb{E}(M)=\sum_{x=0}^{k-1} 1-(1-(1-p)^x)^m,$$ but I don't think that this simplifies nicely unless $m=1$.