Let the transition matrix $P_{ij}$ represents the probability to move from state $i$ to state $j$.
Now I would like to derive the diffusion tensor for this Markov process.
Since I am not sure how to start for the general case, I am taking a $3 \times 3$ matrix as an example: $$ P = \begin{bmatrix} \frac{1}{2} & \frac{1}{4} & \frac{1}{4} \\ \frac{1}{4} & \frac{1}{2} & \frac{1}{4} \\ \frac{1}{4} & \frac{1}{4} & \frac{1}{2} \\ \end{bmatrix} $$
I can derive the diffusion coefficient $D$ assuming time step $\Delta t$. First we assume a 1D random walk with the probability $0.5$ to stay at the same spot and $0.25$ to move $\pm1 \Delta x$:
$$ \begin{align*} X(x,t+\Delta t)-X(x,t) &= \frac{1}{4} (X(x+\Delta X,t)+ X(x-\Delta X,t)) - \frac{1}{2} X(x,t) \\ &= \frac{1}{4} (X(x-\Delta X,t)+ X(x+\Delta X,t) - 2X(x,t)) \end{align*} $$
Where $X$ is the probability to be at $x$ at time $t$.
When taking the space between $\Delta x \to 0$, $\Delta t \to 0$ and dividing by $\Delta t$:
$$ \frac{X(x,t+\Delta t)-X(x,t)}{\Delta t} = \left(\frac{\Delta x}{\Delta x} \right)^2\frac {\frac{1}{4} (X(x-\Delta X,t)+ X(x+\Delta X,t) - 2X(x,t))}{\Delta t} $$
We get the diffusion equation:
$$ \frac{\partial X}{\partial t} = \frac{(\Delta x)^2}{4 \Delta t} \frac{\partial^2 X}{\partial^2 x} $$
Where $D=\frac{(\Delta x)^2}{4 \Delta t}$
Or back to the discrete case $D=1/4$ in unit less dimensions.
Could I achieve a diffusion tensor for a general $P_{ij}$ transition Markov process matrix.
Calculating the stationary matrix: $\lim_{k \to \infty} P^k = \lim_{k \to \infty} \begin{bmatrix} \frac{1}{2} & \frac{1}{4} & \frac{1}{4} \\ \frac{1}{4} & \frac{1}{2} & \frac{1}{4} \\ \frac{1}{4} & \frac{1}{4} & \frac{1}{2} \\ \end{bmatrix} ^k $
Which means our stationary states are to be anywhere see the Matlab code:
>> a=[1/2 1/4 1/4; 1/4 1/2 1/4; 1/4 1/4 1/2 ]
a =
0.5000 0.2500 0.2500
0.2500 0.5000 0.2500
0.2500 0.2500 0.5000
>> a^1e99
ans =
0.3333 0.3333 0.3333
0.3333 0.3333 0.3333
0.3333 0.3333 0.3333