Fix all the doxygen warnings.

This commit is contained in:
Antonio Sánchez
2025-02-01 00:00:31 +00:00
parent 9589cc4e7f
commit b1e74b1ccd
85 changed files with 829 additions and 2782 deletions

View File

@@ -11,7 +11,7 @@ template <typename MatrixType_, int UpLo_, SparseFactorization_t Solver_, bool E
class AccelerateImpl;
/** \ingroup AccelerateSupport_Module
* \class AccelerateLLT
* \typedef AccelerateLLT
* \brief A direct Cholesky (LLT) factorization and solver based on Accelerate
*
* \warning Only single and double precision real scalar types are supported by Accelerate
@@ -25,7 +25,7 @@ template <typename MatrixType, int UpLo = Lower>
using AccelerateLLT = AccelerateImpl<MatrixType, UpLo | Symmetric, SparseFactorizationCholesky, true>;
/** \ingroup AccelerateSupport_Module
* \class AccelerateLDLT
* \typedef AccelerateLDLT
* \brief The default Cholesky (LDLT) factorization and solver based on Accelerate
*
* \warning Only single and double precision real scalar types are supported by Accelerate
@@ -39,7 +39,7 @@ template <typename MatrixType, int UpLo = Lower>
using AccelerateLDLT = AccelerateImpl<MatrixType, UpLo | Symmetric, SparseFactorizationLDLT, true>;
/** \ingroup AccelerateSupport_Module
* \class AccelerateLDLTUnpivoted
* \typedef AccelerateLDLTUnpivoted
* \brief A direct Cholesky-like LDL^T factorization and solver based on Accelerate with only 1x1 pivots and no pivoting
*
* \warning Only single and double precision real scalar types are supported by Accelerate
@@ -53,7 +53,7 @@ template <typename MatrixType, int UpLo = Lower>
using AccelerateLDLTUnpivoted = AccelerateImpl<MatrixType, UpLo | Symmetric, SparseFactorizationLDLTUnpivoted, true>;
/** \ingroup AccelerateSupport_Module
* \class AccelerateLDLTSBK
* \typedef AccelerateLDLTSBK
* \brief A direct Cholesky (LDLT) factorization and solver based on Accelerate with Supernode Bunch-Kaufman and static
* pivoting
*
@@ -68,7 +68,7 @@ template <typename MatrixType, int UpLo = Lower>
using AccelerateLDLTSBK = AccelerateImpl<MatrixType, UpLo | Symmetric, SparseFactorizationLDLTSBK, true>;
/** \ingroup AccelerateSupport_Module
* \class AccelerateLDLTTPP
* \typedef AccelerateLDLTTPP
* \brief A direct Cholesky (LDLT) factorization and solver based on Accelerate with full threshold partial pivoting
*
* \warning Only single and double precision real scalar types are supported by Accelerate
@@ -82,7 +82,7 @@ template <typename MatrixType, int UpLo = Lower>
using AccelerateLDLTTPP = AccelerateImpl<MatrixType, UpLo | Symmetric, SparseFactorizationLDLTTPP, true>;
/** \ingroup AccelerateSupport_Module
* \class AccelerateQR
* \typedef AccelerateQR
* \brief A QR factorization and solver based on Accelerate
*
* \warning Only single and double precision real scalar types are supported by Accelerate
@@ -95,7 +95,7 @@ template <typename MatrixType>
using AccelerateQR = AccelerateImpl<MatrixType, 0, SparseFactorizationQR, false>;
/** \ingroup AccelerateSupport_Module
* \class AccelerateCholeskyAtA
* \typedef AccelerateCholeskyAtA
* \brief A QR factorization and solver based on Accelerate without storing Q (equivalent to A^TA = R^T R)
*
* \warning Only single and double precision real scalar types are supported by Accelerate

View File

@@ -134,8 +134,15 @@ class Array : public PlainObjectBase<Array<Scalar_, Rows_, Cols_, Options_, MaxR
return *this;
}
/** \copydoc PlainObjectBase(const Scalar& a0, const Scalar& a1, const Scalar& a2, const Scalar& a3, const
* ArgTypes&... args)
/** \brief Construct a row of column vector with fixed size from an arbitrary number of coefficients.
*
* \only_for_vectors
*
* This constructor is for 1D array or vectors with more than 4 coefficients.
*
* \warning To construct a column (resp. row) vector of fixed length, the number of values passed to this
* constructor must match the the fixed number of rows (resp. columns) of \c *this.
*
*
* Example: \include Array_variadic_ctor_cxx11.cpp
* Output: \verbinclude Array_variadic_ctor_cxx11.out

View File

@@ -81,9 +81,6 @@ class ArrayBase : public DenseBase<Derived> {
typedef typename Base::CoeffReturnType CoeffReturnType;
#endif // not EIGEN_PARSED_BY_DOXYGEN
#ifndef EIGEN_PARSED_BY_DOXYGEN
typedef typename Base::PlainObject PlainObject;
/** \internal Represents a matrix with all coefficients equal to one another*/
@@ -118,19 +115,57 @@ class ArrayBase : public DenseBase<Derived> {
return derived();
}
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator+=(const Scalar& scalar);
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator-=(const Scalar& scalar);
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator+=(const Scalar& other) {
internal::call_assignment(this->derived(), PlainObject::Constant(rows(), cols(), other),
internal::add_assign_op<Scalar, Scalar>());
return derived();
}
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator+=(const ArrayBase<OtherDerived>& other);
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator-=(const ArrayBase<OtherDerived>& other);
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator-=(const Scalar& other) {
internal::call_assignment(this->derived(), PlainObject::Constant(rows(), cols(), other),
internal::sub_assign_op<Scalar, Scalar>());
return derived();
}
/** replaces \c *this by \c *this + \a other.
*
* \returns a reference to \c *this
*/
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator*=(const ArrayBase<OtherDerived>& other);
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator+=(const ArrayBase<OtherDerived>& other) {
call_assignment(derived(), other.derived(), internal::add_assign_op<Scalar, typename OtherDerived::Scalar>());
return derived();
}
/** replaces \c *this by \c *this - \a other.
*
* \returns a reference to \c *this
*/
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator/=(const ArrayBase<OtherDerived>& other);
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator-=(const ArrayBase<OtherDerived>& other) {
call_assignment(derived(), other.derived(), internal::sub_assign_op<Scalar, typename OtherDerived::Scalar>());
return derived();
}
/** replaces \c *this by \c *this * \a other coefficient wise.
*
* \returns a reference to \c *this
*/
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator*=(const ArrayBase<OtherDerived>& other) {
call_assignment(derived(), other.derived(), internal::mul_assign_op<Scalar, typename OtherDerived::Scalar>());
return derived();
}
/** replaces \c *this by \c *this / \a other coefficient wise.
*
* \returns a reference to \c *this
*/
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator/=(const ArrayBase<OtherDerived>& other) {
call_assignment(derived(), other.derived(), internal::div_assign_op<Scalar, typename OtherDerived::Scalar>());
return derived();
}
public:
EIGEN_DEVICE_FUNC ArrayBase<Derived>& array() { return *this; }
@@ -173,50 +208,6 @@ class ArrayBase : public DenseBase<Derived> {
}
};
/** replaces \c *this by \c *this - \a other.
*
* \returns a reference to \c *this
*/
template <typename Derived>
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& ArrayBase<Derived>::operator-=(const ArrayBase<OtherDerived>& other) {
call_assignment(derived(), other.derived(), internal::sub_assign_op<Scalar, typename OtherDerived::Scalar>());
return derived();
}
/** replaces \c *this by \c *this + \a other.
*
* \returns a reference to \c *this
*/
template <typename Derived>
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& ArrayBase<Derived>::operator+=(const ArrayBase<OtherDerived>& other) {
call_assignment(derived(), other.derived(), internal::add_assign_op<Scalar, typename OtherDerived::Scalar>());
return derived();
}
/** replaces \c *this by \c *this * \a other coefficient wise.
*
* \returns a reference to \c *this
*/
template <typename Derived>
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& ArrayBase<Derived>::operator*=(const ArrayBase<OtherDerived>& other) {
call_assignment(derived(), other.derived(), internal::mul_assign_op<Scalar, typename OtherDerived::Scalar>());
return derived();
}
/** replaces \c *this by \c *this / \a other coefficient wise.
*
* \returns a reference to \c *this
*/
template <typename Derived>
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& ArrayBase<Derived>::operator/=(const ArrayBase<OtherDerived>& other) {
call_assignment(derived(), other.derived(), internal::div_assign_op<Scalar, typename OtherDerived::Scalar>());
return derived();
}
} // end namespace Eigen
#endif // EIGEN_ARRAYBASE_H

View File

@@ -287,7 +287,7 @@ DenseBase<Derived>::LinSpaced(Index size, const Scalar& low, const Scalar& high)
}
/**
* \copydoc DenseBase::LinSpaced(Index, const Scalar&, const Scalar&)
* \copydoc DenseBase::LinSpaced(Index, const DenseBase::Scalar&, const DenseBase::Scalar&)
* Special version for fixed size types which does not require the size parameter.
*/
template <typename Derived>

View File

@@ -1251,8 +1251,6 @@ template <typename T>
EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE EIGEN_CONSTEXPR T div_ceil(T a, T b) {
using UnsignedT = typename internal::make_unsigned<T>::type;
EIGEN_STATIC_ASSERT((NumTraits<T>::IsInteger), THIS FUNCTION IS FOR INTEGER TYPES)
eigen_assert(a >= 0);
eigen_assert(b > 0);
// Note: explicitly declaring a and b as non-negative values allows the compiler to use better optimizations
const UnsignedT ua = UnsignedT(a);
const UnsignedT ub = UnsignedT(b);
@@ -1268,8 +1266,6 @@ EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE EIGEN_CONSTEXPR T round_down(T a, U b) {
using UnsignedU = typename internal::make_unsigned<U>::type;
EIGEN_STATIC_ASSERT((NumTraits<T>::IsInteger), THIS FUNCTION IS FOR INTEGER TYPES)
EIGEN_STATIC_ASSERT((NumTraits<U>::IsInteger), THIS FUNCTION IS FOR INTEGER TYPES)
eigen_assert(a >= 0);
eigen_assert(b > 0);
// Note: explicitly declaring a and b as non-negative values allows the compiler to use better optimizations
const UnsignedT ua = UnsignedT(a);
const UnsignedU ub = UnsignedU(b);
@@ -1279,7 +1275,6 @@ EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE EIGEN_CONSTEXPR T round_down(T a, U b) {
/** Log base 2 for 32 bits positive integers.
* Conveniently returns 0 for x==0. */
EIGEN_CONSTEXPR inline int log2(int x) {
eigen_assert(x >= 0);
unsigned int v(x);
constexpr int table[32] = {0, 9, 1, 10, 13, 21, 2, 29, 11, 14, 16, 18, 22, 25, 3, 30,
8, 12, 20, 28, 15, 17, 24, 7, 19, 27, 23, 6, 26, 5, 4, 31};

View File

@@ -224,8 +224,6 @@ class Matrix : public PlainObjectBase<Matrix<Scalar_, Rows_, Cols_, Options_, Ma
return Base::_set(other);
}
/* Here, doxygen failed to copy the brief information when using \copydoc */
/**
* \brief Copies the generic expression \a other into *this.
* \copydetails DenseBase::operator=(const EigenBase<OtherDerived> &other)
@@ -266,7 +264,15 @@ class Matrix : public PlainObjectBase<Matrix<Scalar_, Rows_, Cols_, Options_, Ma
return *this;
}
/** \copydoc PlainObjectBase(const Scalar&, const Scalar&, const Scalar&, const Scalar&, const ArgTypes&... args)
/** \brief Construct a row of column vector with fixed size from an arbitrary number of coefficients.
*
* \only_for_vectors
*
* This constructor is for 1D array or vectors with more than 4 coefficients.
*
* \warning To construct a column (resp. row) vector of fixed length, the number of values passed to this
* constructor must match the the fixed number of rows (resp. columns) of \c *this.
*
*
* Example: \include Matrix_variadic_ctor_cxx11.cpp
* Output: \verbinclude Matrix_variadic_ctor_cxx11.out
@@ -280,6 +286,7 @@ class Matrix : public PlainObjectBase<Matrix<Scalar_, Rows_, Cols_, Options_, Ma
/** \brief Constructs a Matrix and initializes it from the coefficients given as initializer-lists grouped by row.
* \cpp11
* \anchor matrix_initializer_list
*
* In the general case, the constructor takes a list of rows, each row being represented as a list of coefficients:
*

View File

@@ -115,6 +115,7 @@ EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC Tgt bit_cast(const Src& src) {
}
} // namespace numext
// clang-format off
/** \class NumTraits
* \ingroup Core_Module
*
@@ -126,48 +127,50 @@ EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC Tgt bit_cast(const Src& src) {
*
* The provided data consists of:
* \li A typedef \c Real, giving the "real part" type of \a T. If \a T is already real,
* then \c Real is just a typedef to \a T. If \a T is \c std::complex<U> then \c Real
* then \c Real is just a typedef to \a T. If \a T is `std::complex<U>` then \c Real
* is a typedef to \a U.
* \li A typedef \c NonInteger, giving the type that should be used for operations producing non-integral values,
* such as quotients, square roots, etc. If \a T is a floating-point type, then this typedef just gives
* \a T again. Note however that many Eigen functions such as internal::sqrt simply refuse to
* take integers. Outside of a few cases, Eigen doesn't do automatic type promotion. Thus, this typedef is
* only intended as a helper for code that needs to explicitly promote types.
* \li A typedef \c Literal giving the type to use for numeric literals such as "2" or "0.5". For instance, for \c
* std::complex<U>, Literal is defined as \c U. Of course, this type must be fully compatible with \a T. In doubt, just
* use \a T here. \li A typedef \a Nested giving the type to use to nest a value inside of the expression tree. If you
* don't know what this means, just use \a T here. \li An enum value \a IsComplex. It is equal to 1 if \a T is a \c
* std::complex type, and to 0 otherwise. \li An enum value \a IsInteger. It is equal to \c 1 if \a T is an integer type
* such as \c int, and to \c 0 otherwise. \li Enum values ReadCost, AddCost and MulCost representing a rough estimate of
* the number of CPU cycles needed to by move / add / mul instructions respectively, assuming the data is already stored
* in CPU registers. Stay vague here. No need to do architecture-specific stuff. If you don't know what this means, just
* use \c Eigen::HugeCost. \li An enum value \a IsSigned. It is equal to \c 1 if \a T is a signed type and to 0 if \a T
* is unsigned. \li An enum value \a RequireInitialization. It is equal to \c 1 if the constructor of the numeric type
* \a T must be called, and to 0 if it is safe not to call it. Default is 0 if \a T is an arithmetic type, and 1
* otherwise. \li An epsilon() function which, unlike <a
* href="http://en.cppreference.com/w/cpp/types/numeric_limits/epsilon">std::numeric_limits::epsilon()</a>, it returns a
* \a Real instead of a \a T. \li A dummy_precision() function returning a weak epsilon value. It is mainly used as a
* default value by the fuzzy comparison operators. \li highest() and lowest() functions returning the highest and
* lowest possible values respectively. \li digits() function returning the number of radix digits (non-sign digits for
* integers, mantissa for floating-point). This is the analogue of <a
* href="http://en.cppreference.com/w/cpp/types/numeric_limits/digits">std::numeric_limits<T>::digits</a> which is used
* as the default implementation if specialized. \li digits10() function returning the number of decimal digits that can
* be represented without change. This is the analogue of <a
* href="http://en.cppreference.com/w/cpp/types/numeric_limits/digits10">std::numeric_limits<T>::digits10</a> which is
* used as the default implementation if specialized. \li max_digits10() function returning the number of decimal digits
* required to uniquely represent all distinct values of the type. This is the analogue of <a
* href="http://en.cppreference.com/w/cpp/types/numeric_limits/max_digits10">std::numeric_limits<T>::max_digits10</a>
* \li A typedef \c Literal giving the type to use for numeric literals such as "2" or "0.5". For instance, for
* `std::complex<U>`, Literal is defined as \a U. Of course, this type must be fully compatible with \a T. In doubt,
* just use \a T here.
* \li A typedef \c Nested giving the type to use to nest a value inside of the expression tree. If you don't know what
* this means, just use \a T here.
* \li An enum value \c IsComplex. It is equal to 1 if \a T is a \c std::complex type, and to 0 otherwise.
* \li An enum value \c IsInteger. It is equal to \c 1 if \a T is an integer type such as \c int, and to \c 0 otherwise.
* \li Enum values \c ReadCost, \c AddCost and \c MulCost representing a rough estimate of the number of CPU cycles needed to by
* move / add / mul instructions respectively, assuming the data is already stored in CPU registers. Stay vague here.
* No need to do architecture-specific stuff. If you don't know what this means, just use \c Eigen::HugeCost.
* \li An enum value \c IsSigned. It is equal to \c 1 if \a T is a signed type and to 0 if \a T is unsigned.
* \li An enum value \c RequireInitialization. It is equal to \c 1 if the constructor of the numeric type \a T must be
* called, and to 0 if it is safe not to call it. Default is 0 if \a T is an arithmetic type, and 1 otherwise.
* \li An epsilon() function which, unlike <a href="http://en.cppreference.com/w/cpp/types/numeric_limits/epsilon">
* `std::numeric_limits::epsilon()`</a>, it returns a \c Real instead of a \a T.
* \li A dummy_precision() function returning a weak epsilon value. It is mainly used as a default value by the fuzzy
* comparison operators.
* \li highest() and lowest() functions returning the highest and lowest possible values respectively.
* \li digits() function returning the number of radix digits (non-sign digits for integers, mantissa for floating-point).
* This is the analogue of <a href="http://en.cppreference.com/w/cpp/types/numeric_limits/digits">
* `std::numeric_limits<T>::digits`</a> which is used as the default implementation if specialized.
* \li digits10() function returning the number of decimal digits that can be represented without change. This is the
* analogue of <a href="http://en.cppreference.com/w/cpp/types/numeric_limits/digits10">
* `std::numeric_limits<T>::digits10`</a> which is used as the default implementation if specialized.
* \li max_digits10() function returning the number of decimal digits required to uniquely represent all distinct values
* of the type. This is the analogue of <a
* href="http://en.cppreference.com/w/cpp/types/numeric_limits/max_digits10">`std::numeric_limits<T>::max_digits10`</a>
* which is used as the default implementation if specialized.
* \li min_exponent() and max_exponent() functions returning the highest and lowest possible values, respectively,
* such that the radix raised to the power exponent-1 is a normalized floating-point number. These are equivalent
* to <a
* href="http://en.cppreference.com/w/cpp/types/numeric_limits/min_exponent">std::numeric_limits<T>::min_exponent</a>/
* <a
* href="http://en.cppreference.com/w/cpp/types/numeric_limits/max_exponent">std::numeric_limits<T>::max_exponent</a>.
* to <a href="http://en.cppreference.com/w/cpp/types/numeric_limits/min_exponent">
* `std::numeric_limits<T>::min_exponent`</a>/<a
* href="http://en.cppreference.com/w/cpp/types/numeric_limits/max_exponent">`std::numeric_limits<T>::max_exponent`</a>.
* \li infinity() function returning a representation of positive infinity, if available.
* \li quiet_NaN function returning a non-signaling "not-a-number", if available.
* \li quiet_NaN() function returning a non-signaling "not-a-number", if available.
*/
// clang-format on
template <typename T>
struct GenericNumTraits {
enum {

View File

@@ -80,27 +80,6 @@ struct matrix_swap_impl;
} // end namespace internal
#ifdef EIGEN_PARSED_BY_DOXYGEN
namespace doxygen {
// This is a workaround to doxygen not being able to understand the inheritance logic
// when it is hidden by the dense_xpr_base helper struct.
// Moreover, doxygen fails to include members that are not documented in the declaration body of
// MatrixBase if we inherits MatrixBase<Matrix<Scalar_, Rows_, Cols_, Options_, MaxRows_, MaxCols_> >,
// this is why we simply inherits MatrixBase, though this does not make sense.
/** This class is just a workaround for Doxygen and it does not not actually exist. */
template <typename Derived>
struct dense_xpr_base_dispatcher;
/** This class is just a workaround for Doxygen and it does not not actually exist. */
template <typename Scalar_, int Rows_, int Cols_, int Options_, int MaxRows_, int MaxCols_>
struct dense_xpr_base_dispatcher<Matrix<Scalar_, Rows_, Cols_, Options_, MaxRows_, MaxCols_>> : public MatrixBase {};
/** This class is just a workaround for Doxygen and it does not not actually exist. */
template <typename Scalar_, int Rows_, int Cols_, int Options_, int MaxRows_, int MaxCols_>
struct dense_xpr_base_dispatcher<Array<Scalar_, Rows_, Cols_, Options_, MaxRows_, MaxCols_>> : public ArrayBase {};
} // namespace doxygen
/** \class PlainObjectBase
* \ingroup Core_Module
* \brief %Dense storage base class for matrices and arrays.
@@ -113,12 +92,7 @@ struct dense_xpr_base_dispatcher<Array<Scalar_, Rows_, Cols_, Options_, MaxRows_
* \sa \ref TopicClassHierarchy
*/
template <typename Derived>
class PlainObjectBase : public doxygen::dense_xpr_base_dispatcher<Derived>
#else
template <typename Derived>
class PlainObjectBase : public internal::dense_xpr_base<Derived>::type
#endif
{
class PlainObjectBase : public internal::dense_xpr_base<Derived>::type {
public:
enum { Options = internal::traits<Derived>::Options };
typedef typename internal::dense_xpr_base<Derived>::type Base;

View File

@@ -294,6 +294,7 @@ struct generic_product_impl<Lhs, Rhs, DenseShape, DenseShape, OuterProduct> {
}
};
struct add {
/** Add to dst. */
template <typename Dst, typename Src>
EIGEN_DEVICE_FUNC void operator()(const Dst& dst, const Src& src) const {
dst.const_cast_derived() += src;
@@ -305,9 +306,12 @@ struct generic_product_impl<Lhs, Rhs, DenseShape, DenseShape, OuterProduct> {
dst.const_cast_derived() -= src;
}
};
/** Scaled add. */
struct adds {
Scalar m_scale;
/** Constructor */
explicit adds(const Scalar& s) : m_scale(s) {}
/** Scaled add to dst. */
template <typename Dst, typename Src>
void EIGEN_DEVICE_FUNC operator()(const Dst& dst, const Src& src) const {
dst.const_cast_derived() += m_scale * src;

View File

@@ -24,20 +24,6 @@ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& DenseBase<Derived>::operator*=(co
return derived();
}
template <typename Derived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& ArrayBase<Derived>::operator+=(const Scalar& other) {
internal::call_assignment(this->derived(), PlainObject::Constant(rows(), cols(), other),
internal::add_assign_op<Scalar, Scalar>());
return derived();
}
template <typename Derived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& ArrayBase<Derived>::operator-=(const Scalar& other) {
internal::call_assignment(this->derived(), PlainObject::Constant(rows(), cols(), other),
internal::sub_assign_op<Scalar, Scalar>());
return derived();
}
template <typename Derived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& DenseBase<Derived>::operator/=(const Scalar& other) {
internal::call_assignment(this->derived(), PlainObject::Constant(rows(), cols(), other),

View File

@@ -321,7 +321,7 @@ bool MatrixBase<Derived>::isSkewSymmetric(const RealScalar& prec) const {
return (this->transpose() + *this).isZero(prec);
}
/** \returns the matrix product of \c *this by the skew symmetric matrix \skew.
/** \returns the matrix product of \c *this by the skew symmetric matrix \a skew.
*/
template <typename Derived>
template <typename SkewDerived>

View File

@@ -213,11 +213,12 @@ class trans {
}
/**
* Transposes LxunrollN row major block of matrices stored EIGEN_AVX_MAX_NUM_ACC zmm registers to
* Transposes LxunrollN row major block of matrices stored `EIGEN_AVX_MAX_NUM_ACC` zmm registers to
* "unrollN"xL ymm registers to be stored col-major into C.
*
* For 8x48, the 8x48 block (row-major) is stored in zmm as follows:
*
* ```
* row0: zmm0 zmm1 zmm2
* row1: zmm3 zmm4 zmm5
* .
@@ -231,10 +232,10 @@ class trans {
* .
* .
* row7: zmm14 zmm15
*
* ```
*
* In general we will have {1,2,3} groups of avx registers each of size
* EIGEN_AVX_MAX_NUM_ROW. packetIndexOffset is used to select which "block" of
* `EIGEN_AVX_MAX_NUM_ROW`. packetIndexOffset is used to select which "block" of
* avx registers are being transposed.
*/
template <int64_t unrollN, int64_t packetIndexOffset>

View File

@@ -18,19 +18,24 @@ namespace Eigen {
namespace internal {
static Packet4ui p4ui_CONJ_XOR =
vec_mergeh((Packet4ui)p4i_ZERO, (Packet4ui)p4f_MZERO); //{ 0x00000000, 0x80000000, 0x00000000, 0x80000000 };
inline Packet4ui p4ui_CONJ_XOR() {
return vec_mergeh((Packet4ui)p4i_ZERO, (Packet4ui)p4f_MZERO); //{ 0x00000000, 0x80000000, 0x00000000, 0x80000000 };
}
#ifdef EIGEN_VECTORIZE_VSX
#if defined(_BIG_ENDIAN)
static Packet2ul p2ul_CONJ_XOR1 =
(Packet2ul)vec_sld((Packet4ui)p2d_MZERO, (Packet4ui)p2l_ZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
static Packet2ul p2ul_CONJ_XOR2 =
(Packet2ul)vec_sld((Packet4ui)p2l_ZERO, (Packet4ui)p2d_MZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
inline Packet2ul p2ul_CONJ_XOR1() {
(Packet2ul) vec_sld((Packet4ui)p2d_MZERO, (Packet4ui)p2l_ZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
}
inline Packet2ul p2ul_CONJ_XOR2() {
(Packet2ul) vec_sld((Packet4ui)p2l_ZERO, (Packet4ui)p2d_MZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
}
#else
static Packet2ul p2ul_CONJ_XOR1 =
(Packet2ul)vec_sld((Packet4ui)p2l_ZERO, (Packet4ui)p2d_MZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
static Packet2ul p2ul_CONJ_XOR2 =
(Packet2ul)vec_sld((Packet4ui)p2d_MZERO, (Packet4ui)p2l_ZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
inline Packet2ul p2ul_CONJ_XOR1() {
(Packet2ul) vec_sld((Packet4ui)p2l_ZERO, (Packet4ui)p2d_MZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
}
inline Packet2ul p2ul_CONJ_XOR2() {
(Packet2ul) vec_sld((Packet4ui)p2d_MZERO, (Packet4ui)p2l_ZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
}
#endif
#endif
@@ -50,7 +55,7 @@ struct Packet2cf {
v1 = vec_madd(v1, b.v, p4f_ZERO);
// multiply a_im * b and get the conjugate result
v2 = vec_madd(v2, b.v, p4f_ZERO);
v2 = reinterpret_cast<Packet4f>(pxor(v2, reinterpret_cast<Packet4f>(p4ui_CONJ_XOR)));
v2 = reinterpret_cast<Packet4f>(pxor(v2, reinterpret_cast<Packet4f>(p4ui_CONJ_XOR())));
// permute back to a proper order
v2 = vec_perm(v2, v2, p16uc_COMPLEX32_REV);
@@ -266,7 +271,7 @@ EIGEN_STRONG_INLINE Packet2cf pnegate(const Packet2cf& a) {
}
template <>
EIGEN_STRONG_INLINE Packet2cf pconj(const Packet2cf& a) {
return Packet2cf(pxor<Packet4f>(a.v, reinterpret_cast<Packet4f>(p4ui_CONJ_XOR)));
return Packet2cf(pxor<Packet4f>(a.v, reinterpret_cast<Packet4f>(p4ui_CONJ_XOR())));
}
template <>
@@ -399,7 +404,7 @@ struct Packet1cd {
// multiply a_im * b and get the conjugate result
v2 = vec_madd(a_im, b.v, p2d_ZERO);
v2 = reinterpret_cast<Packet2d>(vec_sld(reinterpret_cast<Packet4ui>(v2), reinterpret_cast<Packet4ui>(v2), 8));
v2 = pxor(v2, reinterpret_cast<Packet2d>(p2ul_CONJ_XOR1));
v2 = pxor(v2, reinterpret_cast<Packet2d>(p2ul_CONJ_XOR1()));
return Packet1cd(padd<Packet2d>(v1, v2));
}
@@ -543,7 +548,7 @@ EIGEN_STRONG_INLINE Packet1cd pnegate(const Packet1cd& a) {
}
template <>
EIGEN_STRONG_INLINE Packet1cd pconj(const Packet1cd& a) {
return Packet1cd(pxor(a.v, reinterpret_cast<Packet2d>(p2ul_CONJ_XOR2)));
return Packet1cd(pxor(a.v, reinterpret_cast<Packet2d>(p2ul_CONJ_XOR2())));
}
template <>

View File

@@ -3155,7 +3155,7 @@ void gemmbfloat16(const DataMapper& res, const bfloat16* indexA, const bfloat16*
#undef MAX_BFLOAT16_ACC_VSX
#include "MatrixVectorProduct.h"
#include "MatrixVectorProduct.inc"
/************************************
* ppc64le template specializations *

View File

@@ -2116,7 +2116,7 @@ EIGEN_STRONG_INLINE Packet8bf F32ToBf16(Packet4f p4f) {
/**
* Pack the high portion of two float Packets into one bfloat16 Packet
*
* @param lohi to expect either a low & high OR odd & even order
* @tparam lohi to expect either a low & high OR odd & even order
*/
template <bool lohi>
EIGEN_ALWAYS_INLINE Packet8bf Bf16PackHigh(Packet4f lo, Packet4f hi) {
@@ -2163,7 +2163,7 @@ EIGEN_ALWAYS_INLINE Packet8bf Bf16PackHigh(Packet4f hi, Packet4f lo) {
/**
* Convert and pack two float Packets into one bfloat16 Packet
*
* @param lohi to expect either a low & high OR odd & even order
* @tparam lohi to expect either a low & high OR odd & even order
*/
template <bool lohi = true>
EIGEN_ALWAYS_INLINE Packet8bf F32ToBf16Two(Packet4f lo, Packet4f hi) {

View File

@@ -19,14 +19,19 @@ namespace Eigen {
namespace internal {
#if !defined(__ARCH__) || (defined(__ARCH__) && __ARCH__ >= 12)
static Packet4ui p4ui_CONJ_XOR = {0x00000000, 0x80000000, 0x00000000,
0x80000000}; // vec_mergeh((Packet4ui)p4i_ZERO, (Packet4ui)p4f_MZERO);
inline Packet4ui p4ui_CONJ_XOR() {
return {0x00000000, 0x80000000, 0x00000000, 0x80000000}; // vec_mergeh((Packet4ui)p4i_ZERO, (Packet4ui)p4f_MZERO);
}
#endif
static Packet2ul p2ul_CONJ_XOR1 =
(Packet2ul)vec_sld((Packet4ui)p2d_ZERO_, (Packet4ui)p2l_ZERO, 8); //{ 0x8000000000000000, 0x0000000000000000 };
static Packet2ul p2ul_CONJ_XOR2 =
(Packet2ul)vec_sld((Packet4ui)p2l_ZERO, (Packet4ui)p2d_ZERO_, 8); //{ 0x8000000000000000, 0x0000000000000000 };
inline Packet2ul p2ul_CONJ_XOR1() {
return (Packet2ul)vec_sld((Packet4ui)p2d_ZERO_, (Packet4ui)p2l_ZERO,
8); //{ 0x8000000000000000, 0x0000000000000000 };
}
inline Packet2ul p2ul_CONJ_XOR2() {
return (Packet2ul)vec_sld((Packet4ui)p2l_ZERO, (Packet4ui)p2d_ZERO_,
8); //{ 0x8000000000000000, 0x0000000000000000 };
}
struct Packet1cd {
EIGEN_STRONG_INLINE Packet1cd() {}
@@ -188,7 +193,7 @@ EIGEN_STRONG_INLINE Packet1cd pmul<Packet1cd>(const Packet1cd& a, const Packet1c
// multiply a_im * b and get the conjugate result
v2 = vec_madd(a_im, b.v, p2d_ZERO);
v2 = (Packet2d)vec_sld((Packet4ui)v2, (Packet4ui)v2, 8);
v2 = (Packet2d)vec_xor((Packet2d)v2, (Packet2d)p2ul_CONJ_XOR1);
v2 = (Packet2d)vec_xor((Packet2d)v2, (Packet2d)p2ul_CONJ_XOR1());
return Packet1cd(v1 + v2);
}
@@ -472,7 +477,7 @@ EIGEN_STRONG_INLINE Packet2cf pcmp_eq(const Packet2cf& a, const Packet2cf& b) {
}
template <>
EIGEN_STRONG_INLINE Packet2cf pconj(const Packet2cf& a) {
return Packet2cf(pxor<Packet4f>(a.v, reinterpret_cast<Packet4f>(p4ui_CONJ_XOR)));
return Packet2cf(pxor<Packet4f>(a.v, reinterpret_cast<Packet4f>(p4ui_CONJ_XOR())));
}
template <>
EIGEN_STRONG_INLINE Packet2cf pmul<Packet2cf>(const Packet2cf& a, const Packet2cf& b) {
@@ -486,7 +491,7 @@ EIGEN_STRONG_INLINE Packet2cf pmul<Packet2cf>(const Packet2cf& a, const Packet2c
// multiply a_im * b and get the conjugate result
prod_im = a_im * b.v;
prod_im = pxor<Packet4f>(prod_im, reinterpret_cast<Packet4f>(p4ui_CONJ_XOR));
prod_im = pxor<Packet4f>(prod_im, reinterpret_cast<Packet4f>(p4ui_CONJ_XOR()));
// permute back to a proper order
prod_im = vec_perm(prod_im, prod_im, p16uc_COMPLEX32_REV);

View File

@@ -305,7 +305,8 @@ inline bool useSpecificBlockingSizes(Index& k, Index& m, Index& n) {
* \param[in,out] k Input: the third dimension of the product. Output: the blocking size along the same dimension.
* \param[in,out] m Input: the number of rows of the left hand side. Output: the blocking size along the same dimension.
* \param[in,out] n Input: the number of columns of the right hand side. Output: the blocking size along the same
* dimension.
* dimension.
* \param[in] num_threads Input: the number of threads used for the computation.
*
* Given a m x k times k x n matrix product of scalar types \c LhsScalar and \c RhsScalar,
* this function computes the blocking size parameters along the respective dimensions

View File

@@ -308,15 +308,19 @@ struct general_product_to_triangular_selector<MatrixType, ProductType, UpLo, fal
}
};
template <typename MatrixType, unsigned int UpLo>
template <typename MatrixType_, unsigned int Mode_>
template <typename ProductType>
EIGEN_DEVICE_FUNC TriangularView<MatrixType, UpLo>& TriangularViewImpl<MatrixType, UpLo, Dense>::_assignProduct(
const ProductType& prod, const Scalar& alpha, bool beta) {
EIGEN_STATIC_ASSERT((UpLo & UnitDiag) == 0, WRITING_TO_TRIANGULAR_PART_WITH_UNIT_DIAGONAL_IS_NOT_SUPPORTED);
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE typename TriangularViewImpl<MatrixType_, Mode_, Dense>::TriangularViewType&
TriangularViewImpl<MatrixType_, Mode_, Dense>::_assignProduct(
const ProductType& prod, const typename TriangularViewImpl<MatrixType_, Mode_, Dense>::Scalar& alpha, bool beta) {
EIGEN_STATIC_ASSERT((Mode_ & UnitDiag) == 0, WRITING_TO_TRIANGULAR_PART_WITH_UNIT_DIAGONAL_IS_NOT_SUPPORTED);
eigen_assert(derived().nestedExpression().rows() == prod.rows() && derived().cols() == prod.cols());
general_product_to_triangular_selector<MatrixType, ProductType, UpLo, internal::traits<ProductType>::InnerSize == 1>::
run(derived().nestedExpression().const_cast_derived(), prod, alpha, beta);
general_product_to_triangular_selector<MatrixType_, ProductType, Mode_,
internal::traits<ProductType>::InnerSize == 1>::run(derived()
.nestedExpression()
.const_cast_derived(),
prod, alpha, beta);
return derived();
}

View File

@@ -13,7 +13,7 @@
namespace Eigen {
/** \class MaxSizeVector
* \ingroup Core
* \ingroup Core_Module
*
* \brief The MaxSizeVector class.
*

View File

@@ -79,7 +79,6 @@ typedef EIGEN_DEFAULT_DENSE_INDEX_TYPE DenseIndex;
* \details To change this, \c \#define the preprocessor symbol \c EIGEN_DEFAULT_DENSE_INDEX_TYPE.
* \sa \blank \ref TopicPreprocessorDirectives, StorageIndex.
*/
typedef EIGEN_DEFAULT_DENSE_INDEX_TYPE Index;
namespace internal {

View File

@@ -40,6 +40,7 @@ struct numeric_list<T, n, nn...> {
static constexpr T first_value = n;
};
// Ddoxygen doesn't like the recursive definition of gen_numeric_list.
#ifndef EIGEN_PARSED_BY_DOXYGEN
/* numeric list constructors
*
@@ -53,6 +54,7 @@ struct numeric_list<T, n, nn...> {
template <typename T, std::size_t n, T start = 0, T... ii>
struct gen_numeric_list : gen_numeric_list<T, n - 1, start, start + n - 1, ii...> {};
template <typename T, T start, T... ii>
struct gen_numeric_list<T, 0, start, ii...> {
typedef numeric_list<T, ii...> type;
@@ -80,6 +82,10 @@ template <typename T, T V, T... nn>
struct gen_numeric_list_repeated<T, 0, V, nn...> {
typedef numeric_list<T, nn...> type;
};
#else
template <typename T, std::size_t n, T start = 0, T... ii>
struct gen_numeric_list;
#endif // not EIGEN_PARSED_BY_DOXYGEN
/* list manipulation: concatenate */
@@ -110,16 +116,20 @@ struct mconcat<a, b, cs...> : concat<a, typename mconcat<b, cs...>::type> {};
template <int n, typename x>
struct take;
template <int n, typename a, typename... as>
struct take<n, type_list<a, as...>> : concat<type_list<a>, typename take<n - 1, type_list<as...>>::type> {};
template <int n>
struct take<n, type_list<>> {
typedef type_list<> type;
};
template <typename a, typename... as>
struct take<0, type_list<a, as...>> {
typedef type_list<> type;
};
template <>
struct take<0, type_list<>> {
typedef type_list<> type;
@@ -128,13 +138,12 @@ struct take<0, type_list<>> {
template <typename T, int n, T a, T... as>
struct take<n, numeric_list<T, a, as...>>
: concat<numeric_list<T, a>, typename take<n - 1, numeric_list<T, as...>>::type> {};
// XXX The following breaks in gcc-11, and is invalid anyways.
// template<typename T, int n> struct take<n, numeric_list<T>> { typedef numeric_list<T> type;
// };
template <typename T, T a, T... as>
struct take<0, numeric_list<T, a, as...>> {
typedef numeric_list<T> type;
};
template <typename T>
struct take<0, numeric_list<T>> {
typedef numeric_list<T> type;
@@ -173,7 +182,6 @@ template <>
struct h_skip_helper_type<0> {
typedef type_list<> type;
};
#endif // not EIGEN_PARSED_BY_DOXYGEN
template <int n>
struct h_skip {

View File

@@ -379,6 +379,8 @@ struct tridiagonalization_inplace_selector;
* decomposition.
* \param[out] subdiag The subdiagonal of the tridiagonal matrix T in
* the decomposition.
* \param[out] hcoeffs
* \param[out] workspace
* \param[in] extractQ If true, the orthogonal matrix Q in the
* decomposition is computed and stored in \p mat.
*

View File

@@ -87,13 +87,8 @@ struct cross_impl<Derived, OtherDerived, 2> {
*/
template <typename Derived>
template <typename OtherDerived>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
#ifndef EIGEN_PARSED_BY_DOXYGEN
typename internal::cross_impl<Derived, OtherDerived>::return_type
#else
inline std::conditional_t<SizeAtCompileTime == 2, Scalar, PlainObject>
#endif
MatrixBase<Derived>::cross(const MatrixBase<OtherDerived>& other) const {
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE typename internal::cross_impl<Derived, OtherDerived>::return_type
MatrixBase<Derived>::cross(const MatrixBase<OtherDerived>& other) const {
return internal::cross_impl<Derived, OtherDerived>::run(*this, other);
}

View File

@@ -21,8 +21,6 @@
namespace Eigen {
#ifndef EIGEN_PARSED_BY_DOXYGEN
// These helpers are required since it allows to use mixed types as parameters
// for the Umeyama. The problem with mixed parameters is that the return type
// cannot trivially be deduced when float and double types are mixed.
@@ -50,8 +48,6 @@ struct umeyama_transform_matrix_type {
} // namespace internal
#endif
/**
* \geometry_module \ingroup Geometry_Module
*

View File

@@ -476,7 +476,8 @@ typename internal::matrix_type_times_scalar_type<typename VectorsType::Scalar, O
return res;
}
/** \ingroup Householder_Module \householder_module
/** \ingroup Householder_Module
* \householder_module
* \brief Convenience function for constructing a Householder sequence.
* \returns A HouseholderSequence constructed from the specified arguments.
*/
@@ -485,7 +486,8 @@ HouseholderSequence<VectorsType, CoeffsType> householderSequence(const VectorsTy
return HouseholderSequence<VectorsType, CoeffsType, OnTheLeft>(v, h);
}
/** \ingroup Householder_Module \householder_module
/** \ingroup Householder_Module
* \householder_module
* \brief Convenience function for constructing a Householder sequence.
* \returns A HouseholderSequence constructed from the specified arguments.
* \details This function differs from householderSequence() in that the template argument \p OnTheSide of

View File

@@ -39,9 +39,9 @@ namespace Eigen {
*
* \b Shifting \b strategy: Let \f$ B = S P A P' S \f$ be the scaled matrix on which the factorization is carried out,
* and \f$ \beta \f$ be the minimum value of the diagonal. If \f$ \beta > 0 \f$ then, the factorization is directly
* performed on the matrix B, and \sigma = 0. Otherwise, the factorization is performed on the shifted matrix \f$ B +
* \sigma I \f$ for a shifting factor \f$ \sigma \f$. We start with \f$ \sigma = \sigma_0 - \beta \f$, where \f$
* \sigma_0 \f$ is the initial shift value as returned and set by setInitialShift() method. The default value is \f$
* performed on the matrix B, and \f$ \sigma = 0 \f$. Otherwise, the factorization is performed on the shifted matrix
* \f$ B + \sigma I \f$ for a shifting factor \f$ \sigma \f$. We start with \f$ \sigma = \sigma_0 - \beta \f$, where
* \f$ \sigma_0 \f$ is the initial shift value as returned and set by setInitialShift() method. The default value is \f$
* \sigma_0 = 10^{-3} \f$. If the factorization fails, then the shift in doubled until it succeed or a maximum of ten
* attempts. If it still fails, as returned by the info() method, then you can either increase the initial shift, or
* better use another preconditioning technique.

View File

@@ -46,8 +46,8 @@
#ifndef EIGEN_COLAMD_H
#define EIGEN_COLAMD_H
namespace Eigen {
namespace internal {
namespace Colamd {
/* Ensure that debugging is turned off: */
@@ -318,7 +318,7 @@ static inline void set_defaults(double knobs[NKnobs]) {
*
* \param n_row number of rows in A
* \param n_col number of columns in A
* \param Alen, size of the array A
* \param Alen size of the array A
* \param A row indices of the matrix, of size ALen
* \param p column pointers of A, of size n_col+1
* \param knobs parameter settings for colamd
@@ -1685,6 +1685,6 @@ static inline IndexType clear_mark /* return the new value for tag_mark */
}
} // namespace Colamd
} // namespace internal
} // namespace Eigen
#endif

View File

@@ -13,11 +13,9 @@
// IWYU pragma: private
#include "./InternalHeaderCheck.h"
namespace Eigen {
#include "Eigen_Colamd.h"
namespace Eigen {
namespace internal {
/** \internal

View File

@@ -147,6 +147,8 @@ class BDCSVD : public SVDBase<BDCSVD<MatrixType_, Options_> > {
* One \b cannot request unitaries using both the \a Options template parameter
* and the constructor. If possible, prefer using the \a Options template parameter.
*
* \param rows number of rows for the input matrix
* \param cols number of columns for the input matrix
* \param computationOptions specification for computing Thin/Full unitaries U/V
* \sa BDCSVD()
*

View File

@@ -547,6 +547,8 @@ class JacobiSVD : public SVDBase<JacobiSVD<MatrixType_, Options_> > {
* One \b cannot request unitaries using both the \a Options template parameter
* and the constructor. If possible, prefer using the \a Options template parameter.
*
* \param rows number of rows for the input matrix
* \param cols number of columns for the input matrix
* \param computationOptions specify whether to compute Thin/Full unitaries U/V
* \sa JacobiSVD()
*

View File

@@ -875,7 +875,6 @@ class SparseMatrix : public SparseCompressedBase<SparseMatrix<Scalar_, Options_,
return *this;
}
#ifndef EIGEN_PARSED_BY_DOXYGEN
template <typename OtherDerived>
inline SparseMatrix& operator=(const EigenBase<OtherDerived>& other) {
return Base::operator=(other.derived());
@@ -883,7 +882,6 @@ class SparseMatrix : public SparseCompressedBase<SparseMatrix<Scalar_, Options_,
template <typename Lhs, typename Rhs>
inline SparseMatrix& operator=(const Product<Lhs, Rhs, AliasFreeProduct>& other);
#endif // EIGEN_PARSED_BY_DOXYGEN
template <typename OtherDerived>
EIGEN_DONT_INLINE SparseMatrix& operator=(const SparseMatrixBase<OtherDerived>& other);

View File

@@ -118,7 +118,6 @@ class SparseMatrixBase : public EigenBase<Derived> {
// FIXME storage order do not match evaluator storage order
typedef SparseMatrix<Scalar, Flags & RowMajorBit ? RowMajor : ColMajor, StorageIndex> PlainObject;
#ifndef EIGEN_PARSED_BY_DOXYGEN
/** This is the "real scalar" type; if the \a Scalar type is already real numbers
* (e.g. int, float or double) then \a RealScalar is just the same as \a Scalar. If
* \a Scalar is \a std::complex<T> then RealScalar is \a T.
@@ -127,6 +126,7 @@ class SparseMatrixBase : public EigenBase<Derived> {
*/
typedef typename NumTraits<Scalar>::Real RealScalar;
#ifndef EIGEN_PARSED_BY_DOXYGEN
/** \internal the return type of coeff()
*/
typedef std::conditional_t<HasDirectAccess_, const Scalar&, Scalar> CoeffReturnType;

View File

@@ -30,15 +30,15 @@
#ifndef SPARSELU_COLUMN_DFS_H
#define SPARSELU_COLUMN_DFS_H
template <typename Scalar, typename StorageIndex>
class SparseLUImpl;
// IWYU pragma: private
#include "./InternalHeaderCheck.h"
namespace Eigen {
namespace internal {
template <typename Scalar, typename StorageIndex>
class SparseLUImpl;
template <typename IndexVector, typename ScalarVector>
struct column_dfs_traits : no_assignment_operator {
typedef typename ScalarVector::Scalar Scalar;

View File

@@ -73,7 +73,7 @@ struct traits<SparseQR_QProduct<SparseQRType, Derived> > {
* detailed in the following paper:
* <i>
* Tim Davis, "Algorithm 915, SuiteSparseQR: Multifrontal Multithreaded Rank-Revealing
* Sparse QR Factorization, ACM Trans. on Math. Soft. 38(1), 2011.
* Sparse QR Factorization", ACM Trans. on Math. Soft. 38(1), 2011.
* </i>
* Even though it is qualified as "rank-revealing", this strategy might fail for some
* rank deficient problems. When this class is used to solve linear or least-square problems

View File

@@ -150,6 +150,10 @@ struct CoreThreadPoolDevice {
namespace internal {
#ifdef EIGEN_PARSED_BY_DOXYGEN
struct Kernel;
#endif
template <typename Kernel>
struct cost_helper {
using SrcEvaluatorType = typename Kernel::SrcEvaluatorType;

View File

@@ -96,9 +96,6 @@ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const
}
/** \returns an expression of the coefficient-wise absdiff of \c *this and \a other
*
* Example: \include Cwise_absolute_difference.cpp
* Output: \verbinclude Cwise_absolute_difference.out
*
* \sa absolute_difference()
*/

View File

@@ -523,15 +523,11 @@ using UnaryPowReturnType =
std::enable_if_t<internal::is_arithmetic<typename NumTraits<ScalarExponent>::Real>::value,
CwiseUnaryOp<internal::scalar_unary_pow_op<Scalar, ScalarExponent>, const Derived>>;
#ifndef EIGEN_PARSED_BY_DOXYGEN
template <typename ScalarExponent>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const UnaryPowReturnType<ScalarExponent> pow(
const ScalarExponent& exponent) const {
return UnaryPowReturnType<ScalarExponent>(derived(), internal::scalar_unary_pow_op<Scalar, ScalarExponent>(exponent));
#else
/** \returns an expression of the coefficients of \c *this raised to the constant power \a exponent
*
* \tparam T is the scalar type of \a exponent. It must be compatible with the scalar type of the given expression.
* \tparam ScalarExponent is the scalar type of \a exponent. It must be compatible with the scalar type
* of the given expression.
* \param exponent the scalar exponent value.
*
* This function computes the coefficient-wise power. The function MatrixBase::pow() in the
* unsupported module MatrixFunctions computes the matrix power.
@@ -543,6 +539,6 @@ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const UnaryPowReturnType<ScalarExponent> p
*/
template <typename ScalarExponent>
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const UnaryPowReturnType<ScalarExponent> pow(
const ScalarExponent& exponent) const;
#endif
const ScalarExponent& exponent) const {
return UnaryPowReturnType<ScalarExponent>(derived(), internal::scalar_unary_pow_op<Scalar, ScalarExponent>(exponent));
}

View File

@@ -43,34 +43,17 @@ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const CwiseBinaryOp<CustomBinaryOp, const
return CwiseBinaryOp<CustomBinaryOp, const Derived, const OtherDerived>(derived(), other.derived(), func);
}
#ifndef EIGEN_PARSED_BY_DOXYGEN
EIGEN_MAKE_SCALAR_BINARY_OP(operator*, product)
#else
/** \returns an expression of \c *this scaled by the scalar factor \a scalar
*
* \tparam T is the scalar type of \a scalar. It must be compatible with the scalar type of the given expression.
*/
template <typename T>
const CwiseBinaryOp<internal::scalar_product_op<Scalar, T>, Derived, Constant<T> > operator*(const T& scalar) const;
/** \returns an expression of \a expr scaled by the scalar factor \a scalar
*
* \tparam T is the scalar type of \a scalar. It must be compatible with the scalar type of the given expression.
*/
template <typename T>
friend const CwiseBinaryOp<internal::scalar_product_op<T, Scalar>, Constant<T>, Derived> operator*(
const T& scalar, const StorageBaseType& expr);
#endif
EIGEN_MAKE_SCALAR_BINARY_OP(operator*, product)
#ifndef EIGEN_PARSED_BY_DOXYGEN
EIGEN_MAKE_SCALAR_BINARY_OP_ONTHERIGHT(operator/, quotient)
#else
/** \returns an expression of \c *this divided by the scalar value \a scalar
*
* \tparam T is the scalar type of \a scalar. It must be compatible with the scalar type of the given expression.
*/
template <typename T>
const CwiseBinaryOp<internal::scalar_quotient_op<Scalar, T>, Derived, Constant<T> > operator/(const T& scalar) const;
#endif
EIGEN_MAKE_SCALAR_BINARY_OP_ONTHERIGHT(operator/, quotient)
/** \returns an expression of the coefficient-wise boolean \b and operator of \c *this and \a other
*

View File

@@ -60,9 +60,6 @@ EIGEN_DEVICE_FUNC inline const CwiseSqrtReturnType cwiseSqrt() const { return Cw
/// \returns an expression of the coefficient-wise cube root of *this.
///
/// Example: \include MatrixBase_cwiseCbrt.cpp
/// Output: \verbinclude MatrixBase_cwiseCbrt.out
///
EIGEN_DOC_UNARY_ADDONS(cwiseCbrt, cube - root)
///
/// \sa cwiseSqrt(), cwiseSquare(), cwisePow()