Examples of factor()


Examples of no.uib.cipr.matrix.QR.factor()

    public void testRepeatFactorNonSquare() {
        QR qr = new QR(Ar.numRows(), Ar.numColumns());
        qr.factor(new DenseMatrix(Ar));
        assertEquals(Ar, qr);
        qr.factor(new DenseMatrix(Ar));
        assertEquals(Ar, qr);
    }

    private void assertEquals(Matrix A, QR qr) {
        assertEquals(A, qr.getQ().mult(qr.getR(), A.copy().zero()));
View Full Code Here

Examples of no.uib.cipr.matrix.RQ.factor()

        assertEquals(Ac, rq.factor(new DenseMatrix(Ac)));
    }

    public void testRepeatFactorNonSquare() {
        RQ rq = new RQ(Ac.numRows(), Ac.numColumns());
        rq.factor(new DenseMatrix(Ac));
        assertEquals(Ac, rq);
        rq.factor(new DenseMatrix(Ac));
        assertEquals(Ac, rq);
    }
View Full Code Here

Examples of no.uib.cipr.matrix.RQ.factor()

    public void testRepeatFactorNonSquare() {
        RQ rq = new RQ(Ac.numRows(), Ac.numColumns());
        rq.factor(new DenseMatrix(Ac));
        assertEquals(Ac, rq);
        rq.factor(new DenseMatrix(Ac));
        assertEquals(Ac, rq);
    }

    private void assertEquals(Matrix A, RQ rq) {
        assertEquals(A, rq.getR().mult(rq.getQ(), A.copy().zero()));
View Full Code Here

Examples of no.uib.cipr.matrix.RQ.factor()

        assertEquals(A, RQ.factorize(A));
    }

    public void testFactor() {
        RQ c = new RQ(A.numRows(), A.numColumns());
        assertEquals(A, c.factor(new DenseMatrix(A)));
    }

    public void testRepeatFactor() {
        RQ rq = new RQ(A.numRows(), A.numColumns());
        rq.factor(new DenseMatrix(A));
View Full Code Here

Examples of no.uib.cipr.matrix.RQ.factor()

        assertEquals(A, c.factor(new DenseMatrix(A)));
    }

    public void testRepeatFactor() {
        RQ rq = new RQ(A.numRows(), A.numColumns());
        rq.factor(new DenseMatrix(A));
        assertEquals(A, rq);
        rq.factor(new DenseMatrix(A));
        assertEquals(A, rq);
    }
View Full Code Here

Examples of no.uib.cipr.matrix.RQ.factor()

    public void testRepeatFactor() {
        RQ rq = new RQ(A.numRows(), A.numColumns());
        rq.factor(new DenseMatrix(A));
        assertEquals(A, rq);
        rq.factor(new DenseMatrix(A));
        assertEquals(A, rq);
    }

    public void testStaticFactorizeNonSquare() {
        assertEquals(Ac, RQ.factorize(Ac));
View Full Code Here

Examples of no.uib.cipr.matrix.RQ.factor()

        assertEquals(Ac, RQ.factorize(Ac));
    }

    public void testFactorNonSquare() {
        RQ rq = new RQ(Ac.numRows(), Ac.numColumns());
        assertEquals(Ac, rq.factor(new DenseMatrix(Ac)));
    }

    public void testRepeatFactorNonSquare() {
        RQ rq = new RQ(Ac.numRows(), Ac.numColumns());
        rq.factor(new DenseMatrix(Ac));
View Full Code Here

Examples of no.uib.cipr.matrix.SVD.factor()

        assertEquals(A, SVD.factorize(A));
    }

    public void testFactor() throws NotConvergedException {
        SVD svd = new SVD(A.numRows(), A.numColumns());
        assertEquals(A, svd.factor(A.copy()));
    }

    private void assertEquals(Matrix A, SVD svd) {
        TridiagMatrix S = new TridiagMatrix(svd.getS().length);
        System.arraycopy(svd.getS(), 0, S.getDiagonal(), 0, svd.getS().length);
View Full Code Here

Examples of no.uib.cipr.matrix.SymmBandEVD.factor()

        assertEquals(U, evd.getEigenvalues(), evd.getEigenvectors());
    }

    public void testLowerFactor() throws NotConvergedException {
        SymmBandEVD evd = new SymmBandEVD(A.numRows(), false);
        evd.factor(L.copy());
        assertEquals(L, evd.getEigenvalues(), evd.getEigenvectors());
    }

    public void testUpperFactor() throws NotConvergedException {
        SymmBandEVD evd = new SymmBandEVD(A.numRows(), true);
View Full Code Here

Examples of no.uib.cipr.matrix.SymmDenseEVD.factor()

        assertEquals(U, evd.getEigenvalues(), evd.getEigenvectors());
    }

    public void testLowerFactor() throws NotConvergedException {
        SymmDenseEVD evd = new SymmDenseEVD(A.numRows(), false);
        evd.factor(L.copy());
        assertEquals(L, evd.getEigenvalues(), evd.getEigenvectors());
    }

    public void testUpperFactor() throws NotConvergedException {
        SymmDenseEVD evd = new SymmDenseEVD(A.numRows(), true);
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.