4 ms·
What connection do you see between CHR and linear logic? I've never seen it described that way. Anyway, the last time I needed to write a constraint solver in
by tom_mellior 8y ago
What connection do you see between CHR and linear logic? I've never seen it described that way.
Anyway, the last time I needed to write a constraint solver in Prolog, I did try it in CHR, but it was way too slow for my needs, so I ended up rewriting it in plain SWI-Prolog. So from this one data point, I don't see where your assertion of "without the performance overhead" comes from.
I also found CHR's multiset semantics quite painful for my application, a lot of my rules had to be careful not to post duplicates of constraints. I would have loved having a single flag for telling the CHR system to just take care of that for me. That would have cleaned up my model and probably been more efficient as well. All of the above is qualified by the fact that I was a relative CHR newbie at the time.
Overall: CHR is quite interesting, but it's no magic silver bullet, and you seem to be overselling it.
- adamnemecek 8y agoIt’s the foundation of chr https://books.google.com/books?id=0CbvBQAAQBAJ&pg=PA18&dq=Chr+Linear+logic&hl=en&sa=X&ved=0ahUKEwi93NzPhLngAhUB0lQKHQ7wDj0Q6AEIJjAA#v=onepage&q=Chr%20Linear%20logic&f=false https://books.google.com/books?id=0CbvBQAAQBAJ&pg=PA18&dq=Ch...
- tom_mellior 8y agoOK, yes, a "foundation" in the sense that researchers went and looked at already existing CHR and decided that its semantics was not as clear as it should be, and that it could be explained nicely in terms of linear logic. Not "the foundation" in the sense that the people initially designing CHR decided to base it on linear logic (unlike Wadler's work on linear type systems, say). Interesting, thanks. But this approach is hardly a way to achieve "[no] performance overhead thanks to the magic of linear logic".