1 (in-package #:clnl-nvm)
3 (defun min-pxcor () (getf *dimensions* :xmin))
4 (defun max-pxcor () (getf *dimensions* :xmax))
5 (defun min-pycor () (getf *dimensions* :ymin))
6 (defun max-pycor () (getf *dimensions* :ymax))
10 :for i :from 0 :to 360
13 ((potential-sin (strictmath:sin (strictmath:to-radians i))))
14 (if (< (abs potential-sin) 3.2d-15) 0d0 potential-sin))))
16 (defun using-cached-sin (n)
17 (if (= (floor n) n) (nth (floor n) *cached-sins*) (strictmath:sin (strictmath:to-radians n))))
19 (defvar *cached-coses*
21 :for i :from 0 :to 360
24 ((potential-cos (strictmath:cos (strictmath:to-radians i))))
25 (if (< (abs potential-cos) 3.2d-15) 0d0 potential-cos))))
27 (defun using-cached-cos (n)
28 (if (= (floor n) n) (nth (floor n) *cached-coses*) (strictmath:cos (strictmath:to-radians n))))