Demos and Usage of java.lang.Math.exp(double a)


   1:                 return Double.NaN;
   2:             return Math.exp(-1.0 * Plan.beta * t) * o.getStateRegion().value;
   3:         } else {
   4:             return Double.NaN;
   5:         }

View Full Code Here
   1:         {
   2:                 return (- 1 / (Math.PI * Math.pow(sigma, 4))) * (1.0 - ((x*x + y*y)/ (2 * sigma * sigma)))
   3:                                 *
   4:         ...
   5:                         Math.exp(-((x*x + y*y) / (2 * sigma * sigma)));
   6:         }
   7:         public String toString() { return "Laplacian of Gaussian 2D "+sigma;  }
   8: }

View Full Code Here
   1:     public double getValue(double x) {
   2:         return Math.exp(-1.0 * (x - this.mean) * (x - this.mean) 
   3:         ...
   4:                 / (2 * this.std * this.std)) / Math.sqrt(2 * Math.PI 
   5:                 * this.std * this.std);
   6:     }

View Full Code Here
   1:             if (zz > (1.036961043 / u + 1.4)) continue;
   2:             if (2.0 * Math.log(u) < (- zz * 0.5 )) return(z*z);
   3:         }
   4:         ...
   5:         if (freedom != freedom_in) {
   6:             b = Math.sqrt(freedom - 1.0);
   7:             vm = - 0.6065306597 * (1.0 - 0.25 / (b * b + 1.0));
   8:         ...
   9:             if (zz > (1.036961043 / u + 1.4)) continue;
  10:             if (2.0 * Math.log(u) < (Math.log(1.0 + z / b) * b * b - zz * 0.5 - z * b)) return((z + b)*(z + b));
  11:         }
  12:         ...
  13:     double logGamma = Fun.logGamma(freedom/2.0);
  14:     return Math.exp((freedom/2.0 - 1.0) * Math.log(x/2.0) - x/2.0 - logGamma) / 2.0;

View Full Code Here
   1: public final class Util {
   2:   public static final double SQRT2PI = Math.sqrt(2*Math.PI);
   3:         ...
   4:   public static final double LOG10 = Math.log(10);
   5: 
   6:         ...
   7:       double y = f.evaluate(x);
   8:       min = Math.min(min, y);
   9:       max = Math.max(max, y);
  10:         ...
  11:       public double evaluate(double x) {
  12:         return Math.exp(-(x-x0)*(x-x0)/s2)/sigma/SQRT2PI;

View Full Code Here
   1:             p = b * randomGenerator.raw();
   2:                 gds = Math.exp(Math.log(p) / a);
   3:         ...
   4:                 if (Math.log(randomGenerator.raw()) <= -gds) return(gds/lambda);
   5:             }
   6:         ...
   7:                 gds = - Math.log ((b - p) / a);
   8:         ...
   9:                 if (Math.log(randomGenerator.raw()) <= ((a - 1.0) * Math.log(gds))) return(gds/lambda);

View Full Code Here

  

View Full Code Here
   1: import bamboo.vivaldi.Vivaldi;
   2: import java.math.BigDecimal;
   3:         ...
   4: import java.math.BigInteger;
   5: import java.net.InetAddress;
   6:         ...
   7: import static bamboo.util.StringUtil.addr_to_sbuf;
   8: import static java.lang.Math.ceil;
   9: import static java.lang.Math.exp;

View Full Code Here