I don't have much advice beyond looking at how people do this in Prolog. We're starting to look into CLP(Set) which will provide much better support for working with sets and doesn't rely on list encodings.
On Sun, Apr 7, 2013 at 5:24 AM, Adam Saleh <adamthecam...@gmail.com> wrote: > Hi, > > I am having trouble creating superset goal. > I managed to create a subset goal: > > (defn subseto [smaller larger] > (fresh [e] > (appendo smaller e larger))) > > (run 3 [s l] > (membero :a s) > (membero :b s) > > (membero :a l) > (membero :c l) > > (subseto s l)) > > results: > ([(:a :b) (:a :b :c . _0)] > [(:a :b :c) (:a :b :c . _0)] > [(:a :b :c _0) (:a :b :c _0 . _1)]) > > Problem is, that I need behavior, where "s" wouldn't have realization, > where it would contain members of "l" that it didn't contain before. > In other words, I need a goal that enforces that "l" is a superset of "s". > > Any hints? > > Thanks! > > Adam > > -- > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to clojure@googlegroups.com > Note that posts from new members are moderated - please be patient with > your first post. > To unsubscribe from this group, send email to > clojure+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en > --- > You received this message because you are subscribed to the Google Groups > "Clojure" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to clojure+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.