comp.lang.prolog
  Home FAQ Contact Sign in
comp.lang.prolog only
 
Advanced search
July 2008
motuwethfrsasuw
 123456 27
78910111213 28
14151617181920 29
21222324252627 30
28293031    31
2008
 Jan   Feb   Mar   Apr 
 May   Jun   Jul   Aug 
 Sep   Oct   Nov   Dec 
2008 2007 2006  
total
comp.lang.prolog Profile…
RELATED GROUPS

POPULAR GROUPS

more...

 Up
  Finding the difference in consequences between two logic programs         


Author: Zoubidoo
Date: Jul 1, 2008 04:20

Hello,

Given two logic programs LP1 and LP2, I would like to generate
consequences of LP1 that are not consequences of LP2. Is there an
efficient way of finding these consequences? A basic solution is
quite simple to express:

lp1_and_not_lp2(X) :- lp1(X), \+ lp2(X).

but as the programs become more complex, the inefficiency of this
approach becomes a problem.

It seems to be quite a general problem - is there any theory I should
know about, and is another setting (e.g. CLP / answer set programming)
more suited than Prolog?

In my case, LP1 and LP2 are closely related (to get LP2 just add/
remove a few clauses from LP1) - does this help make the problem
easier to solve?

Thanks for any pointers!
Zoubidoo

A simple example:
Show full article (0.95Kb)
1 Comment