\returns the determinant of the triangular matrix * \sa MatrixBase::determinant() */
| 319 | /** \returns the determinant of the triangular matrix |
| 320 | * \sa MatrixBase::determinant() */ |
| 321 | EIGEN_DEVICE_FUNC |
| 322 | Scalar determinant() const |
| 323 | { |
| 324 | if (Mode & UnitDiag) |
| 325 | return 1; |
| 326 | else if (Mode & ZeroDiag) |
| 327 | return 0; |
| 328 | else |
| 329 | return m_matrix.diagonal().prod(); |
| 330 | } |
| 331 | |
| 332 | protected: |
| 333 |