Searched refs:diagonal (Results 1 - 25 of 84) sorted by relevance

1234

/external/eigen/test/
H A Ddiagonal.cpp12 template<typename MatrixType> void diagonal(const MatrixType& m) function
26 //check diagonal()
27 VERIFY_IS_APPROX(m1.diagonal(), m1.transpose().diagonal());
28 m2.diagonal() = 2 * m1.diagonal();
29 m2.diagonal()[0] *= 3;
38 // check sub/super diagonal
39 if(m1.template diagonal<N1>().RowsAtCompileTime!=Dynamic)
41 VERIFY(m1.template diagonal<N
[all...]
H A Dnesting_ops.cpp29 VERIFY_IS_APPROX( (m.transpose() * m).diagonal().sum(), (m.transpose() * m).diagonal().sum() );
30 VERIFY_IS_APPROX( (m.transpose() * m).diagonal().array().abs().sum(), (m.transpose() * m).diagonal().array().abs().sum() );
H A Dbandmatrix.cpp29 m.diagonal().setConstant(123);
30 dm1.diagonal().setConstant(123);
33 m.diagonal(i).setConstant(static_cast<RealScalar>(i));
34 dm1.diagonal(i).setConstant(static_cast<RealScalar>(i));
38 m.diagonal(-i).setConstant(-static_cast<RealScalar>(i));
39 dm1.diagonal(-i).setConstant(-static_cast<RealScalar>(i));
H A Dselfadjoint.cpp27 m1.diagonal() = m1.diagonal().real().template cast<Scalar>();
H A Ddiagonalmatrices.cpp45 VERIFY_IS_APPROX(ldm1.diagonal(), ldm3.diagonal());
47 VERIFY_IS_APPROX(ldm1.diagonal(), ldm4.diagonal());
57 VERIFY_IS_APPROX( ((ldm1 * m1)(i,j)) , ldm1.diagonal()(i) * m1(i,j) );
58 VERIFY_IS_APPROX( ((ldm1 * (m1+m2))(i,j)) , ldm1.diagonal()(i) * (m1+m2)(i,j) );
59 VERIFY_IS_APPROX( ((m1 * rdm1)(i,j)) , rdm1.diagonal()(j) * m1(i,j) );
/external/eigen/doc/snippets/
H A DMatrixBase_diagonal_int.cpp3 cout << "Here are the coefficients on the 1st super-diagonal and 2nd sub-diagonal of m:" << endl
4 << m.diagonal(1).transpose() << endl
5 << m.diagonal(-2).transpose() << endl;
H A DMatrixBase_diagonal_template_int.cpp3 cout << "Here are the coefficients on the 1st super-diagonal and 2nd sub-diagonal of m:" << endl
4 << m.diagonal<1>().transpose() << endl
5 << m.diagonal<-2>().transpose() << endl;
H A DMatrixBase_diagonal.cpp3 cout << "Here are the coefficients on the main diagonal of m:" << endl
4 << m.diagonal() << endl;
H A DTridiagonalization_diagonal.cpp10 VectorXd diag = triOfA.diagonal();
11 cout << "The diagonal is:" << endl << diag << endl;
/external/eigen/failtest/
H A Dconst_qualified_diagonal_method_retval.cpp12 Diagonal<Matrix3d> b(m.diagonal());
/external/eigen/Eigen/src/Core/
H A DDiagonalMatrix.h47 { other.diagonal() += diagonal(); }
50 { other.diagonal() -= diagonal(); }
52 inline const DiagonalVectorType& diagonal() const { return derived().diagonal(); } function in class:Eigen::DiagonalBase
53 inline DiagonalVectorType& diagonal() { return derived().diagonal(); } function in class:Eigen::DiagonalBase
55 inline Index rows() const { return diagonal().size(); }
56 inline Index cols() const { return diagonal()
137 inline const DiagonalVectorType& diagonal() const { return m_diagonal; } function in class:Eigen::DiagonalMatrix
139 inline DiagonalVectorType& diagonal() { return m_diagonal; } function in class:Eigen::DiagonalMatrix
241 DiagonalWrapper(DiagonalVectorType& diagonal) argument
244 const DiagonalVectorType& diagonal() const { return m_diagonal; } function in class:Eigen::DiagonalWrapper
[all...]
H A DDiagonalProduct.h51 inline DiagonalProduct(const MatrixType& matrix, const DiagonalType& diagonal) argument
52 : m_matrix(matrix), m_diagonal(diagonal)
54 eigen_assert(diagonal.diagonal().size() == (ProductOrder == OnTheLeft ? matrix.rows() : matrix.cols()));
62 return m_diagonal.diagonal().coeff(ProductOrder == OnTheLeft ? row : col) * m_matrix.coeff(row, col);
83 internal::pset1<PacketScalar>(m_diagonal.diagonal().coeff(id)));
94 m_diagonal.diagonal().template packet<DiagonalVectorPacketLoadMode>(id));
101 /** \returns the diagonal matrix product of \c *this by the diagonal matrix \a diagonal
[all...]
H A DBandMatrix.h83 /** \returns a vector expression of the main diagonal */
84 inline Block<CoefficientsType,1,SizeAtCompileTime> diagonal() function in class:Eigen::internal::BandMatrixBase
87 /** \returns a vector expression of the main diagonal (const version) */
88 inline const Block<const CoefficientsType,1,SizeAtCompileTime> diagonal() const function in class:Eigen::internal::BandMatrixBase
108 /** \returns a vector expression of the \a N -th sub or super diagonal */
109 template<int N> inline typename DiagonalIntReturnType<N>::Type diagonal() function in class:Eigen::internal::BandMatrixBase
114 /** \returns a vector expression of the \a N -th sub or super diagonal */
115 template<int N> inline const typename DiagonalIntReturnType<N>::Type diagonal() const function in class:Eigen::internal::BandMatrixBase
120 /** \returns a vector expression of the \a i -th sub or super diagonal */
121 inline Block<CoefficientsType,1,Dynamic> diagonal(Inde function in class:Eigen::internal::BandMatrixBase
128 inline const Block<const CoefficientsType,1,Dynamic> diagonal(Index i) const function in class:Eigen::internal::BandMatrixBase
[all...]
H A DDiagonal.h19 * \brief Expression of a diagonal/subdiagonal/superdiagonal in a matrix
21 * \param MatrixType the type of the object in which we are taking a sub/main/super diagonal
22 * \param DiagIndex the index of the sub/super diagonal. The default is 0 and it means the main diagonal.
28 * This class represents an expression of the main diagonal, or any sub/super diagonal
29 * of a square matrix. It is the return type of MatrixBase::diagonal() and MatrixBase::diagonal(Index) and most of the
32 * \sa MatrixBase::diagonal(), MatrixBase::diagonal(Inde
167 MatrixBase<Derived>::diagonal() function in class:Eigen::MatrixBase
175 MatrixBase<Derived>::diagonal() const function in class:Eigen::MatrixBase
193 MatrixBase<Derived>::diagonal(Index index) function in class:Eigen::MatrixBase
201 MatrixBase<Derived>::diagonal(Index index) const function in class:Eigen::MatrixBase
220 MatrixBase<Derived>::diagonal() function in class:Eigen::MatrixBase
229 MatrixBase<Derived>::diagonal() const function in class:Eigen::MatrixBase
[all...]
/external/ceres-solver/internal/ceres/
H A Dlevenberg_marquardt_strategy_test.cc56 RegularizationCheckingLinearSolver(const int num_cols, const double* diagonal) argument
58 diagonal_(diagonal) {
131 double diagonal[3]; local
132 diagonal[0] = options.min_lm_diagonal;
133 diagonal[1] = 2.0;
134 diagonal[2] = options.max_lm_diagonal;
136 diagonal[i] = sqrt(diagonal[i] / options.initial_radius);
139 RegularizationCheckingLinearSolver linear_solver(3, diagonal);
H A Dcompressed_row_sparse_matrix_test.cc184 Vector diagonal(5);
186 diagonal(i) = i + 1;
191 diagonal.data(), blocks));
205 for (int i = 0; i < diagonal.size(); ++i) {
206 EXPECT_EQ(y[i], diagonal[i]);
211 for (int i = 0; i < diagonal.size(); ++i) {
212 EXPECT_EQ(y[i], diagonal[i]);
217 EXPECT_EQ((dense.diagonal() - diagonal).norm(), 0.0);
H A Dcompressed_row_sparse_matrix.h74 // Build a square sparse diagonal matrix with num_rows rows and
75 // columns. The diagonal m(i,i) = diagonal(i);
76 CompressedRowSparseMatrix(const double* diagonal, int num_rows);
128 const double* diagonal,
H A Dsymmetric_linear_solver_test.cc50 double diagonal[] = { 1.0, 1.0, 1.0 }; local
52 A(TripletSparseMatrix::CreateSparseDiagonalMatrix(diagonal, 3));
H A Dpolynomial.cc54 companion_matrix_offdiagonal.diagonal().setZero();
96 companion_matrix_offdiagonal.diagonal() = companion_matrix.diagonal();
110 companion_matrix.diagonal(-1).setOnes();
/external/eigen/doc/
H A Dtutorial.cpp15 m3.diagonal().setOnes();
33 m4.diagonal().block(1,2).setOnes();
34 std::cout << "*** Step 5 ***\nm4.diagonal():\n" << m4.diagonal() << std::endl;
35 std::cout << "m4.diagonal().start(3)\n" << m4.diagonal().start(3) << std::endl;
/external/eigen/test/eigen2/
H A Deigen2_submatrices.cpp93 //check diagonal()
94 VERIFY_IS_APPROX(m1.diagonal(), m1.transpose().diagonal());
95 m2.diagonal() = 2 * m1.diagonal();
96 m2.diagonal()[0] *= 3;
97 VERIFY_IS_APPROX(m2.diagonal()[0], static_cast<Scalar>(6) * m1.diagonal()[0]);
H A Deigen2_svd.cpp62 for(int i = 0; i < rows; i++) VERIFY(positive.diagonal()[i] >= 0); // cheap necessary (not sufficient) condition for positivity
68 for(int i = 0; i < rows; i++) VERIFY(positive.diagonal()[i] >= 0); // cheap necessary (not sufficient) condition for positivity
/external/eigen/Eigen/src/Eigenvalues/
H A DTridiagonalization.h44 * main diagonal and the first diagonal below and above it. The Hessenberg
197 * - the diagonal and lower sub-diagonal represent the real tridiagonal
257 * returned by diagonal() and subDiagonal() instead of creating a new
261 * matrixQ(), packedMatrix(), diagonal(), subDiagonal()
269 /** \brief Returns the diagonal of the tridiagonal matrix T in the decomposition.
271 * \returns expression representing the diagonal of T
282 DiagonalReturnType diagonal() const;
292 * \sa diagonal() fo
305 Tridiagonalization<MatrixType>::diagonal() const function in class:Eigen::Tridiagonalization
[all...]
/external/eigen/unsupported/Eigen/src/NonLinearOptimization/
H A Dqrsolv.h28 // the diagonal, though the diagonal is restored afterward
31 /* in particular, save the diagonal elements of r in x. */
32 x = s.diagonal();
37 /* eliminate the diagonal matrix d using a givens rotation. */
41 /* diagonal element using p from the qr factorization. */
57 /* compute the modified diagonal element of r and */
82 sdiag = s.diagonal();
83 s.diagonal() = x;
/external/eigen/Eigen/src/SVD/
H A DUpperBidiagonalization.h71 return HouseholderUSequenceType(m_householder, m_householder.diagonal().conjugate());
77 return HouseholderVSequenceType(m_householder, m_householder.const_derived().template diagonal<1>())
108 m_bidiagonal.template diagonal<0>().coeffRef(k));
120 m_bidiagonal.template diagonal<1>().coeffRef(k));

Completed in 344 milliseconds

1234