Added Pow{,32}.
This commit is contained in:
parent
a77de45eba
commit
52494022f6
10
math.go
10
math.go
@ -72,6 +72,16 @@ func NaN32() float32 {
|
||||
return float32(NaN())
|
||||
}
|
||||
|
||||
// Pow returns the power e of base b.
|
||||
func Pow(b, e float64) float64 {
|
||||
return math.Pow(b, e)
|
||||
}
|
||||
|
||||
// Pow32 returns the power e of base b.
|
||||
func Pow32(b, e float32) float32 {
|
||||
return float32(Pow(float64(b), float64(e)))
|
||||
}
|
||||
|
||||
// Round rounds to the nearest integer.
|
||||
func Round(f float64) float64 {
|
||||
return math.Round(f)
|
||||
|
Loading…
Reference in New Issue
Block a user