☰
↑
←
→
🔍
TOC
Efficiency Issues in Prolog
»
Table of Contents
Table of Contents
What efficiency means here
Efficiency (Slide 2)
Data structures
Data structures (Slides 3–4)
Let unification do the work
Swapping two arguments (Slide 5)
Checking that a list has three elements (Slide 6)
The dynamic database
Do not simulate global variables (Slide 7)
Where the database
is
the right answer: lemmas (Slide 8)
Determinism
Do not keep alternatives that are not needed (Slide 9)
Choosing the algorithm (Slide 10)
Search order and indexing
Fail as early as possible (Slide 11)
Indexing (Slides 12–13)
Iteration, cuts and delaying
Iteration versus recursion (Slides 14–15)
Cuts (Slide 16)
Delaying work (Slides 17–18)
Conclusions
Conclusions (Slide 19)