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)=±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
U and V as a bi-product of the SVD-implementation in numpy,scipy or a similar library in Python, without having to call det(U) and det(V).det(U), based on the fact that U/V is orthogonal.