# Integral for (kind of) standard Cauchy distibution and an alternative solution.

1. Sep 6, 2012

### nobahar

Hello!

I have a couple of questions on the following. Firstly, I was hoping someone could check my working and my reasoning.
Secondly, I was wondering if someone knew an alternative way of solving this problem.

I wanted to integrate this from $x = -\infty$ to $x = \infty$:
$$\lim_{a \rightarrow 0^{\pm}} \left(\frac{a}{\pi(x^2 + a^2)}\right)$$
It looks kind of like the standard Cauchy distribution-thingy...

I figured since $a \neq 0$ then I can ignore the limit ($a$ could just be a really small number, for example, or a large number, and, as a constant, except for the sign it wouldn't make a difference what its value is). I put $a \rightarrow 0^{\pm}$ rather than just $a \rightarrow 0$ because the limit is different from either side, which is also important. I think...

Therefore:

$$\int_{-\infty}^{\infty} \left( \lim_{a \rightarrow 0^{\pm}} \left(\frac{a}{\pi(x^2 + a^2)}\right) \right) dx = \lim_{a \rightarrow 0^{\pm}} \left( \int_{-\infty}^{\infty}\frac{a}{\pi(x^2 + a^2)} dx \right)$$

I used a trig substitution $x = a \ tan(\theta)$ since the range of $\theta$ is the same as x: $-\infty < \tan(\theta) < \infty$. To change the endpoints to $\theta$, for a>0 I get the lower bound to be $\frac{-\pi}{2}$ and the upper bound to be $\frac{\pi}{2}$, but for $a<0$ I get $\frac{\pi}{2}$ and $\frac{-\pi}{2}$ (they 'flip'); for the example, using $a>0$:

$$\int_{-\infty}^{\infty}\frac{a}{(x^2 + a^2)} dx = \int_{\frac{-\pi}{2}}^{\frac{\pi}{2}}\frac{a}{\pi((a \tan(\theta))^2 + a^2)}\,a (\tan^2(\theta) + 1) d\theta = \int_{\frac{-\pi}{2}}^{\frac{\pi}{2}}\frac{a^2 (\tan^2(\theta) + 1)}{\pi a^2 (\tan^2(\theta) + 1)} d\theta$$

$$= \frac{a^2}{\pi a^2} \int_{\frac{-\pi}{2}}^{\frac{\pi}{2}} d\theta = \frac{a^2}{\pi a^2} \left( \theta \Biggr|_{\frac{-\pi}{2}}^{\frac{\pi}{2}} \right) = \frac{a^2}{\pi a^2} \left(\frac{\pi}{2} + \frac{\pi}{2}\right) = 1$$

Evaluating the integral without converting back to x, for $a>0$ I get +1, as above. For $a<0$, I get -1 (because the endpoints would be the other way up).
The $a$ constants cancelled, but $a$ impacted on the sign of the final value. I'm guessing this is necessary to consider when stating the limit: either a right-hand limit or a left-hand limit.

I want to convert back to x so that someone could check my reasoning if that's okay.

I get $\theta = \arctan{\frac{x}{a}}$.
Here then, I would have to apply the endpoints for x, that is $\infty$ and $-\infty$. To do this, I believe limits are applied to constants for the endpoints: the upper bound is $\beta$, the lower bound is $\alpha$, and:

$$\frac{a^2}{\pi a^2} \left(\lim_{\beta \rightarrow \infty} \left(\arctan{\frac{\beta}{a}}\right) - \lim_{\alpha \rightarrow -\infty} \left(\arctan{\frac{\alpha}{a}}\right)\right)$$

Again, this gives +1 if $a>0$, and -1 if $a<0$, since arctan(x/a) changes sign if $a$ changes sign.

I'm guessing it is at this point that I can re-introduce the limit for $a \rightarrow 0^{\pm}$. As $a \rightarrow 0^{\pm}$, $\frac{1}{a} \rightarrow \pm\infty$; For $\frac{x}{a}$, both $x$ and $a$ want to take the value to either positive or negative infinity. For $a \rightarrow 0^{+}$, $\frac{\beta}{a} \rightarrow \infty$ and $\frac{\alpha}{a} \rightarrow -\infty$; and for $a \rightarrow 0^{-}$, $\frac{\beta}{a} \rightarrow -\infty$ and $\frac{\alpha}{a} \rightarrow \infty$. Therefore:

$$\lim_{a \rightarrow 0^{+}} \left( \frac{a^2}{\pi a^2} \left(\lim_{\beta \rightarrow \infty} \left(\arctan{\frac{\beta}{a}}\right) - \lim_{\alpha \rightarrow -\infty} \left(\arctan{\frac{\alpha}{a}}\right)\right) \right) = \frac{a^2}{\pi a^2} \left(\frac{\pi}{2} - \frac{-\pi}{2}\right) = \frac{a^2}{\pi a^2} \left(\frac{\pi}{2} + \frac{\pi}{2}\right) = 1$$

or

$$\lim_{a \rightarrow 0^{-}} \left( \frac{a^2}{\pi a^2} \left(\lim_{\beta \rightarrow \infty} \left(\arctan{\frac{\beta}{a}}\right) - \lim_{\alpha \rightarrow -\infty} \left(\arctan{\frac{\alpha}{a}}\right)\right) \right) = \frac{a^2}{\pi a^2} \left(\frac{-\pi}{2} - \frac{\pi}{2}\right) = -1$$

Okay, in both cases - either substituting back or not - I get the same results. However, as mentioned earlier, the limit is different from both sides for the limit of $a$; this means I would have to explicitly state the direction for it to be meaningful, but the limit still exists. Is this in any way accurate?

The other question concerns an alternative solution to the integral. Wolfram Alpha churns out:
$$a \sqrt{\frac{1}{a^2}}$$
It's also possible to see from this how the direction of the limit for $a$ affects the value, being 1 or -1. Does anyone know how wolfram got this solution?

Any help appreciated.

Last edited: Sep 7, 2012
2. Sep 7, 2012

### susskind_leon

Your result seems correct to me.
I'm guessing Wolfram has tables with definite integrals such as int 1/(x^2+1)=pi
Since you want further proof that your answer is correct, here are two things you can do:
- substitute y=x/|a| first. the modulus of a makes sure that you don't have to swap your upper and lower bound in the integral. this reduces your expression to the standard cauchy distribution one times a*|a|/a^2=sgn(a).
- if you want an entirely alternative proof, you can try contour integration.
http://en.wikipedia.org/wiki/Method...xample_.28II.29_.E2.80.93_Cauchy_distribution
You can see that depending on the nominator's sign, you only enclose one of the two singularities.

3. Sep 11, 2012

### nobahar

Hi susskind, thanks for the response.
Phew, all those limits and infinities hurt my brain, good to see it worked out in the end!
Ihave never seen the signum function before - it doesn't look that familiar, anyway. When you use the y = x/|a| substitution, is the following correct?:

$$\frac{a}{\pi(x^{2}+a^{2})} = \frac{sgn(a)|a|}{\pi|a|^{2}}\frac{1}{(y^{2}+1)}$$

and therefore, using |a|dy = dx:

$$\frac{sgn(a)|a|^{2}}{\pi|a|^{2}}\int_{-\infty}^{\infty}\frac{1}{(y^{2}+1)}dy = sgn(a)$$

I don't know what this means! Your assertion that my results are accurate and your method of using sgn(a) is sufficient for me at this point.
Many thanks for all the help!

4. Sep 11, 2012

### susskind_leon

You got it, dude, because $a=sgn(a)*|a|$
This is probably the quickest way if you already know that $\int_{-\infty}^\infty \frac{1}{1+x^2}dx=\pi$

5. Sep 11, 2012

### nobahar

Thaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaankyoooooooouuuuuuuuuuuuuuuuuu!!!!!!!!!

6. Sep 11, 2012

### susskind_leon

You're weeeeeeeeeeeeeeeeeelcooooooooooooooooooooooome ;-)