Solved: Mean & Variance: Find E(Y), Var(Y) of |tan(X)|, cot(X)

  • Thread starter Thread starter island-boy
  • Start date Start date
  • Tags Tags
    Mean Variance
island-boy
Messages
93
Reaction score
0
I'm having a problem with my answer for a question involving finding the mean and variance of a function. I'll state the question and list the steps I did so maybe you guys can see where I went wrong.

The question is:
Given Y = |tan(X)| and X is uniformly distributed on (-pi/2, pi/2) Find
a) the pdf of Y
b) E(Y)
c) Var(Y)

for a) I was able to come up with the answer
g(y) = \frac{2}{\pi (1 + y^2)} for 0 < y < \infty
0 otherwise

which I'm pretty sure is correct (by transformation of variables)

for b)
I have:

E(Y) = \int_{0}^{\infty} y \frac{2}{\pi (1+y^{2})} dy
= \frac{1}{\pi} \lim_{b\rightarrow\infty} [ ln (1+y^{2}]_{0}^{b}
= \frac{1}{\pi} [ \infty - 0]
= \infty

for c)
I solve first for E[Y^2]
E[Y^{2}] = \int_{0}^{\infty} y^{2} \frac{2}{\pi (1+y^{2})} dy
= \frac{2}{\pi}\int_{0}^{\infty} \frac{y^{2}}{(1+y^{2})} dy
= \frac{2}{\pi}\int_{0}^{\infty} 1 - \frac{1}{(1+y^{2})} dy
= \frac{2}{\pi} \lim_{b\rightarrow\infty}[ y - arctan(y)]_{0}^{b}
= \frac{2}{\pi} [\infty - \frac{\pi}{2} - (0 - 0)]
= \infty

thus
Var[Y] = E[Y^{2}] - (E[Y])^{2}
= \infty - (\infty)^{2}
= undefined ?

Is this correct?
my real problem is the mean being equal to infinity, is this possible?
as for the variance, is it possible to have undefined variance?

A similar problem was also asked where I am to find
Given Y = cot(X) and X is uniformly distributed on (0, pi) Find
a) the pdf of Y
b) E(Y)
c) Var(Y)

Here, I was able to get
E(Y) = either 0 or undefined
and
Var(Y) = either infinity (if mean is 0) or undefined (if mean is undefined)

are these possible? and which is correct?
Specifically, I'm not sure if my solution for the mean is correct, which would affect my solution for the variance

my solution for the pdf, btw, is
g(y) = \frac{1}{\pi (1 + y^{2})} for -\infty < y < \infty

here's what I did:
E(Y) = \int_{-\infty}^{\infty} y \frac{1}{\pi (1+y^{2})} dy
= \frac{1}{2\pi} \lim_{b\rightarrow\infty} [ ln (1+y^{2}]_{-b}^{b}
= \frac{1}{2\pi}[ \lim_{b\rightarrow\infty} ln (1+b^{2}) - \lim_{b\rightarrow\infty} ln (1+(-b)^{2})

now is this
= \frac{1}{2\pi} [ \infty - \infty]
= undefined

or
= \frac{1}{2\pi}[0]
= 0

since I'm pretty sure that my answer for
E(Y^2) = infinity
is correct

thus var(Y) = either infinity (if mean is 0) or undefined (if mean is undefined)

are these answers correct (and which ones are the correct answers?)

Thanks for you help guys
 
Last edited:
Physics news on Phys.org
I guess you could say that my main problem has more to do with operations of infinity and limits than on mean and variance :)
 
Prove $$\int\limits_0^{\sqrt2/4}\frac{1}{\sqrt{x-x^2}}\arcsin\sqrt{\frac{(x-1)\left(x-1+x\sqrt{9-16x}\right)}{1-2x}} \, \mathrm dx = \frac{\pi^2}{8}.$$ Let $$I = \int\limits_0^{\sqrt 2 / 4}\frac{1}{\sqrt{x-x^2}}\arcsin\sqrt{\frac{(x-1)\left(x-1+x\sqrt{9-16x}\right)}{1-2x}} \, \mathrm dx. \tag{1}$$ The representation integral of ##\arcsin## is $$\arcsin u = \int\limits_{0}^{1} \frac{\mathrm dt}{\sqrt{1-t^2}}, \qquad 0 \leqslant u \leqslant 1.$$ Plugging identity above into ##(1)## with ##u...
There are two things I don't understand about this problem. First, when finding the nth root of a number, there should in theory be n solutions. However, the formula produces n+1 roots. Here is how. The first root is simply ##\left(r\right)^{\left(\frac{1}{n}\right)}##. Then you multiply this first root by n additional expressions given by the formula, as you go through k=0,1,...n-1. So you end up with n+1 roots, which cannot be correct. Let me illustrate what I mean. For this...
Back
Top