# Funktion zur Berechnung von Matrizen-Potenzen matrix.power <- function(mat, pow=2) { mhelp <- mat for(i in 2:pow) mhelp <- mhelp%*%mat return(mhelp) } # ergodische MK P <- matrix(c(0.2,0.8,0,0.6,0.4,0,0.2,0.3,0.5), nrow=3, ncol=3, byrow=T) #P <- matrix(c(0.2,0.7,0.1,0.6,0.4,0,0.2,0.3,0.5), nrow=3, ncol=3, byrow=T) P matrix.power(P,2) matrix.power(P,3) matrix.power(P,4) matrix.power(P,5) matrix.power(P,10) matrix.power(P,20) matrix.power(P,30) # periodische MK P <- matrix(c(0,1,0,1,0,0,0.2,0.3,0.5), nrow=3, ncol=3, byrow=T) P matrix.power(P,10) matrix.power(P,20) matrix.power(P,30) matrix.power(P,50) matrix.power(P,50) matrix.power(P,51) matrix.power(P,52) matrix.power(P,53) matrix.power(P,54)