public double this[int row, int col] { get { if (row < 0 || row > Rows || col < 0 || col > Columns) { throw new IndexOutOfRangeException("Trying to get cell(" + row + ";" + col + ") of matrix(" + Rows + ";" + Columns + ")."); } return(DllImporter.igraph_matrix_e(matrix, row, col)); } set { if (row < 0 || row > Rows || col < 0 || col > Columns) { throw new IndexOutOfRangeException("Trying to set cell(" + row + ";" + col + ") of matrix(" + Rows + ";" + Columns + ")."); } DllImporter.igraph_matrix_set(matrix, row, col, value); } }