2008-06-15 11:54:18 +00:00
|
|
|
// This file is part of Eigen, a lightweight C++ template library
|
2009-05-22 20:25:33 +02:00
|
|
|
// for linear algebra.
|
2008-06-15 11:54:18 +00:00
|
|
|
//
|
2010-06-24 23:21:58 +02:00
|
|
|
// Copyright (C) 2008 Gael Guennebaud <gael.guennebaud@inria.fr>
|
2009-06-28 21:27:37 +02:00
|
|
|
// Copyright (C) 2007-2009 Benoit Jacob <jacob.benoit.1@gmail.com>
|
2008-06-15 11:54:18 +00:00
|
|
|
//
|
2012-07-13 14:42:47 -04:00
|
|
|
// This Source Code Form is subject to the terms of the Mozilla
|
|
|
|
|
// Public License v. 2.0. If a copy of the MPL was not distributed
|
|
|
|
|
// with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
2008-06-15 11:54:18 +00:00
|
|
|
|
|
|
|
|
#ifndef EIGEN_DIAGONALPRODUCT_H
|
|
|
|
|
#define EIGEN_DIAGONALPRODUCT_H
|
|
|
|
|
|
2023-08-21 16:25:22 +00:00
|
|
|
// IWYU pragma: private
|
2021-09-10 19:12:26 +00:00
|
|
|
#include "./InternalHeaderCheck.h"
|
|
|
|
|
|
2012-04-15 11:06:28 +01:00
|
|
|
namespace Eigen {
|
|
|
|
|
|
2014-02-18 10:52:26 +01:00
|
|
|
/** \returns the diagonal matrix product of \c *this by the diagonal matrix \a diagonal.
|
|
|
|
|
*/
|
|
|
|
|
template <typename Derived>
|
|
|
|
|
template <typename DiagonalDerived>
|
2017-02-28 14:58:45 -08:00
|
|
|
EIGEN_DEVICE_FUNC inline const Product<Derived, DiagonalDerived, LazyProduct> MatrixBase<Derived>::operator*(
|
2014-02-18 10:52:26 +01:00
|
|
|
const DiagonalBase<DiagonalDerived> &a_diagonal) const {
|
|
|
|
|
return Product<Derived, DiagonalDerived, LazyProduct>(derived(), a_diagonal.derived());
|
|
|
|
|
}
|
2009-06-28 21:27:37 +02:00
|
|
|
|
2012-04-15 11:06:28 +01:00
|
|
|
} // end namespace Eigen
|
2009-06-28 21:27:37 +02:00
|
|
|
|
2008-06-15 11:54:18 +00:00
|
|
|
#endif // EIGEN_DIAGONALPRODUCT_H
|