From f3c70d3741269eca6c795cd529a37d3b78c691dd Mon Sep 17 00:00:00 2001 From: Revar Desmera Date: Sun, 30 Jul 2023 22:45:15 -0700 Subject: [PATCH] Corrected modang() example. --- math.scad | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/math.scad b/math.scad index a273999..8cc9587 100644 --- a/math.scad +++ b/math.scad @@ -602,12 +602,12 @@ function posmod(x,m) = // Description: // Takes an angle in degrees and normalizes it to an equivalent angle value between -180 and 180. // Example: -// a1 = modang(-700,360); // Returns: 20 -// a2 = modang(-270,360); // Returns: 90 -// a3 = modang(-120,360); // Returns: -120 -// a4 = modang(120,360); // Returns: 120 -// a5 = modang(270,360); // Returns: -90 -// a6 = modang(700,360); // Returns: -20 +// a1 = modang(-700); // Returns: 20 +// a2 = modang(-270); // Returns: 90 +// a3 = modang(-120); // Returns: -120 +// a4 = modang(120); // Returns: 120 +// a5 = modang(270); // Returns: -90 +// a6 = modang(700); // Returns: -20 function modang(x) = assert( is_finite(x), "Input must be a finite number.") let(xx = posmod(x,360)) xx<180? xx : xx-360;