if (nz < 0) { System.out.print(String.format("%d-by-%d, nzmax: %d nnz: %d, 1-norm: %g\n", m, n, nzmax, Ap[n], Dcs_norm .cs_norm(A))); for (j = 0; j < n; j++) { System.out.print(String.format(" col %d : locations %d to %d\n", j, Ap[j], Ap[j + 1] - 1));
/** * Returns the 1-norm of matrix <tt>A</tt>, which is the maximum absolute * column sum. */ public double norm1(DoubleMatrix2D A) { DoubleProperty.DEFAULT.checkSparse(A); double norm; if (A instanceof SparseCCDoubleMatrix2D) { norm = Dcs_norm.cs_norm((Dcs) A.elements()); } else { norm = Dcs_norm.cs_norm(((SparseRCDoubleMatrix2D) A).getColumnCompressed().elements()); } return norm; }
/** * Returns the 1-norm of matrix <tt>A</tt>, which is the maximum absolute * column sum. */ public double norm1(DoubleMatrix2D A) { DoubleProperty.DEFAULT.checkSparse(A); double norm; if (A instanceof SparseCCDoubleMatrix2D) { norm = Dcs_norm.cs_norm((Dcs) A.elements()); } else { norm = Dcs_norm.cs_norm(((SparseRCDoubleMatrix2D) A).getColumnCompressed().elements()); } return norm; }