[CM] cmn's iratify

Bill Schottstaedt bil at ccrma.Stanford.EDU
Wed Jan 18 06:19:03 PST 2006


cmn's iratify stops searching for a ratio (it uses continued fractions,
so it's very fast) when the error is less than "smallest-note" --
in this case smallest-note is .015 so

* (- (* .125 9) (/ 10 9))

0.013888836

If you set smallest-note smaller (say .001) you'll get 9/8:

* (setf smallest-note .001)

0.001
* (iratify (* .125 9))

9/8

If I remember right, this part of cmn is trying to simplify incoming notelist
data, so it's very hard to decide what the right thing is for all cases.




More information about the Cmdist mailing list