From 10dc967494de6c2e51042a3f3010dcb79eee1c4c Mon Sep 17 00:00:00 2001 From: John Benediktsson Date: Wed, 13 May 2015 14:47:15 -0700 Subject: [PATCH] picomath: simplify. --- extra/picomath/picomath.factor | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extra/picomath/picomath.factor b/extra/picomath/picomath.factor index abbcb81e27..ff614b58d2 100644 --- a/extra/picomath/picomath.factor +++ b/extra/picomath/picomath.factor @@ -22,7 +22,7 @@ PRIVATE> :: erf ( x -- value ) x 0 >= 1 -1 ? :> sign x abs :> x! - p x * 1 + 1 swap / :> t + p x * 1 + recip :> t a5 t * a4 + t * a3 + t * a2 + t * a1 + t * x x neg * e^ * 1 swap - :> y sign y * ; @@ -34,7 +34,7 @@ PRIVATE> :: phi ( x -- value ) x 0 >= 1 -1 ? :> sign x abs 2 sqrt / :> x! - p x * 1 + 1 swap / :> t + p x * 1 + recip :> t a5 t * a4 + t * a3 + t * a2 + t * a1 + t * x x neg * e^ * 1 swap - :> y sign y * 1 + 2 / ;