Probability Question for Random Variable $R = \sqrt{X^2 + Y^2}$ Problem: Let $(X, Y)$ be uniformly distributed on the unit disk $\{ (x,y) : x^2 + y^2 \le 1\}$. Let $R = \sqrt{X^2 + Y^2}$. Find the CDF and PDF of $R$.
Attempted Solution: First note that $r \in R = \sqrt{X^2 + Y^2}$ represents a point on $\mathbb{R}^2$ with radius $r$ about the origin. Since only points with radius $1$ had probability greater than $0$ on $(X, Y)$ we have that
$$
F_R(r) = \begin{cases} 0 & r < 1 \\ 1 & r \ge 1 \end{cases}
$$
so that
$$
f_R(r) = F_R'(r) = \begin{cases} 0 & r < 1 \\ \text{undefined} & r = 0 \\ 0 & r > 1 \end{cases}
$$
since 


*

*$F'_R$ is discontinuous at $r = 0$.

*$F_R$ is constant everywhere else (so that the derivative of a constant is $0$, and hence $F_R'$ is $0$).


Question: Is my reasoning correct here?
 A: As the random variable is uniformly distributed, the probability of $R$ not exceeding a given $r$ is proportional to the enclosed area.
$$P(R\le r)\propto r^2.$$
As the probability is exactly $1$ for the radius $r=1$, the constant of proportionality is $1$.
For $r\le1$,
$$F_R(r)=r^2,\\f_R(r)=2r.$$
A: One of the reasons I love probability is that there are usual a million ways to do a problem.
I provide a heuristic alternative.
We recognize that we are interested in the event $R\in dr$. In words, this means we want the radius to fall in an infinitesimal annulus, with infinitesimal width $dr$, and area $2\pi rdr$. Since we were told that the points are uniformly distributed, then density is flat over the region of interest, call this $h$. We know the entire volume must be $1$, hence
$$h\cdot \pi 1^2  = 1\implies  h = \frac{1}{\pi}.$$
This tells us that
$$P(R\in dr) = \frac{1}{\pi}\cdot 2\pi r\,dr = 2r\,dr.$$
This implies that the density is $f_R(r) = 2r$ over the region of interest.
Thus, for $0\leq r\leq 1$,
$$F_R(r) = \int_0^r f(t)\,dt = r^2.$$
A: Your reasoning is incorrect.
First of all,  by the definition of CDF, 
$$
F_R(r)=P(R\leq r)=P(X^2+Y^2\leq r^2)\neq 0
$$
when $0<r<1$. 
Second, for a probability density $f_R(r)$, one must have 
$$\int_{\mathbb{R}} f_R(r)\ dr=1$$
which contradicts your calculation. 
A: I know that this question is quite old  but I asked the same some days ago  and now I think I have an answer which involves more calculus. Since this question is more popular than mine, I'm gonna copy-paste my answer here so that other people in the futere can see it:
Consider the following function:
 $$ g:\mathbb{R}^2\to \mathbb{R}^2 \quad g(x,y)=\left(\sqrt{x^2+y^2},\arctan\left(\frac{x}{y}\right)\right) $$
It is inyective and has inverse $ g^{-1}(r,s) =(r\sin(s),r\cos(s)) $ then 
$$ f_{g(X,Y)}(r,s)=f_{(X,Y)}(g^{-1}(r,s))|\det(J_{g^{-1}})(r,s)| =\frac{r}{\pi}1_{[0,1]}(r^2)=\frac{r}{\pi}1_{[-1,1]}(r) $$
Recall that we want to know $f_R $ which is the marginal distribution of $  f_{g(X,Y)}$:
$$ f_R(r)= \int_{\mathbb{R}} f_{g(X,Y)}(r,s) \; ds = \int_{0}^{2\pi} \frac{r}{\pi}1_{[-1,1]}(r) \; ds =2r 1_{[-1,1]}(r)   $$
