aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/PermutationMatrix.h
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2015-06-19 15:38:19 +0200
committerGravatar Gael Guennebaud <g.gael@free.fr>2015-06-19 15:38:19 +0200
commit0c8b0e007b282139b4d3ab8e74f287c8e5109d69 (patch)
treeac16b08787bf23face06d0be6454bc8f923a57f7 /Eigen/src/Core/PermutationMatrix.h
parent3f6aa4cd5d03bd9e6e41d2f997fa7bd9b98bd68e (diff)
Introduce a AliasFreeProduct option for Permutations and Transpositions
Diffstat (limited to 'Eigen/src/Core/PermutationMatrix.h')
-rw-r--r--Eigen/src/Core/PermutationMatrix.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/Eigen/src/Core/PermutationMatrix.h b/Eigen/src/Core/PermutationMatrix.h
index 8cf989f2c..bfe6f899a 100644
--- a/Eigen/src/Core/PermutationMatrix.h
+++ b/Eigen/src/Core/PermutationMatrix.h
@@ -541,11 +541,11 @@ class PermutationWrapper : public PermutationBase<PermutationWrapper<_IndicesTyp
*/
template<typename MatrixDerived, typename PermutationDerived>
EIGEN_DEVICE_FUNC
-const Product<MatrixDerived, PermutationDerived, DefaultProduct>
+const Product<MatrixDerived, PermutationDerived, AliasFreeProduct>
operator*(const MatrixBase<MatrixDerived> &matrix,
const PermutationBase<PermutationDerived>& permutation)
{
- return Product<MatrixDerived, PermutationDerived, DefaultProduct>
+ return Product<MatrixDerived, PermutationDerived, AliasFreeProduct>
(matrix.derived(), permutation.derived());
}
@@ -553,11 +553,11 @@ operator*(const MatrixBase<MatrixDerived> &matrix,
*/
template<typename PermutationDerived, typename MatrixDerived>
EIGEN_DEVICE_FUNC
-const Product<PermutationDerived, MatrixDerived, DefaultProduct>
+const Product<PermutationDerived, MatrixDerived, AliasFreeProduct>
operator*(const PermutationBase<PermutationDerived> &permutation,
const MatrixBase<MatrixDerived>& matrix)
{
- return Product<PermutationDerived, MatrixDerived, DefaultProduct>
+ return Product<PermutationDerived, MatrixDerived, AliasFreeProduct>
(permutation.derived(), matrix.derived());
}
@@ -620,19 +620,19 @@ class Transpose<PermutationBase<Derived> >
/** \returns the matrix with the inverse permutation applied to the columns.
*/
template<typename OtherDerived> friend
- const Product<OtherDerived, Transpose, DefaultProduct>
+ const Product<OtherDerived, Transpose, AliasFreeProduct>
operator*(const MatrixBase<OtherDerived>& matrix, const Transpose& trPerm)
{
- return Product<OtherDerived, Transpose, DefaultProduct>(matrix.derived(), trPerm.derived());
+ return Product<OtherDerived, Transpose, AliasFreeProduct>(matrix.derived(), trPerm.derived());
}
/** \returns the matrix with the inverse permutation applied to the rows.
*/
template<typename OtherDerived>
- const Product<Transpose, OtherDerived, DefaultProduct>
+ const Product<Transpose, OtherDerived, AliasFreeProduct>
operator*(const MatrixBase<OtherDerived>& matrix) const
{
- return Product<Transpose, OtherDerived, DefaultProduct>(*this, matrix.derived());
+ return Product<Transpose, OtherDerived, AliasFreeProduct>(*this, matrix.derived());
}
const PermutationType& nestedExpression() const { return m_permutation; }