Examples of subtract()


Examples of java.math.BigInteger.subtract()

   
            // mQ = ((input mod q) ^ dQ)) mod q
            mQ = (input.remainder(q)).modPow(dQ, q);
   
            // h = qInv * (mP - mQ) mod p
            h = mP.subtract(mQ);
            h = h.multiply(qInv);
            h = h.mod(p);               // mod (in Java) returns the positive residual
   
            // m = h * q + mQ
            m = h.multiply(q);
View Full Code Here

Examples of javafx.geometry.Point2D.subtract()

    Point2D p = new Point2D(event.getX(), event.getY());
    for( LineCell cell : visibleCells ) {
      if( cell.getBoundsInParent().contains(p) ) {
        if( cell.getDomainElement() != null ) {
          // Calculate to cell relative
          p = p.subtract(cell.getLayoutX(), cell.getLayoutY());
          Region g = (Region) cell.getGraphic();
          p = p.subtract(g.getLayoutX(), g.getLayoutY());
         
          TextFlow flow = (TextFlow) g.getChildrenUnmodifiable().get(0);
          // Calculate to text flow
View Full Code Here

Examples of jscicalc.complex.Complex.subtract()

  Complex d = new Complex();
  for( Complex o : statMemory ){
      d = d.add( o );
  }
  for( Complex o : statMemoryNeg ){
      d = d.subtract( o );
  }
  if( statSize() > 0 ){
     mean.setValue( d.divide( new Complex( statSize(), 0 ) ) );
  } else {
      mean.setError( true );
View Full Code Here

Examples of lipstone.joshua.parser.types.BigDec.subtract()

    }
   
    while ((operation.equals("sec") || operation.equals("csc") || operation.equals("cot")) && inp.lt(BigDec.ZERO))
      inp = inp.add(new BigDec(Math.PI * 2));
    while ((operation.equals("sec") || operation.equals("csc") || operation.equals("cot")) && inp.gt(new BigDec(Math.PI * 2)))
      inp = inp.subtract(new BigDec(Math.PI * 2));
   
    if (operation.equals("sin"))
      output = new BigDec(ApcomplexMath.sin(inp.getInternal()));
    if (operation.equals("cos"))
      output = new BigDec(ApcomplexMath.cos(inp.getInternal()));
View Full Code Here

Examples of mage.Mana.subtract()

                    else {
                        for (Mana mana: copy) {
                            Mana newMana = new Mana();
                            newMana.add(mana);
                            if (mana.contains(ability.getManaCosts().getMana())) {
                                newMana.subtract(ability.getManaCosts().getMana());
                                newMana.add(ability.getNetMana(game));
                            }
                            this.add(newMana);
                        }
                    }
View Full Code Here

Examples of net.i2p.util.NativeBigInteger.subtract()

      BigInteger X = new NativeBigInteger(1, Wbuf);
     
      // 9: Let c = X mod 2q. Set p = X - ( c - 1 ). Therefore p mod 2q = 1.
     
      BigInteger c = X.mod(q.add(q));
      BigInteger p = X.subtract(c.subtract(BigInteger.ONE));
     
      if(p.bitLength() >= keyLength-1) {
        if(isPrime(p)) {
          finish(r, hashLength, new NativeBigInteger(p), new NativeBigInteger(q), seed, counter);
          return true;
View Full Code Here

Examples of net.minecraft.src.Vec3.subtract()

          //Counteract the base station yaw to get back to absolute razer coordinates
          originOffset.rotateAroundY(-baseStationYawOffset*PIOVER180);

            // save raw - originOffset as origin. That way, when origin is subtracted in the future,
          // positions very close to the current location+orientation will have the eye in the correct spot
          origin = originOffset.subtract(raw);
           
            resetOrigin = false;
        }

        // Rotate the centre eye position around any world yaw offset (mouse/controller induced rotation)
View Full Code Here

Examples of net.wigis.graph.dnv.utilities.Vector2D.subtract()

    Vector2D zeroPixels = ImageRenderer.transformScreenToWorld( 0, 0, minX, maxX, minY, maxY, globalMinX, globalMaxX, globalMinY, globalMaxY, width, height );

    Vector2D fivePixels = ImageRenderer.transformScreenToWorld( 5, 5, minX, maxX, minY, maxY, globalMinX, globalMaxX, globalMinY, globalMaxY, width, height );

    fivePixels.subtract( zeroPixels );

    Vector2D movement = new Vector2D( 0, 0 );
    if( selectedNode == null && sameNode )
    {
      selectedNode = pb.getSelectedNode();
View Full Code Here

Examples of net.wigis.graph.dnv.utilities.Vector3D.subtract()

            if( nodes != null && nodes.size() > 0 )
            {
              anyNodes = true;
              Vector3D color = new Vector3D( LIGHT_GREEN );
              Vector3D difference = new Vector3D( LIGHT_RED );
              difference.subtract( color );
              difference.dotProduct( (float)( distance - 1 ) / (float)maxDistance );
              color.add( difference );
              Vector3D outlineColor = new Vector3D( color );
              outlineColor.setX( (float)Math.max( 0, outlineColor.getX() - 0.3 ) );
              outlineColor.setY( (float)Math.max( 0, outlineColor.getY() - 0.3 ) );
View Full Code Here

Examples of org.apache.batik.ext.awt.geom.RectListManager.subtract()

                    String id = st.nextToken();
                    Object o = rlms.get(id);
                    if (o == null) continue;
                    int overhead = Integer.parseInt(st.nextToken());
                    int lineOverhead = Integer.parseInt(st.nextToken());
                    currRLM.subtract((RectListManager)o,
                                     overhead, lineOverhead);
                }
                else if (CONTAINS_ALL_PREF.equals(pref)) {
                    if (currRLM == null) continue;
                    String id = st.nextToken();
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.