Posts Tagged ‘help’

Request a Post

If you cant find a post on the maths topic you need help with or want to read about on this site you can now send me a request for a post at this blogs new location, just follow the link below.
I cant guarantee that I will create the post but as long as it is on a maths related topic that I have an understanding of I will try to create it. You can also use this feature to ask questions.

If I do create the post I will email you a link to it at the email address provided.

Categories: maths Tags: , ,

Prolog — Install and use

this is a quick guide on how to get going with swi-prolog. Prolog is a fith generathion “declerative” laungage, it uses facts and rules which can then be quired to give a responce, this sort of thing can used to create Artifical Inteligence (AI). Despite this sounding complicated it is in fact much easier to use and learn (once youve got your head round the way it works) than other (4th generation) laungages such as java and c++.

First of all you need to download it, go to and download the version of prolog for you operating system. You can then run the file you have downloaded (follow the instructions) to install it.

Prolog programs are saved as text files, ending in .pl, you should save these into the prolog folder (this was created in my documents during installation) these can then be opened by typing [file without .pl]. rember the dot (.) at the end, in the prolog window.

To run a prolog program you must first open the prolog command thing, from the start menu, programs can then be loaded and run.

Some things to rember about prolog:
>all commands and lines should end in a dot
>leave a line at the end of each file
>reload a file after it has been changed
>dont use capital letters for values only for things in which the value changes
>it wont recognise a calculation unles you use is, X=5+2 doesnt mean X=7 but X is 5+2 does
>a semi collon (;) will show the next result of the query

I dont have a good enough knowlage to write a full tutorial of prolog, only some basic points like those above however a good one is at

anyway enjoy coding