/** * Sorts row indexes */ public void sortRowIndexes() { dcs = Dcs_transpose.cs_transpose(dcs, true); dcs = Dcs_transpose.cs_transpose(dcs, true); if (dcs == null) { throw new IllegalArgumentException("Exception occured in cs_transpose()!"); } rowIndexesSorted = true; }
/** * Sorts row indexes */ public void sortRowIndexes() { dcs = Dcs_transpose.cs_transpose(dcs, true); dcs = Dcs_transpose.cs_transpose(dcs, true); if (dcs == null) { throw new IllegalArgumentException("Exception occured in cs_transpose()!"); } rowIndexesSorted = true; }
C = (mark == 1) ? A : Dcs_transpose.cs_transpose(A, false); if (C == null) return (false); /* bfs of C=A' to find R3,C3 from R0 */
/** * Returns a new matrix that is the transpose of this matrix. This method * creates a new object (not a view), so changes in the returned matrix are * NOT reflected in this matrix. * * @return the transpose of this matrix */ public SparseCCDoubleMatrix2D getTranspose() { Dcs dcst = Dcs_transpose.cs_transpose(dcs, true); SparseCCDoubleMatrix2D tr = new SparseCCDoubleMatrix2D(columns, rows); tr.dcs = dcst; return tr; }
/** * Returns a new matrix that has the same elements as this matrix, but is in * a row-compressed form. This method creates a new object (not a view), so * changes in the returned matrix are NOT reflected in this matrix. * * @return this matrix in a row-compressed form */ public SparseRCDoubleMatrix2D getRowCompressed() { Dcs dcst = Dcs_transpose.cs_transpose(dcs, true); SparseRCDoubleMatrix2D rc = new SparseRCDoubleMatrix2D(rows, columns); rc.columnIndexes = dcst.i; rc.rowPointers = dcst.p; rc.values = dcst.x; rc.columnIndexesSorted = true; return rc; }
/** * Returns a new matrix that is the transpose of this matrix. This method * creates a new object (not a view), so changes in the returned matrix are * NOT reflected in this matrix. * * @return the transpose of this matrix */ public SparseCCDoubleMatrix2D getTranspose() { Dcs dcst = Dcs_transpose.cs_transpose(dcs, true); SparseCCDoubleMatrix2D tr = new SparseCCDoubleMatrix2D(columns, rows); tr.dcs = dcst; return tr; }
/** * Returns a new matrix that has the same elements as this matrix, but is in * a row-compressed form. This method creates a new object (not a view), so * changes in the returned matrix are NOT reflected in this matrix. * * @return this matrix in a row-compressed form */ public SparseRCDoubleMatrix2D getRowCompressed() { Dcs dcst = Dcs_transpose.cs_transpose(dcs, true); SparseRCDoubleMatrix2D rc = new SparseRCDoubleMatrix2D(rows, columns); rc.columnIndexes = dcst.i; rc.rowPointers = dcst.p; rc.values = dcst.x; rc.columnIndexesSorted = true; return rc; }
dcs = Dcs_transpose.cs_transpose(dcs, true); dcs = Dcs_transpose.cs_transpose(dcs, true); if (dcs == null) { throw new IllegalArgumentException("Exception occured in cs_transpose()!");
dcs = Dcs_transpose.cs_transpose(dcs, true); dcs = Dcs_transpose.cs_transpose(dcs, true); if (dcs == null) { throw new IllegalArgumentException("Exception occured in cs_transpose()!");
dcs = Dcs_transpose.cs_transpose(dcs, true); dcs = Dcs_transpose.cs_transpose(dcs, true); if (dcs == null) { throw new IllegalArgumentException("Exception occured in cs_transpose()!");
dcs = Dcs_transpose.cs_transpose(dcs, true); dcs = Dcs_transpose.cs_transpose(dcs, true); if (dcs == null) { throw new IllegalArgumentException("Exception occured in cs_transpose()!");
C = (m2 < n2) ? Dcs_transpose.cs_transpose(A, false) : A; /* transpose if needed */ if (C == null) return null;
delta = colcount = new int[n]; /* allocate result */ w = new int[s]; /* get workspace */ AT = Dcs_transpose.cs_transpose(A, false); /* AT = A' */ ancestor = w; maxfirst = w;
AT = Dcs_transpose.cs_transpose(A, false); /* compute A' */ if (AT == null) return (null); A2 = Dcs_transpose.cs_transpose(AT, false); /* A2 = AT' */
Ap = A.p; D = Dcs_util.cs_dalloc(n, 0); /* allocate result */ AT = Dcs_transpose.cs_transpose(A, false); /* AT = A' */ xi = new int[2 * n + 1]; /* get workspace */ if (D == null || AT == null)
AT = Dcs_transpose.cs_transpose(A, true); /* Ax=b is underdetermined */ S = Dcs_sqr.cs_sqr(order, AT, true); /* ordering and symbolic analysis */