Re: core.logic - getting good at writing non-terminating programs

2013-08-14 Thread Mark
Thanks! On Tuesday, August 13, 2013 12:18:33 PM UTC-7, Norman Richards wrote: > > > > > On Mon, Aug 12, 2013 at 4:03 PM, Mark >wrote: > >> >> At run level 6, I get all the permutations of [1 2 3], just as expected. >> However, at 7, the program does not terminate and I'd like to understand >

Re: core.logic - getting good at writing non-terminating programs

2013-08-13 Thread Norman Richards
On Mon, Aug 12, 2013 at 4:03 PM, Mark wrote: > > At run level 6, I get all the permutations of [1 2 3], just as expected. > However, at 7, the program does not terminate and I'd like to understand > why. I feel like I need to constrain the relation between o-h and o better > but I'm not sure wha

core.logic - getting good at writing non-terminating programs

2013-08-12 Thread Mark
I needed to extend rembero to handle removing multiple items. For example (rememberallo [1 2 3] [1 2 3 4 5] [4 5]) is true. My relation is: (l/defne remberallo [s l o] ([() l l]) ([[h . r] _ _] (l/fresh [o-h] (l/rembero h l o-h) (remberallo r o-h o It's go