LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 07-04-2004, 12:15 PM   #1
dfownz
Member
 
Registered: Jan 2004
Posts: 35

Rep: Reputation: 15
Programming AI


I'm not asking the specifics, but can someone give me a basic overview of how it works. Is AI "simply" a whole set of IF statements that look at the movements of something else. I just can't see how that would be efficient or easy to produce.

KEEP IT SIMPLE!

Thanks,

DF
 
Old 07-04-2004, 12:30 PM   #2
Dark_Helmet
Senior Member
 
Registered: Jan 2003
Posts: 2,786

Rep: Reputation: 374Reputation: 374Reputation: 374Reputation: 374
It depends on what type of AI your talking about.

In general, no, there are no AI constructs that are created with a whole big gob of if statements. The only format I know of that comes close to that would be Expert Systems.

Neural networks, for instance, "encode intelligence" in a large number of coefficients. There are no if statements; the coefficients act as "weights" to influence a particular action. The bigger the coefficient, the stronger the influence.

If you're talking about game programming AI, then that's completely different. Game AI is not really "true" artificial intelligence. Game AI is basicaly a script of simple "If this condition exists, do this" statements. The script writer has explicitly mapped out what the computer will do for a given situation, and there's very little room for the computer to adapt to new situations.

Last edited by Dark_Helmet; 07-04-2004 at 02:21 PM.
 
Old 07-04-2004, 01:01 PM   #3
llama_meme
Member
 
Registered: Nov 2001
Location: London, England
Distribution: Gentoo, FreeBSD
Posts: 590

Rep: Reputation: 30
AI is a research issue, and no-one really agrees on how to do it (there are many people who are very skeptical about neural networks, for example). Your best bet is to:

1) Decide exactly what it is that you want your AI to do.
2) Try to find any books/papers which discuss methods of doing that kind of thing, and try to implement them in your program.

There aren't really any general principles of AI. Just think about all the different things that a human intelligence can do, and see if you can find any (interesting) general principles underlying it — I doubt you can. There are lots of algorithms around for solving particular problems, though.

If you're doing games programming, you can probably get away with a very simple AI, so long as the AI doesn't have to deal with too many situations. Like Dark Helment said, you can just program an appropriate behaviour for each situation.

Alex
 
Old 07-04-2004, 01:34 PM   #4
infamous41md
Member
 
Registered: Mar 2003
Posts: 804

Rep: Reputation: 30
simply put: AI is (almost)all about trees. creating them, finding good ways to prune them, and traversing them to find the solutions to problems. trees represent the state space of a problem; if you're talking about a board game, then nodes on the tree represent the board state(the arrangement of pieces), if you're talking about finding the shortest path between 2 places on a map, nodes in the tree represent different cities along the route along with stats on how long it took to get to that city from the root node, etc.. no real AI agent is programmed with blocks of if or switch statements.

that was just a simple view, and obviously there are other strategies. there are lots of good sites to be found on google, or if u want a book, "AI A modern approach" by norvig and russel seems to be standard.
 
Old 07-04-2004, 06:14 PM   #5
keefaz
LQ Guru
 
Registered: Mar 2004
Distribution: Slackware
Posts: 6,552

Rep: Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872
You can download IQ test like here http://www.queendom.com/tests/iq/ and make a program that sucessfully answer to all the questions
 
Old 07-04-2004, 11:34 PM   #6
SciYro
Senior Member
 
Registered: Oct 2003
Location: hopefully not here
Distribution: Gentoo
Posts: 2,038

Rep: Reputation: 51
in my opinion AI's are all about controlling multiple things by what is most important

like set up the core part of a program so other parts can talk to it by giving it a number that it tells the core part how important and influential this task it wants to perform is, then either tell it what it can have to do the task, or that it cant do such a tasks,... it makes it decision based on the number, where it comes from, and how long/what it is compared with all other tasks currently running (is it just me or is this sounding more like a computer kernel?)

heres an example:

importance: 90/100

where the message came from: protector program (this program is fitted to protect all others (basically protect the computer or whatnot if under attack from something, like someone coming at it with a sledgehammer after losing to many chess games to the new AI)

other running tasks: moving a chess piece to win the game

the core program chooses to allow the protector program to do something ..., it requests what the program needs)

needs: use of all arms/limps

the core program, knowing that the protector program's requests are urgent, compared to other programs (not counting the importance number), and that the importance number is pretty high, allows for the protector program to use all limps to keep the computer/other programs safe)


the core program really only makes critical decisions, the other programs should talk to each other with a number of such given from the core program, they can talk so things like the protector program doesn't go off and steal the sledgehammer and knock that sore losers brains all over its case



all in all, for an actually smart AI you'll need multiple computer, each setup (or better yet: hardwired) to preform certain tasks, like translate spoken language into numbers that all other programs can understand, or to process input from a camera into stuff other parts of a computer can understand (if they need it)

keefaz: that iq test has to be messed up, it gave me ugly number! (plus some of them have no "correct" responses)

Last edited by SciYro; 07-04-2004 at 11:37 PM.
 
Old 07-11-2004, 03:16 PM   #7
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
There are several areas that fall under Artificial Intelligence. Speech recognition, pattern matching, analyzing text, neural networks, rule based systems, model based systems, robotics.

I think basically, when there is a capability of people that is hard to do on a computer, the study of how such a task would be accomplished on a computer can be called Artificial Intelligence.

The example you gave is a rule based system. It was once referred to as an Expert System. The program consists of a database of rules, and an engine which uses these rules. It is the data and rules that determine the behavior of the system rather than the engine.

This type of system today tends to be embedded in other software. Examples are the FTC analyzing stock trades to flag possible insider trading. Credit card companies analyzing purchase history to determine whether to approve a purchase, and even determine if the card was probably stolen.

A very simple circuit in modems help them adapt to changing line conditions. This circuit is a from neural network research.

I'm sure you have noticed companies, like FED EX that use speech recognition for there phone orders.
 
Old 07-17-2004, 10:53 AM   #8
clausi
Member
 
Registered: Mar 2004
Distribution: Debian
Posts: 48

Rep: Reputation: 15
I once found the following two projects for Game AI but haven't looked into them.

http://fear.sourceforge.net/

http://opensteer.sourceforge.net/

It may be helpful for somebody.
 
Old 11-19-2004, 12:14 PM   #9
earcam
LQ Newbie
 
Registered: Aug 2004
Location: London
Distribution: suse, debian
Posts: 13

Rep: Reputation: 0
There are two schools of AI.

Symbolic AI is rule based, uses decision trees etc. It's defined in logic. Eg. expert systems

Sub-symbolic AI manipulates numeric parameters. Eg. neural networks
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
which programming language is used to do tcp/ip programming?? gajaykrishnan Linux - Networking 9 12-21-2012 05:16 AM
im new to programming but..... boxerboy Programming 6 08-26-2005 06:17 AM
Difference between Top Down programming & Bottom up programming minil Programming 1 06-17-2005 02:42 AM
C programming oranj Linux - Networking 1 12-07-2004 12:40 AM
Qt Programming... jinksys Programming 1 08-06-2003 04:33 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 07:59 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration