JOURNAL ARTICLE

Dynamic Magic Sets for Disjunctive Datalog Programs

Mario Alviano

Year: 2010 Journal:   Leibniz-Zentrum für Informatik (Schloss Dagstuhl) Pages: 226-235   Publisher: Schloss Dagstuhl – Leibniz Center for Informatics

Abstract

Answer set programming (ASP) is a powerful formalism for knowledge representation and common sense reasoning that allows disjunction in rule heads and nonmonotonic negation in bodies. Magic Sets are a technique for optimizing query answering over logic programs and have been originally defined for standard Datalog, that is, ASP without disjunction and negation. Essentially, the input program is rewritten in order to identify a subset of the program instantiation which is sufficient for answering the query. Dynamic Magic Sets (DMS) are an extension of this technique to ASP. The optimization provided by DMS can be exploited also during the nondeterministic phase of ASP systems. In particular, after some assumptions have been made during the computation, parts of the program may become irrelevant to a query (because of these assumptions). This allows for dynamic pruning of the search space, which may result in exponential performance gains. DMS has been implemented in the dlv system and experimental results confirm the effectiveness of the technique.

Keywords:
Datalog Computer science Negation Nondeterministic algorithm Answer set programming Logic programming MAGIC (telescope) Rotation formalisms in three dimensions Theoretical computer science Tuple Programming language Formalism (music) Deductive database Computation Pruning Algorithm Mathematics Discrete mathematics

Metrics

1
Cited By
0.40
FWCI (Field Weighted Citation Impact)
8
Refs
0.75
Citation Normalized Percentile
Is in top 1%
Is in top 10%

Topics

Logic, Reasoning, and Knowledge
Physical Sciences →  Computer Science →  Artificial Intelligence
Multi-Agent Systems and Negotiation
Physical Sciences →  Computer Science →  Artificial Intelligence
AI-based Problem Solving and Planning
Physical Sciences →  Computer Science →  Artificial Intelligence

Related Documents

JOURNAL ARTICLE

Magic Sets for disjunctive Datalog programs

Mario AlvianoWolfgang FaberGianluigi GrecoNicola Leone

Journal:   Artificial Intelligence Year: 2012 Vol: 187-188 Pages: 156-192
JOURNAL ARTICLE

Modular stratification and magic sets for Datalog programs with negation

Kenneth A. Ross

Journal:   Journal of the ACM Year: 1994 Vol: 41 (6)Pages: 1216-1266
JOURNAL ARTICLE

Datalog rewritability of Disjunctive Datalog programs and non-Horn ontologies

Mark KaminskiYavor NenovBernardo Cuenca Grau

Journal:   Artificial Intelligence Year: 2016 Vol: 236 Pages: 90-118
© 2026 ScienceGate Book Chapters — All rights reserved.