Two Graph Algorithms On an Associative Computing Model

Size: px
Start display at page:

Download "Two Graph Algorithms On an Associative Computing Model"

Transcription

1 Two Grph Algorithms On n Assoitiv Computing Modl Mingxin Jin Dprtmnt of Mthmtis nd Computr Sin Fyttvill Stt Univrsity, Fyttvill, NC 801 Emil: mjin@unfsu.du Astrt - Th MASC (for Multipl Assoitiv Computing) modl is SIMD modl nhnd with ssoitiv proprtis nd multipl synhronous instrution strms (). A numr of lgorithms hv n dvlopd for this modl nd som hv n implmntd using its ssoitiv progrmming lngug. In this ppr, w prsnt two grph lgorithms for th rstritd MASC modl with on (lld th ASC modl). Ths r n ASC vrsion of Kruskl lgorithm for th minimum spnning tr (MST) prolm nd n ASC vrsion of Dijsktr lgorithm for th singl sour shortst pth (SSSP) prolm. Both of our lgorithms hv worst s tim of O(n) whih provid spdups of t lst n ovr thir squntil vrsions. Also, our sond lgorithm is ost optiml. Ths lgorithms hv dvntgs of ing sy to progrm, highly sll nd hving smll ovrhd osts. Thy provid ttr undrstnding out th powr of th ASC/MASC modl in trms of fftivnss of lgorithms it supports. Kywords: Prlll lgorithms, ssoitiv omputing, SIMD lgorithms, minimum spnning tr, singl sour shortst pth 1. Introdution Th MASC (for Multipl Assoitiv Computing) modl is SIMD modl nhnd with ssoitiv proprtis nd multipl synhronous instrution strms tht n xut nd oordint dt prlll thrds (i.., multi-simd modl). It ws proposd y Pottr nd Bkr in 199 [1], motivtd y th STARAN omputr uilt in 1970s y Goodyr Arosp. It hs n tivly studid t Knt Stt Univrsity s prtil modl for yrs. Th MASC modl posssss rtin onstnt tim glol proprtis suh s onstnt tim rodsting, onstnt tim glol rdution oprtions, nd onstnt tim ssoitiv srh, ll of whih hv n justifid in [9]. Ths proprtis mk it distinguishl from numr of othr prlll modls, in tht it solvs not only gnrl prlll prossing prolms fftivly ut lso solvs prolms in spil Johnni W. Bkr Dprtmnt of Computr Sin Knt Stt Univrsity Knt, OH Emil: jkr@s.knt.du rs suh s rl-tim ir trffi ontrol in n xtrmly ffiint mnnr [1]. Th MASC modl hs n omprd using simultions to othr wll-known prlll modls []. A stndrd ssoitiv lngug tht supports th on vrsion of MASC, lld ASC, hs n implmntd ross numr of pltforms. A numr of MASC lgorithms hv n dvlopd to solv prolms in vrious rs [1,, 1]. In this ppr, w prsnt two grph lgorithms for th ASC modl, nmly on for Kruskl lgorithm for th minimum spnning tr (MST) prolm, nd on for Dijkstr lgorithm for th singl sour shortst pth (SSSP) prolm. By tking dvntgs of onstnt tim ssoitiv oprtions on th modl, oth of our ASC vrsions of th lgorithms tk O(n) tim, whih is optiml nd provids n O(n) spdup whn omprd to thir squntil vrsions in worst s. Sin th MST nd SSSP prolms oth hv numrous prtil pplitions, this work provids dditionl informtion out th powr of th ASC nd MASC modl in trms of fftivnss of lgorithms thy support. Th ppr is orgnizd s following. Stion rviws th squntil lgorithms for Kruskl lgorithm nd Dijkstr lgorithm. Stion outlins th ASC/MASC modl nd its proprtis. Stions nd prsnt th ASC vrsion of Kruskl lgorithm for th MST prolm nd th ASC vrsion of Dijkstr lgorithm for SSSP prolm. Stion provids summry.. Prolms nd Thir Squntil Algorithms.1 Th MST Prolm Th MST prolm is dsrid s follows. Givn n wightd, undirtd onntd grph G=(V, E) whil V is th st of vrtis nd E is th st of dgs. Th prolm is to find tr T= (V, E ) suh tht E E nd th wight of T is minimizd. Clssil lgorithms to solv this prolm r Prim lgorithm nd Kruskl lgorithm, s dsrid in

2 []. An ASC vrsion of Prim lgorithm hs n dvlopd prviously [1]. In this ppr, w prsnt n ASC vrsion of Kruskl lgorithm in Stion. As dsrid in [], th squntil vrsion of Kruskl lgorithm uss th disjoint-st oprtions to itrtivly xmin ll dgs whih r pr-sortd in non-drsing ordr y wight. Initilly h of vrtis is md st. Th lgorithm slts n dg (u, v) with th smllst wight nd hks if it is sf dg. A sf dg is dfind to n dg tht n sfly ddd to th minimum spnning tr without mking yl or rking its proprty of prsrving minimum wight. If th dg (u, v) is sf, th st ontining u nd th st ontining v r mrgd to lrgr st. If th dg is not sf, thn it is disrdd. This produr is itrtd until ll dgs r xmind. Th squntil Kruskl lgorithm rquirs sorting ll dgs. Th running tim of th lgorithm is O( E log E ). Sin E V, this tim is qul to O( E log V ). If n = V nd m = E, this is O(m log n) or O(n log n) in worst s. Prlll vrsions of this lgorithm on diffrnt modls hv n studid. Most of thm r on th PRAM modl nd mny still rquir sorting dgs, unlss thy us nothr mthod [17]. For xmpls, th uthor of [10] dvlopd prlll Kruskl lgorithm on CRCW PRAM in O(log m) with mn prossors. Th uthors of [18] gv nothr prlll vrsion of this lgorithm on CRCW PRAM in O(log m) using O(m+n) prossors. Although our lgorithm tks mor tim, its ovrll ost is lss thn th ov xmpls, prtiulrly in worst s, s w us fwr prossors. Also, unlik othr vrsions of th lgorithms, our lgorithm limints nd of sorting dgs du to onstnt tim ssoitiv oprtions of th MASC modl.. Th SSSP Prolm Th SSSP prolm is dsrid s follows. Givn wightd, dirtd grph G = (V, E) whr V is th st of vrtis nd E is th st of dgs. Th wight of pth from vrtx u to vrtx v is dfind to th sum of th wights of ll inludd dgs from u to v. A pth is shortst pth if its wight is miniml. Th prolm is to find shortst pth from givn sour vrtx s V to h othr vrtx v V. Dijkstr lgorithm is lssil lgorithm to solv this prolm. As dsrid in [], th si id is th us of th grdy strtgy. Whil th lgorithm prods, th distn of h vrtx from th sour vrtx s is updtd. Th urrnt shortst distn from sour s to vrtx u is dnotd to d(u). Initilly d(u) for h vrtx u is st to infinit xpt d(s) is zro. A priority quu is usd to slt th nxt vrtx u with th shortst distn to s mong ll of th vrtis in th quu. Aftr u is xtrtd from th quu, d(v) for h djnt vrtx v of u is xmind. If th wight of th dg (u, v) is w(u, v) nd d(v) > d(u) + w(u, v) thn d(v) is st to d(u)+w(u, v), whih rprsnts th updtd urrnt shortst distn from s to v. Th produr is itrtd until th quu is mpty. Th running tim of Dijkstr lgorithm is O( V log V + E ) or O(n log n + m) if n = V nd m= E. This is O(n ) tim in worst s whn m = n. Howvr, using MASC, w do not nd to mintin th priority quu to find th minimum vlu. Instd, th MASC ssoitiv srh n find this dt itm in onstnt tim. Thrfor, th MASC vrsion of Dijkstr lgorithm tht will prsntd in Stion tks O(n) tim in worst s.. Th MASC Modl Th MASC modl is n nhnd multi-simd modl with ssoitiv oprtions. As shown in Figur 1, MASC onsists of n rry of prossing lmnts () nd on or mor instrution strms (s). A MASC with n nd j s is writtn s MASC(n, j). Sts of ssignd to h r disjoint nd form prtition of th st of ll. This prtition is dynmi in th sns tht th ssignmnt of to s n hng during xution. Eh PE, pird with its lol mmory, is lld ll. (In this ppr, w us th trms PE nd lls intrhngly whn thr is no onflit.) Instrutd y its ssignd, PE ts s n ALU to prform si rithmti nd logi oprtions. A PE nithr stors opy of th progrm nor prtiipts in doding this progrm. C E L L N E T W O R K Clls Mmory Mmory Mmory Th MASC modl hs thr ntworks; nmly, ll ntwork for ll ommunitions, n ntwork for ommunitions, nd rodst/rdution ntwork for ommunition twn n nd its st of lls. PE PE PE Brodst/rdution Ntwork Figur 1 Th MASC modl I S N E T W O R K

3 With its rodst/rdution ntwork, th MASC modl supports si ssoitiv oprtions in onstnt tim (ssuming word lngth is onstnt) nd rodst from n to its tiv lls in onstnt tim. Ths ssoitiv oprtions inlud th glol rdution oprtions of OR nd AND, th mximum nd minimum of intgr or rl vlus. In ddition, th MASC modl supports onstnt tim ssoitiv srh du to th ft tht dt in th lol mmoris of th r lotd y ontnt rthr thn y ddrss. Th lls whos dt vlu mths th srh pttrn r lld rspondrs nd th unsussful ons r lld non-rspondrs. Th n tivt ithr th rspondrs or th non-rspondrs. Eh n dtrmin if thr is rspondr ( ny rspondrs ) nd n slt (or pik on ) rspondr from th st of tiv lls in onstnt tim. An n instrut th sltd ll to pl vlu on th us nd ll othr lls in its st riv this vlu in onstnt tim. Th fsiility of ths ssumptions hs n justifid in [9] nd mor dtils n found thr. Th numr of s is nturlly smllr thn th numr of. s r oordintd using ontrol prlllism nd ommunit using th ntwork []. In this ppr, howvr, w only us th MASC modl with on instrution strm. A stndrd ssoitiv lngug tht supports th on vrsion of MASC, lso lld ASC, hs n implmntd ross numr of pltforms. It provids tru portility for prlll lgorithms [1]. As mntiond rlir, th MASC modl is l to support gnrl lgorithm dvlopmnt nd nlysis. A wid rng of diffrnt typ of ASC lgorithms nd svrl lrg progrms hs n implmntd using th ASC lngug. A fw xmpls r givn in [1,, 1]. Th MASC modl hs n omprd nd rltd to tht of othr wll-known prlll omputtionl modls suh s PRAM, MMB, nd RM. Som onstnt tim simultion rsults hv n otind []. Ths simultions nd omprisons provid mthods to vlut th powr of th MASC modl. On th othr hnd, it is lso usful to dvlop mor ffiint nd fftiv lgorithms for this modl, nd ths lgorithms provid informtion out its powr. A tulr rprsnttion is usd to stor dt for th MASC modl. Using n ssoitiv srh, dt n lotd y it ontnt rthr thn y its ddrss. For xmpl, Figur shows how dirtd grph n rprsntd in tulr form with h PE storing on vrtx of th grph. Th fiv prlll vrils,, 7 d 8 vrtx d PE 0 PE 0 7 PE 0 PE d 8 0 PE 0 Figur Grph rprsnttion on ASC -- on vrtx pr PE 7 8 d old_rp nw_rp dg u v stu_rp stv_rp sf Figur Grph rprsnttion on ASC -- on dg pr PE visitd PE Ys Ys PE 7 No No PE 8 d d No No PE d d No No PE No No PE d d No No PE No No PE d d No No PE Ys Ys intiv intiv intiv

4 , d, nd stor th wights of outgoing dgs from this vrtx, rsptivly. Figur shows how n undirtd grph n rprsntd with h PE storing on dg of th grph. Th vrils u nd v rprsnt th two vrtis of th dg. Othr vrils will disussd in ltr stions. Not tht sign is usd s suffix of prlll vril in ordr to distinguish it from n vril, whih is lso lld slr vril. Sin only on is usd in our lgorithms, w rfr to thm s ASC rthr thn MASC lgorithms. Ths ASC lgorithms r prsntd in th following stions.. ASC Vrsion of Kruskl Algorithm W us th grph rprsnttion illustrtd in Figur s th dt strutur in our lgorithm. Tht is, th informtion out h dg is stord on on PE. In ddition to th thr vrils (or filds) in Figur for th wight of th dg (dg) nd two nd vrtis (u nd v), four dditionl vrils r dfind, i.., stu_rp nd stv_rp for storing th rprsnttivs of th two disjoint-sts ontining u nd v, rsptivly, sf for idntifying sf dg, nd visitd for trking dgd tht hv n visitd. Initilly, ll stu_rp nd stv_rp r st to th sm vlus s u nd v, i.., stu_rp = u nd stv_rp = v. Th lgorithm follows th id of th squntil Kruskl lgorithm nd slts n dg with minimum wight, ut thr is no nd to first sort ll dgs in th MASC lgorithm. This is us th MASC modl n us its minimum fild oprtion to find n dg with th minimum wight in onstnt tim. Whn suh n dg is sltd, th two sts ontining its two djnt vrtis r hkd. If th two sts r diffrnt, th dg is sf nd n ddd to th rsulting tr. Th rds th vlus of th two st rprsnttivs, i., stu_rp or stv_rp. Th numrilly or lxiogrphilly smllr (i.., smllr using ditionry ordring) rprsnttiv is stord in th slr vril nw_rp, nd th othr rprsnttiv is stord in old_rp. Also, visitd is st to Ys for this dg. Th instruts ll to rpl ll th vlu of old_rp with th vlu of nw_rp in thir filds stu_rp nd stv_rp. Aftr updting, ll with stu_rp qul to stv_rp r dtivtd nd will not prtiipt in futur prossing. Th ov stps r itrtd until ll r intiv. At th lst stp, ll with visitd= Ys rprsnt th dgs of minimum spnning tr. Algorithm ASC-KRUSKAL-MST(G, T) Bgin 1. St ll to tiv. St stu_rp = u, stv_rp = v, sf = No, nd visitd = No. For ll, rpt th following stps until no PE is tiv.1. Find th minimum dg with visitd= No.. Pik on PE from rspondr(s) (if thr r multipl rspondrs).. St sf= Ys, st visitd= Ys.. Lt old_rp = Mx(stu_rp, stv_rp) nd nw_rp = Min(stu_rp, stv_rp).. Updt stu_rp nd stv_rp for ll y rpling th vlu of old_rp with th vlu of nw_rp.. Dtivt ll with stu_rp = stv_rp End. Th orrtnss of th lgorithm n justifid s follows. Initilly h vrtx mks n individul st. Eh round of itrtion xmins n dg with th minimum wight if its two djnt vrtis r in two diffrnt sts. If not, it is sf dg. Thn, w mrg th two sts nd st th nw st rprsnttiv to th vrtx tht hs smllr numr (or lxiogrphilly smllr). All ourrns of th old st rprsnttivs in th stu_rp nd stv_rp filds r updtd with th vlu of this nw st rprsnttiv. At th nd of th itrtion, ll with dgs hving two djnt vrtis in th sm st r dtivtd nd do not prtiipt futur prossing. This voids unnssry prossing. Figur shows vrils ftr two itrtions. Sin h itrtion tks onstnt tim, th running tim of th ov lgorithm is O( V ) or O(n) if V = n. It rprsnts spdup of O(m/n log n) omprd to th squntil vrsion of th lgorithm if E = m. In worst s, this is O(n log n), whih is sustntil. Morovr, w us m to stor dgs whil on dg pr PE. Thy n sily sld to lrg dt st without ny dditionl ovr hd osts.. ASC Vrsion of Dijkstr Algorithm W slightly modify th grph rprsntion in Figur for th dt strutur usd in our lgorithm. Th vrtis r still stord on pr PE. Instd of storing dt of its outgoing dgs, w stor dt of its inoming dgs. Th modifid dt strutur is shown in Figur. On h PE, in ddition to th n filds to rprsnt th grph (fiv filds in Figur ), thr

5 7 d 8 u dist_u sour vrtx d prnt visitd dist PE 0 Ys 0 PE 0 Ys PE No PE d 0 No PE 0 Ys Figur Modifid grph rprsnttion in Figur vrils r dfind. Thy r, dist for th urrnt shortst distn from th sour, prnt for th prnt (or prdssor) vrtx in th shortst pth, nd visitd for trking vrtis tht hv n visitd. On th, thr slr vrils r dfind, i.., sour for th sour vrtx, u for th vrtx urrntly ing prossd, nd dist_u for th urrnt shortst distn from s to u. Th lgorithm initilly sts ll ut th sour with dist to th vlu in th sour s fild, prnt to th sour if dist is not infinit othrwis to, nd visitd to No. For th sour vrtx, st dist to 0, prnt to nd visitd to Ys. Thn loop is xutd until ll vrtis hv n visitd. During h round of itrtion, find vrtx with th minimum dist nd st it visitd to Ys. Th rds th vrtx to th slr vril u nd its dist vlu to nothr slr vril dist_u. Thn th rodsts ths two vlus to ll othr. All with visitd = No hk if its dist > dist_u + th vlu in u s fild. If ys, updt dist with dist_u + th vlu in th u s fild nd its prnt is st to u. Th loop ontinus until no mor vrtx with visitd = No. It n dsrid s follows. Algorithm ASC-DIJKSTRA-SSSP(G, s) Bgin 1. St ll tiv. St visitd = No. St dist to th vlu in th sour s fild. St prnt to sour if dist is not infinit othrwis to. St visitd of sour to Ys. Rpt th following stps until no PE rmins with visitd = No.1. Find th minimum dist with visitd= No.. Pik on PE from th rspondr(s) (if thr r multipl rspondrs).. Rd u nd dist_u from vrtx nd dist of th PE pikd in th ov stp.. St vistd of u to Ys.. Brodst th vlus of u nd dist_u to ll.. For ll with visitd = No, if dist > (dist_u + th vlu in th u s fild) thn..1. St dist to dist_u + th vlu in th u s fild... St prnt to u End. Th orrtnss of th lgorithm n justifid s follows. Strting from th sour s, w slt vrtx u with th shortst distn dist_u to s. Thn w ompr th urrnt shortst distn dist for h of its djnt vrtis with th distn if th pth would go through u (i.., dist_u + th wight of th djnt dg). Th urrnt shortst distns of its djnt vrtis r updtd ordingly. Indutivly, ssum tht during th kth itrtion, th shortst pth from th sour to h vrtx is found, sujt to th rstrition tht th pth n only go through th k losst vrtis to th sour. This grdy strtgy usd in this lgorithm ssurs th shortst pth from th sour to h vrtx is found, sujt to th rstrition tht th pth n go through ithr th initil k+1 losst points to th sour. This ssurs tht for k = n-1, th shortst pth from h vrtx to th sour is found sin this pth is llowd to go through ny of th othr points. Sin h itrtion tks onstnt tim, th totl run tim of th ov lgorithm is O(n) tim if n = V. This rprsnts spdup of O(log n + m/n) ovr th squntil vrsion of Dijkstr lgorithm if m = E. In worst s whn m= n, th spdup is n, whih is linr. Morovr, this lgorithm is ost optiml sin th optiml running tim for th squntil lgorithm in th worst s is n. Prlll vrsions of Dijkstr lgorithm hv lso n studid y othr rsrhrs. Howvr, in th litrtur w hv srhd, thy did not provid lr omplxity nlysis (s xmpls in [1, 17]). In ontrst, th omplxity of our lgorithm is lr. Similrly, our lgorithm uss n, whih is ost

6 optiml. It lso hs dvntgs of sy progrmming nd high slility.. Summrizing Rmrks W hv prsntd two grph lgorithms for th ASC modl, i.., th ASC vrsion of Kruskl lgorithm for th MST prolm nd th ASC vrsion of Dijkstr lgorithm for th SSSP prolm. Both of thm tk O(n) tim. Both hv hivd signifint spdup of t lst ftor of n in th worst s, omprd with thir squntil vrsions. Also, our ASC vrsion of th Dijsktr lgorithm is ost optiml. Th rsults n summrizd in Tl 1, long with th rsults of similr rsrh work on othr modls. Tl 1 Squntil vrsion vs. ASC vrsion of th lgorithms Squntil Kruskl Algo. Numr of prossors Running tim 1 O(m log n) ASC Kruskl Algo. 1 + m O(n) CRCW PRAM Kruskl Algo. in [ 10] CRCW PRAM Kruskl Ago. in [ 18] Squntil Dijkstr Algo. mn O(log m) O(m+n) O(log m) In ddition to th spdups gind, th ASC lgorithms hv dvntgs of sy progrmming, highly slility, nd hving smll ovrhd osts. By tking dvntgs of th onstnt tim ssoitiv oprtions on th ASC modl, w limint nd of sorting dgs in th MST lgorithm. Ths two lgorithms n lso ffiintly implmntd on othr typs of SIMD omputrs, though th running tim my inrs dpnding on th ffiiny with whih th SIMD n support th dditionl si oprtions ssumd for ASC. Our work provids ttr undrstnding of th ASC/MASC modl in trms of fftivnss of lgorithms it supports. It lso ontriuts mor ASC/MASC vrsions of lssil lgorithms to th olltion of lgorithms for this modl. Furthr intrsting work inluds using multipl s to s how muh th running tim for ths 1 O(m+log n) ASC Dijkstr Algo 1 + n O(n) lgorithms n improvd. A possil dirtion for futur work is to implmnt th ov lgorithms on n ASC simultor using th ASC lngug, on SIMD, or COTS SIMD (.g., WorldSp s CSX01). This would provid dt to furthr vlut th fftivnss of ths lgorithms. Rfrns [1] M. Atwh, J.Bkr, S. Akl. An Assoitiv Implmnttion of Clssil Convx Hull Algorithms ; Pro. of th 8th Int l Conf. on Prlll nd Distriutd Computing Systms, pp. -8, 199. [] J. Bkr, M. Jin. Simultion of Enhnd Mshs with MASC, MSIMD Modl, Pro. of th 11th IASTED Int l Conf. on Prlll nd Distriutd Computing Systms, pp. 11-1, [] W. Chntms, J. Bkr, nd M. Shrgr. Compilr Extnsion of th ASC Lngug to Support Multipl Instrution Strms in th MASC Modl using th Mngr-Workr Prdigm, Int l Conf. on Prlll nd Distriutd Prossing Thniqus nd Applitions (PDPTA 0), Ls Vgs, Jun 00 [] K. W. Chong, Y. Hn, T. W. Lm. Conurrnt thrds nd optiml prlll minimum spnning trs lgorithm, Journl of th ACM (JACM), Vol. 8 No. Mrh 001 [] T.H. Cormn, C. E. Lisrson, R.L. Rivst, nd C. Stin. Introdution of Algorithms, nd d., MGrw Hill Highr Edution, 00. [] M. Esnwin, J. Bkr. VLCD String Mthing for Assoitiv Computing nd Multipl Brodst Msh, Pro. of th 9th Int l Conf. on Prlll nd Distriutd Computing Systms, pp. 9-7, [7] A. Grm, A. Gupt, G. Krypis, nd V. Kumr. Introdution to Prlll Computing, nd d., Addison- Wsly, 00. [8] R. M. Hrln. Srhing in prlll: s study with th singl-sour shortst pth lgorithm, ACM SIGCSE Bulltin, Pro. of th twnty-sond SIGCSE thnil symposium on Computr sin dution SIGCSE '91, Vol. No. 1 Mrh [9] M. Jin, J. Bkr, nd K. Bthr. Timings of Assoitiv Oprtions on th MASC modl, Pro. of th 1th IPDPS (Workshop in Mssivly Prlll Prossing), CD-ROM, April 001. [10] L. Kur. Prlll omputtion nd onflits in mmory ss, Inf. Pross Lttr, 1, (0 Apr. 198) 9-9. [11] D. B. Johnson, P. Mtxs. A prlll lgorithm for omputing minimum spnning trs, Pro. of th

7 th ACM Symposium on Prlll Algorithms nd Arhitturs, Jun 199. [1] P. Mtti d N. Do. Prlll lgorithms for th singl sour shortst pth prolm, Computing, vol. 9, No. 1, pp. 1-9, 198. [1] U. Myr nd P. Sndrs. -Stpping: A Prlll Singl Sour Shortst Pth Algorithm, Prodings of ESA '98: th Annul Europn Symposium, Vni, Itly, Springr Brlin/Hidlrg, August [1] W.C. Milndr, M. Jin, J.W. Bkr. Trtl Rl-Tim Control Automtion, Pro. of th 1th IASTED Int'l Conf. on Prlll nd Distriutd Systms (PDCS 00), pp [1] J. Pottr. Assoitiv Computing: A Progrmming Prdigm for Mssivly Prlll Computrs, Plnum Prss, Nw York, 199. [1] J. Pottr, J. Bkr, S. Sott, A. Bnsl, C. Lngsuksun, nd C. Asthgiri, ASC: An Assoitiv- Computing Prdigm, Computr, 7(11), 19-, 199. [17] M. J. Quinn, N. Do. Prlll grph lgorithms, ACM Computing Survys (CSUR), Vol. 1 No. Sptmr 198. [18] F. Surwr, P.Bhtthry. A prlll lgorithm for th minimum spnning tr on n SIMD mhin, Pro. of th 199 ACM nnul onfrn on Communitions CSC '9, April 199.

COMP108 Algorithmic Foundations

COMP108 Algorithmic Foundations Grdy mthods Prudn Wong http://www.s.liv..uk/~pwong/thing/omp108/01617 Coin Chng Prolm Suppos w hv 3 typs of oins 10p 0p 50p Minimum numr of oins to mk 0.8, 1.0, 1.? Grdy mthod Lrning outoms Undrstnd wht

More information

CSC Design and Analysis of Algorithms. Example: Change-Making Problem

CSC Design and Analysis of Algorithms. Example: Change-Making Problem CSC 801- Dsign n Anlysis of Algorithms Ltur 11 Gry Thniqu Exmpl: Chng-Mking Prolm Givn unlimit mounts of oins of nomintions 1 > > m, giv hng for mount n with th lst numr of oins Exmpl: 1 = 25, 2 =10, =

More information

An undirected graph G = (V, E) V a set of vertices E a set of unordered edges (v,w) where v, w in V

An undirected graph G = (V, E) V a set of vertices E a set of unordered edges (v,w) where v, w in V Unirt Grphs An unirt grph G = (V, E) V st o vrtis E st o unorr gs (v,w) whr v, w in V USE: to mol symmtri rltionships twn ntitis vrtis v n w r jnt i thr is n g (v,w) [or (w,v)] th g (v,w) is inint upon

More information

CSE 373: More on graphs; DFS and BFS. Michael Lee Wednesday, Feb 14, 2018

CSE 373: More on graphs; DFS and BFS. Michael Lee Wednesday, Feb 14, 2018 CSE 373: Mor on grphs; DFS n BFS Mihl L Wnsy, F 14, 2018 1 Wrmup Wrmup: Disuss with your nighor: Rmin your nighor: wht is simpl grph? Suppos w hv simpl, irt grph with x nos. Wht is th mximum numr of gs

More information

Minimum Spanning Trees

Minimum Spanning Trees Minimum Spnning Trs Minimum Spnning Trs Problm A town hs st of houss nd st of rods A rod conncts nd only houss A rod conncting houss u nd v hs rpir cost w(u, v) Gol: Rpir nough (nd no mor) rods such tht:

More information

Outline. 1 Introduction. 2 Min-Cost Spanning Trees. 4 Example

Outline. 1 Introduction. 2 Min-Cost Spanning Trees. 4 Example Outlin Computr Sin 33 Computtion o Minimum-Cost Spnnin Trs Prim's Alorithm Introution Mik Joson Dprtmnt o Computr Sin Univrsity o Clry Ltur #33 3 Alorithm Gnrl Constrution Mik Joson (Univrsity o Clry)

More information

(a) v 1. v a. v i. v s. (b)

(a) v 1. v a. v i. v s. (b) Outlin RETIMING Struturl optimiztion mthods. Gionni D Mihli Stnford Unirsity Rtiming. { Modling. { Rtiming for minimum dly. { Rtiming for minimum r. Synhronous Logi Ntwork Synhronous Logi Ntwork Synhronous

More information

CS 461, Lecture 17. Today s Outline. Example Run

CS 461, Lecture 17. Today s Outline. Example Run Prim s Algorithm CS 461, Ltur 17 Jr Si Univrsity o Nw Mxio In Prim s lgorithm, th st A mintin y th lgorithm orms singl tr. Th tr strts rom n ritrry root vrtx n grows until it spns ll th vrtis in V At h

More information

Exam 1 Solution. CS 542 Advanced Data Structures and Algorithms 2/14/2013

Exam 1 Solution. CS 542 Advanced Data Structures and Algorithms 2/14/2013 CS Avn Dt Struturs n Algorithms Exm Solution Jon Turnr //. ( points) Suppos you r givn grph G=(V,E) with g wights w() n minimum spnning tr T o G. Now, suppos nw g {u,v} is to G. Dsri (in wors) mtho or

More information

b. How many ternary words of length 23 with eight 0 s, nine 1 s and six 2 s?

b. How many ternary words of length 23 with eight 0 s, nine 1 s and six 2 s? MATH 3012 Finl Exm, My 4, 2006, WTT Stunt Nm n ID Numr 1. All our prts o this prolm r onrn with trnry strings o lngth n, i.., wors o lngth n with lttrs rom th lpht {0, 1, 2}.. How mny trnry wors o lngth

More information

Module graph.py. 1 Introduction. 2 Graph basics. 3 Module graph.py. 3.1 Objects. CS 231 Naomi Nishimura

Module graph.py. 1 Introduction. 2 Graph basics. 3 Module graph.py. 3.1 Objects. CS 231 Naomi Nishimura Moul grph.py CS 231 Nomi Nishimur 1 Introution Just lik th Python list n th Python itionry provi wys of storing, ssing, n moifying t, grph n viw s wy of storing, ssing, n moifying t. Bus Python os not

More information

Outline. Computer Science 331. Computation of Min-Cost Spanning Trees. Costs of Spanning Trees in Weighted Graphs

Outline. Computer Science 331. Computation of Min-Cost Spanning Trees. Costs of Spanning Trees in Weighted Graphs Outlin Computr Sin 33 Computtion o Minimum-Cost Spnnin Trs Prim s Mik Joson Dprtmnt o Computr Sin Univrsity o Clry Ltur #34 Introution Min-Cost Spnnin Trs 3 Gnrl Constrution 4 5 Trmintion n Eiiny 6 Aitionl

More information

Algorithmic and NP-Completeness Aspects of a Total Lict Domination Number of a Graph

Algorithmic and NP-Completeness Aspects of a Total Lict Domination Number of a Graph Intrntionl J.Mth. Comin. Vol.1(2014), 80-86 Algorithmi n NP-Compltnss Aspts of Totl Lit Domintion Numr of Grph Girish.V.R. (PES Institut of Thnology(South Cmpus), Bnglor, Krntk Stt, Ini) P.Ush (Dprtmnt

More information

CS61B Lecture #33. Administrivia: Autograder will run this evening. Today s Readings: Graph Structures: DSIJ, Chapter 12

CS61B Lecture #33. Administrivia: Autograder will run this evening. Today s Readings: Graph Structures: DSIJ, Chapter 12 Aministrivi: CS61B Ltur #33 Autogrr will run this vning. Toy s Rings: Grph Struturs: DSIJ, Chptr 12 Lst moifi: W Nov 8 00:39:28 2017 CS61B: Ltur #33 1 Why Grphs? For xprssing non-hirrhilly rlt itms Exmpls:

More information

V={A,B,C,D,E} E={ (A,D),(A,E),(B,D), (B,E),(C,D),(C,E)}

V={A,B,C,D,E} E={ (A,D),(A,E),(B,D), (B,E),(C,D),(C,E)} Introution Computr Sin & Enginring 423/823 Dsign n Anlysis of Algorithms Ltur 03 Elmntry Grph Algorithms (Chptr 22) Stphn Sott (Apt from Vinohnrn N. Vriym) I Grphs r strt t typs tht r pplil to numrous

More information

V={A,B,C,D,E} E={ (A,D),(A,E),(B,D), (B,E),(C,D),(C,E)}

V={A,B,C,D,E} E={ (A,D),(A,E),(B,D), (B,E),(C,D),(C,E)} s s of s Computr Sin & Enginring 423/823 Dsign n Anlysis of Ltur 03 (Chptr 22) Stphn Sott (Apt from Vinohnrn N. Vriym) s of s s r strt t typs tht r pplil to numrous prolms Cn ptur ntitis, rltionships twn

More information

Math 61 : Discrete Structures Final Exam Instructor: Ciprian Manolescu. You have 180 minutes.

Math 61 : Discrete Structures Final Exam Instructor: Ciprian Manolescu. You have 180 minutes. Nm: UCA ID Numr: Stion lttr: th 61 : Disrt Struturs Finl Exm Instrutor: Ciprin nolsu You hv 180 minuts. No ooks, nots or lultors r llow. Do not us your own srth ppr. 1. (2 points h) Tru/Fls: Cirl th right

More information

Graph Isomorphism. Graphs - II. Cayley s Formula. Planar Graphs. Outline. Is K 5 planar? The number of labeled trees on n nodes is n n-2

Graph Isomorphism. Graphs - II. Cayley s Formula. Planar Graphs. Outline. Is K 5 planar? The number of labeled trees on n nodes is n n-2 Grt Thortil Is In Computr Sin Vitor Amhik CS 15-251 Ltur 9 Grphs - II Crngi Mllon Univrsity Grph Isomorphism finition. Two simpl grphs G n H r isomorphi G H if thr is vrtx ijtion V H ->V G tht prsrvs jny

More information

CSE 373. Graphs 1: Concepts, Depth/Breadth-First Search reading: Weiss Ch. 9. slides created by Marty Stepp

CSE 373. Graphs 1: Concepts, Depth/Breadth-First Search reading: Weiss Ch. 9. slides created by Marty Stepp CSE 373 Grphs 1: Conpts, Dpth/Brth-First Srh ring: Wiss Ch. 9 slis rt y Mrty Stpp http://www.s.wshington.u/373/ Univrsity o Wshington, ll rights rsrv. 1 Wht is grph? 56 Tokyo Sttl Soul 128 16 30 181 140

More information

Announcements. Not graphs. These are Graphs. Applications of Graphs. Graph Definitions. Graphs & Graph Algorithms. A6 released today: Risk

Announcements. Not graphs. These are Graphs. Applications of Graphs. Graph Definitions. Graphs & Graph Algorithms. A6 released today: Risk Grphs & Grph Algorithms Ltur CS Spring 6 Announmnts A6 rls toy: Risk Strt signing with your prtnr sp Prlim usy Not grphs hs r Grphs K 5 K, =...not th kin w mn, nywy Applitions o Grphs Communition ntworks

More information

Why the Junction Tree Algorithm? The Junction Tree Algorithm. Clique Potential Representation. Overview. Chris Williams 1.

Why the Junction Tree Algorithm? The Junction Tree Algorithm. Clique Potential Representation. Overview. Chris Williams 1. Why th Juntion Tr lgorithm? Th Juntion Tr lgorithm hris Willims 1 Shool of Informtis, Univrsity of Einurgh Otor 2009 Th JT is gnrl-purpos lgorithm for omputing (onitionl) mrginls on grphs. It os this y

More information

, each of which is a tree, and whose roots r 1. , respectively, are children of r. Data Structures & File Management

, each of which is a tree, and whose roots r 1. , respectively, are children of r. Data Structures & File Management nrl tr T is init st o on or mor nos suh tht thr is on sint no r, ll th root o T, n th rminin nos r prtition into n isjoint susts T, T,, T n, h o whih is tr, n whos roots r, r,, r n, rsptivly, r hilrn o

More information

1 Introduction to Modulo 7 Arithmetic

1 Introduction to Modulo 7 Arithmetic 1 Introution to Moulo 7 Arithmti Bor w try our hn t solvin som hr Moulr KnKns, lt s tk los look t on moulr rithmti, mo 7 rithmti. You ll s in this sminr tht rithmti moulo prim is quit irnt rom th ons w

More information

Weighted graphs -- reminder. Data Structures LECTURE 15. Shortest paths algorithms. Example: weighted graph. Two basic properties of shortest paths

Weighted graphs -- reminder. Data Structures LECTURE 15. Shortest paths algorithms. Example: weighted graph. Two basic properties of shortest paths Dt Strutur LECTURE Shortt pth lgorithm Proprti of hortt pth Bllmn-For lgorithm Dijktr lgorithm Chptr in th txtook (pp ). Wight grph -- rminr A wight grph i grph in whih g hv wight (ot) w(v i, v j ) >.

More information

CS 241 Analysis of Algorithms

CS 241 Analysis of Algorithms CS 241 Anlysis o Algorithms Prossor Eri Aron Ltur T Th 9:00m Ltur Mting Lotion: OLB 205 Businss HW6 u lry HW7 out tr Thnksgiving Ring: Ch. 22.1-22.3 1 Grphs (S S. B.4) Grphs ommonly rprsnt onntions mong

More information

Planar Upward Drawings

Planar Upward Drawings C.S. 252 Pro. Rorto Tmssi Computtionl Gomtry Sm. II, 1992 1993 Dt: My 3, 1993 Sri: Shmsi Moussvi Plnr Upwr Drwings 1 Thorm: G is yli i n only i it hs upwr rwing. Proo: 1. An upwr rwing is yli. Follow th

More information

Similarity Search. The Binary Branch Distance. Nikolaus Augsten.

Similarity Search. The Binary Branch Distance. Nikolaus Augsten. Similrity Srh Th Binry Brnh Distn Nikolus Augstn nikolus.ugstn@sg..t Dpt. of Computr Sins Univrsity of Slzurg http://rsrh.uni-slzurg.t Vrsion Jnury 11, 2017 Wintrsmstr 2016/2017 Augstn (Univ. Slzurg) Similrity

More information

Paths. Connectivity. Euler and Hamilton Paths. Planar graphs.

Paths. Connectivity. Euler and Hamilton Paths. Planar graphs. Pths.. Eulr n Hmilton Pths.. Pth D. A pth rom s to t is squn o gs {x 0, x 1 }, {x 1, x 2 },... {x n 1, x n }, whr x 0 = s, n x n = t. D. Th lngth o pth is th numr o gs in it. {, } {, } {, } {, } {, } {,

More information

CSE 373: AVL trees. Warmup: Warmup. Interlude: Exploring the balance invariant. AVL Trees: Invariants. AVL tree invariants review

CSE 373: AVL trees. Warmup: Warmup. Interlude: Exploring the balance invariant. AVL Trees: Invariants. AVL tree invariants review rmup CSE 7: AVL trs rmup: ht is n invrint? Mihl L Friy, Jn 9, 0 ht r th AVL tr invrints, xtly? Disuss with your nighor. AVL Trs: Invrints Intrlu: Exploring th ln invrint Cor i: xtr invrint to BSTs tht

More information

CS200: Graphs. Graphs. Directed Graphs. Graphs/Networks Around Us. What can this represent? Sometimes we want to represent directionality:

CS200: Graphs. Graphs. Directed Graphs. Graphs/Networks Around Us. What can this represent? Sometimes we want to represent directionality: CS2: Grphs Prihr Ch. 4 Rosn Ch. Grphs A olltion of nos n gs Wht n this rprsnt? n A omputr ntwork n Astrtion of mp n Soil ntwork CS2 - Hsh Tls 2 Dirt Grphs Grphs/Ntworks Aroun Us A olltion of nos n irt

More information

CSE303 - Introduction to the Theory of Computing Sample Solutions for Exercises on Finite Automata

CSE303 - Introduction to the Theory of Computing Sample Solutions for Exercises on Finite Automata CSE303 - Introduction to th Thory of Computing Smpl Solutions for Exrciss on Finit Automt Exrcis 2.1.1 A dtrministic finit utomton M ccpts th mpty string (i.., L(M)) if nd only if its initil stt is finl

More information

Announcements. These are Graphs. This is not a Graph. Graph Definitions. Applications of Graphs. Graphs & Graph Algorithms

Announcements. These are Graphs. This is not a Graph. Graph Definitions. Applications of Graphs. Graphs & Graph Algorithms Grphs & Grph Algorithms Ltur CS Fll 5 Announmnts Upoming tlk h Mny Crrs o Computr Sintist Or how Computr Sin gr mpowrs you to o muh mor thn o Dn Huttnlohr, Prossor in th Dprtmnt o Computr Sin n Johnson

More information

12. Traffic engineering

12. Traffic engineering lt2.ppt S-38. Introution to Tltrffi Thory Spring 200 2 Topology Pths A tlommunition ntwork onsists of nos n links Lt N not th st of nos in with n Lt J not th st of nos in with j N = {,,,,} J = {,2,3,,2}

More information

Formal Concept Analysis

Formal Concept Analysis Forml Conpt Anlysis Conpt intnts s losd sts Closur Systms nd Implitions 4 Closur Systms 0.06.005 Nxt-Closur ws dvlopd y B. Gntr (984). Lt M = {,..., n}. A M is ltilly smllr thn B M, if B A if th smllst

More information

Cycles and Simple Cycles. Paths and Simple Paths. Trees. Problem: There is No Completely Standard Terminology!

Cycles and Simple Cycles. Paths and Simple Paths. Trees. Problem: There is No Completely Standard Terminology! Outlin Computr Sin 331, Spnnin, n Surphs Mik Joson Dprtmnt o Computr Sin Univrsity o Clry Ltur #30 1 Introution 2 3 Dinition 4 Spnnin 5 6 Mik Joson (Univrsity o Clry) Computr Sin 331 Ltur #30 1 / 20 Mik

More information

Problem solving by search

Problem solving by search Prolm solving y srh Tomáš voo Dprtmnt o Cyrntis, Vision or Roots n Autonomous ystms Mrh 5, 208 / 3 Outlin rh prolm. tt sp grphs. rh trs. trtgis, whih tr rnhs to hoos? trtgy/algorithm proprtis? Progrmming

More information

Present state Next state Q + M N

Present state Next state Q + M N Qustion 1. An M-N lip-lop works s ollows: I MN=00, th nxt stt o th lip lop is 0. I MN=01, th nxt stt o th lip-lop is th sm s th prsnt stt I MN=10, th nxt stt o th lip-lop is th omplmnt o th prsnt stt I

More information

Constructive Geometric Constraint Solving

Constructive Geometric Constraint Solving Construtiv Gomtri Constrint Solving Antoni Soto i Rir Dprtmnt Llngutgs i Sistms Inormàtis Univrsitt Politèni Ctluny Brlon, Sptmr 2002 CGCS p.1/37 Prliminris CGCS p.2/37 Gomtri onstrint prolm C 2 D L BC

More information

Garnir Polynomial and their Properties

Garnir Polynomial and their Properties Univrsity of Cliforni, Dvis Dprtmnt of Mthmtis Grnir Polynomil n thir Proprtis Author: Yu Wng Suprvisor: Prof. Gorsky Eugny My 8, 07 Grnir Polynomil n thir Proprtis Yu Wng mil: uywng@uvis.u. In this ppr,

More information

12/3/12. Outline. Part 10. Graphs. Circuits. Euler paths/circuits. Euler s bridge problem (Bridges of Konigsberg Problem)

12/3/12. Outline. Part 10. Graphs. Circuits. Euler paths/circuits. Euler s bridge problem (Bridges of Konigsberg Problem) 12/3/12 Outlin Prt 10. Grphs CS 200 Algorithms n Dt Struturs Introution Trminology Implmnting Grphs Grph Trvrsls Topologil Sorting Shortst Pths Spnning Trs Minimum Spnning Trs Ciruits 1 Ciruits Cyl 2 Eulr

More information

CS September 2018

CS September 2018 Loil los Distriut Systms 06. Loil los Assin squn numrs to msss All ooprtin prosss n r on orr o vnts vs. physil los: rport tim o y Assum no ntrl tim sour Eh systm mintins its own lol lo No totl orrin o

More information

5/9/13. Part 10. Graphs. Outline. Circuits. Introduction Terminology Implementing Graphs

5/9/13. Part 10. Graphs. Outline. Circuits. Introduction Terminology Implementing Graphs Prt 10. Grphs CS 200 Algorithms n Dt Struturs 1 Introution Trminology Implmnting Grphs Outlin Grph Trvrsls Topologil Sorting Shortst Pths Spnning Trs Minimum Spnning Trs Ciruits 2 Ciruits Cyl A spil yl

More information

Graphs. CSC 1300 Discrete Structures Villanova University. Villanova CSC Dr Papalaskari

Graphs. CSC 1300 Discrete Structures Villanova University. Villanova CSC Dr Papalaskari Grphs CSC 1300 Disrt Struturs Villnov Univrsity Grphs Grphs r isrt struturs onsis?ng of vr?s n gs tht onnt ths vr?s. Grphs n us to mol: omputr systms/ntworks mthm?l rl?ons logi iruit lyout jos/prosss f

More information

COMPLEXITY OF COUNTING PLANAR TILINGS BY TWO BARS

COMPLEXITY OF COUNTING PLANAR TILINGS BY TWO BARS OMPLXITY O OUNTING PLNR TILINGS Y TWO RS KYL MYR strt. W show tht th prolm o trmining th numr o wys o tiling plnr igur with horizontl n vrtil r is #P-omplt. W uil o o th rsults o uquir, Nivt, Rmil, n Roson

More information

Graphs. Graphs. Graphs: Basic Terminology. Directed Graphs. Dr Papalaskari 1

Graphs. Graphs. Graphs: Basic Terminology. Directed Graphs. Dr Papalaskari 1 CSC 00 Disrt Struturs : Introuon to Grph Thory Grphs Grphs CSC 00 Disrt Struturs Villnov Univrsity Grphs r isrt struturs onsisng o vrs n gs tht onnt ths vrs. Grphs n us to mol: omputr systms/ntworks mthml

More information

A 4-state solution to the Firing Squad Synchronization Problem based on hybrid rule 60 and 102 cellular automata

A 4-state solution to the Firing Squad Synchronization Problem based on hybrid rule 60 and 102 cellular automata A 4-stt solution to th Firing Squ Synhroniztion Prolm s on hyri rul 60 n 102 llulr utomt LI Ning 1, LIANG Shi-li 1*, CUI Shung 1, XU Mi-ling 1, ZHANG Ling 2 (1. Dprtmnt o Physis, Northst Norml Univrsity,

More information

QUESTIONS BEGIN HERE!

QUESTIONS BEGIN HERE! Points miss: Stunt's Nm: Totl sor: /100 points Est Tnnss Stt Univrsity Dprtmnt of Computr n Informtion Sins CSCI 710 (Trnoff) Disrt Struturs TEST for Fll Smstr, 00 R this for strtin! This tst is los ook

More information

Greedy Algorithms, Activity Selection, Minimum Spanning Trees Scribes: Logan Short (2015), Virginia Date: May 18, 2016

Greedy Algorithms, Activity Selection, Minimum Spanning Trees Scribes: Logan Short (2015), Virginia Date: May 18, 2016 Ltur 4 Gry Algorithms, Ativity Sltion, Minimum Spnning Trs Sris: Logn Short (5), Virgini Dt: My, Gry Algorithms Suppos w wnt to solv prolm, n w r l to om up with som rursiv ormultion o th prolm tht woul

More information

Integration Continued. Integration by Parts Solving Definite Integrals: Area Under a Curve Improper Integrals

Integration Continued. Integration by Parts Solving Definite Integrals: Area Under a Curve Improper Integrals Intgrtion Continud Intgrtion y Prts Solving Dinit Intgrls: Ar Undr Curv Impropr Intgrls Intgrtion y Prts Prticulrly usul whn you r trying to tk th intgrl o som unction tht is th product o n lgric prssion

More information

Weighted Matching and Linear Programming

Weighted Matching and Linear Programming Wightd Mtching nd Linr Progrmming Jonthn Turnr Mrch 19, 01 W v sn tht mximum siz mtchings cn b found in gnrl grphs using ugmnting pths. In principl, this sm pproch cn b pplid to mximum wight mtchings.

More information

Using the Printable Sticker Function. Using the Edit Screen. Computer. Tablet. ScanNCutCanvas

Using the Printable Sticker Function. Using the Edit Screen. Computer. Tablet. ScanNCutCanvas SnNCutCnvs Using th Printl Stikr Funtion On-o--kin stikrs n sily rt y using your inkjt printr n th Dirt Cut untion o th SnNCut mhin. For inormtion on si oprtions o th SnNCutCnvs, rr to th Hlp. To viw th

More information

A Simple Code Generator. Code generation Algorithm. Register and Address Descriptors. Example 3/31/2008. Code Generation

A Simple Code Generator. Code generation Algorithm. Register and Address Descriptors. Example 3/31/2008. Code Generation A Simpl Co Gnrtor Co Gnrtion Chptr 8 II Gnrt o for singl si lok How to us rgistrs? In most mhin rhitturs, som or ll of th oprnsmust in rgistrs Rgistrs mk goo tmporris Hol vlus tht r omput in on si lok

More information

Research Scholar, Vinoba Bhave University, Hazaribag, Jharkhand

Research Scholar, Vinoba Bhave University, Hazaribag, Jharkhand Volum Issu July 0 ISSN: X Intrntionl Journl of Advnd Rsrh in Computr Sin nd Softwr Enginring Rsrh Ppr Avill onlin t: www.ijrss.om Dominting Funtion Thory from Nwton to Linitz s Approh of Indfinit Intgrtion

More information

HIGHER ORDER DIFFERENTIAL EQUATIONS

HIGHER ORDER DIFFERENTIAL EQUATIONS Prof Enriqu Mtus Nivs PhD in Mthmtis Edution IGER ORDER DIFFERENTIAL EQUATIONS omognous linr qutions with onstnt offiints of ordr two highr Appl rdution mthod to dtrmin solution of th nonhomognous qution

More information

Numbering Boundary Nodes

Numbering Boundary Nodes Numring Bounry Nos Lh MBri Empori Stt Univrsity August 10, 2001 1 Introution Th purpos of this ppr is to xplor how numring ltril rsistor ntworks ffts thir rspons mtrix, Λ. Morovr, wht n lrn from Λ out

More information

The University of Sydney MATH2969/2069. Graph Theory Tutorial 5 (Week 12) Solutions 2008

The University of Sydney MATH2969/2069. Graph Theory Tutorial 5 (Week 12) Solutions 2008 Th Univrsity o Syny MATH2969/2069 Grph Thory Tutoril 5 (Wk 12) Solutions 2008 1. (i) Lt G th isonnt plnr grph shown. Drw its ul G, n th ul o th ul (G ). (ii) Show tht i G is isonnt plnr grph, thn G is

More information

CSCI Compiler Design

CSCI Compiler Design CSCI 565 - Compilr Dsign Spring 2013 Sond Tst - Solution My 1, 2013 t 3.30 PM in Room RTH 115 Durtion: 2h 30 min. Pls ll ll pgs you turn in with your nm nd studnt numr. Nm: Numr: Grd: Prolm 1 [20 points]:

More information

Outline. Binary Tree

Outline. Binary Tree Outlin Similrity Srh Th Binry Brnh Distn Nikolus Austn nikolus.ustn@s..t Dpt. o Computr Sins Univrsity o Slzur http://rsrh.uni-slzur.t 1 Binry Brnh Distn Binry Rprsnttion o Tr Binry Brnhs Lowr Boun or

More information

(2) If we multiplied a row of B by λ, then the value is also multiplied by λ(here lambda could be 0). namely

(2) If we multiplied a row of B by λ, then the value is also multiplied by λ(here lambda could be 0). namely . DETERMINANT.. Dtrminnt. Introution:I you think row vtor o mtrix s oorint o vtors in sp, thn th gomtri mning o th rnk o th mtrix is th imnsion o th prlllppi spnn y thm. But w r not only r out th imnsion,

More information

Outline. Circuits. Euler paths/circuits 4/25/12. Part 10. Graphs. Euler s bridge problem (Bridges of Konigsberg Problem)

Outline. Circuits. Euler paths/circuits 4/25/12. Part 10. Graphs. Euler s bridge problem (Bridges of Konigsberg Problem) 4/25/12 Outlin Prt 10. Grphs CS 200 Algorithms n Dt Struturs Introution Trminology Implmnting Grphs Grph Trvrsls Topologil Sorting Shortst Pths Spnning Trs Minimum Spnning Trs Ciruits 1 2 Eulr s rig prolm

More information

Chapter 16. 1) is a particular point on the graph of the function. 1. y, where x y 1

Chapter 16. 1) is a particular point on the graph of the function. 1. y, where x y 1 Prctic qustions W now tht th prmtr p is dirctl rltd to th mplitud; thrfor, w cn find tht p. cos d [ sin ] sin sin Not: Evn though ou might not now how to find th prmtr in prt, it is lws dvisl to procd

More information

Instructions for Section 1

Instructions for Section 1 Instructions for Sction 1 Choos th rspons tht is corrct for th qustion. A corrct nswr scors 1, n incorrct nswr scors 0. Mrks will not b dductd for incorrct nswrs. You should ttmpt vry qustion. No mrks

More information

Seven-Segment Display Driver

Seven-Segment Display Driver 7-Smnt Disply Drivr, Ron s in 7-Smnt Disply Drivr, Ron s in Prolm 62. 00 0 0 00 0000 000 00 000 0 000 00 0 00 00 0 0 0 000 00 0 00 BCD Diits in inry Dsin Drivr Loi 4 inputs, 7 outputs 7 mps, h with 6 on

More information

learning objectives learn what graphs are in mathematical terms learn how to represent graphs in computers learn about typical graph algorithms

learning objectives learn what graphs are in mathematical terms learn how to represent graphs in computers learn about typical graph algorithms rp loritms lrnin ojtivs loritms your sotwr systm sotwr rwr lrn wt rps r in mtmtil trms lrn ow to rprsnt rps in omputrs lrn out typil rp loritms wy rps? intuitivly, rp is orm y vrtis n s twn vrtis rps r

More information

CIVL 8/ D Boundary Value Problems - Rectangular Elements 1/7

CIVL 8/ D Boundary Value Problems - Rectangular Elements 1/7 CIVL / -D Boundr Vlu Prolms - Rctngulr Elmnts / RECANGULAR ELEMENS - In som pplictions, it m mor dsirl to us n lmntl rprsnttion of th domin tht hs four sids, ithr rctngulr or qudriltrl in shp. Considr

More information

Register Allocation. Register Allocation. Principle Phases. Principle Phases. Example: Build. Spills 11/14/2012

Register Allocation. Register Allocation. Principle Phases. Principle Phases. Example: Build. Spills 11/14/2012 Rgistr Allotion W now r l to o rgistr llotion on our intrfrn grph. W wnt to l with two typs of onstrints: 1. Two vlus r liv t ovrlpping points (intrfrn grph) 2. A vlu must or must not in prtiulr rhitturl

More information

UNCORRECTED SAMPLE PAGES 4-1. Naming fractions KEY IDEAS. 1 Each shape represents ONE whole. a i ii. b i ii

UNCORRECTED SAMPLE PAGES 4-1. Naming fractions KEY IDEAS. 1 Each shape represents ONE whole. a i ii. b i ii - Nming frtions Chptr Frtions Eh shp rprsnts ONE whol. i ii Wht frtion is shdd? Writ s frtion nd in words. Wht frtion is not shdd? Writ s frtion nd in words. i ii i ii Writ s mny diffrnt frtions s you

More information

Last time: introduced our first computational model the DFA.

Last time: introduced our first computational model the DFA. Lctur 7 Homwork #7: 2.2.1, 2.2.2, 2.2.3 (hnd in c nd d), Misc: Givn: M, NFA Prov: (q,xy) * (p,y) iff (q,x) * (p,) (follow proof don in clss tody) Lst tim: introducd our first computtionl modl th DFA. Tody

More information

Winter 2016 COMP-250: Introduction to Computer Science. Lecture 23, April 5, 2016

Winter 2016 COMP-250: Introduction to Computer Science. Lecture 23, April 5, 2016 Wintr 2016 COMP-250: Introduction to Computr Scinc Lctur 23, April 5, 2016 Commnt out input siz 2) Writ ny lgorithm tht runs in tim Θ(n 2 log 2 n) in wors cs. Explin why this is its running tim. I don

More information

# 1 ' 10 ' 100. Decimal point = 4 hundred. = 6 tens (or sixty) = 5 ones (or five) = 2 tenths. = 7 hundredths.

# 1 ' 10 ' 100. Decimal point = 4 hundred. = 6 tens (or sixty) = 5 ones (or five) = 2 tenths. = 7 hundredths. How os it work? Pl vlu o imls rprsnt prts o whol numr or ojt # 0 000 Tns o thousns # 000 # 00 Thousns Hunrs Tns Ons # 0 Diml point st iml pl: ' 0 # 0 on tnth n iml pl: ' 0 # 00 on hunrth r iml pl: ' 0

More information

QUESTIONS BEGIN HERE!

QUESTIONS BEGIN HERE! Points miss: Stunt's Nm: Totl sor: /100 points Est Tnnss Stt Univrsity Dprtmnt o Computr n Inormtion Sins CSCI 2710 (Trno) Disrt Struturs TEST or Sprin Smstr, 2005 R this or strtin! This tst is los ook

More information

ECE COMBINATIONAL BUILDING BLOCKS - INVEST 13 DECODERS AND ENCODERS

ECE COMBINATIONAL BUILDING BLOCKS - INVEST 13 DECODERS AND ENCODERS C 24 - COMBINATIONAL BUILDING BLOCKS - INVST 3 DCODS AND NCODS FALL 23 AP FLZ To o "wll" on this invstition you must not only t th riht nswrs ut must lso o nt, omplt n onis writups tht mk ovious wht h

More information

ECE 407 Computer Aided Design for Electronic Systems. Circuit Modeling and Basic Graph Concepts/Algorithms. Instructor: Maria K. Michael.

ECE 407 Computer Aided Design for Electronic Systems. Circuit Modeling and Basic Graph Concepts/Algorithms. Instructor: Maria K. Michael. 0 Computr i Dsign or Eltroni Systms Ciruit Moling n si Grph Conptslgorithms Instrutor: Mri K. Mihl MKM - Ovrviw hviorl vs. Struturl mols Extrnl vs. Intrnl rprsnttions Funtionl moling t Logi lvl Struturl

More information

16.unified Introduction to Computers and Programming. SOLUTIONS to Examination 4/30/04 9:05am - 10:00am

16.unified Introduction to Computers and Programming. SOLUTIONS to Examination 4/30/04 9:05am - 10:00am 16.unii Introution to Computrs n Prormmin SOLUTIONS to Exmintion /30/0 9:05m - 10:00m Pro. I. Kristin Lunqvist Sprin 00 Grin Stion: Qustion 1 (5) Qustion (15) Qustion 3 (10) Qustion (35) Qustion 5 (10)

More information

INTEGRALS. Chapter 7. d dx. 7.1 Overview Let d dx F (x) = f (x). Then, we write f ( x)

INTEGRALS. Chapter 7. d dx. 7.1 Overview Let d dx F (x) = f (x). Then, we write f ( x) Chptr 7 INTEGRALS 7. Ovrviw 7.. Lt d d F () f (). Thn, w writ f ( ) d F () + C. Ths intgrls r clld indfinit intgrls or gnrl intgrls, C is clld constnt of intgrtion. All ths intgrls diffr y constnt. 7..

More information

Analysis for Balloon Modeling Structure based on Graph Theory

Analysis for Balloon Modeling Structure based on Graph Theory Anlysis for lloon Moling Strutur bs on Grph Thory Abstrt Mshiro Ur* Msshi Ym** Mmoru no** Shiny Miyzki** Tkmi Ysu* *Grut Shool of Informtion Sin, Ngoy Univrsity **Shool of Informtion Sin n Thnology, hukyo

More information

0.1. Exercise 1: the distances between four points in a graph

0.1. Exercise 1: the distances between four points in a graph Mth 707 Spring 2017 (Drij Grinrg): mitrm 3 pg 1 Mth 707 Spring 2017 (Drij Grinrg): mitrm 3 u: W, 3 My 2017, in lss or y mil (grinr@umn.u) or lss S th wsit or rlvnt mtril. Rsults provn in th nots, or in

More information

FSA. CmSc 365 Theory of Computation. Finite State Automata and Regular Expressions (Chapter 2, Section 2.3) ALPHABET operations: U, concatenation, *

FSA. CmSc 365 Theory of Computation. Finite State Automata and Regular Expressions (Chapter 2, Section 2.3) ALPHABET operations: U, concatenation, * CmSc 365 Thory of Computtion Finit Stt Automt nd Rgulr Exprssions (Chptr 2, Sction 2.3) ALPHABET oprtions: U, conctntion, * otin otin Strings Form Rgulr xprssions dscri Closd undr U, conctntion nd * (if

More information

A Low Noise and Reliable CMOS I/O Buffer for Mixed Low Voltage Applications

A Low Noise and Reliable CMOS I/O Buffer for Mixed Low Voltage Applications Proings of th 6th WSEAS Intrntionl Confrn on Miroltronis, Nnoltronis, Optoltronis, Istnul, Turky, My 27-29, 27 32 A Low Nois n Rlil CMOS I/O Buffr for Mix Low Voltg Applitions HWANG-CHERNG CHOW n YOU-GANG

More information

GREEDY TECHNIQUE. Greedy method vs. Dynamic programming method:

GREEDY TECHNIQUE. Greedy method vs. Dynamic programming method: Dinition: GREEDY TECHNIQUE Gry thniqu is gnrl lgorithm sign strtgy, uilt on ollowing lmnts: onigurtions: irnt hois, vlus to in ojtiv untion: som onigurtions to ithr mximiz or minimiz Th mtho: Applil to

More information

DUET WITH DIAMONDS COLOR SHIFTING BRACELET By Leslie Rogalski

DUET WITH DIAMONDS COLOR SHIFTING BRACELET By Leslie Rogalski Dut with Dimons Brlt DUET WITH DIAMONDS COLOR SHIFTING BRACELET By Lsli Roglski Photo y Anrw Wirth Supruo DUETS TM from BSmith rt olor shifting fft tht mks your work tk on lif of its own s you mov! This

More information

Section 10.4 Connectivity (up to paths and isomorphism, not including)

Section 10.4 Connectivity (up to paths and isomorphism, not including) Toy w will isuss two stions: Stion 10.3 Rprsnting Grphs n Grph Isomorphism Stion 10.4 Conntivity (up to pths n isomorphism, not inluing) 1 10.3 Rprsnting Grphs n Grph Isomorphism Whn w r working on n lgorithm

More information

Register Allocation. How to assign variables to finitely many registers? What to do when it can t be done? How to do so efficiently?

Register Allocation. How to assign variables to finitely many registers? What to do when it can t be done? How to do so efficiently? Rgistr Allotion Rgistr Allotion How to ssign vrils to initly mny rgistrs? Wht to o whn it n t on? How to o so iintly? Mony, Jun 3, 13 Mmory Wll Disprity twn CPU sp n mmory ss sp improvmnt Mony, Jun 3,

More information

Lecture 11 Waves in Periodic Potentials Today: Questions you should be able to address after today s lecture:

Lecture 11 Waves in Periodic Potentials Today: Questions you should be able to address after today s lecture: Lctur 11 Wvs in Priodic Potntils Tody: 1. Invrs lttic dfinition in 1D.. rphicl rprsnttion of priodic nd -priodic functions using th -xis nd invrs lttic vctors. 3. Sris solutions to th priodic potntil Hmiltonin

More information

Fundamental Algorithms for System Modeling, Analysis, and Optimization

Fundamental Algorithms for System Modeling, Analysis, and Optimization Fundmntl Algorithms for Sstm Modling, Anlsis, nd Optimiztion Edwrd A. L, Jijt Rohowdhur, Snjit A. Sshi UC Brkl EECS 144/244 Fll 2011 Copright 2010-11, E. A. L, J. Rohowdhur, S. A. Sshi, All rights rsrvd

More information

CSI35 Chapter 11 Review

CSI35 Chapter 11 Review 1. Which of th grphs r trs? c f c g f c x y f z p q r 1 1. Which of th grphs r trs? c f c g f c x y f z p q r . Answr th qustions out th following tr 1) Which vrtx is th root of c th tr? ) wht is th hight

More information

10/30/12. Today. CS/ENGRD 2110 Object- Oriented Programming and Data Structures Fall 2012 Doug James. DFS algorithm. Reachability Algorithms

10/30/12. Today. CS/ENGRD 2110 Object- Oriented Programming and Data Structures Fall 2012 Doug James. DFS algorithm. Reachability Algorithms 0/0/ CS/ENGRD 0 Ojt- Orint Prormmin n Dt Strutur Fll 0 Dou Jm Ltur 9: DFS, BFS & Shortt Pth Toy Rhility Dpth-Firt Srh Brth-Firt Srh Shortt Pth Unwiht rph Wiht rph Dijktr lorithm Rhility Alorithm Dpth Firt

More information

The Plan. Honey, I Shrunk the Data. Why Compress. Data Compression Concepts. Braille Example. Braille. x y xˆ

The Plan. Honey, I Shrunk the Data. Why Compress. Data Compression Concepts. Braille Example. Braille. x y xˆ h ln ony, hrunk th t ihr nr omputr in n nginring nivrsity of shington t omprssion onpts ossy t omprssion osslss t omprssion rfix os uffmn os th y 24 2 t omprssion onpts originl omprss o x y xˆ nor or omprss

More information

CS553 Lecture Register Allocation 1

CS553 Lecture Register Allocation 1 Low-Lvl Issus Lst ltur Livnss nlysis Rgistr llotion Toy Mor rgistr llotion Wnsy Common suxprssion limintion or PA2 Logistis PA1 is u PA2 hs n post Mony th 15 th, no lss u to LCPC in Orgon CS553 Ltur Rgistr

More information

Minimum Spanning Trees

Minimum Spanning Trees Mnmum Spnnng Trs Spnnng Tr A tr (.., connctd, cyclc grph) whch contns ll th vrtcs of th grph Mnmum Spnnng Tr Spnnng tr wth th mnmum sum of wghts 1 1 Spnnng forst If grph s not connctd, thn thr s spnnng

More information

Chapter 18. Minimum Spanning Trees Minimum Spanning Trees. a d. a d. a d. f c

Chapter 18. Minimum Spanning Trees Minimum Spanning Trees. a d. a d. a d. f c Chptr 8 Minimum Spnning Trs In this hptr w ovr importnt grph prolm, Minimum Spnning Trs (MST). Th MST o n unirt, wight grph is tr tht spns th grph whil minimizing th totl wight o th gs in th tr. W irst

More information

EE1000 Project 4 Digital Volt Meter

EE1000 Project 4 Digital Volt Meter Ovrviw EE1000 Projt 4 Diitl Volt Mtr In this projt, w mk vi tht n msur volts in th rn o 0 to 4 Volts with on iit o ury. Th input is n nlo volt n th output is sinl 7-smnt iit tht tlls us wht tht input s

More information

Graph Contraction and Connectivity

Graph Contraction and Connectivity Chptr 17 Grph Contrtion n Conntivity So r w hv mostly ovr thniqus or solving prolms on grphs tht wr vlop in th ontxt o squntil lgorithms. Som o thm r sy to prllliz whil othrs r not. For xmpl, w sw tht

More information

More Foundations. Undirected Graphs. Degree. A Theorem. Graphs, Products, & Relations

More Foundations. Undirected Graphs. Degree. A Theorem. Graphs, Products, & Relations Mr Funtins Grphs, Pruts, & Rltins Unirt Grphs An unirt grph is pir f 1. A st f ns 2. A st f gs (whr n g is st f tw ns*) Friy, Sptmr 2, 2011 Ring: Sipsr 0.2 ginning f 0.4; Stughtn 1.1.5 ({,,,,}, {{,}, {,},

More information

, between the vertical lines x a and x b. Given a demand curve, having price as a function of quantity, p f (x) at height k is the curve f ( x,

, between the vertical lines x a and x b. Given a demand curve, having price as a function of quantity, p f (x) at height k is the curve f ( x, Clculus for Businss nd Socil Scincs - Prof D Yun Finl Em Rviw vrsion 5/9/7 Chck wbsit for ny postd typos nd updts Pls rport ny typos This rviw sht contins summris of nw topics only (This rviw sht dos hv

More information

Aquauno Video 6 Plus Page 1

Aquauno Video 6 Plus Page 1 Connt th timr to th tp. Aquuno Vio 6 Plus Pg 1 Usr mnul 3 lik! For Aquuno Vio 6 (p/n): 8456 For Aquuno Vio 6 Plus (p/n): 8413 Opn th timr unit y prssing th two uttons on th sis, n fit 9V lklin ttry. Whn

More information

NP-Completeness. CS3230 (Algorithm) Traveling Salesperson Problem. What s the Big Deal? Given a Problem. What s the Big Deal? What s the Big Deal?

NP-Completeness. CS3230 (Algorithm) Traveling Salesperson Problem. What s the Big Deal? Given a Problem. What s the Big Deal? What s the Big Deal? NP-Compltnss 1. Polynomil tim lgorithm 2. Polynomil tim rution 3.P vs NP 4.NP-ompltnss (som slis y P.T. Um Univrsity o Txs t Dlls r us) Trvling Slsprson Prolm Fin minimum lngth tour tht visits h ity on

More information

5/7/13. Part 10. Graphs. Theorem Theorem Graphs Describing Precedence. Outline. Theorem 10-1: The Handshaking Theorem

5/7/13. Part 10. Graphs. Theorem Theorem Graphs Describing Precedence. Outline. Theorem 10-1: The Handshaking Theorem Thorm 10-1: Th Hnshkin Thorm Lt G=(V,E) n unirt rph. Thn Prt 10. Grphs CS 200 Alorithms n Dt Struturs v V (v) = 2 E How mny s r thr in rph with 10 vrtis h of r six? 10 * 6 /2= 30 1 Thorm 10-2 An unirt

More information

Multi-Section Coupled Line Couplers

Multi-Section Coupled Line Couplers /0/009 MultiSction Coupld Lin Couplrs /8 Multi-Sction Coupld Lin Couplrs W cn dd multipl coupld lins in sris to incrs couplr ndwidth. Figur 7.5 (p. 6) An N-sction coupld lin l W typiclly dsign th couplr

More information

Preview. Graph. Graph. Graph. Graph Representation. Graph Representation 12/3/2018. Graph Graph Representation Graph Search Algorithms

Preview. Graph. Graph. Graph. Graph Representation. Graph Representation 12/3/2018. Graph Graph Representation Graph Search Algorithms /3/0 Prvw Grph Grph Rprsntton Grph Srch Algorthms Brdth Frst Srch Corrctnss of BFS Dpth Frst Srch Mnmum Spnnng Tr Kruskl s lgorthm Grph Drctd grph (or dgrph) G = (V, E) V: St of vrt (nod) E: St of dgs

More information