MagicRewriting.Unique_bindingSourceThis module the construction of a new program where every binding pattern for a predicate p is unique, see p 800 of Principles of Database and Knowledge-Base Systems II, Ullman
Log is the log module for Unique_binding
make_unique_binding program rgg Takes a program and a rule/goal graph and returns a program where every binding pattern for a predicate p is unique
type ad_pred_key = {key_rule : int;key_head_ad : Adornment.status list;key_pred : ASPred.pred_id;key_pos : int;}type data = {adorned_prog : ASProg.program;unadorned_map : ASPred.pred_id ASPred.PredIdMap.t;rule_to_rule_map : (int * int) DatalogLib.Datalog_AbstractSyntax.RuleIdMap.t;adornments : Adornment.status list AdPredMap.t;pred_map : ASPred.pred_id AdornmentTrie.t ASPred.PredIdMap.t;}