Evaluating $\int_0^t\frac{1}{\sqrt{x^3}} e^{- \frac{(a-bx)^2}{2x}} dx$

266 Views Asked by At

I've been trying to compute the following integral, but I havent been able to. Mathematica gives me an answer, but I would like to know how to get to that answer. For reference, this is the CDF of first time passage of a brownian motion with drift.

$$\int_0^t\frac{1}{\sqrt{x^3}} e^{-\frac{(a-bx)^2}{2x}} dx$$

The answer according to Mathematica is:

$$ \sqrt{\frac{\pi}{2}} \frac{1}{a} \operatorname{erfc}\left(\frac{a - bt}{\sqrt{2t}}\right) + \sqrt{\frac{\pi}{2}} \frac{1}{a} e^{2ab}\operatorname{erfc}\left(\frac{a + bt}{\sqrt{2t}}\right) $$

where $\operatorname{erfc}$ is the complementary error function. I've been trying to solve this for weeks, without any success.
Here's a link to a similar question, but the integrals are from $0$ to $\infty$ which helps, but doesn't lead to an answer.

Hints would be useful as well, since I want to be able to solve this integral.

1

There are 1 best solutions below

5
On BEST ANSWER

$$\mathcal J(a,b)=\int_0^t\frac{1}{\sqrt{x^3}} \exp\left({-\frac{(a-bx)^2}{2x}}\right) dx\overset{\sqrt x\to \frac{1}{x}}=2\int_\frac{1}{\sqrt t}^\infty \exp\left(-\frac12 \left(ax-b/x\right)^2\right)dx$$ $$\frac{d}{db}\mathcal J(a,b)=2\int_\frac{1}{\sqrt t}^\infty \exp\left(-\frac12 \left(ax-b/x\right)^2\right)\left(a-\frac{b}{x^2}\right)dx$$ The reason why we differentiated with respect to $b$ is to produce the additional term of $a-\frac{b}{x^2}$, differentiating w.r.t. $a$ would have added $b-ax^2$ which doesn't really help. Now similarly to the linked integral we will adjust things by using $(ax-b/x)^2=(ax+b/x)^2+4ab$ which yields: $$\frac{d}{db}\mathcal J(a,b)=2e^{2ab}\int_\frac{1}{\sqrt t}^\infty \exp\left(-\frac12 (ax+b/x)^2\right)\left(a-\frac{b}{x^2}\right)dx$$ $$\overset{ax+b/x\to x}=2e^{2ab}\int_{\frac{a}{\sqrt t}+b\sqrt t}^\infty \exp{\left(-\frac{x^2}{2}\right)}dx=2e^{2ab}\sqrt{\frac{\pi}{2}}\operatorname{erfc}\left(\frac{\frac{a}{\sqrt t}+b\sqrt t}{\sqrt 2}\right)$$ $$\mathcal J(a,-\infty)=0\Rightarrow \mathcal J(a,b)=\sqrt{2\pi}\int_{-\infty}^b e^{2ax}\operatorname{erfc}\left(\frac{\frac{a}{\sqrt t}+x\sqrt t}{\sqrt 2}\right)dx$$ $$\overset{IBP}=\frac{\sqrt{\pi}}{\sqrt 2a}e^{2ax}\operatorname{erfc}\left(\frac{\frac{a}{\sqrt t}+x\sqrt t}{\sqrt 2}\right)\bigg|_{-\infty}^b+\frac{\sqrt t}{a}\int_{-\infty}^b e^{2ax}\exp\left(-\frac{(a+xt)^2}{2t}\right)dx$$ $$=\sqrt{\frac{\pi}{2}}\frac{1}{a}e^{2ab}\operatorname{erfc}\left(\frac{\frac{a}{\sqrt t}+b\sqrt t}{\sqrt 2}\right)+\frac{\sqrt t}{a}\int_{-\infty}^b \exp\left(-\frac12\left(x\sqrt{t}-\frac{a}{\sqrt{t}}\right)^2\right)dx$$ $$\overset{x\sqrt t-\frac{a}{\sqrt t}\to -x}=\sqrt{\frac{\pi}{2}}\frac{1}{a}e^{2ab}\operatorname{erfc}\left(\frac{\frac{a}{\sqrt t}+b\sqrt t}{\sqrt 2}\right)+\frac{1}{a}\int^{\infty}_{\frac{a}{\sqrt t}-b\sqrt t}\exp\left(-\frac{x^2}{2}\right)dx $$ $$=\sqrt{\frac{\pi}{2}}\frac{1}{a}\left(e^{2ab}\operatorname{erfc}\left(\frac{\frac{a}{\sqrt t}+b\sqrt t}{\sqrt 2}\right)+\operatorname{erfc}\left(\frac{\frac{a}{\sqrt t}-b\sqrt t}{\sqrt 2}\right)\right)$$