Title
#of-logic-programming
j

Jason Morris

09/07/2022, 11:24 PM
message has been deleted
w

wtaysom

09/08/2022, 2:30 AM
Example please?
j

Jason Morris

09/08/2022, 5:05 AM
Imagine you have an answer set program that models a complicated set of rules. You want to know under what fact scenarios a given outcome can be derived according to those rules. You run a generic query, without modelling specific inputs in the program, just modelling the schema those inputs must follow. Because it needs to generate and consider a huge number of possible inputs, it takes a long time to run this query. When it finishes, it turns out there is only one model. You look at what values the inputs have in that model, and it turns out that only three inputs are relevant, and only when they have specific values set. Later, you want to check whether this property holds in a specific fact scenario. So instead of adding a model of that specific fact scenario to the program and running the query again, which will be faster, but still slow, you can write a new program that only checks the values of those three relevant inputs, which will be blistering fast.
5:08 AM
The first program might have rules like "if one player throws a sign that beats the sign of the other player... etc." and the second program is reduced to three sets of valid inputs, one each for Rock beats scissors, scissors beats paper, and paper beats rock.
5:11 AM
I don't know enough about typical ASP to know if this is possible, impossible, common, rarely done, unheard of, or what.
w

wtaysom

09/08/2022, 8:22 AM
Tickles my program specialization / partial evaluation feelers.