Eigen_sqrt: Square root of a matrix

View source: R/EigenR.R

Eigen_sqrtR Documentation

Square root of a matrix

Description

Square root of a real or complex square matrix, when possible.

Usage

Eigen_sqrt(M)

Arguments

M

a square matrix, real or complex

Details

See matrix square root.

Value

A square root of M.

Examples

# Rotation matrix over 60 degrees:
M <- cbind(c(cos(pi/3), sin(pi/3)), c(-sin(pi/3), cos(pi/3)))
# Its square root, the rotation matrix over 30 degrees:
Eigen_sqrt(M)

EigenR documentation built on May 18, 2022, 9:05 a.m.