mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
* fix bug in col-pivoting qr, forgot to swap the colNorms when swapping cols
* add Gael a copyright line
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
// for linear algebra.
|
||||
//
|
||||
// Copyright (C) 2006-2009 Benoit Jacob <jacob.benoit.1@gmail.com>
|
||||
// Copyright (C) 2009 Gael Guennebaud <g.gael@free.fr>
|
||||
//
|
||||
// Eigen is free software; you can redistribute it and/or
|
||||
// modify it under the terms of the GNU Lesser General Public
|
||||
|
||||
@@ -306,6 +306,7 @@ ColPivotingHouseholderQR<MatrixType>& ColPivotingHouseholderQR<MatrixType>::comp
|
||||
cols_transpositions.coeffRef(k) = biggest_col_in_corner;
|
||||
if(k != biggest_col_in_corner) {
|
||||
m_qr.col(k).swap(m_qr.col(biggest_col_in_corner));
|
||||
std::swap(colSqNorms.coeffRef(k), colSqNorms.coeffRef(biggest_col_in_corner));
|
||||
++number_of_transpositions;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user