mat
Dense()
Dense Matrix
Creation
new Dense(r, c, data)Parameters
rNumberrowscNumbercolsdataNumber[]
creates a new dense matrix with r rows and c columns.
dims()
at()
set()
T()
creates a new dense matrix of transposed.
| |
add()
| |
sub()
| |
mul()
| |
mulElem()
| |
divElem()
inverse()
| |
solve()
exp()
pow()
scale()
VecDense
Vector
Creation
new VecDense(n, data)Parameters
nNumberCreates a new VecDense of length n. It should be larger than 0.dataNumber[]Array of elements. If data is omit, blank array is assigned.
cap()
len()
atVec()
setVec()
addVec()
subVec()
mulVec()
mulElemVec()
scaleVec()
solveVec()
QR
QR factorization is a decomposition of a matrix A into a product A = QR of an orthonormal matrix Q and a upper triangular matrix R.
QR decomposition is often used to solve the linear least squares (LLS) problem and is the basis for a particular eigenvalue algorithm, the QR algorithm.
Any real square matrix A may be decomposed as
A = QRwhere Q is an orthogonal matrix and R is an upper triangular matrix. If A is invertible, then the factorization is unique if we require the diagonal elements of R to be positive.
Usage example
| |
format()
| |
Last updated on