I was wondering if someone could please me clarify understanding certain topics in expectations in continuous random variables. I am trying to organize my notes, and I get stuck in understanding the joint expectation of 2 transformed continuous random variables.
So if I have for instance
$$f_X(x) \quad \textrm{and} \quad f_Y(y) $$ then in order to find $E[X]$ and E[Y] it would be $$E[X]=\int_{-\infty}^\infty xf_X(x)dx$$ $$E[Y]=\int_{-\infty}^\infty yf_Y(y)dy$$ and if we have the joint distribution
$$f_{X,Y}(x,y)$$then $$E[XY]=\int_x\int_yf_{XY}(x,y)dydx$$
And if $E[X]E[Y]=E[XY]$ then $f_X(x)$ and $f_Y(Y)$ are independent.
Now if we have the functions of the above continuous random variables, suppose $g(X)$ and $g(Y)$ then their expected values $$E(g(X))=\int_{-\infty}^\infty xf_X(x)g(x)dx$$ and random variables, suppose $g(X)$ and $g(Y)$ then their expected values $$E(g(Y))=\int_{-\infty}^\infty yf_Y(y)g(y)dy$$
Here is where I get stuck, that is, how do you find $$E[g(X)g(Y)]$$
From what I understand $E[g(X)g(Y)]$ is the expected value of joint transformed continuous random variables. Could someone please tell me the formula for $E[g(X)g(Y)]$ and perhaps an example, as I am unable to locate and compute one myself. Thank you in advance.