Return the nearest orthogonal matrix to A in the Frobenius norm.
Computed via the polar decomposition: B = U V^T where
A = U S V^T is the SVD of A.
- Parameters:
A (ndarray) – Square real matrix, shape (N, N).
- Return type:
ndarray
- Returns:
Orthogonal matrix of shape (N, N).