Laplace transform of hitting time of Brownian motion with drift I have the process $X_t = W_t + \mu t$ where $W_t$ is Brownian motion and $\mu\in\mathbb{R}$. I also have the hitting time
$$\tau = \inf\{t\geq 0: X_t = a \text{ or } X_t = b \}$$
where $a < 0 < b$. 
I want to compute $E[e^{-\lambda\tau}]$ for arbitrary $\lambda > 0$.
I suppose one way to do that is switch to the measure under which $X_t$ is Brownian motion but that would lead to an integral involving the joint distribution of Brownian motion, its running maximum and minimum. I want to avoid that path and instead find a martingale-based technique.
Following the technique in a similar case where the hitting time is defined in terms of a single boundary (not two), I defined
$$M_t := e^{\theta X_t - \lambda t}$$
for $\theta$ chosen to make $M$ a martingale. This function turned out to be not restrictive enough for my purposes as it only got me so far as to compute the probability that one boundary is hit before the other.
Then, I looked at the case where hitting time is defined in terms of two boundaries for Brownian motion with no drift. In that case, the martingale to work with is
$$M_t = f(t)\cosh\left(\theta W_t - \theta\frac{a+b}{2}\right)$$
for some $f(t)$ chosen to make $M$ a martingale.
Unfortunately, defining $$M_t = f(t)\cosh\left(\theta X_t - \theta\frac{a+b}{2}\right)$$ does not get me far as this cannot be a martingale by any choice of a deterministic function $f$.
So it seems like what I need is some function that only contains $X$ (and some constants) and evaluates to the same known value at both boundaries. Furthermore, this function should probably be monotonic (or bounded) so that I can apply an appropriate convergence theorem. I can multiply this function by another deterministic function (or add them together but nothing too involved) to make the resulting process a martingale. This is where I am at. Any tips on how to proceed from this point on or different approaches are appreciated.
I think I have found the process to work with. I define
$$M_t = f(t)e^{\mu X_t}\sinh\left(\theta X_t - \alpha\right)$$
I can make $M$ a martingale by a suitable choice of $\theta$ and $f$. By choosing $\alpha$ appropriately I can make it behave nicely at the barriers. I will post it an answer if this works.
 A: I think you can solve this via Markov chain techniques. Let $X$ and $\tau$ be as given (or more generally $X$ can be any elliptic diffusion). Denote the generator of $X$ as $L_X$. Define a function $f:[a,b] \to \Bbb R$ by sending $x \mapsto E_x[e^{-\lambda \tau}].$ We claim that $f$ satisfies an ODE: $L_X f- \lambda f=0$ on $[a,b]$, with boundary conditions $f(a)=f(b)=1$.
To prove this, we define a new state space $S=[a,b] \cup \{(*)\}$, where $(*)$ is a "death state" disjoint from $[a,b]$. We define the $S$-valued Markov process $X'_t:=X_t \cdot 1_{\{t < \tau\}} + (*)\cdot 1_{\{t \geq \tau\}}$. In other words, the process $X'$ is just the process $X$ which is "killed" upon hitting the boundary. This new process has a generator $L$ which is just $L_X$ with Dirichlet boundary conditions at $\{a,b\}$. We denote by $S(t)$ the associated semigroup.
Before proving the claim, let us recall the notion of resolvents: for $\lambda>0$, one has a bounded operator $R_{\lambda}: C(S) \to C(S)$ given by $R_{\lambda}f = (\lambda I-L)^{-1}f = \int_0^{\infty} e^{-\lambda t} S(t)f \;dt.$
Next, we make the simple observation that for any random variable $Y$ supported on $[a,b]$ and any $C^1$ function $u$, it holds (by Fubini's theorem) that $E[u(Y)] = u(a)+ \int_a^b u'(y) P(Y \geq y)dy$. Consequently, we have the following for all $x \in S$: $$f(x)-1 = E_x[e^{-\lambda \tau}] -1 = -\int_0^\infty \lambda e^{-\lambda x} P_x(\tau \geq t) dt \\= -\int_0^\infty \lambda e^{-\lambda x} P_x(X'_t \in [a,b]) dt =-\int_0^\infty \lambda e^{-\lambda x} S(t)1_{[a,b]}(x) dt= -\lambda R_{\lambda} (1_{[a,b]})(x).$$ This shows that $f-1=-\lambda R_{\lambda}(1_{[a,b]})$ is in the domain of $L$. Now taking $\lambda I -L$ of both sides, we find that $(\lambda-L)(f-1) = -\lambda \cdot 1_{[a,b]}$, which indeed shows that $\lambda f-L_X f=0$ on $[a,b]$, thus proving the claim.
In this specific case $(X_t=B_t+\mu t)$, we have $L_X=\frac{1}{2}\partial_x^2+\mu \partial_x$. Consequently, $f$ satisfies the ODE $f''+2\mu f'-2\lambda f=0$ on the interval $(a,b)$. This can be solved as $$f(x) = e^{-\mu x} \big( c_1 e^{\sqrt{\mu^2+2\lambda}\;x} +c_2e^{-\sqrt{\mu^2+2\lambda}\;x} \big),$$where $c_1,c_2$ may be determined by the boundary conditions $f(a)=f(b)=1$.
A: Define
$$M_t = f(t)e^{-\mu X_t}\sinh\left(\theta X_t - \alpha\right)$$
Then by Ito's lemma it follows that
\begin{align}
dM_t = Y_tdt + Z_tdW_t
\end{align}
where
\begin{align}
Y_t &= f'(t)e^{-\mu X_t}\sinh\left(\theta X_t - \alpha\right) -\mu^2f(t)e^{-\mu X_t}\sinh\left(\theta X_t - \alpha\right) + \mu\theta f(t)e^{\mu X_t}\cosh\left(\theta X_t - \alpha\right) + \, ... \\
&+ \frac{1}{2}f(t)\mu^2f(t)e^{-\mu X_t}\sinh\left(\theta X_t - \alpha\right) -\frac{1}{2}f(t)\mu\theta f(t)e^{-\mu X_t}\cosh\left(\theta X_t - \alpha\right) + \, ... \\ &- \frac{1}{2}f(t)\mu\theta f(t)e^{-\mu X_t}\cosh\left(\theta X_t - \alpha\right) + \frac{1}{2}f(t)\theta^2 f(t)e^{-\mu X_t}\sinh\left(\theta X_t - \alpha\right)
\end{align}
It does not really matter what $Z_t$ is. The terms with $\cosh$ in $Y_t$ drop out so we are left with
\begin{align}
Y_t &= e^{-\mu X_t}\sinh\left(\theta X_t - \alpha\right)\left(f'(t)-\frac{1}{2}(\mu^2-\theta^2)f(t)\right)
\end{align}
For convenience assume $f(0) = 1$. Then by choosing $f(t) = e^{-\frac{1}{2}(\theta^2-\mu^2)t}$, we get $Y_t \equiv 0$ and hence $M_t$ becomes a martingale.
The next thing to do is to find $\alpha$ such that 
$$e^{-\mu X_\tau}\sinh\left(\theta X_\tau - \alpha\right)$$
is deterministic. Stated otherwise, we solve for $\alpha$ in the following equality.
$$e^{-\mu a}\sinh(\theta a - \alpha) = e^{-\mu b}\sinh(\theta b - \alpha)$$
This equality is equivalent to
$$e^{2\alpha} = \frac{e^{(\theta-\mu)b} - e^{(\theta-\mu)a}}{e^{-(\theta+\mu)b} - e^{-(\theta+\mu)a}}$$
To make sure $\alpha$ has a real solution I insist
$$\theta > \mu \qquad \theta > -\mu $$
This is equivalent to $\theta > \lvert \mu\rvert$. Based on the expression for $f(t)$ we will also need $\lvert\theta\rvert > \lvert \mu\rvert$ to be able to talk about Laplace transform. For any given $\mu$ it is possible to choose $\theta$ such that $\theta > \lvert \mu\rvert$, which in turn implies $\lvert\theta\rvert > \lvert \mu\rvert$. So we are pretty much done.
Finally, we now stop $M_t$ at $\tau$. Then for some constant $C$ we have
$$\lvert M_{\tau \wedge t}\rvert \leq C$$
By the dominated convergence theorem we get
$$\sinh(-\alpha) = E[e^{-\frac{1}{2}(\theta^2-\mu^2)\tau}]e^{-\mu a}\sinh(\theta a - \alpha)$$
This is essentially the answer. I will clean up the final answer later to get a nicer looking expression.
