inst/doc/SolveRationalMatrixEquation.R

## ----setup---------------------------------------------------------------

library(SolveRationalMatrixEquation)

Q <- rbind(c(2,-1,0),c(-1,2,1),c(0,1,2))
L <- rbind(c(2,-2,18),c(2,1,0),c(1,2,0))

##QR Decomposition
QRdecompose(L)

##LQ Decompostion
LQdecompose(L)

##Solve Rational Matrix
X <- sol.rationalmatrix.euqation(Q, L)

#Checking the results
X - (Q + L %*% solve(X) %*% t(L))

Try the SolveRationalMatrixEquation package in your browser

Any scripts or data that you put into this service are public.

SolveRationalMatrixEquation documentation built on May 2, 2019, 2:45 p.m.