Logic Programming is a programming paradigm widely used for teaching Artificial Intelligence in university courses. Prolog, probably the most popular Logic Programming language, is based on inferences similar to theorem provers, and learning it is propaedeutical for understanding formal specification languages. However, after a first phase in which students learn how specifications can be translated into executable code, a second phase is necessary for engineering the resulting program. In this second phase, having a clear picture of the execution model is crucial. In this paper, SLDNF-Draw, a program that visualizes the SLDNF operational semantics of Prolog, is presented. SLDNF- Draw produces trees in LaTeX, the popular typesetting system, so that the generated trees have very high typographic quality and can be embedded in printed documents (e.g., course handouts) as well as in animated presentations. SLDNF Draw is completely written in Prolog, as a meta-interpreter, and does not rely on external imperative languages for the visualization.

SLDNF-Draw: Visualization of Prolog operational semantics in LaTeX

GAVANELLI, Marco
2017

Abstract

Logic Programming is a programming paradigm widely used for teaching Artificial Intelligence in university courses. Prolog, probably the most popular Logic Programming language, is based on inferences similar to theorem provers, and learning it is propaedeutical for understanding formal specification languages. However, after a first phase in which students learn how specifications can be translated into executable code, a second phase is necessary for engineering the resulting program. In this second phase, having a clear picture of the execution model is crucial. In this paper, SLDNF-Draw, a program that visualizes the SLDNF operational semantics of Prolog, is presented. SLDNF- Draw produces trees in LaTeX, the popular typesetting system, so that the generated trees have very high typographic quality and can be embedded in printed documents (e.g., course handouts) as well as in animated presentations. SLDNF Draw is completely written in Prolog, as a meta-interpreter, and does not rely on external imperative languages for the visualization.
2017
Gavanelli, Marco
File in questo prodotto:
Non ci sono file associati a questo prodotto.

I documenti in SFERA sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.

Utilizza questo identificativo per citare o creare un link a questo documento: https://hdl.handle.net/11392/2368458
 Attenzione

Attenzione! I dati visualizzati non sono stati sottoposti a validazione da parte dell'ateneo

Citazioni
  • ???jsp.display-item.citation.pmc??? ND
  • Scopus ND
  • ???jsp.display-item.citation.isi??? 0
social impact