Package de.lmu.ifi.dbs.elki.math.linearalgebra

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


        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));
        for(int l = k + 1; l < pc.length; l++) {
          Vector r = pc[k];
          Vector ppqpr = ppq.plus(r).timesEquals(Math.sqrt(1 / 3.));
          Vector pmqpr = pmq.plus(r).timesEquals(Math.sqrt(1 / 3.));
          Vector ppqmr = ppq.minus(r).timesEquals(Math.sqrt(1 / 3.));
View Full Code Here

          hull.add(pmqpr);
          hull.add(pmqpr.times(-1));
          hull.add(ppqmr);
          hull.add(ppqmr.times(-1));
          hull.add(pmqmr);
          hull.add(pmqmr.times(-1));
        }
      }
      diag.plusEquals(pc[j]);
    }
    diag.timesEquals(1.0 / Math.sqrt(pc.length));
View Full Code Here

        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

        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));
        for(int l = k + 1; l < pc.length; l++) {
          Vector r = pc[k];
          Vector ppqpr = ppq.plus(r).timesEquals(Math.sqrt(1 / 3.));
          Vector pmqpr = pmq.plus(r).timesEquals(Math.sqrt(1 / 3.));
          Vector ppqmr = ppq.minus(r).timesEquals(Math.sqrt(1 / 3.));
View Full Code Here

          hull.add(pmqpr);
          hull.add(pmqpr.times(-1));
          hull.add(ppqmr);
          hull.add(ppqmr.times(-1));
          hull.add(pmqmr);
          hull.add(pmqmr.times(-1));
        }
      }
      diag.plusEquals(pc[j]);
    }
    diag.timesEquals(1.0 / Math.sqrt(pc.length));
View Full Code Here

   * @return the orthonormal basis generated by this method.
   * @throws RuntimeException if the given vectors are not linear independent.
   */
  private Matrix generateOrthonormalBasis(List<Vector> vectors) {
    Vector first = vectors.get(0);
    first = first.times(1.0 / first.euclideanLength());
    Matrix ret = new Matrix(first.getDimensionality(), vectors.size());
    ret.setCol(0, first);
    for(int i = 1; i < vectors.size(); i++) {
      // System.out.println("Matrix:" + ret);
      Vector v_i = vectors.get(i);
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.