Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 263 for double (0.23 sec)

  1. android/guava/src/com/google/common/primitives/Doubles.java

       * value).hashCode()}.
       *
       * <p><b>Java 8+ users:</b> use {@link Double#hashCode(double)} instead.
       *
       * @param value a primitive {@code double} value
       * @return a hash code for the value
       */
      public static int hashCode(double value) {
        return ((Double) value).hashCode();
        // TODO(kevinb): do it this way when we can (GWT problem):
        // long bits = Double.doubleToLongBits(value);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 29 15:43:06 GMT 2024
    - 27.1K bytes
    - Viewed (0)
  2. android/guava-tests/benchmark/com/google/common/math/StatsBenchmark.java

        KAHAN {
          @Override
          double mean(double[] values) {
            double sum = 0.0;
            double c = 0.0;
            for (double value : values) {
              double y = value - c;
              double t = sum + y;
              c = (t - sum) - y;
              sum = t;
            }
            return sum / values.length;
          }
        },
        KNUTH {
          @Override
          double mean(double[] values) {
            double mean = values[0];
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 4.7K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/math/DoubleMathTest.java

      }
    
      public void testLog2NaNInfinity() {
        assertEquals(Double.POSITIVE_INFINITY, DoubleMath.log2(Double.POSITIVE_INFINITY));
        assertTrue(Double.isNaN(DoubleMath.log2(Double.NEGATIVE_INFINITY)));
        assertTrue(Double.isNaN(DoubleMath.log2(Double.NaN)));
      }
    
      @GwtIncompatible // StrictMath
      private strictfp double trueLog2(double d) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 07 17:50:39 GMT 2024
    - 28.1K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/math/StatsTesting.java

      static final double MANY_VALUES_MAX = 555.555;
      static final double MANY_VALUES_MIN = -44.44;
    
      // Doubles which will overflow if summed:
      static final double[] LARGE_VALUES = {Double.MAX_VALUE, Double.MAX_VALUE / 2.0};
      static final double LARGE_VALUES_MEAN = 0.75 * Double.MAX_VALUE;
    
      static final ImmutableList<Double> OTHER_MANY_VALUES =
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Nov 09 22:49:56 GMT 2023
    - 22.4K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/util/concurrent/AtomicDoubleTest.java

      private static final double[] VALUES = {
        Double.NEGATIVE_INFINITY,
        -Double.MAX_VALUE,
        (double) Long.MIN_VALUE,
        (double) Integer.MIN_VALUE,
        -Math.PI,
        -1.0,
        -Double.MIN_VALUE,
        -0.0,
        +0.0,
        Double.MIN_VALUE,
        1.0,
        Math.PI,
        (double) Integer.MAX_VALUE,
        (double) Long.MAX_VALUE,
        Double.MAX_VALUE,
        Double.POSITIVE_INFINITY,
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Feb 09 22:57:07 GMT 2022
    - 10.2K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/math/LinearTransformation.java

        final double slope;
        final double yIntercept;
    
        @CheckForNull @LazyInit LinearTransformation inverse;
    
        RegularLinearTransformation(double slope, double yIntercept) {
          this.slope = slope;
          this.yIntercept = yIntercept;
          this.inverse = null; // to be lazily initialized
        }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri May 12 17:02:53 GMT 2023
    - 9.6K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/math/ToDoubleRounder.java

            case HALF_UP:
              return Double.MAX_VALUE * sign(x);
            case FLOOR:
              return (roundArbitrarily == Double.POSITIVE_INFINITY)
                  ? Double.MAX_VALUE
                  : Double.NEGATIVE_INFINITY;
            case CEILING:
              return (roundArbitrarily == Double.POSITIVE_INFINITY)
                  ? Double.POSITIVE_INFINITY
                  : -Double.MAX_VALUE;
            case UP:
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 07 17:50:39 GMT 2024
    - 5.8K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/primitives/DoubleArrayAsListTest.java

          Double[] suffix = {(double) 86, (double) 99};
          Double[] all = concat(concat(prefix, elements), suffix);
          return asList(all).subList(2, elements.length + 2);
        }
      }
    
      private static Double[] concat(Double[] left, Double[] right) {
        Double[] result = new Double[left.length + right.length];
        System.arraycopy(left, 0, result, 0, left.length);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Jun 01 09:32:35 GMT 2023
    - 5.6K bytes
    - Viewed (0)
  9. guava-tests/benchmark/com/google/common/math/QuantilesBenchmark.java

      @Param QuantilesAlgorithm algorithm;
    
      private double[][] datasets = new double[0x100][];
    
      @BeforeExperiment
      void setUp() {
        Random rng = new Random();
        for (int i = 0; i < 0x100; i++) {
          datasets[i] = new double[datasetSize];
          for (int j = 0; j < datasetSize; j++) {
            datasets[i][j] = rng.nextDouble();
          }
        }
      }
    
      private double[] dataset(int i) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 3.1K bytes
    - Viewed (0)
  10. guava-tests/benchmark/com/google/common/math/StatsBenchmark.java

        KAHAN {
          @Override
          double mean(double[] values) {
            double sum = 0.0;
            double c = 0.0;
            for (double value : values) {
              double y = value - c;
              double t = sum + y;
              c = (t - sum) - y;
              sum = t;
            }
            return sum / values.length;
          }
        },
        KNUTH {
          @Override
          double mean(double[] values) {
            double mean = values[0];
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 4.7K bytes
    - Viewed (0)
Back to top