Consider $B=(B_t)_{t\geq 0}$ a real $\mathcal F_t$ - brownian motion starting at zero, in a probability space $(\Omega, \mathcal F, (\mathcal F_t)_{t\geq 0}, \mathbb P)$. Then, consider for $a,\ b \ \in \mathbb R, \ a< b$, the following sequence of stopping times
\begin{align} T_1 &= \inf\{t\geq 0 : B_t =a\}, \quad T_2 = \inf\{t> T1 : B_t =b\}, \\ T_{2k+1} &= \inf\{t> T_{2k} : B_t =a\}, \quad T_{2k+2} = \inf\{t> T_{2k+1} : B_t =b\}. \end{align}
I was interested in showing that the random variables $(Z_k, \ k \in \mathbb N)$ following defined are independent and have same distribution.
$$Z_k := \int_{T_{2k+1}}^{T_{2k+2}}f^2(B_s) ~ds$$ with $f\in \mathcal C ^0(\mathbb R,\mathbb R)$ and $f \not\equiv 0$.
I have tried to explore the strong Markov property but I had some difficult to deal with this approach and so to conclude it. However I believe being in the right way to solve it.
Could someone give me an advice on that problem, please? Thank's in advance.
Crossposted on overflow
Hint: Can you show or is it clear to you that each $Z_k$ is distributed as $$ \zeta=\int_0^\tau f^2(a+W_t)\mathrm dt, $$ where $(W_t)$ is a standard Brownian motion starting from $W_0=0$ and $\tau$ is the first hitting time of $b-a$ by $W$, that is, $\tau=\inf\{t\geqslant0\mid W_t=b-a\}$?
Once you are done with this part, the independence property stems from the fact that each $Z_k$ is measurable with respect to $$ \mathcal G_k=\sigma(B_{T_{2k+1}+t};0\leqslant t\leqslant T_{2k+2}-T_{2k+1}), $$ and that the sigma-algebras $(\mathcal G_k)$ are independent. Another take on this is to consider $$ \zeta^k_t=B_{T_{2k+1}+t}-a, $$ and to show that the processes $(\zeta^k_t)_{0\leqslant t\leqslant T_{2k+2}-T_{2k+1}}$ are independent and distributed as $(\zeta_t)_{0\leqslant t\leqslant\tau}$.