Package Jama

Examples of Jama.Matrix.det()


        float rgbDet = (float) RGB.det();

        return new float[] {(R[1] * (float) WGB.det()) / (W[1] * rgbDet),
                            (G[1] * (float) RWB.det()) / (W[1] * rgbDet),
                            (B[1] * (float) RGW.det()) / (W[1] * rgbDet)};
    }

    /*
        8.2 - HSI, HSL, HSV, and related color spaces

View Full Code Here


                    subsolution.set(1, 0, solution.get(3, 0));
                    subsolution.set(1, 1, solution.get(4, 0));

                    // Symmetry: MathUtils.round(subsolution.det()) == -1)
                    // Inverse: MathUtils.isIdentity(subsolution.times(subsolution.transpose()))
                    if (MathUtils.round(subsolution.det()) == 0)
                        continue;

                    // we round transformations to 3 decimal places
                    outTransform.setTransform(
                        solution.get(0, 0),
View Full Code Here

            prepareNewMatrixSize(random);
            final int numRow = getNumRow();
            final int numCol = getNumCol();
            double[] elements = createRandomPositiveValues(numRow * numCol);
            final Matrix reference = new Matrix(elements, numCol).transpose();
            if (!(reference.det() >= DETERMINANT_THRESHOLD)) {
                continue; // To close to a singular matrix - search an other one.
            }
            final MatrixSIS matrix = Matrices.create(numRow, numCol, elements);
            /*
             * Computes new random value for the argument. We mix positive and negative values,
View Full Code Here

            prepareNewMatrixSize(random);
            final int numRow = getNumRow();
            final int numCol = getNumCol();
            final double[] elements = createRandomPositiveValues(numRow * numCol);
            final Matrix reference = new Matrix(elements, numCol).transpose();
            if (!(reference.det() >= DETERMINANT_THRESHOLD)) {
                continue; // To close to a singular matrix - search an other one.
            }
            final MatrixSIS matrix = Matrices.create(numRow, numCol, elements);
            assertEqualsJAMA(reference.inverse(), matrix.inverse(), TOLERANCE);
        }
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.