From: Taylor R Campbell Date: Sun, 18 Nov 2018 06:05:10 +0000 (+0000) Subject: Some more atan tests for real values. X-Git-Tag: mit-scheme-pucked-10.1.2~16^2~27 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=4689582a98fe2967813dadeff238aa14eef2cd74;p=mit-scheme.git Some more atan tests for real values. --- diff --git a/tests/runtime/test-arith.scm b/tests/runtime/test-arith.scm index 852f95617..b16802a4f 100644 --- a/tests/runtime/test-arith.scm +++ b/tests/runtime/test-arith.scm @@ -478,8 +478,18 @@ USA. (lambda () (assert-eqv (atan 0) 0))) +(define (rsqrt x) + (/ 1 (sqrt x))) + (define-enumerated-test 'atan (vector + (vector (- 2 (sqrt 3)) (/ 3.1415926535897932 12)) + (vector (- (sqrt 2) 1) (/ 3.1415926535897932 8)) + (vector (rsqrt 3) (/ 3.1415926535897932 6)) + (vector 1 (/ 3.1415926535897932 4)) + (vector (sqrt 3) (/ 3.1415926535897932 3)) + (vector (+ (sqrt 2) 1) (* 3.1415926535897932 3/8)) + (vector (+ 2 (sqrt 3)) (* 3.1415926535897932 5/12)) (vector +2i +1.5707963267948966+.5493061443340549i) (vector +0.+2i +1.5707963267948966+.5493061443340549i) (vector -0.+2i -1.5707963267948966+.5493061443340549i)