# What is the fastest numeric method for determinant calculation?

I have a C++ matrix class which can do the following operations on a square matrix related to determinant calculation:

1. LU Decomposition
2. Calculation of eigenvalues
3. Calculation of determinant by adjoint method

I want to calculate determinant. Which these there methods is faster? I can say that the answer is not "3", but at least can you compare the first two methods for me?

Is there any other numeric method which is better (faster and/or more reliable) than the ones in the list? My matrix class can also do QR decomposition and can solve linear matrix equations in Ax=b format; can these features be used in determinant calculation?

-
Gaussian elimination would be the best approach to use; QR is a bit more expensive, eigendecomposition is even more expensive, and expanding into minors/cofactors is ridiculously expensive. –  Guess who it is. Dec 22 '11 at 16:35

The cost (number of multiplication) for $LU$ decomposition is $$\frac{n^3}{3} + \frac{n^2}{2} - \frac{5n}{6}$$ Add an additional cost of $n-1$ to multiply out the diagonal elements of $U$ to get the determinant.
The cost (number of multiplication) for $QR$ decomposition is $$\frac{2n^3}{3} + n^2 + \frac{n}{3} - 2$$ Add an additional cost of $n-1$ to multiply out the diagonal elements of $R$ to get the determinant.