Mathematics, Probability, Data Science, Stochastic Process, Artificial Intelligence.
recurrent while the middle states are transient. If we raise the matrix to the 100th power, we get the following: matrixpower(random_walk, 100) [,0] [,1] [,2] [,3] [,4] [0,] 1.00 0.000000e+00 0.000000e+00 0.000000e+00 0.00 [1,] 0.75 4.440892e-16 0.000000e+00 4.440892e-16 0.25 [2,] 0.50 0.000000e+00