The following problem is from the book, "Introduction to Probability" by
Hoel, Port and Stone. My answer does not match the back of the book. What did I do wrong?
Thanks,
Bob
Problem:
Let $X$ have a Cauchy density. Find the upper quartile for $X$.
Answer:
Recall the density function for the Cauchy distribution is:
\begin{align*}
f(x) &= \frac{1}{x^2+1} \\
\end{align*}
Let $a$ be the number we seek.
\begin{align*}
F(x) &= \tan^{-1}{x} \\
\int_{-\infty}^{a} \frac{1}{x^2+1} \,\, dx &= \frac{3}{4} \\
\tan^{-1} \Big|_{-\infty}^{a} &= \frac{3}{4} \\
\tan^{-1}(a) – \frac{-\pi}{2} &= \frac{3}{4} \\
\tan^{-1}(a) + \frac{\pi}{2} &= \frac{3}{4} \\
\tan^{-1}(a) &= \frac{3}{4} – \frac{\pi}{2} \\
\end{align*}
The books's answer is $1$. What did I do wrong?
I ran the following command in R: pcauchy(1) . R returned 0.75 therefore,
I believe the book is right.
Best Answer
You forgot the factor $\frac{1}{\pi}$ in the probability density function. Correct density function is $$ f(x) =\frac{1}{\pi(1+x^2)} $$ so that $\int_{-\infty}^\infty f(x) dx =1$. Your problem is to find $a$ such that $$ \frac{1}{\pi}\int_{-\infty}^a \frac{dx}{1+x^2}=\frac{\arctan a+\frac{\pi}{2}}{\pi}=\frac{3}{4} $$ or equivalently $$ \arctan a=\frac{\pi}{4}. $$ This gives $a=\tan \frac{\pi}{4}=1$.