If U_1, dots , U_n are independent uniform random variables, find E(U_{(n)} -U_{(1)})

If $$\displaystyle{U}_{{1}},\dots{{}},{U}_{{n}}$$ are independent uniform random variables, find $$\displaystyle{E}{\left({U}_{{{\left({n}\right)}}}-{U}_{{{\left({1}\right)}}}\right)}$$

• Questions are typically answered in as fast as 30 minutes

Solve your problem for the price of one coffee

• Math expert for every subject
• Pay only if we can solve it

SchulzD

Step 1
$$\displaystyle{U}_{{1}},{U}_{{2}},\dots{{}},{U}_{{n}}$$ are independent uniform random variables in the interval [a,b].
The density of $$\displaystyle{U}_{{i}}$$ is,
$$f_{U_i}(u)\begin{cases}\frac{1}{b-a}, & \text{if } a\leq u \leq b\\0, & \text{otherwise}\end{cases}$$
The distribution of U is
$$\displaystyle{F}{\left({u}\right)}={P}{\left[{U}\leq{u}\right]}$$
$$=\begin{cases}0, & \text{if } x<a\\\frac{x-a}{b-a}, & \text{if } a\leq x \leq b\\1,&\text{if } x>b\end{cases}$$
Step 2
The cumulative distribution function of $$\displaystyle{U}_{{{\left({n}\right)}}}$$ is
$$\displaystyle{F}_{{{U}_{{{\left({n}\right)}}}}}{\left({u}\right)}={P}{\left[{U}_{{{\left({n}\right)}}}\leq{u}\right]}$$
$$=P\left[\max\left\{U_1,U_2, \dots, U_n\right\}\leq u\right]$$
$$=P\left[U_1 \leq u , U_2 \leq u , \dots , U_n \leq u \right] , \text{ as } U_1 , U_2 , \dots , U_n \text{ are independent. }$$
$$=P\left[U_1 \leq u\right] P \left[U_2\leq u\right] \dots P \left[U_n \leq u\right]$$
$$\displaystyle={\left[{P}{\left[{U}_{{1}}\leq{u}\right]}\right]}^{{n}}$$
$$\displaystyle={\left[{\frac{{{u}-{a}}}{{{b}-{a}}}}\right]}^{{n}}$$
The density function of $$\displaystyle{U}_{{{\left({n}\right)}}}$$ is
$$\displaystyle{F}_{{{U}_{{{\left({n}\right)}}}}}{\left({u}\right)}={\frac{{{d}{F}_{{{U}_{{{\left({n}\right)}}}}}{\left({u}\right)}}}{{{d}{u}}}}$$
$$=\begin{cases}\frac{d}{du} \left[\frac{u-a}{b-a}\right]^n , & \text{if } a\leq u\leq b\\ 0, & \text{ overwise.}\end{cases}$$
$$=\begin{cases}\frac{1}{(b-a)^n}n(u-a)^{n-1} & \text{if } a\leq u\leq b\\0, & \text{ overwise.}\end{cases}$$
Then the Expectation of $$\displaystyle{U}_{{{\left({n}\right)}}}$$ is
$$\displaystyle{E}{\left[{U}_{{{\left({n}\right)}}}\right]}={\int_{{a}}^{{b}}}{u}{f{{\left({u}\right)}}}{d}{u}$$
$$\displaystyle={\int_{{a}}^{{b}}}{\left({u}-{a}\right)}{f{{\left({u}\right)}}}{d}{u}+{\int_{{a}}^{{b}}}{a}{f{{\left({u}\right)}}}{d}{u}$$
$$\displaystyle={\int_{{a}}^{{b}}}{u}{\frac{{{1}}}{{{\left({b}-{a}\right)}^{{n}}}}}{n}{\left({u}-{a}\right)}^{{{n}-{1}}}{d}{u}+{a}{\int_{{a}}^{{b}}}{f{{\left({u}\right)}}}{d}{u}$$
$$\displaystyle={\int_{{a}}^{{b}}}{\left({u}-{a}\right)}{\frac{{{1}}}{{{\left({b}-{a}\right)}^{{n}}}}}{n}{\left({u}-{a}\right)}^{{{n}-{1}}}{d}{u}+{a}$$
$$\displaystyle={\frac{{{n}}}{{{\left({b}-{a}\right)}^{{n}}}}}{\int_{{a}}^{{b}}}{\left({u}-{a}\right)}^{{n}}{d}{u}+{a}$$
$$\displaystyle={a}+{\frac{{{n}}}{{{\left({b}-{a}\right)}^{{n}}}}}{{\left[{\frac{{{\left({u}-{a}\right)}^{{{n}+{1}}}}}{{{n}+{1}}}}\right]}_{{a}}^{{b}}}$$
$$\displaystyle={a}+{\left[{\frac{{{n}}}{{{\left({b}-{a}\right)}^{{n}}}}}\times{\frac{{{\left({b}-{a}\right)}^{{{n}+{1}}}}}{{{n}+{1}}}}\right]}$$
$$\displaystyle={a}+{\left[{\frac{{{n}}}{{{n}+{1}}}}{\left({b}-{a}\right)}\right]}$$
Step 3
The cumulative distribution function of $$\displaystyle{U}_{{{\left({1}\right)}}}$$ is
$$\displaystyle{F}_{{{U}_{{{\left({1}\right)}}}}}{\left({u}\right)}={P}{\left[{U}_{{{\left({1}\right)}}}\leq{u}\right]}$$
$$=P\left[\min\left\{U_1,U_2, \dots , U_n\right\}\leq u \right]$$
$$=1-P\left[\min\left\{U_1,U_2, \dots , U_n\right\}>u\right]$$
$$=1-P\left[U_1 > u , U_2 > u , \dots , U_n > u \right]$$
$$=1-\left\{P\left[U_1 > u\right]P\left[U_2 > u \right] \dots P\left[U_n > u \right]\right\} , \text{ as } U_1 , U_2 , \dots , U_n \text{ are independent.}$$
$$\displaystyle={1}-{\left[{P}{\left[{U}_{{1}}{>}{u}\right]}\right]}^{{n}}$$
$$\displaystyle={1}-{\left[{1}-{P}{\left[{U}_{{1}}\leq{u}\right]}\right]}^{{n}}$$
$$\displaystyle={1}-{\left[{1}-{\frac{{{u}-{a}}}{{{b}-{a}}}}\right]}^{{n}}$$
The density function of $$\displaystyle{U}_{{{\left({1}\right)}}}$$ is
$$\displaystyle{{f}_{{{U}_{{{\left({1}\right)}}}}}{\left({u}\right)}}={\frac{{{d}{F}_{{{U}_{{{\left({1}\right)}}}}}{\left({u}\right)}}}{{{d}{u}}}}$$
$$=\begin{cases}\frac{d}{du}\left[1-\left[1-\frac{u-a}{b-a}\right]^n\right] , & \text{if } a\leq u\leq b\\ 0, & \text{ overwise.}\end{cases}$$
$$=\begin{cases}\frac{n}{(b-a)}\left(1-\frac{u-a}{b-a}\right)^{n-1} & \text{if } a\leq u\leq b\\0, & \text{ overwise.}\end{cases}$$
Then the Expectation of $$\displaystyle{U}_{{{\left({1}\right)}}}$$ is
$$\displaystyle{E}{\left[{U}_{{{\left({1}\right)}}}\right]}={\int_{{a}}^{{b}}}{u}{f{{\left({u}\right)}}}{d}{u}$$
$$\displaystyle={\int_{{a}}^{{b}}}{\left({u}-{a}\right)}{f{{\left({u}\right)}}}{d}{u}+{\int_{{a}}^{{b}}}{a}{f{{\left({u}\right)}}}{d}{u}$$
$$\displaystyle={a}+{\int_{{a}}^{{b}}}{\left({u}-{a}\right)}{\frac{{{n}}}{{{\left({b}-{a}\right)}}}}{\left({1}-{\frac{{{u}-{a}}}{{{b}-{a}}}}\right)}^{{{n}-{1}}}{d}{u}$$
$$\displaystyle{z}={1}-{\frac{{{u}-{a}}}{{{b}-{a}}}}\Leftrightarrow{\left.{d}{z}\right.}=-{\frac{{{1}}}{{{\left({b}-{a}\right)}}}}{d}{u}$$
$$\displaystyle={a}+{n}{\left({b}-{a}\right)}{\int_{{0}}^{{1}}}{\left({1}-{z}\right)}{z}^{{{n}-{1}}}{\left.{d}{z}\right.}$$
$$\displaystyle={a}+{n}{\left({b}-{a}\right)}{\left[{\int_{{0}}^{{1}}}{z}^{{{n}-{1}}}{\left.{d}{z}\right.}-{\int_{{0}}^{{1}}}{z}^{{n}}{\left.{d}{z}\right.}\right]}$$
$$=a+n(b-a)\left[ \frac{z^n}{n}\bigg|_0^1 - \frac{z^{n+1}}{n+1}\bigg|_0^1\right]$$
$$\displaystyle={a}+{n}{\left({b}-{a}\right)}{\left[{\frac{{{1}}}{{{n}}}}-{\frac{{{1}}}{{{n}+{1}}}}\right]}$$
$$\displaystyle={a}+{n}{\left({b}-{a}\right)}{\frac{{{1}}}{{{n}{\left({n}+{1}\right)}}}}$$
$$\displaystyle={a}+{\frac{{{\left({b}-{a}\right)}}}{{{n}+{1}}}}$$
Step 4
Hence,
$$\displaystyle{E}{\left[{U}_{{{\left({n}\right)}}}-{U}_{{{\left({1}\right)}}}\right]}={E}{\left[{U}_{{{\left({n}\right)}}}\right]}-{E}{\left[{U}_{{{\left({1}\right)}}}\right]}$$
$$\displaystyle={a}+{\left[{\frac{{{n}}}{{{n}+{1}}}}{\left({b}-{a}\right)}\right]}-{a}-{\left[{\frac{{{\left({b}-{a}\right)}}}{{{n}+{1}}}}\right]}$$
$$\displaystyle={\frac{{{\left({b}-{a}\right)}}}{{{n}+{1}}}}{\left({n}-{1}\right)}$$
Therefore, the $$\displaystyle{E}{\left[{U}_{{{\left({n}\right)}}}-{U}_{{{\left({1}\right)}}}\right]}={\left({b}-{a}\right)}{\frac{{{n}-{1}}}{{{n}+{1}}}}$$