For an undirected adjacency matrix without isolated vertices the simple random
walk has stationary law \(d_v/(2|E|)\)
(Research.P3.RandomWalk.stationary); for a directed one the
out-degree law is checked and in general fails (directed_fails).
Usage
morie_random_walk_exposure(adj)
Arguments
- adj
Adjacency matrix (0/1); symmetric for an undirected graph.
Value
A list: pi (the degree law), stationary (whether
\(\pi P = \pi\)), undirected.
References
Grimmett G, Stirzaker D (2020). Probability and Random Processes,
4th ed., Exercise 6.4.6. Oxford.
Examples
adj <- matrix(c(0, 1, 1, 1, 0, 1, 1, 1, 0), 3)
morie_random_walk_exposure(adj)
#> $pi
#> [1] 0.3333333 0.3333333 0.3333333
#>
#> $stationary
#> [1] TRUE
#>
#> $undirected
#> [1] TRUE
#>
#> attr(,"theorem")
#> [1] "Research.P3.RandomWalk.stationary"