Paths and Probabilities for a Random Walk on a Graph
You can make a state machine from this as follows. 

Let the set of points generated be $V$. 

Add extra dummy start node $s$. Add edges $(s, v)$ for all $v \in V$. And add edge 
from $(u, v)$ where $u, v \in V$ are nearest neighbors. 

Assuming points to visit are chosen uniformly assign probability $1/|V|$ to edges $(s,v)$ 
and probability of $1/\text{number of nearest neighbors}$ to edges that connect nearest neighbors. 

This now forms a state diagram like http://en.wikipedia.org/wiki/Markov_chain#Example

The graph can be represented as matrix $G$ where $G_{ij} =1$ if there is edge between $i$ and $j$. 
And probabilities can be put in a matrix $P$ of size $N + 1 \times N + 1$. 

$G^k_{ij}$ gives number of paths of length $k$ from $i$  to $j$. 

$(P^k x)_j$ gives probability of reaching $j$ from $i$ in $k$ steps where $x$ is a vector where only $i^{th}$ entry is 1 and others are 0.