C 188: Atiiil Intllign ing 2010 Ltu 2: Quu-Bs 1/21/2010 Pit Al UC Bkly Mny slis om Dn Klin Announmnts Pojt 0: Pyton Tutoil Out toy. Du nxt wk Tusy. L sssions in 271 o: Mony 2-3m Wnsy 4-5m T l tim is otionl, ut P0 itsl is not On sumit, you soul gt mil om t utog Potntilly mo l sssions o oi ous l in t l --- tk t nnounmnts stion on t wg! Wittn 1: On t w toy, lso u nxt wk Tusy. tions stting nxt wk, lotion: 285 Coy tion 101: Tu 3-4m tion 104: Tu 4-5m tion 102: W 11-noon tion 103: W noon-1m 1
Toy Polms Uninom Mtos (t viw o som) Dt-Fist Bt-Fist Uniom-Cost Huisti Mtos (nw o ll) Gy Rmin Only vy smll tion o AI is out mking omuts ly gms intlligntly Rll: omut vision, ntul lngug, ootis, min lning, omuttionl iology, t. Tt ing si: gms tn to ovi ltivly siml xml sttings wi gt to illustt n ln out lgoitms wi unli mny s o AI 2
Attmt t AI o siml gm Rlx gnt Wil(oo lt) ot t ossil itions to mov oing to t mount o oo in ition Go in t ition wit t lgst mount o oo Attmt t AI o siml gm Rlx gnt Wil(oo lt) ot t ossil itions to mov oing to t mount o oo in ition Go in t ition wit t lgst mount o oo 3
Attmt t AI o siml gm Rlx gnt Wil(oo lt) ot t ossil itions to mov oing to t mount o oo in ition Go in t ition wit t lgst mount o oo But, i ot otions vill, xlu t ition w just m om Attmt t AI o siml gm Rlx gnt Wil(oo lt) ot t ossil itions to mov oing to t mount o oo in ition Go in t ition wit t lgst mount o oo But, i ot otions vill, xlu t ition w just m om 4
Attmt t AI o siml gm Rlx gnt Wil(oo lt) I n k going in t unt ition, o so Otwis: ot itions oing to t mount o oo Go in t ition wit t lgst mount o oo But, i ot otions vill, xlu t ition w just m om Rlx Agnts Rlx gnts: Coos tion s on unt t (n my mmoy) My v mmoy o mol o t wol s unt stt Do not onsi t utu onsuns o ti tions At on ow t wol I Cn lx gnt tionl? 5
Gol Bs Agnts Gol-s gnts: Pln Ask wt i Disions s on (yotsiz) onsuns o tions Must v mol o ow t wol volvs in sons to tions At on ow t wol WOULD BE Polms A s olm onsists o: A stt s A susso untion N, 1.0 A stt stt n gol tst E, 1.0 A solution is sun o tions ( ln) wi tnsoms t stt stt to gol stt 6
Exml: Romni tt s: Citis usso untion: Go to j ity wit ost = ist tt stt: A Gol tst: Is stt == Bust? olution? tt Gs tt s g: A mtmtil snttion o s olm Fo vy s olm, t s osoning stt s g T susso untion is snt y s G W n ly uil tis g in mmoy (so w on t) Riiulously tiny s g o tiny s olm 7
tt izs? Polm: Et ll o t oo Pmn ositions: 10 x 12 = 120 Foo ount: 30 Gost ositions: 12 Pmn ing: u, own, lt, igt Ts N, 1.0 E, 1.0 A s t: Tis is wt i t o lns n outoms tt stt t t oot no Ciln oson to sussos Nos ontin stts, oson to PLAN to tos stts Fo most olms, w n nv tully uil t wol t 8
Anot T : Exn out ossil lns Mintin ing o unxn lns Ty to xn s w t nos s ossil Gnl T Imotnt is: Fing Exnsion Exlotion sttgy Dtil suoo is in t ook! Min ustion: wi ing nos to xlo? 9
10 Exml: T G tt Gs vs. Ts G G G W onstut ot on mn n w onstut s littl s ossil. E NODE in in t s t is n nti PATH in t olm g.
11 Rviw: Dt Fist G G G ttgy: xn st no ist Imlmnttion: Fing is LIFO stk Rviw: Bt Fist G G G Tis ttgy: xn sllowst no ist Imlmnttion: Fing is FIFO uu
Algoitm Potis Comlt? Gunt to in solution i on xists? Otiml? Gunt to in t lst ost t? Tim omlxity? omlxity? Vils: n Num o stts in t olm T vg ning to B (t vg num o sussos) C* Cost o lst ost solution s m Dt o t sllowst solution Mx t o t s t DF Algoitm Comlt Otiml Tim DF Dt Fist N N N N O(B Ininit LMAX ) O(LMAX) Ininit TART GOAL Ininit ts mk DF inomlt How n w ix tis? 12
DF Wit yl king, DF is omlt.* 1 no nos 2 nos m tis m nos Algoitm Comlt Otiml Tim DF w/ Pt Cking Y N O( m+1 ) O(m) Wn is DF otiml? * O g s nxt ltu. BF Algoitm Comlt Otiml Tim DF BF w/ Pt Cking Y N O( m+1 ) O(m) Y N* O( s+1 ) O( s ) s tis 1 no nos 2 nos s nos m nos Wn is BF otiml? 13
Comisons Wn will BF outom DF? Wn will DF outom BF? Ittiv Dning Ittiv ning uss DF s suoutin: 1. Do DF wi only ss o ts o lngt 1 o lss. 2. I 1 il, o DF wi only ss ts o lngt 2 o lss. 3. I 2 il, o DF wi only ss ts o lngt 3 o lss..n so on. Algoitm Comlt Otiml Tim DF BF ID w/ Pt Cking Y N O( m+1 ) O(m) Y N* O( s+1 ) O( s ) Y N* O( s+1 ) O(s) 14
Costs on Ations TART 2 3 1 1 2 3 8 2 9 8 2 4 4 15 GOAL 2 1 Noti tt BF ins t sotst t in tms o num o tnsitions. It os not in t lst-ost t. W will uikly ov n lgoitm wi os in t lst-ost t. Uniom Cost Exn st no ist: Fing is ioity uu Cost ontous 4 6 11 3 9 1 13 5 7 8 11 G 10 1 17 11 3 0 G 2 1 15 8 2 9 8 1 16 G 2 1 15
Pioity Quu Rs A ioity uu is t stutu in wi you n inst n tiv (ky, vlu) is wit t ollowing otions:.us(ky, vlu).o() insts (ky, vlu) into t uu. tuns t ky wit t lowst vlu, n movs it om t uu. You n s ky s ioity y using it gin Unlik gul uu, instions n t onstnt tim, usully O(log n) W ll n ioity uus o ost-snsitiv s mtos Uniom Cost Algoitm Comlt Otiml Tim DF BF UC w/ Pt Cking Y N O( m+1 ) O(m) Y N O( s+1 ) O( s ) Y* Y O( C*/ε ) O( C*/ε ) C*/ε tis * UC n il i tions n gt itily 16
Uniom Cost Issus Rmm: xlos insing ost ontous T goo: UC is omlt n otiml! 1 2 3 T : Exlos otions in vy ition No inomtion out gol lotion tt Gol [mo: s mo mty] Huistis Any stimt o ow los stt is to gol Dsign o tiul s olm Exmls: Mnttn istn, Eulin istn 10 5 11.2 17
Huistis Bst Fist / Gy Exn t no tt sms losst Wt n go wong? [mo: gy] 18
Bst Fist / Gy A ommon s: Bst-ist tks you stigt to t (wong) gol Wost-s: lik lygui DF in t wost s Cn xlo vyting Cn gt stuk in loos i no yl king Lik DF in omltnss (init stts w/ yl king) 19