# Math Help - Straightforward PDF/CDF question

1. ## Straightforward PDF/CDF question

Hi there, I am taking a Statistics course at University, but it's been a while since I did any of this stuff so I'm a bit rusty. Here's a question I'm trying to do:

Let X denote a random variable with probability density function

$f(x) = 2e^{-2x} when 0

(i) Derive the CDF of X
(ii) Calculate $E[X^2 + 3X]$
(iii) Let Y = min(V,W), where V and W are independent and each have the same distribution as X. Find the CDF of Y and hence the PDF of Y.
Well for part (i) I simply integrated 2e^{-2x} to get -e^{-2x} for when x is between 0 and infinity. But then I remembered, isn't 0 <= F(x) <= 1 a property of the CDF? And in this case, if x is for example 3, then F(3) = -e^{-6} which certainly isn't between 0 and 1. So where have I wrong here?

I then thought I could do part (ii) without successfully having done part (i). I used the fact that E[X^2 + 3X] = E[X^2] + 3E[X] and ended up getting an answer of 2, can anyone verify this for me please? Just so I know whether I'm doing things right!

And for part (iii) I decided I needed to know about part (i) first...once I get part (i), I think I might be able to do it, I have something in my notes and 2 random variables being "independent and identically distributed" which I think may apply here.

Many thanks for anyone who can help me out, my exam is on Friday and I need to sort out a few kinks!

Best,
Ruaraidh

2. I think you made an integration error in part 1

$F(x) = \int_0^{x} 2e^{-2x} = \left[-e^{-2x} \right]^{x}_0 = \left( -e^{-2x} - -e^{0}} \right) = \left(-e^{-2x} + 1} \right) = (1-e^{-2x})$

i dont think your part b is quite right either
E(X) = 0.5
E(X^2) = 0.25

(note, it is just a coincident that E(X^2) = E(X) * E(X) in this case)

You can get the above answers by integration

$E(X) = \int x f(x) ~dx$
$E(X^2) = \int x^2 f(x) ~dx$

3. Hi Springfan25, many thanks for your response. I see where I went wrong with part (i) now, I messed up the limits basically.

But with part (ii), I don't see how you get E(X^2) = 0.25? I get E(X^2) = 0.5, and E(X) = 0.5 which gives my value of E(X^2 + 3X) to be 0.5 + 3*0.5 = 2.

To get E(X^2) = 0.5 I did:

$
E(X^2) = \int^{\infty}_{0} x^2 f(x) ~dx
\\ = [(-x^2 -x - \frac{1}{2})e^{-2x}]^{\infty}_{0} \\ = 0 - (-\frac{1}{2}) = \frac{1}{2}
$

Which one of us has made a mistake?

4. http://www.wolframalpha.com/input/?i=integral+x^2(exp[-2x])dx+x%3D0+to+x%3Dinfi

As you can see the $\int\limits_0^\infty {x^2 \exp ( - 2x)dz} = 0.25$

5. But f(x) isn't exp(-2x), it's 2*exp(-2x). So from that I take it that E[X^2] = 2*0.25 = 0.5 is correct?

Also, I have had a go at part (iii), can anyone verify this?

CDF:
$F(Y) = 0 for v \leq 0, w \leq 0$

$F(Y) = 1 - e^{-2v} for 0

$F(Y) = 1 - e^{-w} for 0

And thus the PDF:

$f(y) = 2*e^{-2v} 0

$f(y) = 2*e^{-2w} 0

$f(y) = 0 elsewhere$

I don't think this is right though because the integral of f(y) between the limits should equal 1, but this doesn't...

6. OK I'm really stuck on part (iii). I've done similar questions that are like "Let Y = 1 - X. Find the CDF and PDF of Y", which I can do by using a technique like this (arbitrary example):

$F_Y(y) = P(Y \leq y) = P(1-X \leq y) = P(1-y \leq X) = 1 - P(X \leq 1 -y) = 1 - F_X(1-y)$

Which can then be solved using the CDF for X, but with this specific question, I don't really know how to do that cos we have Y=min(V,W) which isn't an explicit function of X. I thought I had something in my notes about independent and identically distributed (iid) random variables, but I can't seem to find it. Can anyone explain to me how to solve part (iii)?