Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 50 for sqrt1 (0.56 sec)

  1. test/codegen/math.go

    	sink64[4] = math.RoundToEven(x)
    }
    
    func sqrt(x float64) float64 {
    	// amd64:"SQRTSD"
    	// 386/sse2:"SQRTSD" 386/softfloat:-"SQRTD"
    	// arm64:"FSQRTD"
    	// arm/7:"SQRTD"
    	// mips/hardfloat:"SQRTD" mips/softfloat:-"SQRTD"
    	// mips64/hardfloat:"SQRTD" mips64/softfloat:-"SQRTD"
    	// wasm:"F64Sqrt"
    	// ppc64x:"FSQRT"
    	// riscv64: "FSQRTD"
    	return math.Sqrt(x)
    }
    
    func sqrt32(x float32) float32 {
    	// amd64:"SQRTSS"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 04 15:24:29 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  2. src/math/sqrt.go

    // and "bias" are found in src/math/bits.go
    
    // Sqrt returns the square root of x.
    //
    // Special cases are:
    //
    //	Sqrt(+Inf) = +Inf
    //	Sqrt(±0) = ±0
    //	Sqrt(x < 0) = NaN
    //	Sqrt(NaN) = NaN
    func Sqrt(x float64) float64 {
    	return sqrt(x)
    }
    
    // Note: On systems where Sqrt is a single instruction, the compiler
    // may turn a direct call into a direct use of that instruction instead.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 15 17:07:57 UTC 2022
    - 4.8K bytes
    - Viewed (0)
  3. src/math/big/sqrt.go

    import (
    	"math"
    	"sync"
    )
    
    var threeOnce struct {
    	sync.Once
    	v *Float
    }
    
    func three() *Float {
    	threeOnce.Do(func() {
    		threeOnce.v = NewFloat(3.0)
    	})
    	return threeOnce.v
    }
    
    // Sqrt sets z to the rounded square root of x, and returns it.
    //
    // If z's precision is 0, it is changed to x's precision before the
    // operation. Rounding is performed according to z's precision and
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 11 16:34:30 UTC 2022
    - 2.8K bytes
    - Viewed (0)
  4. src/cmd/internal/obj/mips/anames.go

    	"NEGD",
    	"NEGF",
    	"NEGW",
    	"NEGV",
    	"NOOP",
    	"NOR",
    	"OR",
    	"REM",
    	"REMU",
    	"RFE",
    	"ROTR",
    	"ROTRV",
    	"SC",
    	"SCV",
    	"SEB",
    	"SEH",
    	"SGT",
    	"SGTU",
    	"SLL",
    	"SQRTD",
    	"SQRTF",
    	"SRA",
    	"SRL",
    	"SUB",
    	"SUBD",
    	"SUBF",
    	"SUBU",
    	"SUBW",
    	"SYNC",
    	"SYSCALL",
    	"TEQ",
    	"TLBP",
    	"TLBR",
    	"TLBWI",
    	"TLBWR",
    	"TNE",
    	"WORD",
    	"WSBH",
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 08 12:17:12 UTC 2023
    - 1.4K bytes
    - Viewed (0)
  5. src/cmd/internal/obj/loong64/anames.go

    	"MULU",
    	"MULH",
    	"MULHU",
    	"MULW",
    	"NEGD",
    	"NEGF",
    	"NEGW",
    	"NEGV",
    	"NOOP",
    	"NOR",
    	"OR",
    	"REM",
    	"REMU",
    	"RFE",
    	"SC",
    	"SCV",
    	"SGT",
    	"SGTU",
    	"SLL",
    	"SQRTD",
    	"SQRTF",
    	"SRA",
    	"SRL",
    	"ROTR",
    	"SUB",
    	"SUBD",
    	"SUBF",
    	"SUBU",
    	"SUBW",
    	"DBAR",
    	"SYSCALL",
    	"TEQ",
    	"TNE",
    	"WORD",
    	"XOR",
    	"MASKEQZ",
    	"MASKNEZ",
    	"MOVV",
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 02:04:54 UTC 2024
    - 1.9K bytes
    - Viewed (0)
  6. src/math/const.go

    	Phi = 1.61803398874989484820458683436563811772030917980576286213544862 // https://oeis.org/A001622
    
    	Sqrt2   = 1.41421356237309504880168872420969807856967187537694807317667974 // https://oeis.org/A002193
    	SqrtE   = 1.64872127070012814684865078781416357165377610071014801157507931 // https://oeis.org/A019774
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 21 14:07:39 UTC 2022
    - 2.8K bytes
    - Viewed (0)
  7. test/codegen/README

    subsequent non-comment line. Inline comments are also supported; the
    regexp will be matched against the code found on the same line:
    
      func Sqrt(x float64) float64 {
      	   return math.Sqrt(x) // arm:"SQRTD"
      }
    
    It's possible to specify a comma-separated list of regexps to be
    matched. For example, the following test:
    
      func TZ8(n uint8) int {
      	   // amd64:"BSFQ","ORQ\t\\$256"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jul 18 19:55:29 UTC 2023
    - 5.2K bytes
    - Viewed (0)
  8. src/math/log.go

    //
    // __ieee754_log(x)
    // Return the logarithm of x
    //
    // Method :
    //   1. Argument Reduction: find k and f such that
    //			x = 2**k * (1+f),
    //	   where  sqrt(2)/2 < 1+f < sqrt(2) .
    //
    //   2. Approximation of log(1+f).
    //	Let s = f/(2+f) ; based on log(1+f) = log(1+s) - log(1-s)
    //		 = 2s + 2/3 s**3 + 2/5 s**5 + .....,
    //	     	 = 2s + s*R
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 11 16:34:30 UTC 2022
    - 3.9K bytes
    - Viewed (0)
  9. src/math/log_amd64.s

    	ORPD    X0, X2 // X2= f1
    	SHRQ    $52, BX
    	ANDL    $0x7FF, BX
    	SUBL    $0x3FE, BX
    	XORPS   X1, X1 // break dependency for CVTSL2SD
    	CVTSL2SD BX, X1 // x1= k, x2= f1
    	// if f1 < math.Sqrt2/2 { k -= 1; f1 *= 2 }
    	MOVSD   $HSqrt2, X0 // x0= 0.7071, x1= k, x2= f1
    	CMPSD   X2, X0, 5 // cmpnlt; x0= 0 or ^0, x1= k, x2 = f1
    	MOVSD   $1.0, X3 // x0= 0 or ^0, x1= k, x2 = f1, x3= 1
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 23 20:52:57 UTC 2023
    - 3.7K bytes
    - Viewed (0)
  10. test/typeparam/issue50193.go

    func zero[T Complex]() T {
    	return T(0)
    }
    func pi[T Complex]() T {
    	return T(3.14)
    }
    func sqrtN1[T Complex]() T {
    	return T(-1i)
    }
    
    func main() {
    	fmt.Println(zero[complex128]())
    	fmt.Println(pi[complex128]())
    	fmt.Println(sqrtN1[complex128]())
    	fmt.Println(zero[complex64]())
    	fmt.Println(pi[complex64]())
    	fmt.Println(sqrtN1[complex64]())
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 01 19:45:34 UTC 2022
    - 599 bytes
    - Viewed (0)
Back to top