Skip to contents

Computes the spectral radius (the largest absolute eigenvalue) of a matrix

Usage

spectral_radius(W)

Arguments

W

A matrix

Value

The spectral radius of the matrix

Examples

B <- matrix(c(0, 0.6, -0.5, 0), nrow = 2, byrow = TRUE)
spectral_radius(B)
#> [1] 0.5477226