- Sort Score
- Result 10 results
- Languages All
Results 101 - 110 of 206 for sqrt1 (0.04 sec)
-
test/typeparam/absdiff.go
// // complex types. // type complexAbs[T Complex] T // // func (a complexAbs[T]) Abs() complexAbs[T] { // r := float64(real(a)) // i := float64(imag(a)) // d := math.Sqrt(r*r + i*i) // return complexAbs[T](complex(d, 0)) // } // // // OrderedAbsDifference returns the absolute value of the difference // // between a and b, where a and b are of an ordered type.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 01 19:45:34 UTC 2022 - 2.9K bytes - Viewed (0) -
tensorflow/cc/gradients/math_grad_test.cc
} TEST_F(CWiseUnaryGradTest, Sqrt) { auto x_fn = [this](const int i) { return RV({0.5, 1, 2, 3, 4, 5, 6, 7}); }; TestCWiseGrad<float, float>(SQRT, x_fn); } TEST_F(CWiseUnaryGradTest, Sqrt_Complex) { auto x_fn = [this](const int i) { return CRV({{-1.0f, 0.5f}, {1.0f, 0.5f}, {2, -1}}); }; TestCWiseGrad<complex64, complex64>(SQRT, x_fn); } TEST_F(CWiseUnaryGradTest, Rsqrt) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri Aug 25 18:20:20 UTC 2023 - 36K bytes - Viewed (0) -
testing/internal-performance-testing/src/main/groovy/org/gradle/performance/measure/DataSeries.java
sumSquares = sumSquares.add(diff); } // This isn't quite right, as we may lose precision when converting to a double BigDecimal result = BigDecimal.valueOf(Math.sqrt(sumSquares.divide(BigDecimal.valueOf(size()), RoundingMode.HALF_UP).doubleValue())).setScale(2, RoundingMode.HALF_UP); standardError = Amount.valueOf(result, baseUnits); } public Amount<Q> getAverage() {
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Thu Apr 04 07:21:38 UTC 2024 - 3.9K bytes - Viewed (0) -
src/hash/maphash/smhasher_test.go
var c float64 // find c such that Prob(mean-c*stddev < x < mean+c*stddev)^N > .9999 for c = 0.0; math.Pow(math.Erf(c/math.Sqrt(2)), float64(N)) < .9999; c += .1 { } c *= 11.0 // allowed slack: 40% to 60% - we don't need to be perfectly random mean := .5 * REP stddev := .5 * math.Sqrt(REP) low := int(mean - c*stddev) high := int(mean + c*stddev) for i := 0; i < n; i++ { for j := 0; j < hashSize; j++ {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 16:41:38 UTC 2024 - 11K bytes - Viewed (0) -
src/math/example_test.go
fmt.Printf("%.2f", math.Tan(0)) // Output: 0.00 } func ExampleTanh() { fmt.Printf("%.2f", math.Tanh(0)) // Output: 0.00 } func ExampleSqrt() { const ( a = 3 b = 4 ) c := math.Sqrt(a*a + b*b) fmt.Printf("%.1f", c) // Output: 5.0 } func ExampleCeil() { c := math.Ceil(1.49) fmt.Printf("%.1f", c) // Output: 2.0 } func ExampleFloor() { c := math.Floor(1.51)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 07 18:09:53 UTC 2021 - 3.7K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/util/flowcontrol/metrics/metrics.go
// Rationale for the bucket boundaries: // For 0--1, evenly spaced and not too many; // For 1--2, roughly powers of sqrt(sqrt(2)); // For 2--6, roughly powers of sqrt(2); // We need coverage over 1, but do not want too many buckets. Buckets: []float64{0.2, 0.4, 0.6, 0.8, 1, 1.2, 1.4, 1.7, 2, 2.8, 4, 6}, StabilityLevel: compbasemetrics.ALPHA, },
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Jul 24 19:40:05 UTC 2023 - 25.6K bytes - Viewed (0) -
src/math/erfinv.go
r := 0.180625 - 0.25*x*x z1 := ((((((a7*r+a6)*r+a5)*r+a4)*r+a3)*r+a2)*r+a1)*r + a0 z2 := ((((((b7*r+b6)*r+b5)*r+b4)*r+b3)*r+b2)*r+b1)*r + b0 ans = (x * z1) / z2 } else { var z1, z2 float64 r := Sqrt(Ln2 - Log(1.0-x)) if r <= 5.0 { r -= 1.6 z1 = ((((((c7*r+c6)*r+c5)*r+c4)*r+c3)*r+c2)*r+c1)*r + c0 z2 = ((((((d7*r+d6)*r+d5)*r+d4)*r+d3)*r+d2)*r+d1)*r + d0 } else { r -= 5.0
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 19 11:59:09 UTC 2023 - 3.4K bytes - Viewed (0) -
test/typeparam/absdiff2.go
} func (a complexAbs[T]) Abs() T { // TODO use direct conversion instead of realimag once #50937 is fixed r, i := realimag(a.Value_) // r := float64(real(a.Value)) // i := float64(imag(a.Value)) d := math.Sqrt(r*r + i*i) return T(complex(d, 0)) } func (a complexAbs[T]) Value() T { return a.Value_ } // OrderedAbsDifference returns the absolute value of the difference
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Mar 09 21:26:42 UTC 2022 - 3.6K bytes - Viewed (0) -
src/crypto/internal/nistec/generate.go
tables[tableIndex].Select(t, windowValue) p.Add(p, t) tableIndex-- } return p, nil } // {{.p}}Sqrt sets e to a square root of x. If x is not a square, {{.p}}Sqrt returns // false and e is unchanged. e and x can overlap. func {{.p}}Sqrt(e, x *{{ .Element }}) (isSquare bool) { candidate := new({{ .Element }}) {{.p}}SqrtCandidate(candidate, x) square := new({{ .Element }}).Square(candidate)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 04 17:29:44 UTC 2024 - 19.7K bytes - Viewed (0) -
test/chan/sieve2.go
composites <- head heap.Push(&h, &PeekCh{<-m, m}) } }() // Sieve out 'composites' from 'candidates'. go func() { // In order to generate the nth prime we only need multiples of // primes ≤ sqrt(nth prime). Thus, the merging goroutine will // receive from 'primes' much slower than this goroutine // will send to it, making the buffer accumulate and block this
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Sun Feb 19 06:44:02 UTC 2012 - 3.9K bytes - Viewed (0)