1. Game Playing in Artificial Intelligence CMT310 --- Mwendwa Kivuva 1014638 Catholic University of Eastern Africa March 2009 [email_address] www.transworldafrica.com
2.
3.
4.
5.
6.
7.
8. Chess: 23-Mar-2009 Artificial Intelligence - CMT310 Kasparov 5’10” 176 lbs 34 years 50 billion neurons 2 pos/sec Extensive Electrical/chemical Enormous Height Weight Age Computers Speed Knowledge Power Source Ego Deep Blue 6’ 5” 2,400 lbs 4 years 32 RISC processors + 256 VLSI chess engines 200,000,000 pos/sec Primitive Electrical None 1997: Deep Blue wins by 3 wins, 1 loss, and 2 draws
9.
10.
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
21. Minimax Algorithm 23-Mar-2009 Artificial Intelligence - CMT310 function MINIMAX-DECISION( state ) returns an action inputs: state , current state in game v MAX-VALUE( state ) return the action in SUCCESSORS( state ) with value v function MIN-VALUE( state ) returns a utility value if TERMINAL-TEST( state ) then return UTILITY( state ) v ∞ for a,s in SUCCESSORS( state ) do v MIN( v, MAX-VALUE(s) ) return v function MAX-VALUE( state ) returns a utility value if TERMINAL-TEST( state ) then return UTILITY( state ) v -∞ for a,s in SUCCESSORS( state ) do v MAX( v, MIN-VALUE(s) ) return v
22.
23.
24. Pruning Example 23-Mar-2009 Artificial Intelligence - CMT310 3 MAX MIN =3 3 12 8 2 X X 2 14 14 5 5 2 =2 =3
25.
26. Alpha-Beta Algorithm 1 MAX Ply 23-Mar-2009 Artificial Intelligence - CMT310 function ALPHA-BETA-SEARCH( state ) returns an action inputs: state , current state in game v MAX-VALUE( state, - ∞ , + ∞ ) return the action in SUCCESSORS( state ) with value v function MAX-VALUE( state, , ) returns a utility value if TERMINAL-TEST( state ) then return UTILITY( state ) v - ∞ for a,s in SUCCESSORS( state ) do v MAX( v, MIN-VALUE( s , , )) if v ≥ then return v MAX( , v ) return v
27. Alpha-Beta Algorithm II MIN Ply 23-Mar-2009 Artificial Intelligence - CMT310 function MIN-VALUE( state, , ) returns a utility value if TERMINAL-TEST( state ) then return UTILITY( state ) v + ∞ for a,s in SUCCESSORS( state ) do v MIN( v, MAX-VALUE( s , , )) if v ≤ then return v MIN( , v ) return v
28.
29.
30.
31.
32.
33.
34. 23-Mar-2009 Artificial Intelligence - CMT310 To adapt hierarchical task-network planning techniques for use in BRIDGE GAME, ways for the planner to perform complex numeric calculations, plan for multiple agents, consult external information sources, and reason about uncertain information were developed. These same techniques are now proving useful in generating and evaluating manufacturing process plans Applications
35.
36.
37.
38.
39.
40.
41.
42.
43.
44.
45.
46.
47.
48.
Editor's Notes
Coarse-grained systems consist of fewer, larger components than fine-grained systems; a coarse-grained description of a system regards large subcomponents while a fine-grained description regards smaller components of which the larger ones are composed. Data are communicated are infrequent, after larger amounts of computation