Examples of columnCount()


Examples of ch.akuhn.matrix.SparseMatrix.columnCount()

    Stopwatch.enter();
    Stopwatch.p();
    SparseMatrix A = Matrix.sparse(4000, 10000);
    Random rand = new Random(1);
    for (int i = 0; i < A.rowCount(); i++) {
      for (int j = 0; j < A.columnCount(); j++) {
        if (rand.nextDouble() > 0.2) continue;
        A.put(i, j, rand.nextDouble() * 23);
      }
    }
    SingularValues singular = new SingularValues(A, 10).decompose();
View Full Code Here

Examples of com.almworks.sqlite4java.SQLiteStatement.columnCount()

      List<Map<String, Object>> list = new ArrayList<Map<String, Object>>();
      if(st.step()) {
        do {
          // true if there is data (SQLITE_ROW) was returned, false if statement has been completed (SQLITE_DONE)
          Map<String, Object> objectToRead = new HashMap<String, Object>();
          for(int i = 0; i < st.columnCount(); i++) {
            objectToRead.put(st.getColumnName(i), st.columnValue(i));
          }
          list.add(objectToRead);
        } while(st.step() && list.size() < maxResults);
      }
View Full Code Here

Examples of com.almworks.sqlite4java.SQLiteStatement.columnCount()

      protected List<List<Object>> job(SQLiteConnection connection) throws Throwable {
        SQLiteStatement currStatement = connection.prepare(request, false);
        List<List<Object>> datas = new ArrayList<List<Object>>();
        while (currStatement.step()) {
          ArrayList<Object> row = new ArrayList<Object>();
          for (int i = 0; i < currStatement.columnCount(); i++) {
            row.add(currStatement.columnValue(i));
          }
          datas.add(row);
        }
        currStatement.dispose();
View Full Code Here

Examples of com.mycila.testing.plugin.db.api.SqlResults.columnCount()

    //@Test
    public void test_select() throws Exception {
        SqlResults results2 = db2.prepare("SELECT * FROM TESTTYPES").query();
        System.out.println("All results:\n" + results2);
        System.out.println("columns: " + results2.columnCount());
        System.out.println("rows: " + results2.columnCount());
        System.out.println("9th element of row 5: " + results2.row(4).column(8));
        System.out.println("name of column 4: " + results2.columnHeader(3).name());
    }
}
View Full Code Here

Examples of com.mycila.testing.plugin.db.api.SqlResults.columnCount()

    //@Test
    public void test_select() throws Exception {
        SqlResults results2 = db2.prepare("SELECT * FROM TESTTYPES").query();
        System.out.println("All results:\n" + results2);
        System.out.println("columns: " + results2.columnCount());
        System.out.println("rows: " + results2.columnCount());
        System.out.println("9th element of row 5: " + results2.row(4).column(8));
        System.out.println("name of column 4: " + results2.columnHeader(3).name());
    }
}
View Full Code Here

Examples of com.trolltech.qt.core.QAbstractItemModel.columnCount()

        protected boolean filterAcceptsRow(int sourceRow, QModelIndex sourceParent){
            QRegExp filter = filterRegExp();
            QAbstractItemModel model = sourceModel();
            boolean matchFound = false;

            for(int i=0; i < model.columnCount(); i++){
              Object data = model.data(sourceModel().index(sourceRow, i, sourceParent));
              matchFound |= data != null && filter.indexIn(data.toString()) != -1;
            }
            return matchFound;
        }
View Full Code Here

Examples of mikera.matrixx.AMatrix.columnCount()

    AMatrix q=result.getQ();
    AMatrix r=result.getR();
   
    assertTrue(q.isOrthogonal(1e-8));
    assertTrue(r.isUpperTriangular());
    assertTrue(r.rowCount() == a.rowCount() && r.columnCount() == a.columnCount());
   
    assertTrue("product not valid",q.innerProduct(r).epsilonEquals(a));
  }

}
View Full Code Here

Examples of mikera.matrixx.AMatrix.columnCount()

    private boolean extractTogether() {
        // extract the orthogonal from the similar transform
//        V = decomp.getQ(V,true);
        AMatrix temp = decomp.getQ(true);
        V = Matrix.wrap(temp.rowCount(), temp.columnCount(), temp.asDoubleArray());

        // tell eigenvector algorithm to update this matrix as it computes the rotators
        helper.setQ(V);

        vector.setFastEigenvalues(false);
View Full Code Here

Examples of mikera.matrixx.AMatrix.columnCount()

        offSaved = helper.swapOff(offSaved);

        // extract the orthogonal from the similar transform
//        V = decomp.getQ(V,true);
        AMatrix temp = decomp.getQ(true);
        V = Matrix.wrap(temp.rowCount(), temp.columnCount(), temp.asDoubleArray());

        // tell eigenvector algorithm to update this matrix as it computes the rotators
        vector.setQ(V);

        // extract eigenvectors
View Full Code Here

Examples of mikera.matrixx.AMatrix.columnCount()

            "Matrix must be square for inverse!"); }

        double []vv = decomp._getVV();
        AMatrix LU = decomp.getLU();
       
        Matrix A_inv = Matrix.create(LU.rowCount(), LU.columnCount());

        int n = A.columnCount();

        double dataInv[] = A_inv.data;
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.