Macaulay2 Engine
Loading...
Searching...
No Matches

◆ isZero() [1/2]

template<typename RT>
bool MatrixOps::isZero ( const DMat< RT > & A)

Definition at line 213 of file mat-arith.hpp.

214{
215 for (int r = 0; r < A.numRows(); ++r)
216 for (int c = 0; c < A.numColumns(); ++c)
217 if (!A.ring().is_zero(A.entry(r,c))) return false;
218 return true;
219}
size_t numRows() const
Definition dmat.hpp:144
ElementType & entry(size_t row, size_t column)
Definition dmat.hpp:148
const ACoeffRing & ring() const
Definition dmat.hpp:143
size_t numColumns() const
Definition dmat.hpp:145

References DMat< ACoeffRing >::entry(), DMat< ACoeffRing >::numColumns(), DMat< ACoeffRing >::numRows(), and DMat< ACoeffRing >::ring().

Referenced by fill_from_lapack_upper(), fill_from_lapack_upper(), fill_lower_and_upper(), fill_lower_and_upper(), MutableMat< Mat >::is_zero(), DMatLinAlg< RingType >::setUpperLower(), LUUtil< RT >::setUpperLower(), and TEST().