mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-09-17 03:43:13 +08:00
Several changes in comments to keep Doxygen happy.
This commit is contained in:
parent
3d9764ee24
commit
1420f8b3a1
@ -266,7 +266,7 @@ class Array
|
|||||||
#define EIGEN_MAKE_ARRAY_TYPEDEFS(Type, TypeSuffix, Size, SizeSuffix) \
|
#define EIGEN_MAKE_ARRAY_TYPEDEFS(Type, TypeSuffix, Size, SizeSuffix) \
|
||||||
/** \ingroup arraytypedefs */ \
|
/** \ingroup arraytypedefs */ \
|
||||||
typedef Array<Type, Size, Size> Array##SizeSuffix##SizeSuffix##TypeSuffix; \
|
typedef Array<Type, Size, Size> Array##SizeSuffix##SizeSuffix##TypeSuffix; \
|
||||||
/** \ingroup matrixtypedefs */ \
|
/** \ingroup arraytypedefs */ \
|
||||||
typedef Array<Type, Size, 1> Array##SizeSuffix##TypeSuffix;
|
typedef Array<Type, Size, 1> Array##SizeSuffix##TypeSuffix;
|
||||||
|
|
||||||
#define EIGEN_MAKE_ARRAY_FIXED_TYPEDEFS(Type, TypeSuffix, Size) \
|
#define EIGEN_MAKE_ARRAY_FIXED_TYPEDEFS(Type, TypeSuffix, Size) \
|
||||||
|
@ -251,7 +251,7 @@ DenseBase<Derived>::LinSpaced(Sequential_t, Index size, const Scalar& low, const
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \copydoc DenseBase<Derived>::LinSpaced(Sequential_t, Index, const Scalar&, const Scalar&)
|
* \copydoc DenseBase::LinSpaced(Sequential_t, Index, const Scalar&, const Scalar&)
|
||||||
* Special version for fixed size types which does not require the size parameter.
|
* Special version for fixed size types which does not require the size parameter.
|
||||||
*/
|
*/
|
||||||
template<typename Derived>
|
template<typename Derived>
|
||||||
@ -284,7 +284,7 @@ DenseBase<Derived>::LinSpaced(Index size, const Scalar& low, const Scalar& high)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \copydoc DenseBase<Derived>::LinSpaced(Index, const Scalar&, const Scalar&)
|
* \copydoc DenseBase::LinSpaced(Index, const Scalar&, const Scalar&)
|
||||||
* Special version for fixed size types which does not require the size parameter.
|
* Special version for fixed size types which does not require the size parameter.
|
||||||
*/
|
*/
|
||||||
template<typename Derived>
|
template<typename Derived>
|
||||||
@ -359,6 +359,7 @@ DenseStorageBase<Derived>::setConstant(Index size, const Scalar& value)
|
|||||||
*
|
*
|
||||||
* \param rows the new number of rows
|
* \param rows the new number of rows
|
||||||
* \param cols the new number of columns
|
* \param cols the new number of columns
|
||||||
|
* \param value the value to which all coefficients are set
|
||||||
*
|
*
|
||||||
* Example: \include Matrix_setConstant_int_int.cpp
|
* Example: \include Matrix_setConstant_int_int.cpp
|
||||||
* Output: \verbinclude Matrix_setConstant_int_int.out
|
* Output: \verbinclude Matrix_setConstant_int_int.out
|
||||||
|
@ -45,14 +45,13 @@ template<typename Derived> class DenseBase
|
|||||||
#endif // not EIGEN_PARSED_BY_DOXYGEN
|
#endif // not EIGEN_PARSED_BY_DOXYGEN
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
#ifndef EIGEN_PARSED_BY_DOXYGEN
|
|
||||||
using ei_special_scalar_op_base<Derived,typename ei_traits<Derived>::Scalar,
|
using ei_special_scalar_op_base<Derived,typename ei_traits<Derived>::Scalar,
|
||||||
typename NumTraits<typename ei_traits<Derived>::Scalar>::Real>::operator*;
|
typename NumTraits<typename ei_traits<Derived>::Scalar>::Real>::operator*;
|
||||||
|
|
||||||
class InnerIterator;
|
class InnerIterator;
|
||||||
|
|
||||||
typedef typename ei_traits<Derived>::StorageKind StorageKind;
|
typedef typename ei_traits<Derived>::StorageKind StorageKind;
|
||||||
typedef typename ei_traits<Derived>::Index Index;
|
typedef typename ei_traits<Derived>::Index Index; /**< The type of indices */
|
||||||
typedef typename ei_traits<Derived>::Scalar Scalar;
|
typedef typename ei_traits<Derived>::Scalar Scalar;
|
||||||
typedef typename ei_packet_traits<Scalar>::type PacketScalar;
|
typedef typename ei_packet_traits<Scalar>::type PacketScalar;
|
||||||
typedef typename NumTraits<Scalar>::Real RealScalar;
|
typedef typename NumTraits<Scalar>::Real RealScalar;
|
||||||
@ -90,8 +89,6 @@ template<typename Derived> class DenseBase
|
|||||||
using Base::colStride;
|
using Base::colStride;
|
||||||
using typename Base::CoeffReturnType;
|
using typename Base::CoeffReturnType;
|
||||||
|
|
||||||
#endif // not EIGEN_PARSED_BY_DOXYGEN
|
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
|
|
||||||
RowsAtCompileTime = ei_traits<Derived>::RowsAtCompileTime,
|
RowsAtCompileTime = ei_traits<Derived>::RowsAtCompileTime,
|
||||||
|
@ -65,7 +65,10 @@ template<typename MatrixType, unsigned int UpLo> class SelfAdjointView
|
|||||||
public:
|
public:
|
||||||
|
|
||||||
typedef TriangularBase<SelfAdjointView> Base;
|
typedef TriangularBase<SelfAdjointView> Base;
|
||||||
|
|
||||||
|
/** \brief The type of coefficients in this matrix */
|
||||||
typedef typename ei_traits<SelfAdjointView>::Scalar Scalar;
|
typedef typename ei_traits<SelfAdjointView>::Scalar Scalar;
|
||||||
|
|
||||||
typedef typename MatrixType::Index Index;
|
typedef typename MatrixType::Index Index;
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
|
@ -135,7 +135,7 @@ template<typename MatrixType,int _Direction> class Homogeneous
|
|||||||
*
|
*
|
||||||
* \return an expression of the equivalent homogeneous vector
|
* \return an expression of the equivalent homogeneous vector
|
||||||
*
|
*
|
||||||
* \vectoronly
|
* \only_for_vectors
|
||||||
*
|
*
|
||||||
* Example: \include MatrixBase_homogeneous.cpp
|
* Example: \include MatrixBase_homogeneous.cpp
|
||||||
* Output: \verbinclude MatrixBase_homogeneous.out
|
* Output: \verbinclude MatrixBase_homogeneous.out
|
||||||
|
@ -277,19 +277,6 @@ typedef Quaternion<double> Quaterniond;
|
|||||||
* Specialization of Map<Quaternion<Scalar>>
|
* Specialization of Map<Quaternion<Scalar>>
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
/** \class Map<Quaternion>
|
|
||||||
*
|
|
||||||
*
|
|
||||||
* \brief Expression of a quaternion from a memory buffer
|
|
||||||
*
|
|
||||||
* \param _Scalar the type of the Quaternion coefficients
|
|
||||||
* \param PacketAccess see class Map
|
|
||||||
*
|
|
||||||
* This is a specialization of class Map for Quaternion. This class allows to view
|
|
||||||
* a 4 scalar memory buffer as an Eigen's Quaternion object.
|
|
||||||
*
|
|
||||||
* \sa class Map, class Quaternion, class QuaternionBase
|
|
||||||
*/
|
|
||||||
template<typename _Scalar, int _PacketAccess>
|
template<typename _Scalar, int _PacketAccess>
|
||||||
struct ei_traits<Map<Quaternion<_Scalar>, _PacketAccess> >:
|
struct ei_traits<Map<Quaternion<_Scalar>, _PacketAccess> >:
|
||||||
ei_traits<Quaternion<_Scalar> >
|
ei_traits<Quaternion<_Scalar> >
|
||||||
@ -301,6 +288,16 @@ ei_traits<Quaternion<_Scalar> >
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/** \brief Expression of a quaternion from a memory buffer
|
||||||
|
*
|
||||||
|
* \param _Scalar the type of the Quaternion coefficients
|
||||||
|
* \param PacketAccess see class Map
|
||||||
|
*
|
||||||
|
* This is a specialization of class Map for Quaternion. This class allows to view
|
||||||
|
* a 4 scalar memory buffer as an Eigen's Quaternion object.
|
||||||
|
*
|
||||||
|
* \sa class Map, class Quaternion, class QuaternionBase
|
||||||
|
*/
|
||||||
template<typename _Scalar, int PacketAccess>
|
template<typename _Scalar, int PacketAccess>
|
||||||
class Map<Quaternion<_Scalar>, PacketAccess >
|
class Map<Quaternion<_Scalar>, PacketAccess >
|
||||||
: public QuaternionBase<Map<Quaternion<_Scalar>, PacketAccess> >
|
: public QuaternionBase<Map<Quaternion<_Scalar>, PacketAccess> >
|
||||||
|
@ -914,7 +914,7 @@ struct ei_projective_transform_inverse<TransformType, Projective>
|
|||||||
* \returns the inverse transformation according to some given knowledge
|
* \returns the inverse transformation according to some given knowledge
|
||||||
* on \c *this.
|
* on \c *this.
|
||||||
*
|
*
|
||||||
* \param traits allows to optimize the inversion process when the transformation
|
* \param hint allows to optimize the inversion process when the transformation
|
||||||
* is known to be not a general transformation. The possible values are:
|
* is known to be not a general transformation. The possible values are:
|
||||||
* - Projective if the transformation is not necessarily affine, i.e., if the
|
* - Projective if the transformation is not necessarily affine, i.e., if the
|
||||||
* last row is not guaranteed to be [0 ... 0 1]
|
* last row is not guaranteed to be [0 ... 0 1]
|
||||||
|
@ -87,7 +87,7 @@ Output: \verbinclude Tutorial_AdvancedInitialization_LinSpaced.out
|
|||||||
|
|
||||||
This example shows that objects like the ones returned by LinSpaced() can be assigned to variables (and
|
This example shows that objects like the ones returned by LinSpaced() can be assigned to variables (and
|
||||||
expressions). Eigen defines utility functions like \link DenseBase::setZero() setZero()\endlink,
|
expressions). Eigen defines utility functions like \link DenseBase::setZero() setZero()\endlink,
|
||||||
\link MatrixBase::setIdentity() \endlink and \link DenseBase:setLinSpaced() \endlink to do this
|
\link MatrixBase::setIdentity() \endlink and \link DenseBase::setLinSpaced() \endlink to do this
|
||||||
conveniently. The following example contrasts three ways to construct the matrix
|
conveniently. The following example contrasts three ways to construct the matrix
|
||||||
\f$ J = \bigl[ \begin{smallmatrix} O & I \\ I & O \end{smallmatrix} \bigr] \f$: using static methods and
|
\f$ J = \bigl[ \begin{smallmatrix} O & I \\ I & O \end{smallmatrix} \bigr] \f$: using static methods and
|
||||||
assignment, using static methods and the comma-initializer, or using the setXxx() methods.
|
assignment, using static methods and the comma-initializer, or using the setXxx() methods.
|
||||||
|
@ -37,7 +37,7 @@ The \em trace of a matrix, as returned by the function \c trace(), is the sum of
|
|||||||
|
|
||||||
|
|
||||||
\subsection TutorialReductionsVisitorsBroadcastingReductionsNorm Norm reductions
|
\subsection TutorialReductionsVisitorsBroadcastingReductionsNorm Norm reductions
|
||||||
Eigen also provides reductions to obtain the Euclidean norm or squared norm of a vector with \link MatrixBase::norm() norm() \endlink and \link Matrix::squaredNorm() squaredNorm() \endlink respectively.
|
Eigen also provides reductions to obtain the Euclidean norm or squared norm of a vector with \link MatrixBase::norm() norm() \endlink and \link MatrixBase::squaredNorm() squaredNorm() \endlink respectively.
|
||||||
These operations can also operate on matrices; in that case, they use the Frobenius norm. The following example shows these methods.
|
These operations can also operate on matrices; in that case, they use the Frobenius norm. The following example shows these methods.
|
||||||
|
|
||||||
<table class="tutorial_code"><tr><td>
|
<table class="tutorial_code"><tr><td>
|
||||||
@ -190,7 +190,7 @@ reductions and partial reductions.
|
|||||||
|
|
||||||
Now that broadcasting, reductions and partial reductions have been introduced, we can dive into a more advanced example that finds
|
Now that broadcasting, reductions and partial reductions have been introduced, we can dive into a more advanced example that finds
|
||||||
the nearest neighbour of a vector <tt>v</tt> within the columns of matrix <tt>m</tt>. The Euclidean distance will be used in this example,
|
the nearest neighbour of a vector <tt>v</tt> within the columns of matrix <tt>m</tt>. The Euclidean distance will be used in this example,
|
||||||
computing the squared Euclidean distance with the partial reduction named \link DenseBase::squaredNorm() squaredNorm() \endlink:
|
computing the squared Euclidean distance with the partial reduction named \link MatrixBase::squaredNorm() squaredNorm() \endlink:
|
||||||
|
|
||||||
<table class="tutorial_code"><tr><td>
|
<table class="tutorial_code"><tr><td>
|
||||||
Example: \include Tutorial_ReductionsVisitorsBroadcasting_broadcast_1nn.cpp
|
Example: \include Tutorial_ReductionsVisitorsBroadcasting_broadcast_1nn.cpp
|
||||||
|
@ -457,7 +457,7 @@ mat = 2 7 8
|
|||||||
\endcode</td></tr>
|
\endcode</td></tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
Special versions of \link DenseBase::minCoeff(int*,int*) minCoeff \endlink and \link DenseBase::maxCoeff(int*,int*) maxCoeff \endlink:
|
Special versions of \link DenseBase::minCoeff(Index*,Index*) minCoeff \endlink and \link DenseBase::maxCoeff(Index*,Index*) maxCoeff \endlink:
|
||||||
<div class="desired_tutorial_width">
|
<div class="desired_tutorial_width">
|
||||||
\code
|
\code
|
||||||
int i, j;
|
int i, j;
|
||||||
@ -476,8 +476,8 @@ if((array1 < array2).any()) ... // if there exist a pair i,j such that array1(i,
|
|||||||
|
|
||||||
<a href="#" class="top">top</a>\section QuickRef_Blocks Sub-matrices
|
<a href="#" class="top">top</a>\section QuickRef_Blocks Sub-matrices
|
||||||
|
|
||||||
Read-write access to a \link DenseBase::col(int) column \endlink
|
Read-write access to a \link DenseBase::col(Index) column \endlink
|
||||||
or a \link DenseBase::row(int) row \endlink of a matrix (or array):
|
or a \link DenseBase::row(Index) row \endlink of a matrix (or array):
|
||||||
<div class="desired_tutorial_width">
|
<div class="desired_tutorial_width">
|
||||||
\code
|
\code
|
||||||
mat1.row(i) = mat2.col(j);
|
mat1.row(i) = mat2.col(j);
|
||||||
@ -501,9 +501,9 @@ Read-write access to sub-vectors:
|
|||||||
Read-write access to sub-matrices:</td><td></td><td></td></tr>
|
Read-write access to sub-matrices:</td><td></td><td></td></tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>\code mat1.block(i,j,rows,cols)\endcode
|
<td>\code mat1.block(i,j,rows,cols)\endcode
|
||||||
\link DenseBase::block(int,int,int,int) (more) \endlink</td>
|
\link DenseBase::block(Index,Index,Index,Index) (more) \endlink</td>
|
||||||
<td>\code mat1.block<rows,cols>(i,j)\endcode
|
<td>\code mat1.block<rows,cols>(i,j)\endcode
|
||||||
\link DenseBase::block(int,int) (more) \endlink</td>
|
\link DenseBase::block(Index,Index) (more) \endlink</td>
|
||||||
<td>the \c rows x \c cols sub-matrix \n starting from position (\c i,\c j)</td></tr>
|
<td>the \c rows x \c cols sub-matrix \n starting from position (\c i,\c j)</td></tr>
|
||||||
<tr><td>\code
|
<tr><td>\code
|
||||||
mat1.topLeftCorner(rows,cols)
|
mat1.topLeftCorner(rows,cols)
|
||||||
@ -547,7 +547,7 @@ Declare a diagonal matrix</td><td>\code
|
|||||||
DiagonalMatrix<Scalar,SizeAtCompileTime> diag1(size);
|
DiagonalMatrix<Scalar,SizeAtCompileTime> diag1(size);
|
||||||
diag1.diagonal() = vector;\endcode
|
diag1.diagonal() = vector;\endcode
|
||||||
</td></tr>
|
</td></tr>
|
||||||
<tr><td>Access the \link MatrixBase::diagonal() diagonal \endlink and \link MatrixBase::diagonal(int) super/sub diagonals \endlink of a matrix as a vector (read/write)</td>
|
<tr><td>Access the \link MatrixBase::diagonal() diagonal \endlink and \link MatrixBase::diagonal(Index) super/sub diagonals \endlink of a matrix as a vector (read/write)</td>
|
||||||
<td>\code
|
<td>\code
|
||||||
vec1 = mat1.diagonal(); mat1.diagonal() = vec1; // main diagonal
|
vec1 = mat1.diagonal(); mat1.diagonal() = vec1; // main diagonal
|
||||||
vec1 = mat1.diagonal(+n); mat1.diagonal(+n) = vec1; // n-th super diagonal
|
vec1 = mat1.diagonal(+n); mat1.diagonal(+n) = vec1; // n-th super diagonal
|
||||||
|
Loading…
x
Reference in New Issue
Block a user