Examples of swapRows()


Examples of com.google.gwt.widgetideas.table.client.SortableGrid.swapRows()

        rowIndexBox1.setText((row1 + 1) + "");
      } else if (sender == swapRowsButton) {
        // Swap two rows
        int row1 = Integer.parseInt(rowIndexBox1.getText());
        int row2 = Integer.parseInt(rowIndexBox2.getText());
        dataTable.swapRows(row1, row2);
      } else if (sender == reverseRowsButton) {
        // Reverse all rows
        dataTable.reverseRows();
      } else if (sender == sortColumnButton) {
        // Sort a column
View Full Code Here

Examples of mikera.matrixx.impl.PermutationMatrix.swapRows()

          biggest = i;
      }

      if (biggest != j) {
        m.swapRows(biggest, j);
        p.swapRows(biggest, j);
      }

      if ((j < n) && (m.get(j, j) != 0.0)) {
        for (int i = j + 1; i < n; i++) {
          m.set(i, j, m.get(i, j) / m.get(j, j));
View Full Code Here

Examples of net.fec.openrq.util.linearalgebra.matrix.ByteMatrix.swapRows()

                // swap in A
                A.swapRows(i, chosenRowPos);

                // swap in X
                X.swapRows(i, chosenRowPos);

                // decoding process - swap in d
                ArrayUtils.swapInts(d, i, chosenRowPos);

                // update values in 'rows' map
View Full Code Here

Examples of org.jamesii.core.math.Matrix.swapRows()

    double[][] data = new double[][] { { 1, 2, 3 }, { 4, 5, 6 }, { 7, 8, 9 } };
    double[][] result =
        new double[][] { { 7, 8, 9 }, { 4, 5, 6 }, { 1, 2, 3 } };

    Matrix m = new Matrix(data);
    m.swapRows(0, 2);

    for (int c = 0; c < m.getColumns(); c++) {
      for (int r = 0; r < m.getRows(); r++) {
        assertEquals(result[r][c], m.getElement(r, c));
      }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.