Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for log1p (0.02 sec)

  1. android/guava/src/com/google/common/hash/BloomFilter.java

         * is close to 1 (why?), gives the following formula.
         */
        double fractionOfBitsSet = (double) bitCount / bitSize;
        return DoubleMath.roundToLong(
            -Math.log1p(-fractionOfBitsSet) * bitSize / numHashFunctions, RoundingMode.HALF_UP);
      }
    
      /** Returns the number of bits in the underlying bit array. */
      @VisibleForTesting
      long bitSize() {
        return bits.bitSize();
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sun Aug 31 13:15:26 UTC 2025
    - 26.9K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/math/BigIntegerMathTest.java

      @GwtIncompatible // TODO
      public void testLog10HalfEven() {
        for (BigInteger x : POSITIVE_BIGINTEGER_CANDIDATES) {
          int halfEven = BigIntegerMath.log10(x, HALF_EVEN);
          // Now figure out what rounding mode we should behave like (it depends if FLOOR was
          // odd/even).
          boolean floorWasEven = (BigIntegerMath.log10(x, FLOOR) & 1) == 0;
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 27K bytes
    - Viewed (0)
  3. android/guava-tests/benchmark/com/google/common/math/BigIntegerMathRoundingBenchmark.java

          int j = i & ARRAY_MASK;
          tmp += BigIntegerMath.log2(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int log10(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
          int j = i & ARRAY_MASK;
          tmp += BigIntegerMath.log10(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int sqrt(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Dec 19 18:03:30 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/math/IntMathTest.java

            assertEquals(BigIntegerMath.log10(valueOf(x), mode), IntMath.log10(x, mode));
          }
        }
      }
    
      // Relies on the correctness of log10(int, FLOOR) and of pow(int, int).
      @GwtIncompatible // pow()
      public void testLog10Exact() {
        for (int x : POSITIVE_INTEGER_CANDIDATES) {
          int floor = IntMath.log10(x, FLOOR);
          boolean expectSuccess = IntMath.pow(10, floor) == x;
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Mon Aug 11 19:31:30 UTC 2025
    - 24.1K bytes
    - Viewed (0)
  5. src/main/java/org/codelibs/core/log/JulLoggerAdapter.java

        }
    
        @Override
        public void info(final String message, final Throwable t) {
            logger.logp(Level.INFO, sourceClass, null, message, t);
        }
    
        @Override
        public boolean isDebugEnabled() {
            return logger.isLoggable(Level.FINE);
        }
    
        @Override
        public void debug(final String message) {
            logger.logp(Level.FINE, sourceClass, null, message);
    Registered: Fri Sep 05 20:58:11 UTC 2025
    - Last Modified: Thu Jun 19 09:12:22 UTC 2025
    - 2.9K bytes
    - Viewed (0)
  6. guava-tests/test/com/google/common/math/LongMathTest.java

      @GwtIncompatible // TODO
      public void testLog10MatchesBigInteger() {
        for (long x : POSITIVE_LONG_CANDIDATES) {
          for (RoundingMode mode : ALL_SAFE_ROUNDING_MODES) {
            assertEquals(BigIntegerMath.log10(valueOf(x), mode), LongMath.log10(x, mode));
          }
        }
      }
    
      // Relies on the correctness of log10(long, FLOOR) and of pow(long, int).
      @GwtIncompatible // TODO
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Mon Aug 11 19:31:30 UTC 2025
    - 31.4K bytes
    - Viewed (0)
  7. android/guava-tests/benchmark/com/google/common/math/IntMathRoundingBenchmark.java

          int j = i & ARRAY_MASK;
          tmp += IntMath.log2(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int log10(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
          int j = i & ARRAY_MASK;
          tmp += IntMath.log10(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int sqrt(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Dec 19 18:03:30 UTC 2024
    - 2.6K bytes
    - Viewed (0)
  8. guava-tests/benchmark/com/google/common/math/BigIntegerMathRoundingBenchmark.java

          int j = i & ARRAY_MASK;
          tmp += BigIntegerMath.log2(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int log10(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
          int j = i & ARRAY_MASK;
          tmp += BigIntegerMath.log10(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int sqrt(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Dec 19 18:03:30 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  9. android/guava-tests/benchmark/com/google/common/math/LongMathRoundingBenchmark.java

          int j = i & ARRAY_MASK;
          tmp += LongMath.log2(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int log10(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
          int j = i & ARRAY_MASK;
          tmp += LongMath.log10(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int sqrt(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Dec 19 18:03:30 UTC 2024
    - 2.6K bytes
    - Viewed (0)
  10. guava/src/com/google/common/math/BigIntegerMath.java

       *     is not a power of ten
       */
      @GwtIncompatible // TODO
      @SuppressWarnings("fallthrough")
      public static int log10(BigInteger x, RoundingMode mode) {
        checkPositive("x", x);
        if (fitsInLong(x)) {
          return LongMath.log10(x.longValue(), mode);
        }
    
        int approxLog10 = (int) (log2(x, FLOOR) * LN_2 / LN_10);
        BigInteger approxPow = BigInteger.TEN.pow(approxLog10);
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 18.8K bytes
    - Viewed (0)
Back to top