summaryrefslogtreecommitdiff
path: root/src/approx/maceps.lisp
diff options
context:
space:
mode:
Diffstat (limited to 'src/approx/maceps.lisp')
-rw-r--r--src/approx/maceps.lisp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/approx/maceps.lisp b/src/approx/maceps.lisp
index debaa67..e2738e4 100644
--- a/src/approx/maceps.lisp
+++ b/src/approx/maceps.lisp
@@ -3,10 +3,10 @@
(defun compute-maceps (f a init)
(let ((h init)
(err init))
- (loop while (> err 0)
+ (loop collect (list a h err)
do
(setf h (/ h 2)
err (abs (- (funcall f (+ a h))
(funcall f a))))
- when (> err 0)
- collect (list a h err))))
+ while (> err 0))))
+