/tutorial/backtracking/backtracking.txt

http://github.com/tybor/Liberty · Plain Text · 68 lines · 51 code · 17 blank · 0 comment · 0 complexity · ad66979dfcc4ce6419e7e9de053271ef MD5 · raw file

  1. Tutorial of lib/backtracking
  2. ############################
  3. The cluster lib/backtracking provides a useful abstraction to implement
  4. all kinds of backtracking algorithms or and/or tree explorations.
  5. The tutorial backtracking/expand_expression
  6. ===========================================
  7. The main class, ABSTRACT_BACKTRACKING,
  8. implements the abstract algorithm that explore a virtual and/or tree.
  9. It defines the basic data used for the explorations and the way the exploration
  10. is done. The tutorial [expand_expression] shows its use.
  11. That tutorial expands the expressions that are entered at its input.
  12. Here is a short example.
  13. {{{{
  14. > cd expand_expression/tree
  15. > se c -clean -o ee expand_expression
  16. > ./ee
  17. the(good+bad)(boy+girl)
  18. (1) the good boy
  19. (2) the good girl
  20. (3) the bad boy
  21. (4) the bad girl
  22. }}}}
  23. The tutorial backtracking/logigram
  24. ==================================
  25. A tutorial that shows how to solve problems
  26. that sometimes are called logigrams. The logigrams
  27. are made of a set of items (persons, date, places, ...)
  28. grouped into categories and sets of true propositions
  29. about the items. From these propositions you must deduce
  30. how the given items are combined together.
  31. Here is an example: there are 3 women, Marie, Julie and Eve of
  32. the 19th century. We know that:
  33. - The one who has no child was born in 1804 and she is not Marie.
  34. - Julie doesn't have exactly one child and has less children than Marie.
  35. - The one who had 2 children was not born in 1805 and she is not Eve.
  36. Which woman is born in 1806? How many children did she have?
  37. The tutorial backtracking/tiny_parse
  38. ==============================
  39. WORK IN PROGRESS NOTHING TO SEE HERE
  40. The tutorial backtracking/tiny_prolog
  41. ===============================
  42. WORK IN PROGRESS NOTHING TO SEE HERE
  43. Some other examples
  44. ===================
  45. The cluster regular_expression uses the cluster bactracking.
  46. Just take a look at it.
  47. .end
  48. .def [[:upper:]_]\{2,\} <span class="class">&</span>
  49. .def {{{{ <pre>
  50. .def }}}} </pre>
  51. .def ^\.end <div class="sesign"><rule/>Copyright \&copy; The SmartEiffel Team - <a href="mailto:SmartEiffel@loria.fr">\&lt;SmartEiffel@loria.fr\&gt;</a></div>