Sunday, October 7, 2012

Prolog: Mother of Erlang





PROLOG
Mother Of Erlang

"Prolog (PROgramming in LOGic) is a logic programming language developed by Alain Colmerauer and Phillipe Rousel that is quite similar to Erlang. It is a rich collection of data structures in the language and human reasoning and a powerful notation for encoding end-user applications. It has its logical and declarative aspects, interpretative nature, compactness and inherent modularity."

Prolog is one of the most widely used programming languages in artificial intelligence research. As opposed to imperative languages such as C or Java (which also happens to be object-oriented) it is a declarative programming language. That means, when implementing the solution to a problem, instead of specifying how to achieve a certain goal in a certain situation, we specify what the situation (rules and facts) and the goal (query) are and let the Prolog interpreter derive the solution for us. Prolog is very useful in some problem areas, such as artificial intelligence, natural language processing, databases, but pretty useless in others, such as graphics or numerical algorithms.

THE HUMBLE BEGGININGS OF PROLOG




Alain Colmerauer

Prolog is the programming language developed by Alain Colmerauer and Phillipe Roussel in the summer of 1972. The name was suggested by Roussel’s wife, Jacqueline, as an abbreviation for programmation en logique. It was influenced by Planner, also a logic programmong language and was created to represent logic in a declarative, procedural manner. Today Prolog is also used in the field of theorem proving,expert systems, games etc some variations of prolog have evolved since the creation of  the original version. Up to this day prolog is still widely used, ISO Prolog Standardisation(1995) was  founded to ensure that the core of the language was still fixed.

What people say about PROLOG:



 In  the  eyes of  most  North  American  researchers  in AI,  resolution  had  long  been discredited. 
The fashion  had  turned.  . . toward  the  procedural  representation  of knowledge  and domain- 
specific  problem  solvers. - Robert A Kowalski






 To the extent that anyone but a Prolog programmer can understand \X totally. And to the extent that a Prolog programmer can understand 'cut'. - Larry Wall




I have used Prolog for my Masteral Thesis for AI programming. It’s a powerful language to use, especially for AI purposes - Sir Mercado

Since we did not touch logic programming as a topic in CMSC 124, I think Prolog will be a challenging and interesting language to learn even if its ancient.” - 2010-19833

 Prolog reminds me so much of Erlang. I like concept of Prolog being a logical programming language wherein it applies techniques that were actually designed to prove theorems using logic and therefore could implement all algorithms rather than it solving only those problems that it was specially designed to solve. -2010-04510

 Everything is a hypothesis. - Prolog. :P

Based on our research, I think Prolog would be very challenging to take. Although it is similar with Erlang, Prolog is used for AI which may be advanced when taken in CMSC124. But I guess it would be very interesting to study and practice.” 
-2009-00288


HoW To PrOgRaM iN PrOLoG...

Hello World:
            
            write(‘Hello world!’), n1.


Factorial:

               factorial(0,1).

       factorial(A,B) :- A > 0, C is A-1,

       factorial(C,D), B is A*D.


String Concatenation: 




References:

                    Kowalski, R. A.. The Early Years of Logic Programming.

                    http://www.deransart.fr//prolog/overview.html

                    http://alain.colmerauer.free.fr/

                    http://www.mta.ca/~rrosebru/oldcourse/371199/prolog/history.html

                    http://www.csupomona.edu/~jrfisher/www/prolog_tutorial/2.html

                    http://groups.engin.umd.umich.edu/CIS/course.des/cis479/prolog/bench.pro


CMSC 124 T-1L

MEMBERS:                    
                   2010-19833
                   2010-19873
                   2010-08886
                   2010-04510
                   2009-00288


1 comment:

  1. Erlang came from Prolog via the committed choice logic programming languages. These dropped Prolog's backtracking in order to map the logic programming idea of successive constraint of single-assignment variables onto a practical concurrent model. These programming languages were never able to pull out of the shadow of Prolog, so Erlang's adoption of a superficial functional syntax and promotion as a functional rather than a logic language was a good marketing idea for their underlying principle.

    ReplyDelete