LASwift
LASwift copied to clipboard
Description for eig()
In my understanding the eigenvectors are in the columns of V and not as stated here "by rows"
/// Compute eigen values and vectors of a given square matrix.
///
/// A precondition error is thrown if the algorithm fails to converge.
///
/// - Parameters:
/// - A: square matrix to calculate eigen values and vectors of
/// - Returns: eigenvectors matrix (by rows) and diagonal matrix with eigenvalues on the main diagonal
public func eig(_ A: Matrix) -> (V: Matrix, D: Matrix) {
I would rather return the right eigenvectors returned in vr. Most commonly right eigenvectors are used in physics and engineering when nothing in particular is mentioned. This likely would also avoid the transposition.