# Density of first hitting time of Brownian motion with drift

I just started learning about Brownian motion and I am struggling with this question:

Suppose that $X_t = B_t + ct$, where $B$ is a Brownian motion, $c$ is a constant. Set $H_a = \inf \{ t: X_t =a \}$ for $a >0$. Show that for $c \in \mathbb{R}$, the density of $H_a$ is $$f_{H_a} (t) = \frac{ a \exp \Big\{ \frac{- (a-ct)^2}{2t} \Big\} }{\sqrt{2 \pi t^3}}.$$

• Do you know the reflection principle? – saz Dec 6 '14 at 7:11
• @saz I have heard of that, but haven't formally learnt that. Do you mind teaching me how to apply this? – Richard Dec 6 '14 at 12:15
• No, I don't mind, but since my proof is rather involved I'll wait a bit and see if someone else has a better idea. Is this an exercise from a book? – saz Dec 6 '14 at 12:49
• Yes. From a book written by Prof. Chris Rogers. – Richard Dec 6 '14 at 12:55

For $c=0$ this result is knows as reflection principle (see e.g. René Schilling/Lothar Partzsch: Brownian Motion - An Introduction to Stochastic Processes, Chapter 6) and follows from the Markov property and symmetry of Brownian motion. However, for $c>0$ the proof is more involved since we have to get rid of the drift term.

Since by definition

$$[H_a \leq t] = \left[ \sup_{s \leq t} X_s \geq a \right] \tag{1}$$

determining the distribution of $H_a$ is equivalent to finding the distribution of $\sup_{s \leq t} X_s$. In order to find the distribution of the latter, we need two ingredients: Girsanov's theorem and the joint distribution $(X_t,\sup_{s \leq t} X_s)$ for a Brownian motion $(X_t)_{t \ge 0}$.

Girsanov theorem: Let $c \in \mathbb{R}$ and $(B_t)_{t \geq 0}$ be a Brownian motion on a probability space $(\Omega,\mathcal{A},\mathbb{P})$. Then $$X_t := B_t+ct, \qquad t \leq T,$$ is a Brownian motion with respect to the probability measure $$d\mathbb{Q} := d\mathbb{Q}_T := \exp \left( -c B_T - \frac{c^2}{2} T \right) d\mathbb{P}.$$

For a proof see e.g. René Schilling/Lothar Partzsch: Brownian Motion - An Introduction to Stochastic Processes, Chapter 18.

Joint distribution of $(X_t, \sup_{s \leq t} X_s)$: Let $(X_t)_{t \geq 0}$ be a Brownian motion on a probability space $(\Omega,\mathcal{A},\mathbb{Q})$. Then the joint distribution $(X_t,\sup_{s \leq t} X_s)$ equals $$\mathbb{Q} \left[ X_t \in dx, \sup_{s \leq t} X_s \in dy \right] = \frac{2 (2y-x)}{\sqrt{2\pi t^3}} \exp \left(- \frac{(2y-x)^2}{2t} \right) 1_{[-\infty,y]}(x) \, dx \, dy. \tag{2}$$

For a proof see e.g. René Schilling/Lothar Partzsch: Brownian Motion - An Introduction to Stochastic Processes, Exercise 6.8 (there are full solutions available on the web).

So let's finally put it all together: It follows from $(1)$ and the definition of the probability measure $\mathbb{Q}_T$ that

\begin{align*} \mathbb{P}[H_a \leq T] &= \mathbb{P} \left[ \sup_{s \leq T} X_s \geq a \right] = \int 1_{[a,\infty)} \left( \sup_{s \leq T} X_s \right) \, d\mathbb{P} \\ &= \int 1_{[a,\infty)}\left( \sup_{s \leq T} X_s \right) \exp \left( c B_T + \frac{c^2}{2} T \right) \, d\mathbb{Q}_T \\ &= \int 1_{[a,\infty)}\left( \sup_{s \leq T} X_s \right)\exp\left(c X_T- \frac{c^2}{2} T \right) \, d\mathbb{Q}_T. \end{align*}

By Girsanov's theorem, $(X_t)_{t \leq T}$ is a Brownian motion with respect to $\mathbb{Q}_T$ and therefore $(2)$ gives

\begin{align*} \mathbb{P}[H_a \leq T] &= \exp\left(- \frac{c^2}{2} T \right) \int_{y \geq a} \int_{x \leq y} e^{cx} \frac{2 (2y-x)}{\sqrt{2\pi T^3}} \exp \left(- \frac{(2y-x)^2}{2T} \right) \, dx \, dy. \end{align*}

It remains to calculate the integral expression. First of all, by Fubini's theorem,

\begin{align*} \mathbb{P}[H_a \leq T] &= \frac{1}{\sqrt{2\pi T}} \exp \left(- \frac{c^2}{2} T \right) \left(\int_{x \geq a} e^{cx} I_1(x) \, dx + \int_{x \leq a} e^{-cx} I_2(x) \, dx \right) \\ &:=J_1+J_2 \tag{3} \end{align*}

where

\begin{align*} I_1(x):= \int_{y \geq x} \frac{2(2y-x)}{T} \exp \left(- \frac{(2y-x)^2}{2T} \right) \, dy &= \left[ - \exp \left(- \frac{(2y-x)^2}{2T} \right) \right]_{y=x}^{\infty} \\ &= \exp \left(- \frac{x^2}{2T} \right) \\ I_2(x) := \int_{y \geq a} \frac{2(2y-x)}{T} \exp \left(- \frac{(2y-x)^2}{2T} \right) \, dy &=\exp \left(- \frac{(2a-x)^2}{2T} \right). \end{align*}

Hence, \begin{align*} J_1 &= \frac{1}{\sqrt{2\pi T}} \exp \left(- \frac{c^2}{2} T \right) \int_{x \geq a} e^{cx} I_1(x) \, dx \\ &= \frac{1}{\sqrt{2\pi T}} \int_{x \geq a} \exp \left(- \frac{(x-cT)^2}{2T} \right) \, dx \\ &= \frac{1}{\sqrt{\pi}} \int_{z \geq \frac{a-cT}{\sqrt{2T}}} \exp(-z^2) \, dz \tag{4} \end{align*}

and

\begin{align*} J_2 &= \frac{1}{\sqrt{2\pi T}} \exp \left(- \frac{c^2}{2} T \right) \int_{x \leq a} e^{cx} I_2(x) \, dx \\ &\stackrel{u:=2a-x}{=} \frac{1}{\sqrt{2\pi T}} \exp \left(- \frac{c^2}{2} T \right) \int_{u \geq a} e^{c(2a-u)} \exp\left(-\frac{u^2}{2T} \right) \, du \\ &=\ldots = \frac{e^{2ac}}{\sqrt{\pi}} \int_{z \geq \frac{a+CT}{\sqrt{2T}}} \exp(-z^2) \, dz. \tag{5} \end{align*}

Now if we differentiate $(3)$ with respect to $T$, using $(4)$ and $(5)$, we get

\begin{align*} \frac{d}{dT} \mathbb{P}(H_a \leq T) &= \frac{-1}{\sqrt{\pi}} \exp \left( - \frac{(a-cT)^2}{2T} \right) \left( \frac{-c}{\sqrt{2T}} - \frac{a-cT}{2 \sqrt{2} T^{3/2}} \right) \\ &\quad + \frac{-1}{\sqrt{\pi}} \underbrace{e^{2ac} \exp \left( - \frac{(a+cT)^2}{2T} \right)}_{\exp(-(a-cT)^2/2T)} \left( \frac{c}{\sqrt{2T}} - \frac{a+cT}{2 \sqrt{2} T^{3/2}} \right) \\ &= \frac{a}{\sqrt{2\pi T^3}} \exp \left(- \frac{(a-cT)^2}{2T} \right). \end{align*}

• We know that under the new measure $\mathbb{Q}$, the density is $f^{\mathbb{Q}}_{H_a} (x) = \frac{ a \exp \{\frac{-a^2}{2x} \} }{\sqrt{2 \pi x^3}}$. But by definition, for any Borel set $A$, $\mathbb{Q} (H_a \in A) = \mathbb{E}^{\mathbb{P}} [ \exp \{ c B_T - \frac{c^2}{2} T \} \mathbf{1}_{A} (H_a) \} ]$. If we could evaluate this expectation ( in terms of $f^{\mathbb{P}}_{H_a} (x)$), then the result follows. – Richard Dec 7 '14 at 15:58
• @Richard You are right. I calculated the expectation using the joint density. If you find an easier way to calculate this stuff, then let me know... – saz Dec 7 '14 at 16:02
• Thanks for your detailed working. If you have time, can you please have a look at one of my questions with a bounty. I worked out quite some bits already, but the answer deviates from mine a little bit. math.stackexchange.com/questions/1050319/… – Richard Dec 8 '14 at 18:07
• @saz You assume that $c>0$. Do you know if a similar result holds for the density of the measure $P(H_a \in dt ; H_a < \infty)$ for $c<0$? Many thanks. – Frank Oct 5 '16 at 13:36
• @user657324 For $X_t= \alpha B_t+\lambda t + \mu$ it should work, I think. I'm, however, not aware of more general results for solutions to SDEs. – saz Jun 12 at 6:02

There is a trick for this one, which alleviates you of having to use the joint distribution of $B_t$ and $\sup B_t$:

Start with using Girsanov to construct a change of measure $$\frac{d\mathbb Q}{d \mathbb P}\bigg|_{\mathcal F_t} =\exp(c B_t -\frac{1}{2}c^2t)$$ so that $$\hat B_t = B_t -c t \qquad (=X_t)$$ is a $\mathbb Q$-BM. Denote by $\mathbb P(H_a \in dt)$ the probability of $H_a$ being in some infinitesimal interval. We have $$\mathbb P(H_a \in dt) = \mathbb E_{\mathbb P}[1_{H_a \in dt}] = \mathbb E_{\mathbb Q} \left[ \left(\frac{d\mathbb Q}{d \mathbb P}\bigg|_{\mathcal F_t} \right)^{-1}1_{H_a \in dt} \right] = \mathbb E_{\mathbb Q} \left[ \exp\lbrace-c B_t +\frac{1}{2}c^2t\rbrace 1_{H_a \in dt} \right] \\ = \mathbb E_{\mathbb Q} \left[ \exp\lbrace-c \hat B_t -\frac{1}{2}c^2t\rbrace 1_{H_a \in dt} \right]$$ Now the trick: Instead of invoking the joint density, notice that for $H_a \in dt$ we have that $\hat B_t = a$ since it is continuous. So the above is equal to $$= e^{-c a -\frac{1}{2}c^2t}\mathbb Q ( H_a \in dt )$$ That probability is simply the density of the hitting time of a standard brownian motion (since $X_t$ is driftless in $\mathbb Q$), which is know: Define $H^B_a = \inf \lbrace u:B_u \geq a \rbrace$ $$\mathbb P(H^B_a \in dt) = \frac{a}{\sqrt{2 \pi t^3}} e^{-a^2/(2t)} dt$$ So $$\mathbb P(H_a \in dt) = e^{-c a -\frac{1}{2}c^2t}\frac{a}{\sqrt{2 \pi t^3}} e^{-a^2/(2t)} dt = \frac{a}{\sqrt{2 \pi t^3}} e^{-(a-ct)^2/(2t)} dt$$

I will also use slightly different notation. The solution presented here uses the PDE approach to solve this problem and does not need the Girsanov theorem or the Joint distribution.

Theorem : Let the arithmetic Brownian motion process $$X \left(t\right)$$ be defined by the following Brownian motion driven SDE $$$$\mbox{d}X \left(t\right) = \mu \mbox{d}t + \sigma \mbox{d}{W}\left(t\right).$$$$ with initial value $$X_0$$. Let $$\tau =\inf \left(u |X(u) \le B\right)$$ denote the first passage time for the barrier $$X_0 < B$$. Then the first passage time $$\tau$$ is distributed as Inverse Gaussian Distribution $$$$\tau \sim IG\left(\frac{B - X_0}{\mu}, \frac{\left(B - X_0\right)^2}{\sigma^2}\right),\label{abmFirstPassageDist}$$$$ and for $$t > 0$$ the pdf of $$\tau$$ is $$$$f(t) = \sqrt{\frac{(B - X_0)^2}{2 \pi \sigma^2 t^3}} \exp\left[-\frac{ \left(\mu t - B + X_0\right)^2}{2 \sigma^2 t}\right]\label{abmFirstPassageDensity}.$$$$

Proof: The Kolmogorov Forward Equation corresponding to the SDE is $$$$\frac{\partial p\left(x, t\right)}{\partial t} = -\mu \frac{\partial p\left(x, t\right)}{\partial x} + \frac{1}{2} \sigma^2 \frac{\partial^2 p\left(x, t\right)}{\partial x^2}.$$$$ To obtain the survival probability function, we first solve this PDE with the following initial and boundary value conditions $$$$p\left(x, 0\right) = \delta\left(x - x_0\right); \qquad p\left(\infty, t\right) = p\left(x = B, t\right) = 0 \qquad (t > 0)\nonumber$$$$ where $$x = x_0$$ is the starting point of the diffusive process, containing the initial concentration of the distribution and $$B > x_0$$ denotes the barrier.

This BVP can be solved using the standard method of images technique.

The free-space fundamental solution (Green’s function) of this PDE is $$$$\phi\left(x, t\right) = \frac{1}{\sqrt{2\pi \sigma^2 t}}\, \exp\left[{-\frac{\left\lbrack x - \mu t \right\rbrack^{2}}{2\sigma^2 t}}\right]$$$$ hence, given initial condition the normalized solution for an unrestricted process, starting from $$x_0$$ can be obtained as

$$$$\phi_{x_0}\left(x, t\right) = \frac{1}{\sqrt{2\pi \sigma^2 t}}\, \exp\left[{-\frac{\left\lbrack x - \mu t - x_0\right\rbrack^{2}}{2\sigma^2 t}}\right]$$$$

To solve this problem with the method of images, the barrier at $$B$$ is replaced by a mirror source located at a generic point $$x = m$$, with $$m > B$$ such that the solutions of equation emanating from the original and mirror sources exactly cancel each other at the position of the barrier at each instant of time. This implies the initial conditions in must now be changed to $$$$\qquad p\left(x, 0\right) = \delta\left(x - x_0\right) - \exp\left(- \eta\right)\delta\left(x - m\right),\nonumber$$$$ where $$\eta$$ determines the strength of the mirror image source. Due to the linearity of the PDE, a solution of this BVP is provided by $$$$\qquad p\left(x, t\right) = \phi_{x_0}\left(x, t\right) - \exp\left(- \eta\right)\phi_{m}\left(x, t\right), \tag{1}$$$$ where $$\eta$$ determines the strength of the mirror image source and $$m > B$$ is the location of this source.

The boundary condition requires for $$x = B$$, $$p\left(x, t\right) = 0$$ for all $$t > 0$$, which yields $$\begin{eqnarray} \nonumber \frac{\left\lbrack x - \mu t - x_0 \right\rbrack^{2}}{2 \sigma^2 t} &=& \eta + \frac{\left\lbrack x - \mu t - m\right\rbrack^{2}}{2 \sigma^2 t} \\ \Leftrightarrow\;\; \left\lbrack x - \mu t - x_0\right\rbrack^{2} &=& 2 \eta \sigma^2 t + \left\lbrack x - \mu t - m\right\rbrack^{2}. \tag{2} \end{eqnarray}$$ Upon substituting $$x = B$$ and $$t = 0$$, we get $$$$\left\lbrack B - x_0 \right\rbrack^{2} = \left\lbrack B - m\right\rbrack^{2}\nonumber$$$$ upon recalling $$m > b$$, we see that $$m = 2 B - x_0$$. Upon resubstituting the value of $$m$$ and $$x = B$$ in equation $$(2)$$ we obtain $$\eta = \frac{2 \mu (x_0 - B)}{\sigma ^2}$$. With these choices of $$m$$ and $$\eta$$, $$(1)$$ gives the solution of the BVP as $$\begin{eqnarray}\label{p(x,t)} p\left(x, t\right) &=& \frac{1}{\sqrt{2\pi \sigma^2 t}}\, \left\{\exp\left[{-\frac{\left\lbrack x - \mu t - x_0\right\rbrack^{2}}{2\sigma^2 t}}\right] - \exp\left[-\frac{2 \mu (x_0 - B)}{\sigma ^2}\right] \exp\left[{-\frac{\left\lbrack x - \mu t - 2 B + x_0\right\rbrack^{2}}{2\sigma^2 t}}\right]\right\}. \end{eqnarray}$$

Under the condition $$B > x_0$$, the survival probability can be obtained as $$\begin{eqnarray}\nonumber S(t) &=& \int_{- \infty}^{b } {p\left(x, t\right){\kern 1pt} \,dx} \\\nonumber &=&\frac{1}{2} \left\{\text{erfc}\left[\frac{-B + x_0 + \mu t}{\sqrt{2} \sigma \sqrt{t}}\right] - \exp\left[\frac{2 \mu (B-x_0)}{\sigma ^2}\right] \text{erfc}\left[\frac{B - x_0 +\mu t}{\sqrt{2} \sigma \sqrt{t}}\right]\right\} \end{eqnarray}$$ where $$\text{erfc}\left(z\right)$$ denotes the complementary error function. The first passage density can now be obtained as $$\begin{eqnarray} f\left(t\right) &=& - \frac{\mbox{d} S\left(t\right)}{\mbox{d}t}\\\nonumber &=& \frac{(B - x_0)}{\sqrt{2 \pi } \sigma t^{3/2}} \exp\left[ -\frac{( x_0 - B + \mu t)^2}{2 \sigma ^2 t}\right]. \end{eqnarray}$$ In particular, a Brownian motion with drift $$\mu$$ reaches the level B with probability one if and only if $$\mu$$ and $$B$$ have the same sign and $$B > x_0$$. If $$\mu$$ and $$B$$ have opposite signs, this density is "defective" in the sense that $$\mathbb{P}\left(\tau_B < \infty\right) < 1$$. To put it another way the drift must orient the process towards the barrier, for a non-defective density to exist.

• I don't understand your boundary condition at the begining of the proof. Of for $p(0,t)=\delta (x-x_0)$, but why $p(B,t)=p(\infty ,t)=0$ ? Moreover, if $x_0<B$, why do you need $p(\infty ,t)=0$ ? To finish, can we adpat this method to $B<x_0<\infty$ for the first entrance in $(0,B)$ ? (do you know lecture notes on this kind of subject ?) – user657324 Jun 12 at 19:00

Let's apply the reflection principle more carefully to the Brownian motion with drift.

The events $[H_{a} < t]$ are equivalent to saying that a Brownian particle that starts at time $0$ and ends at time $t$ has crossed the horizontal level $x = a$. Then, the total probability can be written as the sum of two terms $P_{1}$ and $P_{2}$, where

$P_{1}=$ The probability of the path that ends above the level $x = a$ at time $t$, and

$P_{2}=$ probability of the path that ends below the level $x = a$ at time $t$ AND has crossed the level $x = a$ at some time before $t$.

We know the probability distribution of end points $X_t$, is a normal distribution with mean value $ct$ and variance $t$. Thus, it is easy to find the first probability,

$$P_{1} = \int_{a}^{+\infty} dx \frac{1}{\sqrt{2 \pi t}} e^{\frac{(x-ct)^2}{2t}} = N\left(\frac{-a+ct}{\sqrt{t}}\right),$$ where $N(x)$ is the standard normal cumulative distribution function.

The nontrivial $P_{2}$ can be found by invoking a symmetry (reflection principle) in a careful way. The idea is to consider a mirrored Brownian motion starting at $x = 2a$ at $t = 0$ ends at $x$ below $a$ with opposite drift term $-ct$, name $X_t^{'}=2a + B_t -ct$. The application of this idea is not as straightforward as that in the driftless case, but it can be done.

The probability $P_{a}(0,x,t) dx$ of a Brownian particle starting at $0$ ending between the interval $x$ and $x+dx$ at time $t$ that has crossed the level $a$ can be written in words as

$P_{a}(0,x,t) dx =$ Sum over $\tau$ of ( the probability of a Brownian particle starting at $0$ and first reach $a$ at $\tau$ $\times$ the probability of a Brownian particle starting at $a$ and ending between the interval $x$ and $x+dx$ in $t-\tau$ time)

Mathematically, the above sentence is the following equation:

$$P_{a}(0,x,t) = \int_{0}^{t} d\tau P_{\tau}(0,a,\tau) \cdot P_n(a, x, t-\tau)$$

Then, $P_2$ is

$$P_2 = \int_{-\infty}^{a} dx P_{a}(0,x,t)$$

The problem is solved if the $P_{a}(0,x,t)$ is found. This can be found by invoking the symmetry idea we just discussed or by reflection principle in general. The idea is to convert the right hand side of the equation $P_{a}(0,x,t)$ to the mirrored path. The first hitting probability $P_{\tau}(0,a,\tau)$ for a Brownian particle starting at $0$ drift upward (downward if $c<0$) with $ct$ is equal to the first hitting probability $P^{'}_{\tau}(2a,a,\tau)$ for a Brownian particle starting at $2a$ drift downward (upward if $c<0$) with $-ct$, thus $$P_{\tau}(0,a,\tau) = P^{'}_{\tau}(2a,a,\tau)$$ For the probability $P_n(a, x, t-\tau)$, we know its explicit expression, so we just need to rearrange a little bit to let it represent the probability with opposite drift Brownian motion. $$P_n(a, x, t-\tau) = P_n^{'}(a, x, t-\tau) \cdot \frac{P_n(a, x, t-\tau)}{P_n^{'}(a, x, t-\tau)} \\ = P_n^{'}(a, x, t-\tau) \cdot e^{-\frac{(x-a-c(t-\tau))^2-(x-a+c(t-\tau))^2}{2(t-\tau)}} \\ = P_n^{'}(a, x, t-\tau) \cdot e^{2c(x-a)}$$ The key is the factor $e^{2c(x-a)}$ does not depend on $\tau$, which can be pulled out from the integral. Then,

$$P_{a}(0,x,t) =e^{2c(x-a)} \cdot \int_{0}^{t} d\tau P_{\tau}^{'}(2a,a,\tau) \cdot P^{'}_n(a, x, t-\tau) \\ = e^{2c(x-a)} \cdot P^{'}_{a} (2a,x,t)$$ Now, $P^{'}_{a} (2a,x,t) dx$ is the probability of a Brownian particle with $-ct$ drift starting at $2a$ ending between the interval $x$ and $x+dx$ at time $t$ that has crossed the level $a$, remember $x < a$, every path starting at $2a$ and ending at $x$ must cross the level $a$, so $$P^{'}_{a} (2a,x,t) = P^{'}_{n} (2a,x,t) = \frac{1}{\sqrt{2\pi t}}e^{-\frac{(x-2a+ct)^2}{2t}}$$

Therefore $$P_2 = \int_{-\infty}^{a} dx e^{2c(x-a)} P^{'}_{a}(2a,x,t) \\ = \int_{-\infty}^{a} dx e^{2c(x-a)} \cdot \frac{1}{\sqrt{2\pi t}}e^{-\frac{(x-2a+ct)^2}{2t}} \\ = e^{2ac} \cdot \int_{-\infty}^{a} dx \frac{1}{\sqrt{2\pi t}}e^{-\frac{(x-2a-ct)^2}{2t}} \\ = e^{2ac}N\left(\frac{-a-ct}{\sqrt{t}}\right)$$

Put two pieces together, we arrive at the same expression as the most voted answer.

$$P[H_{a} < t] = P_{1} + P_{2} = N\left(\frac{-a+ct}{\sqrt{t}}\right) + e^{2ac}N\left(\frac{-a-ct}{\sqrt{t}}\right)$$

Take derivative with respect to $t$ on $P[H_{a} < t]$, the desired expression is obtained.

• I just made a few typesetting edits to your answer so it was a bit easier on the eyes. – DMcMor Apr 4 '17 at 20:30
• Thanks, I just got registered an account. – Xin Apr 5 '17 at 2:36
• I have a question regarding the FHT when the underlying process follows Brownian motion with zero drift. I have found in wiki that it follows Levy distribution. Can anybody of you help me with the exact idea of this and in finding the pdf, cdf, mean and variance of this type of FHT? Thanks in advance... – Sandipan Karmakar Jun 29 '17 at 12:48