/** * Performs a matrix inversion operations that takes advantage of the special * properties of a covariance matrix. * * @param cov On input it is a covariance matrix, on output it is the inverse. Modified. * @return true if it could invert the matrix false if it could not. */ public static boolean invert( DenseMatrix64F cov ) { return invert(cov,cov); }
/** * Performs a matrix inversion operations that takes advantage of the special * properties of a covariance matrix. * * @param cov On input it is a covariance matrix, on output it is the inverse. Modified. * @return true if it could invert the matrix false if it could not. */ public static boolean invert( DenseMatrix64F cov ) { return invert(cov,cov); }
/** * Performs a matrix inversion operations that takes advantage of the special * properties of a covariance matrix. * * @param cov On input it is a covariance matrix, on output it is the inverse. Modified. * @return true if it could invert the matrix false if it could not. */ public static boolean invert( DenseMatrix64F cov ) { return invert(cov,cov); }
public void computeInverse() { CovarianceOps.invert(covariance,covarianceInv); }
public Matrix calc(Matrix source) { DenseMatrix64F matrix = null; if (source instanceof EJMLDenseDoubleMatrix2D) { matrix = ((EJMLDenseDoubleMatrix2D) source).getWrappedObject(); } else { matrix = new EJMLDenseDoubleMatrix2D(source).getWrappedObject(); } DenseMatrix64F ret = new DenseMatrix64F(matrix.numRows, matrix.numCols); CovarianceOps.invert(matrix, ret); return new EJMLDenseDoubleMatrix2D(ret); }
private void computeInverseCovariance() { Q.set(0,0,found.cxx); Q.set(0,1,found.cxy); Q.set(1,0,found.cxy); Q.set(1,1,found.cyy); Q.print(); CovarianceOps.invert(Q); Q.print(); // extract elements for speed found.sxx = Q.get(0,0); found.sxy = Q.get(1,0); found.syy = Q.get(1,1); }