\returns the value of the matrix at position \a i, \a j * This function returns Scalar(0) if the element is an explicit \em zero */
| 209 | /** \returns the value of the matrix at position \a i, \a j |
| 210 | * This function returns Scalar(0) if the element is an explicit \em zero */ |
| 211 | inline Scalar coeff(Index row, Index col) const { |
| 212 | eigen_assert(row >= 0 && row < rows() && col >= 0 && col < cols()); |
| 213 | |
| 214 | const Index outer = IsRowMajor ? row : col; |
| 215 | const Index inner = IsRowMajor ? col : row; |
| 216 | Index end = m_innerNonZeros ? m_outerIndex[outer] + m_innerNonZeros[outer] : m_outerIndex[outer + 1]; |
| 217 | return m_data.atInRange(m_outerIndex[outer], end, inner); |
| 218 | } |
| 219 | |
| 220 | /** \returns a non-const reference to the value of the matrix at position \a i, \a j. |
| 221 | * |
no test coverage detected