# Finding a constant given joint density

Suppose a point has a random location in the circle of radius 1 around the origin. The coordinates $(X,Y)$ of the point have a joint density

$$f_{X,Y}(x,y) = \begin{cases}c(x^2+y^2)&\mathrm{\ if \ } x^2+y^2\le1\\ 0&\mathrm{\ otherwise\ }\end{cases}$$

How do I find $c$? Currently, I have the following.

$$\int_{-1}^1\int_{-1}^{\sqrt{1-y^2}} c(x^2+y^2)dxdy = 1$$

Is this correct?

-
@Andrew I think you meant over $[-\sqrt{1-y^2},\sqrt{1-y^2}]$, maybe? – Dilip Sarwate Sep 28 '12 at 2:29

An efficient way to do it is to switch to polar coordinates. We have $x^2+y^2=r^2$, so our integral is equal to $$\int_{\theta=0}^{2\pi}\left(\int_{r=0}^1 (cr^2)r\,dr\right)d\theta.$$. The integration is exceptionally easy. Then, as you did, you will be setting the result equal to $1$ to evaluate $c$.

Your procedure will also succeed, with somewhat more work. A small change needs to be made, for correctness.

If one does it more or less your way, the inner integral needs to be from $x=-\sqrt{1-y^2}$ to $x=\sqrt{1-y^2}$. Out of habit, other things being equal, I slightly prefer integrating first with respect to $y$, from $-\sqrt{1-x^2}$ to $\sqrt{1-x^2}$.

I would suggest exploiting symmetry . Integrate over the first quadrant, and multiply the result by $4$.

-
Why is it $(r^2)r$? Shouldn't it be $(r^2)$? – idealistikz Sep 28 '12 at 2:24
It is $r^3$. The $r^2$ comes from $x^2+y^2$. The $r\,dr\,d\theta$ comes either from the Jacobian (usually second year), or from the fact that while the area element in rectangular coordinates is $dx\,dy$, in polar coordinates it is $r\,dr\,d\theta$. Area in polar coordinates is, in North America, often part of the integration section, second term of calculus. – André Nicolas Sep 28 '12 at 2:29
If I integrated over the first quadrant, what would my limits be? – idealistikz Sep 28 '12 at 2:38
In polar coordinates might as well go all around, not first quadrant. In rectangular coordinates, if integrating first with respect to $x$, then $x$ goes $0$ to $\sqrt{1-y^2}$, then $y$ goes $0$ to $1$. More pleasant, fewer negatives, less chance of error. Or else integrate first with respect to $y$, $y=0$ to $y=\sqrt{1-x^2}$, then $x$ from $0$ to $1$. – André Nicolas Sep 28 '12 at 2:45
If you do the integration the long way, then after a fair bit of effort you will find that the constant is $\frac{2}{\pi}$. – André Nicolas Sep 28 '12 at 4:31