From 06d9fc69fdf0988aceea64fa2310c22deddb107d Mon Sep 17 00:00:00 2001 From: David Thompson Date: Fri, 1 Aug 2014 07:26:15 -0400 Subject: Tweak docstring for linear-scale. * sly/math.scm (linear-scale): Tweak docstring. --- sly/math.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sly/math.scm b/sly/math.scm index c25e24d..1a5f2c6 100644 --- a/sly/math.scm +++ b/sly/math.scm @@ -92,8 +92,8 @@ actually less than MAX." ((> x max) max) (else x))) -(define (linear-scale min max a b val) - "Map a VAL in the range [MIN,MAX] to numbers in [A,B]" +(define (linear-scale min max a b n) + "Map a number N in the range [MIN,MAX] to the range [A,B]." (+ a - (/ (* (- b a) (- val min)) + (/ (* (- b a) (- n min)) (- max min)))) -- cgit v1.2.3