In a markov process a random walker has to reach N (absorbing boundary) from $x_o$ on a $[0,N]$ lattice, where $0$ is the reflecting boundary. To find the first exit time of the random walker via N, i use the following equation ($mean = 0$) $$ \frac{d^2T}{dx^2} = -\frac{2}{D} $$ with boundary and initial conditions as $$ 1) T|_{x=N} = 0 \ \ \ 2) \frac{dT}{dx} |_{x=0} = 0 $$ but now I have a trap in between and it acts as a temporary absorbing point. So whenever the random walker visits the trap it gets absorbed by it and after $\tau$ times in trap, the random walker will be released again on the lattice. The process stops when random walker hits the absorbing boundary,N.
So is there way to solve it for the first exit time?
Thank you.