diff options
Diffstat (limited to '')
-rw-r--r-- | stdlib/test/test/lux/math.lux | 4 | ||||
-rw-r--r-- | stdlib/test/test/lux/math/complex.lux | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/stdlib/test/test/lux/math.lux b/stdlib/test/test/lux/math.lux index 7ed31bdb4..18cb1545c 100644 --- a/stdlib/test/test/lux/math.lux +++ b/stdlib/test/test/lux/math.lux @@ -48,10 +48,10 @@ base (|> R;real (:: @ map (r.* factor)))] ($_ seq (assert "Square-root is inverse of square." - (|> base (&;pow 2.0) &;sqrt (r.= base))) + (|> base (&;pow 2.0) &;root2 (r.= base))) (assert "Cubic-root is inverse of cube." - (|> base (&;pow 3.0) &;cbrt (r.= base))) + (|> base (&;pow 3.0) &;root3 (r.= base))) )) (test: "Rounding" diff --git a/stdlib/test/test/lux/math/complex.lux b/stdlib/test/test/lux/math/complex.lux index 9fba68dc9..04ebcb3c0 100644 --- a/stdlib/test/test/lux/math/complex.lux +++ b/stdlib/test/test/lux/math/complex.lux @@ -138,11 +138,11 @@ (assert "x*(x^-1) = 1" (|> x (&;c.* (&;reciprocal x)) (within? margin-of-error &;one))) - (assert "Absolute value of signum is always sqrt(2), 1 or 0." + (assert "Absolute value of signum is always root2(2), 1 or 0." (let [signum-abs (|> x &;c.signum &;c.abs (get@ #&;real))] (or (r.= 0.0 signum-abs) (r.= 1.0 signum-abs) - (r.= (math;sqrt 2.0) signum-abs)))) + (r.= (math;root2 2.0) signum-abs)))) (assert "Negation is its own inverse." (let [there (&;c.negate x) @@ -173,7 +173,7 @@ [x gen-complex] ($_ seq (assert "Square root is inverse of power 2.0" - (|> x (&;pow' 2.0) &;sqrt (within? margin-of-error x))) + (|> x (&;pow' 2.0) &;root2 (within? margin-of-error x))) (assert "Logarithm is inverse of exponentiation." (|> x &;log &;exp (within? margin-of-error x))) |