Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 206 for sqrt1 (0.68 sec)

  1. src/math/big/int_test.go

    			if !testModSqrt(t, &elt, &mod, &sq, &sqrt) {
    				t.Errorf("#%d: failed (sqrt(%d,%d) = %s)", x, &elt, &mod, &sqrt)
    			}
    			isSquare[sq.Uint64()] = true
    		}
    
    		// test all non-squares
    		for x := 1; x < n; x++ {
    			sq.SetInt64(int64(x))
    			z := sqrt.ModSqrt(&sq, &mod)
    			if !isSquare[x] && z != nil {
    				t.Errorf("#%d: failed (sqrt(%d,%d) = nil)", x, &sqrt, &mod)
    			}
    		}
    	}
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 18:42:28 UTC 2024
    - 58.5K bytes
    - Viewed (0)
  2. pkg/scheduler/framework/parallelize/parallelism.go

    }
    
    // chunkSizeFor returns a chunk size for the given number of items to use for
    // parallel work. The size aims to produce good CPU utilization.
    // returns max(1, min(sqrt(n), n/Parallelism))
    func chunkSizeFor(n, parallelism int) int {
    	s := int(math.Sqrt(float64(n)))
    
    	if r := n/parallelism + 1; s > r {
    		s = r
    	} else if s < 1 {
    		s = 1
    	}
    	return s
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 09 17:12:30 UTC 2023
    - 2K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/math/LongMathTest.java

            assertEquals(BigIntegerMath.sqrt(valueOf(x), mode), valueOf(LongMath.sqrt(x, mode)));
          }
        }
      }
    
      /* Relies on the correctness of sqrt(long, FLOOR). */
      @GwtIncompatible // TODO
      public void testSqrtExactMatchesFloorOrThrows() {
        for (long x : POSITIVE_LONG_CANDIDATES) {
          long sqrtFloor = LongMath.sqrt(x, FLOOR);
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Mar 04 20:15:57 UTC 2024
    - 32.5K bytes
    - Viewed (0)
  4. tensorflow/c/experimental/ops/math_ops.cc

      TF_RETURN_IF_ERROR(op_ptr->AddInput(x));
      int num_retvals = 1;
      return op_ptr->Execute(absl::MakeSpan(y, 1), &num_retvals);
    }
    
    // Op: Sqrt()
    // Summary: Computes square root of x element-wise.
    //
    // Description:
    //   I.e., \\(y = \sqrt{x} = x^{1/2}\\).
    Status Sqrt(AbstractContext* ctx, AbstractTensorHandle* const x,
                AbstractTensorHandle** y, const char* name,
                const char* raw_device_name) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 10 19:11:36 UTC 2022
    - 12.2K bytes
    - Viewed (0)
  5. src/math/hypot_386.s

    	FDIVD   F1, F0       // F0=q(=q/p), F1=p
    	FMULD   F0, F0       // F0=q*q, F1=p
    	FLD1                 // F0=1, F1=q*q, F2=p
    	FADDDP  F0, F1       // F0=1+q*q, F1=p
    	FSQRT                // F0=sqrt(1+q*q), F1=p
    	FMULDP  F0, F1       // F0=p*sqrt(1+q*q)
    	FMOVDP  F0, ret+16(FP)
    	RET
    	FMOVDP  F0, F1       // F0=0
    	FMOVDP  F0, ret+16(FP)
    	RET
    not_finite:
    // test bits for -Inf or +Inf
    	MOVL    p_hi+4(FP), AX  // high word p
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 15 15:48:19 UTC 2021
    - 1.8K bytes
    - Viewed (0)
  6. test/fixedbugs/issue60991.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package p
    
    import "math"
    
    func f() {
    	_ = min(0.1, 0.2, math.Sqrt(1))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 26 17:08:05 UTC 2023
    - 242 bytes
    - Viewed (0)
  7. src/math/cmplx/asin.go

    		return complex(math.Copysign(math.Pi/2, re), math.Copysign(re, im))
    	}
    	ct := complex(-imag(x), real(x)) // i * x
    	xx := x * x
    	x1 := complex(1-real(xx), -imag(xx)) // 1 - x*x
    	x2 := Sqrt(x1)                       // x2 = sqrt(1 - x*x)
    	w := Log(ct + x2)
    	return complex(imag(w), -real(w)) // -i * w
    }
    
    // Asinh returns the inverse hyperbolic sine of x.
    func Asinh(x complex128) complex128 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 01 03:16:37 UTC 2020
    - 5.9K bytes
    - Viewed (0)
  8. android/guava-tests/benchmark/com/google/common/math/LongMathRoundingBenchmark.java

          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++) {
          int j = i & ARRAY_MASK;
          tmp += LongMath.sqrt(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int divide(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 2.6K bytes
    - Viewed (0)
  9. guava-tests/benchmark/com/google/common/math/IntMathRoundingBenchmark.java

          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++) {
          int j = i & ARRAY_MASK;
          tmp += IntMath.sqrt(positive[j], mode);
        }
        return tmp;
      }
    
      @Benchmark
      int divide(int reps) {
        int tmp = 0;
        for (int i = 0; i < reps; i++) {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 2.6K bytes
    - Viewed (0)
  10. android/guava-tests/benchmark/com/google/common/math/BigIntegerMathRoundingBenchmark.java

          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++) {
          int j = i & ARRAY_MASK;
          tmp += BigIntegerMath.sqrt(positive[j], mode).intValue();
        }
        return tmp;
      }
    
      @Benchmark
      int divide(int reps) {
        int tmp = 0;
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Jun 30 13:06:20 UTC 2020
    - 2.8K bytes
    - Viewed (0)
Back to top