# Distribution function of a Bernoulli variable

Let $$X_1, X_2,\dots, X_n$$ be i.i.d. real-valued random variables. Let $$F_X$$ be the (common) distribution function of these random variables.

1. Find the distribution function of the random variable $$Y=\max\{X_1,X_2,\dots,X_n\}$$ in terms of $$F_X$$.

We have $$F_Y(x)=\mathbb{P}(Y\le x)=\mathbb{P}(X_1\le x,\dots,X_n\le x)\overset{X_i\, i.i.d.}=\mathbb{P}(X_1\le x)\cdot\cdot\cdot\mathbb{P}(X_n\le x)=F_X(x)^n$$

1. In case when the $$X_i$$’s are Bernoulli random variables with parameter $$p$$, that is $$\mathbb{P}(X_i = 0) = p$$, $$\mathbb{P}(X_i = 1) = 1 − p$$, find the expectation of $$Y$$ .

My approach: Is it right to say, since $$\mathbb{P}(X_i=0)=p$$ and $$\mathbb{P}(X_i=1)=1-p$$, that $$F_X(0)=\mathbb{P}(X\le0)=p$$, $$F_X(1)=\mathbb{P}(X\le1)=p(1-p)?$$ I don't know, it starts getting confusing. Maybe this is not relevant for the exercise?

$$\mathbb{E}(Y)=\sum^\infty_{k=0}k\mathbb{P}(Y=k)$$? Since Bernoulli distribution is discrete. Any help?

• For 2, $Y$ can only take the values $0$ or $1$. What is the probability it is $1$ (use answer to 1)? What is the expectation of $Y$? Commented Mar 24, 2022 at 15:21
• @Henry since $Y$ is defined as the maximum of all $X_i$, does it mean that $F_Y(x)=\mathbb{P}(X=1)^n=(1-p)^n$?
• No - clearly $P(Y\le 1)=F_Y(1)=1$. But the interesting calculation is $P(Y=1)=P(Y\le 1)-P(Y\lt 1)$ which here is $F_Y(1)-F_Y(0) =1 - p^n$ Commented Mar 24, 2022 at 16:02
A full form of a Bernoulli cdf is $$F_X(1)=1,\,F_X(0)=1-p\implies F_X(x)=(1-p)^{(1-\lfloor x\rfloor)^+}\mathbf{1}_{[0,\infty)}(x)$$ Therefore $$F_Y(x)=(F_X(x))^n=(1-p)^{n(1-\lfloor x\rfloor)^+}\mathbf{1}_{[0,\infty)}(x)$$ This means that $$P_Y(0)=(1-p)^n,\,P_Y(1)=1-(1-p)^n$$ and therefore $$E[Y]=1-(1-p)^n$$.
• (note I use $P(X=0)=1-p$) Commented Mar 24, 2022 at 23:58