You throw a fair dice 3 times, let X be the highest number you will get.
What is the PDF of $P(X=K), K=1,...6$ ?
The answer is : $$\frac{k^3-(k-1)^3}{216}$$ However, I can't understand it, could help me to understand why is this the right answer?
Thank you
For $k$ to be the highest at least one must be $k$ and the other two must be at less or equal to $k$.
If there is only one that has $k$ there are $3$ dice which may be the $k$, and the other two must be less than $k$, there are $k-1$ options for each. So there are $3(k-1)^2$ ways for there to be exactly one $k$ and it being the highest.
If there are two that have $k$ then there are are ${3 \choose 2} =3$ dice that might have the $k$s and $1$ that has the $k-1$ option to not be $k$. So there are $3(k-1)$ ways for that to occur.
And finally there is exactly $1$ way for there to be all three showing $k$.
So $3(k-1)^2 + 3(k-1) + 1 = $
$[(k-1)^3 +3(k-1)^2 + 3(k-1) + 1] - (k-1)^3 = $
$[(k-1) + 1]^3 - (k-1)^3 =$
$k^3 - (k-1)^3$ ways to do this.
And there are $6^3=216$ ways to roll three dice total.
So $P = \frac {k^3 - (k-1)^3}{216}$.