Efficient Tabling of Structured Data Using Indexing and Program Transformation

Tabling of structured data is important to support dynamic programming in logic programs. Several existing tabling systems for Prolog do not efficiently deal with structured data, but duplicate part of the structured data in different instances of tabled goals. As a consequence, time and space complexity may often be significantly higher than the theoretically optimal. A simple program transformation is proposed which uses an indexing of structured data that eliminates this problem, and drastic improvements of time and space complexity can be demonstrated. The technique is demonstrated for dynamic programming examples expressed in Prolog and in PRISM.

[1]  Chak-Kuen Wong,et al.  Bounds for the String Editing Problem , 1976, JACM.

[2]  Lawrence R. Rabiner,et al.  A tutorial on hidden Markov models and selected applications in speech recognition , 1989, Proc. IEEE.

[3]  John P. Gallagher,et al.  Non-discriminating Arguments and Their Uses , 2009, ICLP.

[4]  Hisao Tamaki,et al.  OLD Resolution with Tabulation , 1986, ICLP.

[5]  Taisuke Sato,et al.  PRISM: A Language for Symbolic-Statistical Modeling , 1997, IJCAI.

[6]  Li-Yan Yuan,et al.  Implementation of a Linear Tabling Mechanism , 2001, J. Funct. Log. Program..

[7]  Ricardo Rocha,et al.  Global Trie for Subterms , 2011, ArXiv.

[8]  Sean R Eddy,et al.  What is dynamic programming? , 2004, Nature Biotechnology.

[9]  Henning Christiansen,et al.  Taming the Zoo of Discrete HMM Subspecies & Some of their Relatives , 2011, Biology, Computation and Linguistics.

[10]  David Scott Warren,et al.  XSB: Extending Prolog with Tabled Logic Programming , 2010, Theory and Practice of Logic Programming.

[11]  Konstantinos Sagonas,et al.  Tabling in Mercury: Design and Implementation , 2006, PADL.

[12]  Juliana Freire,et al.  The XSB Programmer’s Manual , 1800 .

[13]  Theresa Swift,et al.  Design Patterns for Tabled Logic Programming , 2009, INAP.

[14]  Taisuke Sato,et al.  New Advances in Logic-Based Probabilistic Modeling by PRISM , 2008, Probabilistic Inductive Logic Programming.

[15]  Neng-Fa Zhou,et al.  The language features and architecture of B-Prolog , 2011, Theory and Practice of Logic Programming.