Let $X$ be a continuous random variable with the density function: $$f_X(x)=\frac{1}{\pi}\frac{1}{1+x^2},$$ $-\infty \le x\le\infty$.
We define the random variable $Y=\frac{1}{X}$. Find the density function of $Y$, and find the connection between $X,Y$ distributions.
My Work:
My plan is to find the Cumulative distribution function $F_Y(y)=P(Y\le y)$, and then take derivative to get $f_Y(y)$.
$$F_Y(y)=P(Y\le y)=P(\frac{1}{X}\le y)=P(1 \le Xy)\Longrightarrow(\text{When $y> 0$ }) \Longrightarrow =P\left(X \ge \frac{1}{y}\right)=\int_{\frac{1}{y}}^\infty f_X(x) \, dx=\frac{1}{\pi} \int_{\frac{1}{y}}^\infty \frac{dx}{1+x^2}=\frac{1}{\pi} \left[\frac{\pi}{2}-\arctan\left(\frac{1}{y}\right)\right]$$
$$\text{For $y < 0$:} \Longrightarrow P\left(X \le \frac{1}{y}\right) =\frac{1}{\pi}\int_{-\infty}^\frac{1}{y}\frac{dx}{1+x^2}=\frac{1}{\pi} \left[\arctan\left(\frac{1}{y}\right)-\left(-\frac{\pi}{2}\right)\right]$$
Now I'm not sure if what I did was correct, and I got stuck trying to figure out what happens when $y=0$. And I couldn't figure out what connection there is between the distributions of $X,Y$ until now.
Would appreciate any help or feedback,
thanks in advance to everyone!
There is no need to address the case where $y=0.$ Probability density functions are not defined pointwise (unlike likelihood functions in statistics, for which the distinction between $\text{“}{<}\text{”}$ and $\text{“}{\le}\text{”}$ sometimes matters in ways in which it does not with density functions). Changing a density function at an isolated point does not change the value of its integral over any set. To say that $f$ is the density function of the probability distribution of a random variable $W$ means only that for every measurable set $A,$ $$ \Pr(W\in A) = \int_A f(x)\,dx. $$ Altering $f$ at just one point does not alter the integral, so the value of $f$ at an isolated point isn't really a part of the identity of $f$ at all.
In the case $y>0$ and in the case $y<0,$ the derivative of the c.d.f. with respect to $y$ is $$ \frac 1 \pi \frac 1 {1+y^2}, $$ and the conclusion is that the probability distribution of $1/X$ is the same as that of $X.$