10, April 2000
The requirements of a good AI language are such that can provide the at a minimum the following features:
1] Symbolic and sub-symbolic representation and manipulation.
2] The ability to do basic pattern matching to reduce the programming effort in redefining mundane tasks.
3] Allow logical deduction of data, both symbolic and sub-symbolic
4] Allow the programming facilities to group complex data into units for representation.
5] Give the ability to decompose a complex problem into smaller units/modules for decomposition.
Also some other concerns of a good AI language is related to the hardware/software support given to each language (such as compilers, memory usage, etc.). Ideally an AI language should also have these features.
1] Both low-level and high-level manipulation of the data and program.
2] Speed and compiler support
3] Late-binding time of variables to allow unknown data to be defined at run-time.
4] Flexible and readable syntax for maintainability
No language currently supports all these features. Among the most common of the languages available LISP, PROLOG, and C/C++ are a few of the most common used in programming because each contain some of the features stated above.
Of the three mentioned, LISP and C/C++ were covered in CS150.
C/C++ are sister languages. Both are procedural and allow low-level and high-level control of the data. C is purely procedural language where C++ is a object-oriented language. Both allow for complex data structures and manipulations. C++ objects can be implemented as symbols while the objects attributes can be characterized as the symbols meanings. C++ doesn’t support much pattern support, if any. C/C++ allows for dynamic memory allocation and manipulation. C/C++ is also very fast and the compiler/development environment is well supported. C/C++ has very good data and data manipulation support. ANSI C/C++ are also highly portable across platforms. The lack of natural symbolic representation in C/C++ can be easily implemented via the use of enumerated values.
LISP is a symbolic language that focuses on the manipulation of symbols in lists. It is a functional language that is known for its basis on the manipulation of lists of data (numerical or symbolic). LISP features high-level manipulation since garbage collection and automatic typing are done for the user for the most part. Also LISP supports late variable binding and dynamic memory allocation.
LISP is good because it allows for symbolic representation, but lacks because the symbols lack meaning during run-time context. LISP also is good because it supports recursive programming in which backtracking can be used simply and effectively. I found that LISP is difficult to read if heavy recursion is used. Compiler support and development environment is not as extensive of that of C. Since LISP focuses on high-level interactions and symbolic representation, LISP severely lacks in the ability to manipulate low-level data (such as data structures and numerical values.) LISP compatibility has severe limitations since there are many “dialects” of LISP available; each with their own features.
With the consideration of LISP and C/C++, I’ve found more capability in C/C++ for AI applications. The development environment, support, and compatibility rivals LISP. Although C/C++ does not support symbolic representation and manipulation, C++’s concept of object-oriented design (OOD) can conquer this lacking feature. Also C++’s OOD can even extend beyond the symbolic representation of object by providing attributes/meanings to empty symbols (as in LISP). C/C++ also allow high-speed run-time and controllable memory allocation and de-allocation. Of the above mentioned five (5) features, C/C++ satisfies features 1, 4, 5 naturally. A programmer may extend the others. Also C/C++ satisfies 1, 2, and 4 additional concerns listed above.