# Finding median for a continuous random variable

Let $$X$$ be a continuous random variable with PDF

$$f_X(x)= \begin{cases} cx(1-x), & \text{0 Find the median of $$X$$.

My question is how I am only given PDF, to calculate median, do I need to find CDF for it? And how?

• Note that distribution is not uniform. Feb 11, 2020 at 5:06
• @herbsteinberg fixed Feb 11, 2020 at 5:46

The distribution is symmetric about $$x=\frac 12$$. (Draw it.)
So, median and mean are the same and are equal to $$\frac 12$$.
To get CDF $$F_X(1)=1=c\int_0^1x(1-x)dx =\frac{c}{6}$$, so $$c=6$$
Next $$F_X(x)=6\int_0^xu(1-u)du=3x^2-2x^3$$.
To get median $$3x^2-2x^3=\frac{1}{2}$$ and solve for $$x$$ in the interval $$[0,1]$$.