/// <summary>Element-by-element right division, <c>C = A./B</c>.</summary> public static Matrix ArrayDivide(Matrix m1, Matrix m2) { m1.CheckMatrixDimensions(m2); Matrix X = new Matrix(m1.RowCount, m1.ColumnCount); for (int i = 0; i < m1.RowCount; i++) { for (int j = 0; j < m1.ColumnCount; j++) { X[i, j] = m1[i, j] / m2[i, j]; } } return(X); }
/// <summary>Element-by-element right division, <c>C = A./B</c>.</summary> public static Matrix ArrayDivide(Matrix m1, Matrix m2) { m1.CheckMatrixDimensions(m2); Matrix X = new Matrix(m1.RowCount, m1.ColumnCount); for (int i = 0; i < m1.RowCount; i++) for (int j = 0; j < m1.ColumnCount; j++) X[i, j] = m1[i, j] / m2[i, j]; return X; }