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

◆ operator+=()

template<typename MatType>
void SubMatrix< MatType >::operator+= ( SubMatrix< MatType > src)
inline

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

138 {
140 long rA = begin_row;
141 long rB = src.begin_row;
142 for (; rA < end_row; ++rA, ++rB)
143 {
144 long cA = begin_column;
145 long cB = src.begin_column;
146 for (; cA < end_column; ++cA, ++cB)
147 {
148 auto& a = matrix.entry(rA, cA);
149 matrix.ring().add(a, a, src.matrix.entry(rB, cB));
150 }
151 }
152 }
const long begin_row
Definition mat-arith.hpp:84
const long begin_column
Definition mat-arith.hpp:86
const long end_column
Definition mat-arith.hpp:87
bool sameSize(const SubMatrix &b) const
const long end_row
Definition mat-arith.hpp:85
MatType & matrix
Definition mat-arith.hpp:83

References begin_column, begin_row, end_column, end_row, matrix, sameSize(), and SubMatrix().