Function MatrixView.opIndex

Returns (a reference to) the element at row i, column j.

ref T opIndex (
  size_t i,
  size_t j
) pure nothrow;

Warning

For convenience, this method returns values by reference. This means that one can do stuff like this:

m[1,2] += 3.14;

Unfortunately, it also means that in a triangular matrix one can change the zero element (which is common for all zero elements).

assert ((m[1,0] == 0.0)  &&  m[2,0] == 0.0);
m[1,0] += 3.14;
assert (m[2,0] == 3.14);    // passes

You are hereby warned.