Displaying 1 result from an estimated 1 matches for "3dlapack".
Did you mean:
dlapack
2009 Jun 18
1
Inverting a square... (PR#13762)
...correct this problem:
>=20
> solve.lapack <- function(A, LAPACK=3DTRUE, tol=3D1.e-07) {
> # A function to invert a matrix using "LAPACK" or "LINPACK"
> if (nrow(A) !=3D ncol(A)) stop("Matrix muxt be square")
> qrA <- qr(A, LAPACK=3DLAPACK, tol=3Dtol)
> if (LAPACK) {
> apply(diag(1, ncol(A)), 2, function(x) solve(qrA, x))=20
> } else solve(qrA)
> }
>=20
> hinv3 <- solve.lapack(h5)
> all.equal(hinv1, hinv3) # Now, they are equal
>=20
> _________________________________________...