matrix-inv: The inverse of a matrix

invR Documentation

The inverse of a matrix

Description

Computes the inverse of a matrix.

Usage

inv(x)

Arguments

x

a numeric matrix.

Value

a matrix

References

Golub, van Loan, (1996); Matrix Computations, 3rd edition. Johns Hopkins University Press.

Examples

## Create Pascal Matrix:
   P = pascal(5)
   P
         
## Compute the Inverse Matrix:
   inv(P)
   
## Check:
   inv(P) %*% P    
   
## Alternatives:
   chol2inv(chol(P))
   solve(P)                     

fBasics documentation built on Nov. 3, 2023, 5:10 p.m.