Week 1
9-10      10-11     11-12   12-1   1-2    2-3       3-4       4-5    5-6       6-7Monday      Group 1                     ...
Head lines of the day:1. The installation (fast review)2. Introduction to SWI prolog   I. Making a new file   II. Editing ...
Navigate to this addresshttp://www.swi-prolog.org/
Click on download
Help
pam         tom      bob          lizann          pat      jim
Neck the symbol :-, used in a Prolog rule to separate the head from the body. Usually read as if.hasachild(X) :- parent(X...
Head                       Body              parent(X,Y),female(X).mother(X,Y)
In this example the idea is to write … in threedifferent lines.To separate the writeln command, we use “,” andat the end o...
man(adam).man(peter).man(paul).woman(marry).woman(eve).parent(adam,peter).parent(eve,peter).parent(adam,paul).parent(marry...
man(adam).man(peter).           father(F,C):-man(paul).                   man(F),parent(F,C).woman(marry).         mother(...
man(adam).man(peter).           father(F,C):-man(paul).                   man(F),parent(F,C).woman(marry).         mother(...
Now, make the rules:                      parent(paul,jake).       sisterman(adam).            parent(soozi,jake).      br...
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Week 1
Upcoming SlideShare
Loading in …5
×

Week 1

351 views
306 views

Published on

Published in: Education, Spiritual, Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
351
On SlideShare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
36
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Week 1

  1. 1. Week 1
  2. 2. 9-10 10-11 11-12 12-1 1-2 2-3 3-4 4-5 5-6 6-7Monday Group 1 Group 2Tuesday Group 3Wednesda Group 4 Group 5 Group 6yThursdayFriday (9 MAKE UP 1 MAKE UP 2 MAKE UP 3Dec)Saturday
  3. 3. Head lines of the day:1. The installation (fast review)2. Introduction to SWI prolog I. Making a new file II. Editing and compiling file III. Testing the results IV. Common mistakes3. A Family Tree example4. THE NECK 1. Rules 2. Simple Predecessor
  4. 4. Navigate to this addresshttp://www.swi-prolog.org/
  5. 5. Click on download
  6. 6. Help
  7. 7. pam tom bob lizann pat jim
  8. 8. Neck the symbol :-, used in a Prolog rule to separate the head from the body. Usually read as if.hasachild(X) :- parent(X, Y).
  9. 9. Head Body parent(X,Y),female(X).mother(X,Y)
  10. 10. In this example the idea is to write … in threedifferent lines.To separate the writeln command, we use “,” andat the end of the program we have to like always,put full stop.
  11. 11. man(adam).man(peter).man(paul).woman(marry).woman(eve).parent(adam,peter).parent(eve,peter).parent(adam,paul).parent(marry,paul).
  12. 12. man(adam).man(peter). father(F,C):-man(paul). man(F),parent(F,C).woman(marry). mother(M,C):-woman(eve). woman(M),parent(M,C).parent(adam,peter).parent(eve,peter).parent(adam,paul).parent(marry,paul).
  13. 13. man(adam).man(peter). father(F,C):-man(paul). man(F),parent(F,C).woman(marry). mother(M,C):-woman(eve). woman(M),parent(M,C).parent(adam,peter).parent(eve,peter).parent(adam,paul).parent(marry,paul).
  14. 14. Now, make the rules: parent(paul,jake). sisterman(adam). parent(soozi,jake). brotherman(peter). parent(jake,margaret). grand_paman(paul).woman(marry). Grand_mawoman(eve). grand_sonparent(adam,peter) . grand_daughterparent(eve,peter).parent(adam,paul).parent(marry,paul).

×