August 8, 20169 yr hi all i need a little lisp-help... i want to split things like this perhaps 'an3 into '(a n 3) is there a way? thanx andré
August 8, 20169 yr Author thanx, but i see my idea don't work with that... concrete: i want to split 2/20 into exactly '(2 20) function with numerator/denominator it will be '(1 10) - not what i need also with (explode '2/20) => (1 / 1 0) is there any solution?
August 8, 20169 yr Author i know, but only mathematically!! -> you remember the problem with gen-stacc? => we discussed that with rangarajan? for some functions it's necessary that 2/20 will not be "reduced" to 1/20 => https://opusmodus.com/forums/topic/528-gen-stacc-question/#comment-1446 Quote Yes, I have also experienced this difficulty, for example, can't distinguish between 4/4 and 2/2 because both reduce to 1! As JP points out, this is a Lisp issue, nothing to do with OM. If we are adventurous, we could implement our own "data type", for example keeping numerator and denominator separately as a cons pair (numerator . denominator) or something similar. We can write a set of functions that operate on this, and then apply reduction when actually needed. More work, of course, but Lisp gives you control. Regards, Rangarajan
Create an account or sign in to comment