having trouble finding the covariance(X,Y) of a PDF

35 Views Asked by At

I am trying to compute the co-variance where $f(x,y)$ = $e^{-y}$ for $x,y > 0, E(X) = 1$ and $E(Y) = 2$

I understand that $\operatorname{cov}(X,Y) = E(XY) - E(X)E(Y)$ but I am having trouble computing $E(XY)$.

My attempt starts with $E(XY)$ = $$\iint_0^∞ xyf(x,y) \,dx\,dy$$

but my answer ends up being infinity, which I know is wrong, could it possibly be an issue with my bounds?

1

There are 1 best solutions below

4
On BEST ANSWER

That is because the $f(x,y)$ you gave is not a valid pdf.   It looks like you have the wrong support.

$f(x,y)=e^{-y} ~\big[0\leq x\leq y\big]$ will give $\mathsf E(X)=1$ and $\mathsf E(Y)=2$.

So I suggest you should be looking for: $$\mathsf E(XY)=\int_0^\infty \int_0^y x y~e^{-y}~\mathsf d x~\mathsf d y$$