jaig
jaig

Reputation: 207

Determinant Value For Very Large Matrix

I have a very large square matrix of order around 100000 and I want to know whether the determinant value is zero or not for that matrix.

What can be the fastest way to know that ?

I have to implement that in C++

Upvotes: 1

Views: 1297

Answers (4)

Lutz Lehmann
Lutz Lehmann

Reputation: 25972

Usually, matrices of that size are extremely sparse. Use row and column reordering algorithms to concentrate the entries near the diagonal and then use a QR decomposition or LU decomposition. The product of the diagonal entries of the second factor is - up to a sign in the QR case - the determinant. This may still be too ill-conditioned, the best result for rank is obtained by performing a singular value decomposition. However, SVD is more expensive.

Upvotes: 1

Vikram Bhat
Vikram Bhat

Reputation: 6246

From my knowledge your application doesnt need to calculate determinant but the rank of matrix is sufficient to check if system of equations have non-trivial solution : -

Rank of Matrix

Upvotes: 0

en4bz
en4bz

Reputation: 1132

Assuming you are trying to determine if the matrix is non-singular you may want to look here:

https://math.stackexchange.com/questions/595/what-is-the-most-efficient-way-to-determine-if-a-matrix-is-invertible

As mentioned in the comments its best to use some sort of BLAS library that will do this for you such as Boost::uBLAS.

Upvotes: 1

anavaras lamurep
anavaras lamurep

Reputation: 1493

There is a property that if any two rows are equal or one row is a constant multiple of another row we can say that determinant of that matrix is zero.It is applicable to columns as well.

Upvotes: 0

Related Questions