Marginal pdf of a rotated axis from a joint pdf of two random variables I'm trying to take a marginal pdf $f_{X'}(x')$, where $x'$ is the $x$-axis rotated an angle $\theta$.
What I've done is:
$$ \iint{f_{X,Y}(x,y)}\ dy\ dx= \int f_X(x)\ dx$$
Given that $dy\ dx = |\mathbf J|\  dy'\ dx'$, where $|\mathbf J|$ is the determinant of the Jacobian matrix:
$$\iint{f_{X,Y}(x,y)}\ dy\ dx= \iint{f_{X,Y}(x',y')}\ |\mathbf J|\ dy'\ dx'$$
Given that $|\mathbf J| = 1$, then:
$$\iint{f_{X,Y}(x',y')}\ dy'\ dx' = \int f_X(x)\ dx$$
Now, my question is if I have to differentiate the last equality by $x'$ to get $f_{X'}(x')$, like:
$$ {d\over dx'}{\iint{f_{X,Y}(x',y')}\ dy'\ dx'} = {d\over dx'} \int f_X(x)\ dx$$
$$ \int{f_{X,Y}(x',y')}\ dy' = {d\over dx'} \int f_X(x)\ dx $$
$$ {d\over dx'} \int f_X(x)\ dx = f_{X'}(x')$$
Is it the last equality correct? And then, if that is correct, Can I do follow?
$$ {d\over dx'} \int f_X(x)\ dx= {d\over dx'} \int f_X(x)\ (dx'\cos(\theta)+dy'\sin(\theta))$$
$$ = {d\over dx'} \int f_X(x)\cos(\theta)\ dx'+f_X(x)\sin(\theta)\ dy'$$
$$=f_X(x)\cos(\theta) + \sin(\theta)\int {\partial\over\partial x'}f_X(x)\ dy'$$
So:
$$ f_{X'}(x,y)=f_X(x)\cos(\theta) + \sin(\theta)\int {\partial\over\partial x'}f_X(x)\ dy'$$
EDIT:
After some reasoning, I tried another approach, but searched for the marginal pdf of a random radius $R$. First, this two integral have to be the same:
$$\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}f_{X,Y}(x,y)\ dy\ dx = \int_0^{\infty}\int_0^{2\pi}f_{X,Y}(r,\theta)r\ d\theta\ dr$$
Differentiate for $r$ to get the pdf $f_R(r)$:
$$ {d\over dr}\int_0^{\infty}\int_0^{2\pi}f_{X,Y}(r,\theta)r\ d\theta\ dr = \int_0^{2\pi}f_{X,Y}(r,\theta)r\ d\theta = f_R(r)$$
$$f_R(r) =  {d\over dr}\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}f_{X,Y}(x,y)\ dy\ dx$$
$$= {d\over dr}\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}f_{X,Y}(x,y)\ dy\ dx = \int_{-\infty}^{\infty}\int_{-\infty}^{\infty}{\partial\over\partial r}f_{X,Y}(x,y)\ dy\ dx$$
$$ = \int_{-\infty}^{\infty}\int_{-\infty}^{\infty}\nabla f_{X,Y}(x,y)\cdot {\partial\over\partial r}\langle x,y\rangle\ dy\ dx = f_R(x,y)$$
Is this second approach correct?
 A: 
I'm trying to take a marginal pdf $f_{X'}(x')$, where $x'$ is the $x$-axis rotated an angle $\theta$.
Given that $dy\ dx = |\mathbf J|\  dy'\ dx'$, where $|\mathbf J|$ is the determinant of the Jacobian matrix:
$$\iint{f_{X,Y}(x,y)}\ dy\ dx= \iint{f_{X,Y}(x',y')}\ |\mathbf J|\ dy'\ dx'$$

No.  You cannot just substitute $x'$ for $x$, nor $y'$ for $y$, when changing variables.  Use the same transformation used to obtain the Jacobian.
Since we are rotating: $$\begin{bmatrix}x'\\y'\end{bmatrix}=\begin{bmatrix}\cos\theta&-\sin\theta\\\sin\theta&\cos\theta\end{bmatrix}\begin{bmatrix}x\\y\end{bmatrix}\\~\\\begin{bmatrix}x\\y\end{bmatrix}=\begin{bmatrix}\cos\theta&\sin\theta\\-\sin\theta&\cos\theta\end{bmatrix}\begin{bmatrix}x'\\y'\end{bmatrix}$$
Therefore, the change of variables transformation yeilds:
$$\iint_{D}{f_{X,Y}(x,y)}\ \mathrm dy\ \mathrm dx= \iint_{D'} {f_{X,Y}(x'\cos\theta+y'\sin\theta,y'\cos\theta-x'\sin\theta)}\ \lVert\mathbf J\rVert\ \mathrm dy'\ \mathrm dx'$$

Now, my question is if I have to differentiate the last equality by $x'$ to get $f_{X'}(x')$,

Yesish, but also no.  Clearly it is just:
$$f_{X'}(x')=\int_{\Bbb R}{f_{X,Y}(x'\cos\theta+y'\sin\theta,y'\cos\theta-x'\sin\theta)}\ \lVert\mathbf J\rVert\,\mathrm d y'$$
This is of course $$\dfrac{\partial~~}{\partial x'}\int_{-\infty}^{x'}\int_\Bbb R{f_{X,Y}(s\cos\theta+y'\sin\theta,y'\cos\theta-s\sin\theta)}\ \lVert\mathbf J(s,y')\rVert\,\mathrm d y'\,\mathrm d s$$


After some reasoning, I tried another approach, but searched for the marginal pdf of a random radius $R$. First, this two integral have to be the same:
$$\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}f_{X,Y}(x,y)\ dy\ dx = \int_0^{\infty}\int_0^{2\pi}f_{X,Y}(r,\theta)r\ d\theta\ dr$$

No, because of the same issue.
The transformation is: $x=r \cos\theta, y=r\sin\theta$, therefore changing variables gives:
$$\begin{align}f_{R,\Theta}(r,\theta) = f_{X,Y}(r\cos\theta, r\sin\theta)\begin{Vmatrix}\cos\theta & -r\sin\theta\\\sin\theta&r\cos\theta\end{Vmatrix}\end{align}\\f_R(r)=\int_0^{2\pi} f_{X,Y}(r\cos\theta, r\sin\theta)\cdot r\,\mathrm d \theta$$

Note: This is not the marginal distribution along the rotated $x$-axis, since it is the marginal distribution over distance from the origin.
A: Incomplete solution: I'm still researching
Well, I think that maybe I had asked in a wrong way my question but now I have found the solution of my problem.
I wanted to get the pdf in the sense of slicing through a joint pdf following a curve, with the meaning of showing what is the mode and the expected vector of the combination of random variables that are in the set of the curve. I do a parametrization of the curve $C$ with a parameter $t$, and because line integrals don't depend of the parametrization, that function can represent probabilities.
So given a joint pdf $f_{X,Y}(x,y)$ and a position vector $\vec r$, which is a parametrization of the curve $C$, the line integral is defined as:
$$\int_{\left[\vec a,\vec b\right]}f_{X,Y}(x,y)\Vert{d\vec r}\Vert = \int_{t_0}^{t_1}f_{X,Y}(x^{-1}(t),y^{-1}(t))\left \Vert{d\vec r\over dt}\right\Vert  dt = I$$
The invariance is prooved by setting a parameter $k = f(t)$, which is a monotonic function, and a parametrization $\vec r_2(k)$ of $C$. Because the parametrization $p_0 +\vec r_1(t)$ is equal to $p_0 +\vec r_2(k)$ since both describe the same curve, taking $d\over dt$ in the equality:
$$p_0 +\vec r_1(t)=p_0 +\vec r_2(k)$$
$${d(p_0 +\vec r_1(t))\over dt} = {d(p_0 +\vec r_2(k))\over dt}$$
$$ {d\vec r_1\over dt}={d\vec r_2\over dk}{dk\over dt}$$
$${d\vec r_1\over dt}\left({dk\over dt}\right)^{-1}= {d\vec r_2\over dk}$$
Using the line integral with the parametrization $\vec r_2$
$$\int_{k_0}^{k_1} f_{X,Y}(x^{-1}(k),y^{-1}(k))\left\Vert d\vec r_2\over dk \right \Vert dk $$
and substituing $\vec r_2 \over dk$ gives
$$\int_{t_0}^{t_1} f_{X,Y}(x^{-1}(t),y^{-1}(t))\left\Vert{d\vec r_1\over dt}\left({dk\over dt}\right)^{-1} \right \Vert {dk\over dt}dt $$
$$= \int_{t_0}^{t_1}f_{X,Y}(x^{-1}(t),y^{-1}(t))\left \Vert{d\vec r_1\over dt}\right\Vert  dt$$
and because of the invariance, the function...
$${f_{X,Y}(x^{-1}(t),y^{-1}(t))\over I} $$
represent the same scalar field for any parametrization. Given the above, it makes sense to analize a subset of point in the path as arc lenth $s$, because the line integral can be write as:
$$\int_{\left[\vec a,\vec b\right]}f_{X,Y}(x,y)\Vert{d\vec r}\Vert=\int_{\left[\vec a,\vec b\right]}g_S(s)\ ds $$
where:
$$g_S(s)= {f_{X,Y}(x^{-1}(t),y^{-1}(t))\over I}\left \Vert{d\vec r\over dt}\right\Vert$$
and so probabilities should then define as:
$$\Bbb P(0<S<s)=\int_{0}^{s} g_S(u)du = \int_{t_0}^{s^{-1}(s)} {f_{X,Y}(x^{-1}(u),y^{-1}(u))\over I}\left\Vert{d\vec r\over du}\right\Vert du$$
where $u$ is a dummy variable and be interpreted as the meassure of probability that a point which is in the curve is between the defined start of the curve and the end of the arc lenth meassure.
For a expected point in the curve $\Bbb E[\vec r]$, should be the same for any choosen parameter, and for that, it must be true that $\vec r_1(s^{-1}(\Bbb E[S_t])=\vec r_2(s^{-1}(\Bbb E[S_k])$, where $\Bbb E[S_i]$ is the expected value of the arc lenth $s$ given a parametrization $i$ and $s^{-1}$ is the inverse of the arc lenth function
$$s(t) = \int_{t_0}^t \left\Vert{d\vec r\over du}\right\Vert du$$
The expected value of the arc lenth $\Bbb E[S]$ is:
$$\int s g_S(s)ds = \int_{t_0}^{t_1}s(t)g_S(t)\ dt = \int_{t_0}^{t_1}\left( \int_{t_0}^{t}\left\Vert{d\vec r\over du}\right\Vert du \right) g_S(t) dt$$
The mode in the path $C$ is the maxima of the pdf and the variance seems to be also invariance of parametrization given the test I have done but I don't know hot to prove it. And the expected value depends can be two, depending of any of the two point that delimits the path and which someone choose to "start" the path, but always when applying the inverse of the arc lenth and input to the position vector gives the same point.
