bratteliDistances {bratteli} | R Documentation |
Intrinsic distances
Description
Intrinsic distances on a Bratteli graph
Usage
bratteliDistances(Mn, N)
Arguments
Mn |
a function returning for each integer |
N |
the level up to which the distances are wanted |
Value
The distance matrices in a list.
Examples
# the Pascal graph ####
Pascal <- function(n) {
M <- matrix(0, nrow = n+1, ncol = n+2)
for(i in 1:(n+1)) {
M[i, ][c(i, i+1L)] <- 1
}
M
}
bratteliDistances(Pascal, 4)
# the Euler graph ####
Euler <- function(n) {
M <- matrix(0, nrow = n+1, ncol = n+2)
for(i in 1:(n+1)) {
M[i, ][c(i, i+1L)] <- c(i, n+2-i)
}
M
}
bratteliDistances(Euler, 4)
[Package bratteli version 1.0.0 Index]