diff --git a/src/Numerics/LinearAlgebra/Matrix.cs b/src/Numerics/LinearAlgebra/Matrix.cs index 4bb626f9..b5f9c7e4 100644 --- a/src/Numerics/LinearAlgebra/Matrix.cs +++ b/src/Numerics/LinearAlgebra/Matrix.cs @@ -718,10 +718,10 @@ namespace MathNet.Numerics.LinearAlgebra /// /// The index of the column to remove. /// A new matrix without the chosen column. - /// If is < zero or > the number of columns. + /// If is < zero or >= the number of columns. public Matrix RemoveColumn(int columnIndex) { - if (columnIndex < 0 || columnIndex > ColumnCount) + if (columnIndex < 0 || columnIndex >= ColumnCount) { throw new ArgumentOutOfRangeException("columnIndex"); } @@ -834,10 +834,10 @@ namespace MathNet.Numerics.LinearAlgebra /// /// The index of the row to remove. /// A new matrix without the chosen row. - /// If is < zero or > the number of rows. + /// If is < zero or >= the number of rows. public Matrix RemoveRow(int rowIndex) { - if (rowIndex < 0 || rowIndex > RowCount) + if (rowIndex < 0 || rowIndex >= RowCount) { throw new ArgumentOutOfRangeException("rowIndex"); }