Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for Kulp (0.14 sec)

  1. src/math/big/ftoa.go

    }
    
    func roundShortest(d *decimal, x *Float) {
    	// if the mantissa is zero, the number is zero - stop now
    	if len(d.mant) == 0 {
    		return
    	}
    
    	// Approach: All numbers in the interval [x - 1/2ulp, x + 1/2ulp]
    	// (possibly exclusive) round to x for the given precision of x.
    	// Compute the lower and upper bound in decimal form and find the
    	// shortest decimal number d such that lower <= d <= upper.
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 11:59:09 UTC 2023
    - 13.5K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/math/DoubleMathTest.java

        }
      }
    
      @GwtIncompatible // #trueLog2, Math.ulp
      public void testLog2Accuracy() {
        for (double d : POSITIVE_FINITE_DOUBLE_CANDIDATES) {
          double dmLog2 = DoubleMath.log2(d);
          double trueLog2 = trueLog2(d);
          assertTrue(Math.abs(dmLog2 - trueLog2) <= Math.ulp(trueLog2));
        }
      }
    
      public void testLog2SemiMonotonic() {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 07 17:50:39 UTC 2024
    - 28.1K bytes
    - Viewed (0)
  3. src/math/big/ratconv_test.go

    	// Table 14: Stress Inputs for Conversion to 24-bit Binary, <1/2 ULP
    	"5e-20",
    	"67e+14",
    	"985e+15",
    	"7693e-42",
    	"55895e-16",
    	"996622e-44",
    	"7038531e-32",
    	"60419369e-46",
    	"702990899e-20",
    	"6930161142e-48",
    	"25933168707e+13",
    	"596428896559e+20",
    
    	// Table 15: Stress Inputs for Conversion to 24-bit Binary, >1/2 ULP
    	"3e-23",
    	"57e+18",
    	"789e-35",
    	"2539e-18",
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Nov 15 22:16:34 UTC 2023
    - 19.3K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/math/DoubleMath.java

       * </ul>
       *
       * <p>The computed result is within 1 ulp of the exact result.
       *
       * <p>If the result of this method will be immediately rounded to an {@code int}, {@link
       * #log2(double, RoundingMode)} is faster.
       */
      public static double log2(double x) {
        return log(x) / LN_2; // surprisingly within 1 ulp according to tests
      }
    
      /**
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 07 17:50:39 UTC 2024
    - 18.9K bytes
    - Viewed (0)
  5. guava/src/com/google/common/math/DoubleMath.java

       * </ul>
       *
       * <p>The computed result is within 1 ulp of the exact result.
       *
       * <p>If the result of this method will be immediately rounded to an {@code int}, {@link
       * #log2(double, RoundingMode)} is faster.
       */
      public static double log2(double x) {
        return log(x) / LN_2; // surprisingly within 1 ulp according to tests
      }
    
      /**
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 07 17:50:39 UTC 2024
    - 18.9K bytes
    - Viewed (0)
  6. src/html/template/js_test.go

    		{uint32(42), " 42 ", false},
    		{int16(-42), " -42 ", false},
    		{uint16(42), " 42 ", false},
    		{int64(-42), " -42 ", false},
    		{uint64(42), " 42 ", false},
    		{uint64(1) << 53, " 9007199254740992 ", false},
    		// ulp(1 << 53) > 1 so this loses precision in JS
    		// but it is still a representable integer literal.
    		{uint64(1)<<53 + 1, " 9007199254740993 ", false},
    		{float32(1.0), " 1 ", false},
    		{float32(-1.0), " -1 ", false},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Feb 27 02:20:11 UTC 2024
    - 12.6K bytes
    - Viewed (0)
  7. src/math/erf.go

    //         point of erf(x) is near 0.6174 (i.e., erf(x)=x when x is
    //         near 0.6174), and by some experiment, 0.84375 is chosen to
    //         guarantee the error is less than one ulp for erf.
    //
    //      2. For |x| in [0.84375,1.25], let s = |x| - 1, and
    //         c = 0.84506291151 rounded to single (24 bits)
    //              erf(x)  = sign(x) * (c  + P1(s)/Q1(s))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 11 16:34:30 UTC 2022
    - 11.5K bytes
    - Viewed (0)
  8. src/strconv/atof.go

    // and include err.Num = s.
    //
    // If s is not syntactically well-formed, ParseFloat returns err.Err = ErrSyntax.
    //
    // If s is syntactically well-formed but is more than 1/2 ULP
    // away from the largest floating point number of the given size,
    // ParseFloat returns f = ±Inf, err.Err = ErrRange.
    //
    // ParseFloat recognizes the string "NaN", and the (possibly signed) strings "Inf" and "Infinity"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 06 18:50:50 UTC 2022
    - 15.9K bytes
    - Viewed (0)
  9. src/math/cmplx/cmath_test.go

    	if isExact(real(b)) {
    		realAlike = alike(real(a), real(b))
    	} else {
    		// Allow non-exact special cases to have errors in ULP.
    		realAlike = veryclose(real(a), real(b))
    	}
    	if isExact(imag(b)) {
    		imagAlike = alike(imag(a), imag(b))
    	} else {
    		// Allow non-exact special cases to have errors in ULP.
    		imagAlike = veryclose(imag(a), imag(b))
    	}
    	return realAlike && imagAlike
    }
    func isExact(x float64) bool {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 01 03:16:37 UTC 2020
    - 48.1K bytes
    - Viewed (0)
  10. testing/performance/src/templates/native-dependents-resources/googleTest/libs/googleTest/1.7.0/include/gtest/internal/gtest-internal.h

      // calculations are done with 80-bit precision, while double has 64
      // bits.  Therefore, 4 should be enough for ordinary use.
      //
      // See the following article for more details on ULP:
      // http://randomascii.wordpress.com/2012/02/25/comparing-floating-point-numbers-2012-edition/
      static const size_t kMaxUlps = 4;
    
      // Constructs a FloatingPoint from a raw floating-point number.
      //
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 04 07:21:38 UTC 2024
    - 43.1K bytes
    - Viewed (0)
Back to top