Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Lisp, Scheme better than C for AI?

Name: Anonymous 2013-08-02 18:42

Hello. It seems everyone believes that Lisp-like languages are better than proceedural languages like C for AI. Why is that?

I suspect that recursion plays a part, but could use specific examples. Recursion is also possible in C, but not to the same degree or with the same ease, perhaps? Also, the distinctions between "live" processes and "dead" data have been said to be less clear in dialects of Lisp. Does this imply some valuable sorcery not easily wielded in C yet essential to AI advances? Examples and natural-language responses would be appreciated.

Perhaps a discussion of what's essential to AI and what's not (with respect to programming techniques and paradigms) is the thing I crave, something beyond the many FAQ-level responses.

Name: Anonymous 2013-08-02 20:42

Sure, it could be done. All turing complete languages can be used to achieve the same thing. But it would be a waste of time. Any AI experiment is going to be a failure 99.999% of the time anyway, so there is no need to waste resource worrying about how the prototype implementation runs with regards to speed or efficiency. It's more important to be able to be able to implement ideas quickly and save time for the programmer, who can spend more time thinking about what to write and less time worrying about whether whitespace is going to make Boost shit all over the linker.

If you're writing code that is actually going to do something important, like an autopilot or something, it would be best to rewrite it in C (or more likely Ada, the government loves that shit), where it can be tuned to the hardware and ensure that there is absolutely no room for error. If you're writing controls for a nuclear power plan, you'd better prove that shit is correct, down to the last bit. You could do this in Lisp too, but it's abstract enough to need you to prove the interpreter as well.

Working on machine vision? No one gives a flying fuck if that microcontroller crashes. Write it in Lisp. It'll be more elegant and readable than C, and it won't take nearly as long to write.

Name: Anonymous 2013-08-02 21:33

Lisp is better for mathematics in general. In C, 2*x is just an expression. You can't do anything with it. In lisp, (* 2 x) is an expression and a data structure. You can easily write a function to take its derivative or integral. You can also store it in a list to include it in vector and matrix operations. These are all very important in AI.

In practice however, most AI is done in C++.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List