Brownian motion, harmonic functions and the Dirichlet problem I am having trouble understanding one detail of the standard use of Brownian motion to solve the Dirichlet problem,  I will write the statement and proof and then point to the detail I don't understand.  
Let $U$ be a bounded domain in $\mathbb{R}^n$, and let $B_t$ be a Brownian motion in $\mathbb{R}^n$, $\tau_{2}$ be the hitting time of $\partial U$, and let $\phi(x)$ be a continuous function defined on $\partial U$.  The following function is a harmonic function on $U$, $u(x) = \mathbb{E}_x \phi(B_{\tau_{2}})$.  Here is the proof
Let $x\in U$, and let $r$ be small enough that $\partial D(x,r)\subseteq U$.  Let $D(x,r)$ represent the ball of radius $r$ around $x$.  Let $\tau_1$ be the hitting time of $\partial D(x,r)$, by the strong Markov property the process $\tilde{B}_t =  B_{t+\tau_1}-B_{\tau_1}$ is a Brownian motion independent of $\mathcal{F}_{\tau_1}$.  Now let $\tau_2 = \inf\{t>0:B_t\in \partial U\}$.  We show that $u(x)$ satisfies the mean value property,
\begin{align}
u(x) &= \mathbb{E}_x\phi(B_{\tau_2})\\
&= \mathbb{E}_x(\mathbb{E}[\phi(B_{\tau_2})|\mathcal{F}_{\tau_1}])\\
&= \mathbb{E}_x(\mathbb{E}[\phi(B_{\tau_2}-B_{\tau_1}+B_{\tau_1}|\mathcal{F}_{\tau_1}])\\
&= \mathbb{E}_x( \psi(B_{\tau_1}))
\end{align}
Where $\psi(y) = \mathbb{E}_{y} \phi(\tilde{B}_{\tau_2-\tau_1})$, because Brownian motion is rotationally invariant, the distribution of $B_{\tau_1}$ is uniform over the sphere, thus if $\lambda$ is the uniform distribution over the sphere
\begin{align}
u(x) &= \mathbb{E}_x( \psi(B_{\tau_1}))\\
&= \int\limits_{\partial D(x,r)} \mathbb{E}_{y} \phi(\tilde{B}_{\tau_2-\tau_1}) \lambda(dy)
\end{align}
If $\tilde{B}_{\tau_2-\tau_1}$ represents the hitting time of $\partial U$ for each $y$, then this is equal to $\int\limits_{\partial D(x,r)} u(y)\lambda(dy)$, then we are done, however I don't see why  $\tilde{B}_{\tau_2-\tau_1}$ necessarily represents the hitting time of $\partial U$, or maybe I have the proof wrong somewhere else
 A: Given a ball $\bar B_r(x)\subset D$,  consider the stopping time: 
$$\tau = \min\{t\geq 0;~ x+B_t\not\in B_r(x)\}$$ 
and also for each $z\in D$ let $\tau_z = \min\{t\geq 0;~ z+B_t\not\in
D\}$. We introduce two random variables $X_1$ and $X_2$ on the
probability space $(\Omega,\mathcal{F}, \mathbb{P})$ on which the
standard Brownian motion $\{B_t\}_{t\geq 0}$ is defined. The first
random variable is simply: $X_1=x+B_{\tau}$, taking values in the
measurable space $(D, \mathcal{F}_1)$ with the usual $\sigma$-algebra
$\mathcal{F}_1$ of Borel subsets of $D$.  
The second random variable $X_2$ is given by the paths of $B_{\tau+t} -
B_\tau$, almost surely belonging to $E_0=C[0,\infty),
\mathbb{R}^n)$. We make $E_0$ a measurable space by equipping it with
the $\sigma$-algebra $\mathcal{B}(E_0)$ of its Borel subsets with
respect to the topology of uniform convergence on compact
intervals. In fact, $X_2$ takes values in a measurable subset $E$ of
$E_0$, consisting of these $f\in E$ which satisfy:
$f(0)=0$ and $|f(T)|>\mbox{diam} \, D$ for some $T>0$. We name
$\mathcal{F}_2$ the $\sigma$-algebra $\mathcal{B}(E_0)$ restricted to $E$. 
Checking the measurability property of $E$ in $E_0$, as well as
measurability of $X_2$ with respect to $(E,\mathcal{F}_2)$ relies on
observing that $\mathcal{B}(E_0)$ is generated by the countable family
of sets of the type $A_{g,T,r} = \{f\in E_0;~
\|f-g\|_{L^\infty[0,T]}\leq r\}$, where $g$ are polynomials with
rational coefficients, and $T,r>0$ are rationals. 
Now, the crucial observation is that $X_1$ and $X_2$ are
independent. Indeed, $X_1$ is clearly $\mathcal{F}_\tau$-measurable,
whereas $X_2$ is $\mathcal{F}_\tau$-independent. This last statement
is a direct consequence of the strong Markov property for the shifted
Brownian motion $\{B_{\tau+t} - B_\tau\}_{t\geq 0}$ and can be checked
directly on the preimages of sets $A_{g,T,r}$. 
We call $\mu_1$ the push-forward measure of $\mathbb{P}$ via $X_1$
and $\mu_2$ the push-forward of $\mathbb{P}$ via $X_2$.
Thus $(D,\mathcal{F}_1,\mu_1)$ and $(E,\mathcal{F}_2,\mu_2)$ 
are two probability spaces, and the independence of $X_1$ and $X_2$
  is equivalent to the product $\mu_1\times
\mu_2$ equaling the push-forward of $\mathbb{P}$ on $D\times E$
via $(X_1, X_2)$. 
Finally, consider the following random variable on $D\times E$, valued in $\mathbb{R}$:
$$F(z,f) = \varphi\big(z+f(\min\{t\geq 0;~ z+f(t)\not\in D\})\big).$$
We write:
\begin{equation*}
\begin{split}
u(x) & = \mathbb{E}[\varphi(x+B_{\tau_x}] = \mathbb{E}[F\circ (X_1,
X_2)] = \int_{D\times E} F \;d(\mu_1\times\mu_2) \\ & = 
\int_D\int_E F(z,f)\;d\mu_2(f) \;d\mu_1(z)=\int_D \mathbb{E}[F(z,X_2)]\;d\mu_1(z),
\end{split}
\end{equation*}
where we simply used Fubini's theorem. In conclusion:
\begin{equation*}
\begin{split} 
u(x) & = \int_D \varphi(z+B_{\tau_z}) \;d\mu_1(z) = \int_D u(z)
\;d\mu_1(z) \\ & = \mathbb{E}[u\circ X_1] = \mathbb{E}[u(x+B_{\tau})], 
\end{split}
\end{equation*}
as claimed.
