Outline. Graphs Describing Precedence. Graphs Describing Precedence. Topological SorFng of DAGs. Graphs Describing Precedence 4/25/12. Part 10.
|
|
- Quentin Henry
- 5 years ago
- Views:
Transcription
1 4// Outlin Prt. Grphs CS Algorithms n Dt Struturs Introution Trminology Implmnting Grphs Grph Trvrsls Topologil Sorting Shortst Pths Spnning Trs Minimum Spnning Trs Ciruits Grphs Dsriing Prn Grphs Dsriing Prn Exmpls: prrquisits for st of ourss pnnis twn progrms Eg from to inits shoul om for Btmn imgs r from th ook IntrouFon to ioinformfs lgorithms Grphs Dsriing Prn Wnt n orring of th vrtis of th grph tht rspts th prn rltion Exmpl: An orring of CS ourss Th grph os not ontin yls. Why? Topologil SorFng of DAGs DAG: Dirt Ayli Grph Topologil sort: listing of nos suh tht if (,) is n g, pprs for in th list Is topologil sort uniqu?
2 4// A irt grph without yls f Topologil Sort - Algorithm topsort(in G:Grph)!!n= numr of vrtis in G!!for (stp = through n)!!!slt vrtx v tht hs no sussors!!!list.(first_vill_lo,v)!!!dlt from G vrtx v n its gs!!rturn List! g,g,,,,,f,,g,,,f, Algorithm rlis on th ft tht in DAG thr is lwys vrtx tht hs no sussors Algorithm : Exmpl Algorithm : Exmpl f A B C D E F G H g g f I A, D, E, B, G, C, F, H, I Topologil Sort - Algorithm DFS Exmpl: rviw Moifition of DFS: Trvrs tr using DFS strting from ll nos tht hv no prssor. A no to th list whn ry to ktrk. A B C D E F G H I J K L M N O P
3 4// ItrFv DFS: rviw fs(in v:vrtx)! s stk for kping trk of tiv vrtis! s.push(v)! mrk v s visit! whil(!s.isempty()) {!!if (no unvisit vrtis jnt to th vrtx on top of th stk) {!!!s.pop() \\ktrk!!ls {!!!slt unvisit vrtx u jnt to vrtx on top of th stk!!!s.push(u)!!!mrk u s visit!!}! }! Topologil Sort - Algorithm topsort( in thgrph:grph):list!!s.rtstk()!!for (ll vrtis v in th grph thgrph)!!!if (v hs no prssors)!!!!s.push(v)!!!!mrk v s visit!!whil (!s.isempty())!!!if (ll vrtis jnt to th vrtx on top of th stk hv n visit)!!!!v = s.pop()!!!!llist.(, v)!!!ls!!!!slt n unvisit vrtx u jnt to vrtx on top of th stk!!!!s.push(u)!!!!mrk u s visit!!rturn List! Algorithm : Exmpl Algorithm : Exmpl f g f g g f A B C D E F G I H A, D, G, I, E, B, C, F, H Outlin Introution Trminology Implmnting Grphs Grph Trvrsls Topologil Sorting Shortst Pths Spnning Trs Minimum Spnning Trs Ciruits Shortst Pth Algorithms (Dijkstr s Algorithm) Grph G(V,E) with non-ngtiv wights ( istns ) Comput shortst istns from vrtx s to vry othr vrtx in th grph 3
4 4// Shortst Pth Algorithms (Dijkstr s Algorithm) Shortst Pth Algorithms (Dijkstr s Algorithm) Algorithm Mintin rry (minimum istn stimts) Init: [s]=, [v]= v V-s Priority quu of vrtis not yt visit slt minimum istn vrtx, visit v, upt nighors Shortst Pth Algorithms (Dijkstr s Algorithm): IniFliz / / Shortst Pth Algorithms (Dijkstr s Algorithm): stp / / / / / 4/ Shortst Pth Algorithms (Dijkstr s Algorithm): stp 4 / / / / / 4/ / / / / Shortst Pth Algorithms (Dijkstr s Algorithm): stp 3 4
5 4// / / / / / 4/ / / / / / / / / Shortst Pth Algorithms (Dijkstr s Algorithm): stp 4 / / / / Shortst Pth Algorithms (Dijkstr s Algorithm): Don Minimum istn from to : Minimum istn from to : Minimum istn from to : Minimum istn from to : Exmpl Dijkstr s Algorithm Dijkstr(G: grph with vrtis v v n- n wights w [u][v])!!// omputs shortst istn of vrtx to vry othr vrtx!!rt st vrtxst tht ontins only vrtx!![] =!!for (v = through n-)!!![v] = infinity!!for (stp = through n)!!!fin th smllst [v] suh tht v is not in vrtxst!!! v to vrtxst!!!for (ll vrtis u not in vrtxst)!!!!if ([u] > [v] + w[v][u])!!!!![u] = [v] + w[v][u]! Shortst Pth Algorithms Using Priority Quu (Dijkstr s Algorithm): stp Shortst Pth Algorithms (Dijkstr s Algorithm): stp 4 [,],[,] [,],[,],[4,]
6 4// Shortst Pth Algorithms (Dijkstr s Algorithm): stp 3 Shortst Pth Algorithms (Dijkstr s Algorithm): stp 4 [,],[,] [,] Shortst Pth Algorithms (Dijkstr s Algorithm): Don Dijkstr s Algorithm How to otin th shortst pths? At h vrtx mintin pointr tht tlls you th vrtx from whih you rriv. Outlin Conntnss in Dirt Grphs Introution Trminology Implmnting Grphs Grph Trvrsls Topologil Sorting Shortst Pths Spnning Trs Minimum Spnning Trs Ciruits A irt grph is strongly onnt if thr is pth from to n from to whnvr n r vrtis in th grph. A irt grph is wkly onnt if thr is pth twn vry two vrtis in th unrlying unirt grph
7 4// Exmpl Trs s Grphs Tr: n unirt onnt grph tht hs no yls. A B C D E F G H Grph A Grph B I J K L 3 M N O P Root Trs Exmpl: Buil root trs. A root tr is tr in whih on vrtx hs n signt s th root n vry g is irt wy from th root A B C D E F G H I J K L M N O P Trs s Grphs Tr: n unirt onnt grph tht hs no simpl iruits. Thorm - An unirt grph is tr iff thr is uniqu simpl pth (no rpt vrtis) twn ny two vrtis.
8 4// Whn is grph Tr? Cn xpliitly hk tht th grph is onnt n hs no yls. (How?) W n n ltrntiv hrtriztion Whn is grph Tr?: Thorm - A onnt unirt grph with n vrtis must hv t lst n- gs (PROOF: y inution on th numr of vrtis) Whn is grph Tr?: Thorm - 3 A onnt unirt grph tht hs n vrtis n xtly n- gs nnot ontin yl (PROOF: y ontrition with prvious sttmnt) Whn is grph Tr? : Thorm - 4 A onnt unirt grph tht hs n vrtis n mor thn n- gs must ontin yl. Whn is grph Tr? Conlusion: A onnt grph with n vrtis n n- gs is tr. In orr to hk if grph is tr w n to hk tht it is onnt n ount th numr of gs n vrtis. Spnning Trs Spnning tr: A sugrph of onnt unirt grph G tht ontins ll of G s vrtis n nough of its gs to form tr. How to gt spnning tr: Rmov gs until you gt tr. A gs until you hv spnning tr
9 4// Spnning Trs - DFS lgorithm Spnning Tr Dpth First Srh Exmpl fstr(in v:vrtx)!!mrk v s visit!!for (h unvisit vrtx u jnt to v)!!!mrk th g from u to v!!!fstr(u)! A B C D E F G H I J K L M N O P Exmpl Outlin Suppos tht n irlin must ru its flight shul to sv mony. If its originl routs r s illustrt hr, whih flights n isontinu to rtin srvi twn ll pirs of itis (whr it my nssry to omin flights to fly from on ity to nothr?) Chigo Bngor Shl Boston Dtroit SF NYC LA Sn Digo Dnvr Dlls St. Louis Atlnt Wshington D.C. Introution Trminology Implmnting Grphs Grph Trvrsls Topologil Sorting Shortst Pths Spnning Trs Minimum Spnning Trs Ciruits Minimum Spnning Tr Prim s Algorithm Minimum spnning tr Spnning tr minimizing th sum of g wights Exmpl: Connting h hous in th nighorhoo to l Grph whr h hous is vrtx. N th grph to onnt, n minimiz th ost of lying th ls. I: inrmntlly uil spnning tr y ing th lst-ost g to th tr Wight grph Fin st of gs Touhs ll vrtis Miniml wight Not ll th gs my us
10 4// Prim s Algorithm: Exmpl Prim s Algorithm 4 h g i 4 6 f prims(in: G=(V,E):Grph)!!//V T urrnt vrtis in spnning tr!!//e T gs longing to th spnning tr!!v T = {w} // w is n ritrrily hosn vrtx!!e T = ϕ //spnning tr ontins no vrtis initilly!!for i = to V - o!!!fin minimum-wight g =(u,v) mong gs tht!onnts vrtx in V T with vrtx in V V T!!! v to V T!!! to E T!!rturn E T! {(,),(,), (,i), (,), (,f), (f,g), (g,h), (h,) } ImplmnFng Prim s Algorithm Eh no not in th tr hs n tthing ost th wight of th smllst g tht onnts it to th forming tr (infinity if no suh g xists). At h itrtion, w rtriv th no with th smllst tthing ost n upt th tthing ost of its nighors. Cn us priority quu! (n to mtho for upting prioritis).
Lecture Outline. Memory Hierarchy Management. Register Allocation. Register Allocation. Lecture 19. Cache Management. The Memory Hierarchy
Ltur Outlin Mmory Hirrhy Mngmnt Rgistr Allotion Ltur 19 Rgistr Allotion Rgistr intrrn grph Grph oloring huristis Spilling Ch Mngmnt Pro. Boik CS 164 Ltur 17 1 Pro. Boik CS 164 Ltur 17 2 Th Mmory Hirrhy
More informationHistory Rgistr Allotion Exmpl As ol s intrmit o Consir this progrm with six vrils: := + := + := - 1 Us in th originl FORTRAN ompilr (1950 s) Vry ru lg
Th Mmory Hirrhy Avn Compilrs CMPSCI 710 Spring 2003 Highr = smllr, str, losr to CPU A rl sktop mhin (min) Rgistr Allotion Emry Brgr rgistrs 8 intgr, 8 loting-point; 1-yl ltny L1 h 8K t & instrutions; 2-yl
More informationReachability. Directed DFS. Strong Connectivity Algorithm. Strong Connectivity. DFS tree rooted at v: vertices reachable from v via directed paths
irt Grphs OR SFO FW LX JFK MI OS irph is rph whos s r ll irt Short or irt rph pplitions on-wy strts lihts tsk shulin irphs ( 12.) irt Grphs 1 irt Grphs 2 irph Proprtis rph G=(V,) suh tht h os in on irtion:
More informationLecture Outline. Memory Hierarchy Management. Register Allocation. Register Allocation. Lecture 38. Cache Management. Managing the Memory Hierarchy
Ltur Outlin Mmory Hirrhy Mngmnt Rgistr Allotion Ltu8 (rom nots y G. Nul n R. Boik) Rgistr Allotion Rgistr intrrn grph Grph oloring huristis Spilling Ch Mngmnt 4/27/08 Pro. Hilingr CS164 Ltu8 1 4/27/08
More informationGlobal Register Allocation
Ltur Outlin Glol Rgistr Allotion Mmory Hirrhy Mngmnt Rgistr Allotion vi Grph Coloring Rgistr intrrn grph Grph oloring huristis Spilling Ch Mngmnt 2 Th Mmory Hirrhy Rgistrs 1 yl 256-8000 yts Ch 3 yls 256k-16M
More informationV = set of vertices (vertex / node) E = set of edges (v, w) (v, w in V)
Definitions G = (V, E) V = set of verties (vertex / noe) E = set of eges (v, w) (v, w in V) (v, w) orere => irete grph (igrph) (v, w) non-orere => unirete grph igrph: w is jent to v if there is n ege from
More informationGreedy Algorithm. Algorithm Fall Semester
Greey Algorithm Algorithm 0 Fll Semester Optimiztion prolems An optimiztion prolem is one in whih you wnt to fin, not just solution, ut the est solution A greey lgorithm sometimes works well for optimiztion
More informationReview: Binary Trees. CSCI 262 Data Structures. Search Trees. In Order Traversal. Binary Search Trees 4/10/2018. Review: Binary Tree Implementation
Rviw: Binry Trs CSCI 262 Dt Struturs 21 Binry Srh Trs A inry tr is in rursivly: = or A inry tr is (mpty) root no with lt hil n riht hil, h o whih is inry tr. Rviw: Binry Tr Implmnttion Just ollow th rursiv
More informationChapter 9. Greedy Technique. Copyright 2007 Pearson Addison-Wesley. All rights reserved.
Chpter 9 Greey Tehnique Copyright 2007 Person Aison-Wesley. All rights reserve. Greey Tehnique Construts solution to n optimiztion prolem piee y piee through sequene of hoies tht re: fesile lolly optiml
More informationQuadrilateral Decomposition by Two-Ear Property Resulting in CAD Segmentation
Quriltrl Domposition y wo-er Proprty Rsulting in CAD Sgmnttion Mhrvo Rnrinrivony Astrt W minly im t splitting simply onnt polygon into st o onvx quriltrls without insrting nw ounry nos. Our pproh is s
More informationGraph Traversals. CS200 - Graphs 1
Graph Traversals CS200 - Graphs 1 Tree traversal reminder A Pre order A B D G H C E F I B C In order G D H B A E C F I D E F Post order G H D B E I F C A G H I Level order A B C D E F G H I Connected Components
More informationFinding a Funicular Curve Through Two Points
This is th glss pyrmi t th Louvr Musum in Pris, sign y rhitt I.M. Pi. It is support from nth y stl ls. In signing strutur suh s this, it is oftn most usful to slt l of rtin siz n tnsil strngth, n thn to
More informationTiling the plane with equilateral convex pentagons
Prol Volum 52, Issu 3 (2016) Tiling th pln with quiltrl onvx pntgons Mri Fishr 1 Mthmtiins n non-mthmtiins hv n onrn with fining pntgonl tilings for lmost 100 yrs, yt tiling th pln with onvx pntgons rmins
More informationPremaster Course Algorithms 1 Chapter 6: Shortest Paths. Christian Scheideler SS 2018
Premster Course Algorithms Chpter 6: Shortest Pths Christin Scheieler SS 8 Bsic Grph Algorithms Overview: Shortest pths in DAGs Dijkstr s lgorithm Bellmn-For lgorithm Johnson s metho SS 8 Chpter 6 Shortest
More informationLesson 4.4. Euler Circuits and Paths. Explore This
Lesson 4.4 Euler Ciruits nd Pths Now tht you re fmilir with some of the onepts of grphs nd the wy grphs onvey onnetions nd reltionships, it s time to egin exploring how they n e used to model mny different
More informationOutline. CS38 Introduction to Algorithms. Graphs. Graphs. Graphs. Graph traversals
Outline CS38 Introution to Algorithms Leture 2 April 3, 2014 grph trversls (BFS, DFS) onnetivity topologil sort strongly onnete omponents heps n hepsort greey lgorithms April 3, 2014 CS38 Leture 2 2 Grphs
More informationLecture 13: Graphs I: Breadth First Search
Leture 13 Grphs I: BFS 6.006 Fll 2011 Leture 13: Grphs I: Bredth First Serh Leture Overview Applitions of Grph Serh Grph Representtions Bredth-First Serh Rell: Grph G = (V, E) V = set of verties (ritrry
More informationCOMP108 Algorithmic Foundations
Grph Theory Prudene Wong http://www.s.liv..uk/~pwong/tehing/omp108/201617 How to Mesure 4L? 3L 5L 3L ontiner & 5L ontiner (without mrk) infinite supply of wter You n pour wter from one ontiner to nother
More informationCS 331: Artificial Intelligence Bayesian Networks (Inference) Inference
S 331: rtificil Intllignc ysin Ntworks Infrnc 1 Infrnc Suppos you r givn ysin ntwork with th grph structur n th prmtrs ll figur out Now you woul lik to us it to o infrnc You n infrnc to mk prictions or
More informationParadigm 5. Data Structure. Suffix trees. What is a suffix tree? Suffix tree. Simple applications. Simple applications. Algorithms
Prdigm. Dt Struture Known exmples: link tble, hep, Our leture: suffix tree Will involve mortize method tht will be stressed shortly in this ourse Suffix trees Wht is suffix tree? Simple pplitions History
More information10.2 Graph Terminology and Special Types of Graphs
10.2 Grph Terminology n Speil Types of Grphs Definition 1. Two verties u n v in n unirete grph G re lle jent (or neighors) in G iff u n v re enpoints of n ege e of G. Suh n ege e is lle inient with the
More informationGraph theory Route problems
Bhelors thesis Grph theory Route prolems Author: Aolphe Nikwigize Dte: 986 - -5 Sujet: Mthemtis Level: First level (Bhelor) Course oe: MAE Astrt In this thesis we will review some route prolems whih re
More informationCS200: Graphs. Rosen Ch , 9.6, Walls and Mirrors Ch. 14
CS200: Graphs Rosen Ch. 9.1-9.4, 9.6, 10.4-10.5 Walls and Mirrors Ch. 14 Trees as Graphs Tree: an undirected connected graph that has no cycles. A B C D E F G H I J K L M N O P Rooted Trees A rooted tree
More informationIf you are at the university, either physically or via the VPN, you can download the chapters of this book as PDFs.
Lecture 5 Wlks, Trils, Pths nd Connectedness Reding: Some of the mteril in this lecture comes from Section 1.2 of Dieter Jungnickel (2008), Grphs, Networks nd Algorithms, 3rd edition, which is ville online
More informationMITSUBISHI ELECTRIC RESEARCH LABORATORIES Cambridge, Massachusetts. Introduction to Matroids and Applications. Srikumar Ramalingam
Cmrige, Msshusetts Introution to Mtrois n Applitions Srikumr Rmlingm MERL mm//yy Liner Alger (,0,0) (0,,0) Liner inepenene in vetors: v, v2,..., For ll non-trivil we hve s v s v n s, s2,..., s n 2v2...
More informationDistance vector protocol
istne vetor protool Irene Finohi finohi@i.unirom.it Routing Routing protool Gol: etermine goo pth (sequene of routers) thru network from soure to Grph strtion for routing lgorithms: grph noes re routers
More informationPresentation for use with the textbook, Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, Directed Graphs BOS SFO
Prsntation for us with th txtbook, Algorithm Dsign and Applications, by M. T. Goodrich and R. Tamassia, Wily, 2015 Dirctd Graphs BOS ORD JFK SFO LAX DFW MIA 2015 Goodrich and Tamassia Dirctd Graphs 1 Digraphs
More informationCompiling: Examples and Sample Problems
REs for Kywors Compiling: Exmpls n mpl Prolms IC312 Mchin-Lvl n ystms Progrmming Hnri Csnov (hnric@hwii.u) It is sy to fin RE tht scris ll kywors Ky = if ls for whil int.. Ths cn split in groups if n Kywor
More informationCMPUT101 Introduction to Computing - Summer 2002
CMPUT Introdution to Computing - Summer 22 %XLOGLQJ&RPSXWHU&LUFXLWV Chpter 4.4 3XUSRVH We hve looked t so fr how to uild logi gtes from trnsistors. Next we will look t how to uild iruits from logi gtes,
More information12/9/14. CS151 Fall 20124Lecture (almost there) 12/6. Graphs. Seven Bridges of Königsberg. Leonard Euler
CS5 Fll 04Leture (lmost there) /6 Seven Bridges of Königserg Grphs Prof. Tny Berger-Wolf Leonrd Euler 707-783 Is it possile to wlk with route tht rosses eh ridge e Seven Bridges of Königserg Forget unimportnt
More informationCSE P 501 Compilers. Register Allocation Hal Perkins Spring UW CSE P 501 Spring 2018 P-1
CSE P 501 Compilrs Rgistr Allotion Hl Prkins Spring 2018 UW CSE P 501 Spring 2018 P-1 Agn Rgistr llotion onstrints Lol mthos Fstr ompil, slowr o, ut goo nough or lots o things (JITs, ) Glol llotion rgistr
More informationBelow, are instructions about how to set each goal and report achievements in Your Club, Service, and Foundation Giving.
Rotry Clu Cntrl is n onlin tool to hlp lus st nd trk lu gols nd hivmnts. This rfrn guid outlins th stps you nd to tk to st nd dit gols s wll s rport hivmnts in Rotry Clu Cntrl. If ny dt is displyd inorrtly,
More informationGraph Theory & Applications. Boundaries Using Graphs. Graph Search. Find the route that minimizes. cost
Graph Thory & Appliations Bounaris Using Graphs 3 4 3 4 5 Fin th rout that minimizs osts Fin th ritial path in a projt Fin th optimal borr aroun a rgion Fin loop an no quations or analog iruit analysis
More informationCHAPTER 14 GRAPH ALGORITHMS ORD SFO LAX DFW
SO OR HPTR 1 GRPH LGORITHMS LX W KNOWLGMNT: THS SLIS R PT ROM SLIS PROVI WITH T STRUTURS N LGORITHMS IN JV, GOORIH, TMSSI N GOLWSSR (WILY 16) 6 OS MINIMUM SPNNING TRS SO 16 PV OR 1 1 16 61 JK 1 1 11 WI
More informationLecture 39: Register Allocation. The Memory Hierarchy. The Register Allocation Problem. Managing the Memory Hierarchy
Ltur 39: Rgistr Alloation [Aapt rom nots y R. Boik an G. Nula] Topis: Mmory Hirarhy Managmnt Rgistr Alloation: Rgistr intrrn graph Graph oloring huristis Spilling Cah Managmnt Th Mmory Hirarhy Computrs
More informationLecture 8: Graph-theoretic problems (again)
COMP36111: Advned Algorithms I Leture 8: Grph-theoreti prolems (gin) In Prtt-Hrtmnn Room KB2.38: emil: iprtt@s.mn..uk 2017 18 Reding for this leture: Sipser: Chpter 7. A grph is pir G = (V, E), where V
More informationMa/CS 6b Class 1: Graph Recap
M/CS 6 Clss 1: Grph Recp By Adm Sheffer Course Detils Adm Sheffer. Office hour: Tuesdys 4pm. dmsh@cltech.edu TA: Victor Kstkin. Office hour: Tuesdys 7pm. 1:00 Mondy, Wednesdy, nd Fridy. http://www.mth.cltech.edu/~2014-15/2term/m006/
More informationCS201 Discussion 10 DRAWTREE + TRIES
CS201 Discussion 10 DRAWTREE + TRIES DrwTree First instinct: recursion As very generic structure, we could tckle this problem s follows: drw(): Find the root drw(root) drw(root): Write the line for the
More informationMa/CS 6b Class 1: Graph Recap
M/CS 6 Clss 1: Grph Recp By Adm Sheffer Course Detils Instructor: Adm Sheffer. TA: Cosmin Pohot. 1pm Mondys, Wednesdys, nd Fridys. http://mth.cltech.edu/~2015-16/2term/m006/ Min ook: Introduction to Grph
More informationLecture 12 : Topological Spaces
Leture 12 : Topologil Spes 1 Topologil Spes Topology generlizes notion of distne nd loseness et. Definition 1.1. A topology on set X is olletion T of susets of X hving the following properties. 1. nd X
More informationIntroduction. Example
OMS0 Introution isjoint sets n minimum spnning trees In this leture we will strt by isussing t struture use for mintining isjoint subsets of some bigger set. This hs number of pplitions, inluing to mintining
More informationCS 241 Week 4 Tutorial Solutions
CS 4 Week 4 Tutoril Solutions Writing n Assemler, Prt & Regulr Lnguges Prt Winter 8 Assemling instrutions utomtilly. slt $d, $s, $t. Solution: $d, $s, nd $t ll fit in -it signed integers sine they re 5-it
More informationITEC2620 Introduction to Data Structures
ITEC0 Introduction to Dt Structures Lecture 7 Queues, Priority Queues Queues I A queue is First-In, First-Out = FIFO uffer e.g. line-ups People enter from the ck of the line People re served (exit) from
More informationEE 231 Fall EE 231 Homework 10 Due November 5, 2010
EE 23 Fall 2 EE 23 Homwork Du Novmbr 5, 2. Dsign a synhronous squntial iruit whih gnrats th following squn. (Th squn should rpat itslf.) (a) Draw a stat transition diagram for th iruit. This is a systm
More informationCS311H: Discrete Mathematics. Graph Theory IV. A Non-planar Graph. Regions of a Planar Graph. Euler s Formula. Instructor: Işıl Dillig
CS311H: Discrete Mthemtics Grph Theory IV Instructor: Işıl Dillig Instructor: Işıl Dillig, CS311H: Discrete Mthemtics Grph Theory IV 1/25 A Non-plnr Grph Regions of Plnr Grph The plnr representtion of
More informationSoftware Pipelining Can we decrease the latency? Goal of SP Lecture. Seth Copen Goldstein Software Pipelining
5-4 Ltur 5-745 Sotwr Piplinin Copyrit St Copn Goltin -8 Sotwr Piplinin Sotwr piplinin i n IS tniqu tt rorr t intrution in loop. Poily movin intrution rom on itrtion to t prviou or t nxt itrtion. Vry lr
More informationWhat are suffix trees?
Suffix Trees 1 Wht re suffix trees? Allow lgorithm designers to store very lrge mount of informtion out strings while still keeping within liner spce Allow users to serch for new strings in the originl
More informationAdjacency. Adjacency Two vertices u and v are adjacent if there is an edge connecting them. This is sometimes written as u v.
Terminology Adjeny Adjeny Two verties u nd v re djent if there is n edge onneting them. This is sometimes written s u v. v v is djent to nd ut not to. 2 / 27 Neighourhood Neighourhood The open neighourhood
More informationAnswer Key Lesson 6: Workshop: Angles and Lines
nswer Key esson 6: tudent Guide ngles nd ines Questions 1 3 (G p. 406) 1. 120 ; 360 2. hey re the sme. 3. 360 Here re four different ptterns tht re used to mke quilts. Work with your group. se your Power
More informationSection 2.3 Functions. Definition: Let A and B be sets. A function (mapping, map) f from A to B, denoted f :A B, is a subset of A B such that
Setion 2.3 Funtions Definition: Let n e sets. funtion (mpping, mp) f from to, enote f :, is suset of suh tht x[x y[y < x, y > f ]] n [< x, y 1 > f < x, y 2 > f ] y 1 = y 2 Note: f ssoites with eh x in
More informationNetwork Interconnection: Bridging CS 571 Fall Kenneth L. Calvert All rights reserved
Network Interconnection: Bridging CS 57 Fll 6 6 Kenneth L. Clvert All rights reserved The Prolem We know how to uild (rodcst) LANs Wnt to connect severl LANs together to overcome scling limits Recll: speed
More informationCS 551 Computer Graphics. Hidden Surface Elimination. Z-Buffering. Basic idea: Hidden Surface Removal
CS 55 Computer Grphis Hidden Surfe Removl Hidden Surfe Elimintion Ojet preision lgorithms: determine whih ojets re in front of others Uses the Pinter s lgorithm drw visile surfes from k (frthest) to front
More informationMinimal Memory Abstractions
Miniml Memory Astrtions (As implemented for BioWre Corp ) Nthn Sturtevnt University of Alert GAMES Group Ferury, 7 Tlk Overview Prt I: Building Astrtions Minimizing memory requirements Performnes mesures
More informationCS553 Lecture Introduction to Data-flow Analysis 1
! Ide Introdution to Dt-flow nlysis!lst Time! Implementing Mrk nd Sweep GC!Tody! Control flow grphs! Liveness nlysis! Register llotion CS553 Leture Introdution to Dt-flow Anlysis 1 Dt-flow Anlysis! Dt-flow
More informationCOMMON FRACTIONS. or a / b = a b. , a is called the numerator, and b is called the denominator.
COMMON FRACTIONS BASIC DEFINITIONS * A frtion is n inite ivision. or / * In the frtion is lle the numertor n is lle the enomintor. * The whole is seprte into "" equl prts n we re onsiering "" of those
More informationTries. Yufei Tao KAIST. April 9, Y. Tao, April 9, 2013 Tries
Tries Yufei To KAIST April 9, 2013 Y. To, April 9, 2013 Tries In this lecture, we will discuss the following exct mtching prolem on strings. Prolem Let S e set of strings, ech of which hs unique integer
More informationPartitioning a Polygon into Two Mirror Congruent Pieces
rtitioning olygon into Two Mirror Congrunt is Dni El-Khhn Thoms Fvns John Iono 1 Introution olygon omposition prolms r wll stui in th litrtur [6], yt mny vrints o ths prolms rmin opn. In this ppr, w r
More informationHomework. Context Free Languages III. Languages. Plan for today. Context Free Languages. CFLs and Regular Languages. Homework #5 (due 10/22)
Homework Context Free Lnguges III Prse Trees nd Homework #5 (due 10/22) From textbook 6.4,b 6.5b 6.9b,c 6.13 6.22 Pln for tody Context Free Lnguges Next clss of lnguges in our quest! Lnguges Recll. Wht
More informationReading. K-D Trees and Quad Trees. Geometric Data Structures. k-d Trees. Range Queries. Nearest Neighbor Search. Chapter 12.6
Rn Cptr 12.6 K-D Trs n Qu Trs CSE 326 Dt Struturs Ltur 9 2/2/05 K-D Trs n Qu Trs - Ltur 9 2 Gomtr Dt Struturs Ornzton o ponts, lns, plns, to support str prossn Appltons Astropsl smulton voluton o ls Grps
More informationCalculus Differentiation
//007 Clulus Differentition Jeffrey Seguritn person in rowot miles from the nerest point on strit shoreline wishes to reh house 6 miles frther down the shore. The person n row t rte of mi/hr nd wlk t rte
More informationObjectives. Two Ways to Implement Lists. Lists. Chapter 24 Implementing Lists, Stacks, Queues, and Priority Queues
Chaptr 24 Implmnting Lists, Stacks, Quus, and Priority Quus CS2: Data Structurs and Algorithms Colorado Stat Univrsity Original slids by Danil Liang Modifid slids by Chris Wilcox Objctivs q To dsign common
More informationSection 10.4 Hyperbolas
66 Section 10.4 Hyperbols Objective : Definition of hyperbol & hyperbols centered t (0, 0). The third type of conic we will study is the hyperbol. It is defined in the sme mnner tht we defined the prbol
More informationMATH 25 CLASS 5 NOTES, SEP
MATH 25 CLASS 5 NOTES, SEP 30 2011 Contents 1. A brief diversion: reltively prime numbers 1 2. Lest common multiples 3 3. Finding ll solutions to x + by = c 4 Quick links to definitions/theorems Euclid
More informationInternet Routing. Reminder: Routing. CPSC Network Programming
PS 360 - Network Progrmming Internet Routing Mihele Weigle eprtment of omputer Siene lemson University mweigle@s.lemson.eu pril, 00 http://www.s.lemson.eu/~mweigle/ourses/ps360 Reminer: Routing Internet
More informationWORKSHOP 2 Solid Shell Composites Modeling
WORKSHOP 2 Soli Shll Composits Moling WS2-1 WS2-2 Workshop Ojtivs Bom fmilir with stting up soli omposit shll mol Softwr Vrsion Ptrn 2011 MD Nstrn 2011.1 Fils Rquir soli_shll. WS2-3 Prolm Dsription Simult
More informationContainers: Queue and List
Continers: Queue n List Queue A ontiner in whih insertion is one t one en (the til) n eletion is one t the other en (the he). Also lle FIFO (First-In, First-Out) Jori Cortell n Jori Petit Deprtment of
More informationInternet Routing. IP Packet Format. IP Fragmentation & Reassembly. Principles of Internet Routing. Computer Networks 9/29/2014.
omputer Networks 9/29/2014 IP Pket Formt Internet Routing Ki Shen IP protool version numer heder length (words) for qulity of servie mx numer remining hops (deremented t eh router) upper lyer protool to
More information10.5 Graphing Quadratic Functions
0.5 Grphing Qudrtic Functions Now tht we cn solve qudrtic equtions, we wnt to lern how to grph the function ssocited with the qudrtic eqution. We cll this the qudrtic function. Grphs of Qudrtic Functions
More informationCS 340, Fall 2016 Sep 29th Exam 1 Note: in all questions, the special symbol ɛ (epsilon) is used to indicate the empty string.
CS 340, Fll 2016 Sep 29th Exm 1 Nme: Note: in ll questions, the speil symol ɛ (epsilon) is used to indite the empty string. Question 1. [10 points] Speify regulr expression tht genertes the lnguge over
More informationRay surface intersections
Ry surfce intersections Some primitives Finite primitives: polygons spheres, cylinders, cones prts of generl qudrics Infinite primitives: plnes infinite cylinders nd cones generl qudrics A finite primitive
More informationThe Network Layer: Routing Algorithms. The Network Layer: Routing & Addressing Outline
PS 6 Ntwork Programming Th Ntwork Layr: Routing lgorithms Michl Wigl partmnt of omputr Scinc lmson Univrsity mwigl@cs.clmson.du http://www.cs.clmson.du/~mwigl/courss/cpsc6 Th Ntwork Layr: Routing & ddrssing
More informationTight triangulations: a link between combinatorics and topology
Tight tringultions: link between ombintoris nd topology Jonthn Spreer Melbourne, August 15, 2016 Topologil mnifolds (Geometri) Topology is study of mnifolds (surfes) up to ontinuous deformtion Complited
More informationMath 227 Problem Set V Solutions. f ds =
Mth 7 Problem Set V Solutions If is urve with prmetriztion r(t), t b, then we define the line integrl f ds b f ( r(t) ) dr dt (t) dt. Evlute the line integrl f(x,y,z)ds for () f(x,y,z) xosz, the urve with
More informationBayesian Networks: Directed Markov Properties (Cont d) and Markov Equivalent DAGs
Byesin Networks: Direte Mrkov Properties (Cont ) n Mrkov Equivlent DAGs Huizhen Yu jney.yu@s.helsinki.fi Dept. Computer Siene, Univ. of Helsinki Proilisti Moels, Spring, 2010 Huizhen Yu (U.H.) Byesin Networks:
More informationCPSC 826 Internetworking. The Network Layer: Routing & Addressing Outline. The Network Layer: Routing Algorithms. Routing Algorithms Taxonomy
PS Intrntworking Th Ntwork Layr: Routing & ddrssing Outlin Th Ntwork Layr: Routing lgorithms Michl Wigl partmnt of omputr Scinc lmson Univrsity mwigl@cs.clmson.du Novmbr, Ntwork layr functions Routr architctur
More informationMTH 146 Conics Supplement
105- Review of Conics MTH 146 Conics Supplement In this section we review conics If ou ne more detils thn re present in the notes, r through section 105 of the ook Definition: A prol is the set of points
More informationCOMP 423 lecture 11 Jan. 28, 2008
COMP 423 lecture 11 Jn. 28, 2008 Up to now, we hve looked t how some symols in n lphet occur more frequently thn others nd how we cn sve its y using code such tht the codewords for more frequently occuring
More informationChapter 4 Fuzzy Graph and Relation
Chpter 4 Fuzzy Grph nd Reltion Grph nd Fuzzy Grph! Grph n G = (V, E) n V : Set of verties(node or element) n E : Set of edges An edge is pir (x, y) of verties in V.! Fuzzy Grph ~ n ( ~ G = V, E) n V :
More informationCompression Outline :Algorithms in the Real World. Lempel-Ziv Algorithms. LZ77: Sliding Window Lempel-Ziv
Compression Outline 15-853:Algorithms in the Rel World Dt Compression III Introduction: Lossy vs. Lossless, Benchmrks, Informtion Theory: Entropy, etc. Proility Coding: Huffmn + Arithmetic Coding Applictions
More informationSolving Problems by Searching. CS 486/686: Introduction to Artificial Intelligence Winter 2016
Solving Prolems y Serching CS 486/686: Introduction to Artificil Intelligence Winter 2016 1 Introduction Serch ws one of the first topics studied in AI - Newell nd Simon (1961) Generl Prolem Solver Centrl
More informationCS321 Languages and Compiler Design I. Winter 2012 Lecture 5
CS321 Lnguges nd Compiler Design I Winter 2012 Lecture 5 1 FINITE AUTOMATA A non-deterministic finite utomton (NFA) consists of: An input lphet Σ, e.g. Σ =,. A set of sttes S, e.g. S = {1, 3, 5, 7, 11,
More informationDefinition of Regular Expression
Definition of Regulr Expression After the definition of the string nd lnguges, we re redy to descrie regulr expressions, the nottion we shll use to define the clss of lnguges known s regulr sets. Recll
More informationCSCI 104. Rafael Ferreira da Silva. Slides adapted from: Mark Redekopp and David Kempe
CSCI 0 fel Ferreir d Silv rfsilv@isi.edu Slides dpted from: Mrk edekopp nd Dvid Kempe LOG STUCTUED MEGE TEES Series Summtion eview Let n = + + + + k $ = #%& #. Wht is n? n = k+ - Wht is log () + log ()
More information4/29/18 FIBONACCI NUMBERS GOLDEN RATIO, RECURRENCES. Fibonacci function. Fibonacci (Leonardo Pisano) ? Statue in Pisa Italy
/9/8 Fioncci (Leonrdo Pisno) -? Sttue in Pis Itly FIBONACCI NUERS GOLDEN RATIO, RECURRENCES Lecture CS Spring 8 Fioncci function fi() fi() fi(n) fi(n-) + fi(n-) for n,,,,,, 8,,, In his ook in titled Lier
More informationGreedy Algorithms. Interval Scheduling. Greedy Algorithm. Optimality. Greedy Algorithm (cntd) Greed is good. Greed is right. Greed works.
Algorithm Grdy Algorithm 5- Grdy Algorithm Grd i good. Grd i right. Grd work. Wall Strt Data Structur and Algorithm Andri Bulatov Algorithm Grdy Algorithm 5- Algorithm Grdy Algorithm 5- Intrval Schduling
More information1⅝" - 3¾" (40-95mm) FIXTURE BASE. 3/4" (19mm) 4" - 6¾" ( mm) ALLEN KEY (INCLUDED)
PG: 1 O 7 IMPORTNT - R RULLY OR INSTLLING IXTUR. RTIN THS INSTRUTIONS OR UTUR RRN. THIS PROUT MUST INSTLL IN ORN WITH TH NTIONL LTRIL O N LL PPLIL LOL OS, Y PRSON MILIR WITH TH ONSTRUTION N OPRTION O TH
More informationLexical Analysis: Constructing a Scanner from Regular Expressions
Lexicl Anlysis: Constructing Scnner from Regulr Expressions Gol Show how to construct FA to recognize ny RE This Lecture Convert RE to n nondeterministic finite utomton (NFA) Use Thompson s construction
More informationRational Numbers---Adding Fractions With Like Denominators.
Rtionl Numbers---Adding Frctions With Like Denomintors. A. In Words: To dd frctions with like denomintors, dd the numertors nd write the sum over the sme denomintor. B. In Symbols: For frctions c nd b
More informationCONVEX POLYGONS FOR APERIODIC TILING
Rsrh n ommunitions in Mthmtis n Mthmtil Sins Vol. 8, Issu 1, 2017, Pgs 69-79 ISSN 2319-6939 Pulish Onlin on Sptmr 7, 2017 2017 Jyoti Ami Prss http://jyotimiprss.org ONVX POLYGONS FOR APRIOI TILING TRUHISA
More information1 Quad-Edge Construction Operators
CS48: Computer Grphics Hndout # Geometric Modeling Originl Hndout #5 Stnford University Tuesdy, 8 December 99 Originl Lecture #5: 9 November 99 Topics: Mnipultions with Qud-Edge Dt Structures Scribe: Mike
More informationSuffix trees, suffix arrays, BWT
ALGORITHMES POUR LA BIO-INFORMATIQUE ET LA VISUALISATION COURS 3 Rluc Uricru Suffix trees, suffix rrys, BWT Bsed on: Suffix trees nd suffix rrys presenttion y Him Kpln Suffix trees course y Pco Gomez Liner-Time
More informationDynamic Programming. Andreas Klappenecker. [partially based on slides by Prof. Welch] Monday, September 24, 2012
Dynmic Progrmming Andres Klppenecker [prtilly bsed on slides by Prof. Welch] 1 Dynmic Progrmming Optiml substructure An optiml solution to the problem contins within it optiml solutions to subproblems.
More informationThree planes in networks
Three plnes in networks Prof. Mlthi eerrghvn Ele. & Comp. Engg. Dept/CATT Polytehni University mv@poly.eu M. eerrghvn 1 Polytehni University User plne, ontrol plne, n mngement plne Mngement plne: onsists
More informationToday. Search Problems. Uninformed Search Methods. Depth-First Search Breadth-First Search Uniform-Cost Search
Uninformed Serch [These slides were creted by Dn Klein nd Pieter Abbeel for CS188 Intro to AI t UC Berkeley. All CS188 mterils re vilble t http://i.berkeley.edu.] Tody Serch Problems Uninformed Serch Methods
More informationUnit 5 Vocabulary. A function is a special relationship where each input has a single output.
MODULE 3 Terms Definition Picture/Exmple/Nottion 1 Function Nottion Function nottion is n efficient nd effective wy to write functions of ll types. This nottion llows you to identify the input vlue with
More informationF B DETAIL B 1 : 1 DETAIL A 1 : KVu CHILAMA. IKos MOUNTING PARTS SEVERN GLOCON-ND9000 LIITOSOSAT. Metso Automation Oy MUUT ISSUE
3 6 9 7 7 9 6 3 3 3 7 9 TIL : TIL : M MUUT n*m N:O WN. T PPR. Metso utomation Oy MOUNTING PRTS SVRN GLOON-N9 LIITOSOST T HLSINKI INLN -- WN NT. OL MIROILM. MUUTOS HILM TRK. HK. UUSI NW IKos 76 PPR. KVu
More informationFinite Automata. Lecture 4 Sections Robb T. Koether. Hampden-Sydney College. Wed, Jan 21, 2015
Finite Automt Lecture 4 Sections 3.6-3.7 Ro T. Koether Hmpden-Sydney College Wed, Jn 21, 2015 Ro T. Koether (Hmpden-Sydney College) Finite Automt Wed, Jn 21, 2015 1 / 23 1 Nondeterministic Finite Automt
More information3 4. Answers may vary. Sample: Reteaching Vertical s are.
Chpter 7 Answers Alterntive Activities 7-2 1 2. Check students work. 3. The imge hs length tht is 2 3 tht of the originl segment nd is prllel to the originl segment. 4. The segments pss through the endpoints
More information1.5 Extrema and the Mean Value Theorem
.5 Extrem nd the Men Vlue Theorem.5. Mximum nd Minimum Vlues Definition.5. (Glol Mximum). Let f : D! R e function with domin D. Then f hs n glol mximum vlue t point c, iff(c) f(x) for ll x D. The vlue
More informationTable-driven look-ahead lexical analysis
Tle-riven look-he lexil nlysis WUU YANG Computer n Informtion Siene Deprtment Ntionl Chio-Tung University, HsinChu, Tiwn, R.O.C. Astrt. Moern progrmming lnguges use regulr expressions to efine vli tokens.
More information