>From your original post http://jsoftware.com/pipermail/programming/2009-August/015923.html :
"Then from this result, pick the entries which maximize the next highest difference between any two adjacent entries, repeating until every remaining difference has been considered." So mmd gives these solutions where all remaining differences are considered. Notice that the scope of comb is much more limited than that of mmd, as I tried to indicate in previous posts. Only in some cases ;@mmd matches comb : (i.15) (;@mmd -:&$ comb)"(0) 18 1 1 0 0 0 0 0 0 0 0 1 1 1 1 1 R.E. Boss > -----Oorspronkelijk bericht----- > Van: [email protected] [mailto:programming- > [email protected]] Namens Raul Miller > Verzonden: dinsdag 18 augustus 2009 19:33 > Aan: Programming forum > Onderwerp: Re: [Jprogramming] minmax differences > > On Tue, Aug 18, 2009 at 12:37 PM, Aai<[email protected]> wrote: > > @ R.E. Boss: > > > > Combinations k mmd n that result in 0=z1 won't work > > > > 5 mmd 13 > > |domain error: combnu > > Note that R.E.Boss has posted a followup which deals with this issue. > > > @ R. Miller: > > > > if you're after a final result then 2-stage filtering seems to be an > option: > > I am. > > And, I have a few other issues, which I did not mention in my > initial message. > > The actual problem I am dealing with involves a "circular" arrangement of > bits. And, where multiple options are available, I am supposed to pick > the option with the set bits furthest to the right. But these are easy to > deal with, once I have the core solution. > > Meanwhile, ;@mmd works as a "more efficient" replacement for comb, > so I can just drop it into place in John Randall's implementation. except, > in some cases, mmd is not more efficient than comb. > 10 (;@mmd -:&$ comb) 18 > 1 > > That said, I have not tested to see if mmd overall gives a factor of > two speed improvement over comb (averaged over a lot of different > valid arguments). > > But that's ok -- the key issue which I was stumbling over > was addressed by John Randall. > > Thanks again, > > -- > Raul > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
