This function is similar to solve(Q,y) but with the added benefit that it allows for permuted matrices. This function does the job in order to minimise
user error when attempting to re-permute the matrices prior or after solving. The user also has an option for the permuted Cholesky factorisation of Q to be carried out
internally.
Usage
cholsolve(Q = NULL, y = NULL, perm = FALSE, cholQ = NULL,
cholQp = NULL, P = NULL)
Arguments
Q
matrix (if of class Matrix needs to be column-compressed, i.e., dgCMatrix or dsCMatrix)), the Cholesky factor of which needs to be found
y
matrix with the same number of rows as Q
perm
if FLASE no permutation is carried out, if TRUE permuted Cholesky factors are used
cholQ
the lower Cholesky factor of Q (if known already)
cholQp
the lower Cholesky factor of a permuted Q (if known already)
P
the permutation matrix (if known already)
Value
x solution to Qx = y
References
Havard Rue and Leonhard Held (2005). Gaussian Markov Random Fields: Theory and Applications. Chapman & Hall/CRC Press