Examples of times()


Examples of de.lmu.ifi.dbs.elki.math.linearalgebra.Matrix.times()

      for(int i = 0; i < k; i++) {
        V difference = x.minus(means.get(i));
        Matrix differenceRow = difference.getRowVector();
        Vector differenceCol = difference.getColumnVector();
        Matrix rowTimesCov = differenceRow.times(invCovMatr.get(i));
        Vector rowTimesCovTimesCol = rowTimesCov.times(differenceCol);
        double power = rowTimesCovTimesCol.get(0, 0) / 2.0;
        double prob = normDistrFactor.get(i) * Math.exp(-power);
        if(logger.isDebuggingFinest()) {
          logger.debugFinest(" difference vector= ( " + difference.toString() + " )\n" + " differenceRow:\n" + FormatUtil.format(differenceRow, "    ") + "\n" + " differenceCol:\n" + FormatUtil.format(differenceCol, "    ") + "\n" + " rowTimesCov:\n" + FormatUtil.format(rowTimesCov, "    ") + "\n" + " rowTimesCovTimesCol:\n" + FormatUtil.format(rowTimesCovTimesCol, "    ") + "\n" + " power= " + power + "\n" + " prob=" + prob + "\n" + " inv cov matrix: \n" + FormatUtil.format(invCovMatr.get(i), "     "));
        }
View Full Code Here

Examples of de.lmu.ifi.dbs.elki.math.linearalgebra.Vector.times()

        Vector ppq = pc[j].plus(q).timesEquals(MathUtil.SQRTHALF);
        Vector pmq = pc[j].minus(q).timesEquals(MathUtil.SQRTHALF);
        hull.add(ppq);
        hull.add(ppq.times(-1));
        hull.add(pmq);
        hull.add(pmq.times(-1));
      }
      diag.plusEquals(pc[j]);
    }
    diag.timesEquals(1.0 / Math.sqrt(pc.length));
    hull.add(diag);
View Full Code Here

Examples of edu.cmu.sphinx.fst.semiring.Semiring.times()

            if (cl[oldState.getId()] != null) {
                for (State pathFinalState : cl[oldState.getId()].keySet()) {
                    State s1 = pathFinalState;
                    if (s1.getFinalWeight() != semiring.zero()) {
                        s.setFinalWeight(semiring.plus(s.getFinalWeight(),
                                semiring.times(getPathWeight(oldState, s1, cl),
                                        s1.getFinalWeight())));
                    }
                    int numArcs = s1.getNumArcs();
                    for (int j = 0; j < numArcs; j++) {
                        Arc a = s1.getArc(j);
View Full Code Here

Examples of edu.gmu.seor.prognos.unbbayesplugin.cps.Jama.Matrix.times()

   
    if(hasNoParents(continuousNode)){ // special case when it is a root node
      Matrix h = new Matrix(continuousNode.getGHK().getGhkPot().getH().gethMatrix());
      Matrix k = new Matrix(continuousNode.getGHK().getGhkPot().getK().getkMatrix());
     
      g = continuousNode.getGHK().getGhkPot().getG() + h.transpose().times(d).det() - (k.times(d).times(d).times(0.5)).det();
      continuousNode.getGHK().getGhkPot().setG(g);
     
      double[][] hMat = new double[1][1];
      hMat[0][0]=0;
      hc.sethMatrix(hMat);
View Full Code Here

Examples of edu.gmu.seor.prognos.unbbayesplugin.cps.Jama.Matrix.times()

   
      //calculate H Matrix
      temp = new Matrix(kc.getkMatrix());
      temp2 = new Matrix(mchar.getmChar().getMeanMatrix().getMeanMatrix());
      hc.sethMatrix(temp.times(temp2).getArray());
      ghk.setH(hc);
     
      //calculate jpd
      temp = new Matrix(kc.getkMatrix());
      temp2 = new Matrix(mchar.getmChar().getMeanMatrix().getMeanMatrix());
View Full Code Here

Examples of edu.gmu.seor.prognos.unbbayesplugin.cps.Jama.Matrix.times()

   
       
        //calculate H Matrix
        temp = new Matrix(kc.getkMatrix());
        temp2 = new Matrix(mchar.getMeanMatValue(i).getMeanMatrix());
        hc.sethMatrix(temp.times(temp2).getArray());
        resH.add(hc);
       
        //calculate jpd
        temp = new Matrix(kc.getkMatrix());
        temp2 = new Matrix(mchar.getMeanMatValue(i).getMeanMatrix());
View Full Code Here

Examples of edu.gmu.seor.prognos.unbbayesplugin.cps.Jama.Matrix.times()

        resCVM.add(cvm)
       
        //calculate Mean Matrix
        temp = new Matrix(cvm.getCoVarMatrix());
        temp2 = new Matrix(ghkPot.getHValue(i).gethMatrix());
        mm.setMeanMatrix(temp.times(temp2).getArray());
        resMM.add(mm);
      } catch (Exception e) {
        cvm=null;
        resCVM.add(cvm);
        mm=null;
View Full Code Here

Examples of edu.gmu.seor.prognos.unbbayesplugin.cps.Jama.Matrix.times()

      mc.setCoVarMatrix(cvm);
     
      //calculate Mean Matrix
      temp = new Matrix(cvm.getCoVarMatrix());
      temp2 = new Matrix(ghkPot.getGhkPot().getH().gethMatrix());
      mm.setMeanMatrix(temp.times(temp2).getArray());
      mc.setMeanMatrix(mm);
     
      //calculate jpd
      temp = new Matrix(ghkPot.getGhkPot().getK().getkMatrix());
      temp2 = new Matrix(mm.getMeanMatrix());
View Full Code Here

Examples of flanagan.analysis.ErrorProp.times()

           for(int i=0; i<this.numberOfTEmeasurementsGrating; i++){
                ErrorProp theta = new ErrorProp(this.anglesRadTM[i], this.errorsRadTM[i]);
                ErrorProp order = new ErrorProp((double)this.gratingOrderTE[i], 0.0D);
                ErrorProp calc = ErrorProp.sin(theta);
                calc = calc.times(superRI);
                calc = calc.plus(lambda.times(order).over(pitch));
                this.effectiveRefractiveIndicesTE[i] = calc.getValue();
                this.effectiveErrorsTE[i] = calc.getError();
           }
           super.enterTEmodeData(this.thicknessesTE, this.effectiveRefractiveIndicesTE, this.effectiveErrorsTE, this.modeNumbersTE);
View Full Code Here

Examples of flanagan.circuits.Phasor.times()

                    for(int i=0; i<this.length; i++)productcc.times(cc[i]);
                    this.productt.add(productcc);
                    break;
            case 15: Phasor[] pp = this.getArray_as_Phasor();
                    Phasor productpp = Phasor.plusOne();
                    for(int i=0; i<this.length; i++)productpp.times(pp[i]);
                    this.productt.add(productpp);
                    break;
            default: throw new IllegalArgumentException("Data type not identified by this method");
        }
        this.productDone = 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.