stdfloat

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 10, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Abs

func Abs(x float64) float64

Abs returns the absolute value of x.

Special cases are:

Abs(±Inf) = +Inf
Abs(NaN) = NaN

func CopySign

func CopySign(x, y float64) float64

CopySign returns a value with the magnitude of x and the sign of y.

func Float64Bits

func Float64Bits(f float64) uint64

Float64Bits returns the IEEE 754 binary representation of f.

func Float64FromBits

func Float64FromBits(b uint64) float64

Float64FromBits returns the floating point number corresponding the IEEE 754 binary representation b.

func IsFinite

func IsFinite(f float64) bool

IsFinite reports whether f is neither NaN nor an infinity.

func IsInf

func IsInf(f float64) bool

IsInf reports whether f is an infinity.

func IsNaN

func IsNaN(f float64) (is bool)

IsNaN reports whether f is an IEEE 754 “not-a-number” value.

Types

type Float16

type Float16 uint16

type Float128

type Float128 struct {
	// contains filtered or unexported fields
}

Float128

TODO: implement

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL