I have a real square matrix $X$ which I need to perform a Singular Value Decomposition on. Now, performing the operation
$$ X = USV^T $$
as $U$ and $V$ are orthogonal, we know that $\det(X)=\pm\det(S)$ and $\det(S)$ is non-negative as singular values are non-negative.
Now, I need to know the sign of the determinants of $U$ and $V$ (which is the same as knowing the determinants, of course). However, the naive approach costs me $2 O(N^3)$
I was wondering whether someone knows of a way to either
- Infer the sign of the determinants of $U$ and $V$ as a bi-product of the SVD-implementation in
scipyor a similar library in Python, without having to call
- Calculate the determinant of an orthogonal matrix that is faster than the default implementation of
det(U), based on the fact that $U/V$ is orthogonal.