I'm trying to solve the following problem. Consider the random walk on the integers. At zero the probability to go right is $1/2$ and the probability to go left is $1/2$. Everywhere else going to the right has probability $p$ and going to the left has probability $1-p$. I want to find the probability of ever returning back to zero if the random walk starts at zero.
My solution:
We know random walk is markov chain, so call it markov chain $(X_n)_{n\geq 0}$. Let's define the probability of ever returning to $i$ if the random walk starts in $i$ as $f_{ii}$ and $f_{ii}^n$ as returning to $i$ with exactly $n$ steps while $X_k\neq i$ if $0<k<n$. In this random walk there is only returning back with even number of steps, so $f_{ii}^{2n+1}=0$. Clearly:
\begin{align} f_{00} = \sum\limits_{k=1}^{\infty} f_{00}^{2k} \end{align}
The first term: \begin{align} f_{00}^{2}=p_{0,1} \cdot p_{1,0} + p_{0,-1}\cdot p_{-1,0} = \frac{1}{2} (1-p) + \frac{1}{2} p = \frac{1}{2} \end{align}
For the next terms we have something like (I dont write it down in formal way, because I want to know if the idea is right): \begin{align} \sum\limits_{k=2}^{\infty} f_{00}^{2k} = p_{0,1} \cdot \mathbb{P}(\text{Ever returning to 1 without going less than 1} | X_1 = 1)\cdot p_{1,0}+ p_{0,-1} \cdot \mathbb{P}(\text{Ever returning to -1 without going greater than -1} | X_1 = -1) \cdot p_{-1,0} \end{align} And that is equal to: \begin{align} \frac{1-p}{2} \mathbb{P}(\text{Ever returning to 1 without going less than 1} | X_1 = 1) + \frac{p}{2} \mathbb{P}(\text{Ever returning to -1 without going greater than -1} | X_1 = -1) \end{align} If the random walk is at $1$ and has positive number of steps left before returning to $0$, then the random walk can do whatever it "wants" as long as it stays to the right side of 1. And when it eventually returns to 1 then it must take one step to the left to reach 0. The same holds for $-1$. I know $\mathbb{P}(\text{Ever returning to 1 without going less than 1} | X_1 = 1)$ is like the probability of ever returning to 1 in one-sided random walk and that is equal to: $\frac{1}{2}(1-|2p-1|)$. The same holds for $\mathbb{P}(\text{Ever returning to -1 without going greater than -1} | X_1 = -1)$ because of symmetry.
So I end up with: \begin{align} f_{00}= \frac{1}{2}+\left(\frac{1-p}{2}+\frac{p}{2}\right)\cdot \frac{1}{2}(1-|2p-1|) = \frac{3}{4}-\frac{1}{4} |2p-1| \end{align}
Question: I know this is wrong, because that must be 1 when $p=\frac{1}{2}$ (recurrent random walk). However that is not the case with my solution. Can you guys tell me where I went wrong? Thanks!