CSE 332. Sorting. Data Abstractions. CSE 332: Data Abstractions. QuickSort Cutoff 1. Where We Are 2. Bounding The MAXIMUM Problem 4

Size: px
Start display at page:

Download "CSE 332. Sorting. Data Abstractions. CSE 332: Data Abstractions. QuickSort Cutoff 1. Where We Are 2. Bounding The MAXIMUM Problem 4"

Transcription

1 Am Blnk Leture 13 Winter 2016 CSE 332 CSE 332: Dt Astrtions Sorting Dt Astrtions QuikSort Cutoff 1 Where We Are 2 For smll n, the reursion is wste. The onstnts on quik/merge sort re higher thn the ones on insertion/seletion sort for smll n. Simple: O(n 2 ) Fny: O(nlgn) Speilize: O(n) The solution is to swith to ifferent lgorithm for smll su-prolems. For sorting, n < 10 is goo hoie. Insertion Sort Seletion Sort Hep Sort Merge Sort Rix Sort For exmple: 1 voi quiksort(int[] rr, int lo, int hi) { 2 if (hi lo < CUTOFF) { 3 insertionsort(rr,lo,hi); 4 } 5 else { } We ve isusse some sorting methos They ll hppene to e Ω(nlgn). Cn we o etter? Bouning The MAXIMUM Prolem 3 Upper Boun 1 int finmx(int[] rr) { 2 int mx = rr[0]; 3 for (i = 0; i < rr.length; i++) { 4 if (rr[i] > mx) { 5 mx = rr[i]; 6 } 7 } 8 return mx; 9 } x mx = x A[3] A[4] A[5] A[6] A[7] This lgorithm tkes t most n 1 omprisons. So, n 1 is n upper oun for the MAXIMUM prolem. Bouning The MAXIMUM Prolem 4 Lower Bouns re muh more iffiult to prove. We must show tht ny lgorithm tht solves the prolem hs to o something. Lower Boun (Proof #1) Consier n lgorithm tht solves the MAXIMUM prolem in fewer thn n 1 omprisons. Sine the lgorithm uses fewer thn n 1 omprisons, there must e some element of the input (ll it x) tht wsn t ompre to some non-empty group of elements (sy y is in tht group): Consier two istint vlues for x: 0 y 2 x A[3] A[4] A[5] A[6] A[7] x = min( 0, 1, 2,..., n ) 1 x = mx( 0, 1, 2,..., n )+1 Notie tht, to e orret, the lgorithm must output ifferent nswers se on the vlue of x. But it never ompres x n y! So, it must lwys output the sme thing on otherwise ientil rrys.

2 Bouning The MAXIMUM Prolem 5 Key Ies Must e le to output ny vli nswer (every inex is the mx for some input) The only omputtions tht give informtion out the orret nswer re the omprisons Must only hve one vli possiility remining efore nswering Deision Tree Consier the omprisons some (ritrry) lgorithm mkes: < > < > > < > This is eision tree. The noes hve the remining vli possiilities. The eges represent mking omprison. < > > Bouning The MAXIMUM Prolem 6 Lower Boun (Proof #2) < > > > < > Every vli output (element of the rry) must e lef Some eision tree ompletely represents the exeution of ny lgorithm tht solves this prolem The lgorithm must get to lef efore stopping We must show tht the worst input tkes t lest f (n) omprisons. So, we re sking how long the minimum length of the longest pth is. A single omprison n rule out (t most) one output. We egin with n possiilities n eh omprison rules out t most one. So, the minimum length of the longest pth is n 1. > > The Min Event! 7 Lower Boun for Sorting The Min Event! 8 Filling In The Blnks > > > > > > > > Every vli output (??????) must e lef Some eision tree ompletely represents the exeution of ny lgorithm tht solves this prolem The lgorithm must get to lef efore stopping We must show tht the worst input tkes t lest f (n) omprisons. So, we re sking how long the minimum length of the longest pth is. A single omprison n rule out (t most)??????? output. We egin with???? possiilities n eh omprison rules out??????. So, the minimum length of the longest pth is???? Wht re the outputs? The outputs re permuttions of the input:,,,,, How mny of them re there? There re n! permuttions of n items:... n hoies n 1 hoies n 2 hoies 1 hoie How mny outputs remove per omprison (min gives us mx len)? Every output either goes left or right. So, one sie hs x/2 n the other hs x/2. The Min Event! 9 Lower Boun for Sorting > > The Min Event! 10 (Asymptoti) Lower Boun for Sorting We ve now shown tht the omprison sorting prolem is Ω(lg(n!)). It turns out tht this is tully Ω(nlg(n)): lg(n!) = lg(n(n 1)(n 2)...1) [Def. of n!] > > = lg(n)+lg(n 1)+...lg( n 2 )+lg(n 1)+...lg(1) [Prop. of Logs] 2 Every vli output (permuttions of A) must e lef Some eision tree ompletely represents the exeution of ny lgorithm tht solves this prolem The lgorithm must get to lef efore stopping We must show tht the worst input tkes t lest f (n) omprisons. So, we re sking how long the minimum length of the longest pth is. A single omprison n rule out (t most) hlf of the outputs. We egin with n! possiilities n eh omprison rules out t most hlf of the remining ones. So, the minimum length of the longest pth is: lg(n!). lg(n)+lg(n 1)+...+lg( n 2 ) ( n 2 )lg(n 2 ) = ( n 2 )(lgn lg2) = nlgn 2 n 2 Ω(nlg(n)) It follows tht Ω(nlg(n)) is lower oun for the sorting prolem!

3 Spetrum of Sorting 11 Boune Set Returns! 12 Rememer the ssumption we me for the BouneSet ADT? Simple: O(n 2 ) Insertion Sort Seletion Sort Fny: O(nlgn) Hep Sort Merge Sort Speilize: O(n) Rix Sort There re lot of omprison se sorts, ut they n t rek the lower oun of Ω(nlgn) BouneSet ADT Dt insert(key) fin(key) elete(key) Set of numeril keys where 0 k B for some B N As key to set Returns true if key is in the set n flse otherwise Deletes key from the set The only ifferene etween Set n BouneSet is tht BouneSet omes with n upper oun of B. Suppose we hve integers etween 1 n B (just like BouneSet). How oul we go out sorting them? But wht out lgorithm tht on t use omprisons! Crete n int rry of size B Loop through the elements n inrement their ounts Then, loop through the rry n output eh element foun Assuming ll t is ints etween 1 n B: Crete n int rry of size B Loop through the elements n inrement their ounts Then, loop through the rry n output eh element foun Assuming ll t is ints etween 1 n B: Crete n int rry of size B Loop through the elements n inrement their ounts Then, loop through the rry n output eh element foun Exmple Input: (B = 5) Initilize the rry: Loop through the elements: Loop through the inies Output: A[3] A[4] A[3] A[4] Best Cse? O(n+B) Worst Cse? O(n+B) Why oesn t the sorting lower oun pply? It s not omprison sort! We tully in t use omprisons t ll! When shoul we use? We shoul use when n B. Rix Sort 15 : 16 Rix Sort Choose numer representtion (e.g. (100) 10 = ( ) 2 = () 128 ) For eh igit from lest signifint to most signifint, o stle sort (why stle?) Usully for the sorting step, we use ounting sort. Rix Sort Choose numer representtion (e.g. (100) 10 = ( ) 2 = () 128 ). Sy se B. For eh igit from lest signifint to most signifint, o stle COUNTING sort. Sy there re P psses. Exmple Best Cse? Worst Cse? O(P(B+n)) O(P(B+n)) Shoul we use rix sort? Consier Strings of English letters up to length 15: Rix Sort will tke 15(52 + n) For n < 33,000, nlgn wins.

4 Applitions n Relte Prolems 17 Possily the most useful pplition of sorting is s form of pre-proessing. We sort the input in O(nlgn) n then solve the tul prolem using the sorte t. (e.g. if we expet to o more thn O(n) fins, the sorting step is worth it) Extr Slies 18 The remining slies re kin of net n interesting, ut we won t over them in leture. Feel free to look t them on your own. Big CS Ie! To mke repete opertion esier, o n expensive pre-proessing step one. You sw this with DFAs n String Mthing in CSE 311 s well! The mein prolem hs lrey ome up. Let s explore it more! Wht is SELECT? 19 SELECT is the omputtionl prolem with the following requirements: Inputs An rry A of E t of length L n numer 0 k < L. A onsistent, totl orering on ll elements of type E: ompre(, ) An Algorithm to Solve SELECT 20 Solving SELECT(k) Copy A into B Sort B Return (B(k) Awesome, exept this is O(nlgn) Another ie, inste of sorting, only sort the prts we nee. Post-Conitions The rry remins unhnge. Let B e the orering tht SORT woul return. We return B(k). QuikSort: A Reminer Choose pivot in A: p Prtition A into two rrys: SMALLER n LARGER QuikSort SMALLER. QuikSort LARGER. SMALLER + [p] + LARGER is sorte rry. Ie: To fin the k-th element, o we nee to reurse on oth sies? An Algorithm to Solve SELECT 21 QuikSelet(A, k) Choose pivot in A: p Prtition A into two rrys: SMALLER n LARGER Sine we know how ig SMALLER n LARGER re, we know the finl inex of p. Cll this x. If k = x, return p. If k < x, return QuikSelet(SMALLER, k) If k > x, return QuikSelet(LARGER, k x) Best Cse: T (n) = T (n/2)+n (So, O(n)) Worst Cse: T (n) = T (n 1)+n (So, O(n 2 )) (Averge Cse is O(n)) QuikSelet 22 mein = 4 th A[3] A[4] A[5] A[6] A[3] A[4] A[5] A[6] mein = 4 2 = 2 n?? A[0] A[1] A[2] A[3] A[4] A[5] A[6] A[2] A[3] A[4] A[5] A[6] mein = 2 n ???? A[2] A[3] A[4] A[5] A[6] A[2] A[3]?? ???? A[3] A[4] A[5] A[6]

5 Deterministi QuikSelet (Mein-of-Meins) 23 Mein-of-Meins Split A into g = n/5 groups of 5 elements. Sort eh group n fin the meins: m 1,m 2,...,m n/5 Fin p: the mein of the meins (reursively ) Seprte the input into two groups SMALLER n LARGER n reurse on the pproprite piee This lgorithm is silly QuikSelet, ut with speil pivot. The key to this lgorithm is tht whihever sie we reurse on is t lest 3/10 of the input. Here s why: Consier SMALLER. We know tht t lest g/2 of the groups hve mein p. Of the 5 elements in eh of these groups, sine the mein is p, 3 of them re p (possily inluing the mein). Putting this together, we hve 3(g/2) = 3((n/5)/2) = 3n/10 elements p. This mens we know we will isr t lest this mny. So, the mximum numer of elements we oul reurse on is 7n/10. The other se is symmetri. Deterministi QuikSelet (Solving the Reurrene) 24 Mein-of-Meins Split A into g = n/5 groups of 5 elements. Sort eh group n fin the meins: m 1,m 2,...,m n/5 Fin p: the mein of the meins (we re gonn o this reursively ) Seprte the input into two groups SMALLER n LARGER n reurse on the pproprite piee Solving The Reurrene So, putting ll this together gives us the reurrene T (n) O(5lg5)( n 5 )+T (n )+T (7n 5 10 ) = n + T ( 2n 10 ) + T ( 7n 10 ) = n + ( 2n 2n 2n + ( 7n 7n 7n = n + 9n 10 + T ( 22 n n ) + 2T (7 2 ( )) + T ( 72 n 2 10 ) 2 Deterministi QuikSelet (Solving the Reurrene) 25 Solving The Reurrene So, putting ll this together gives us the reurrene Whoo hoo! T (n) O(5lg5)( n 5 )+T (n )+T (7n 5 10 ) = n + T ( 2n 10 ) + T ( 7n 10 ) = n + ( 2n 2n 2n + ( 7n 7n 7n = n + 9n 10 + T ( 22 n n ) + 2T (7 2 ( )) + T ( 72 n 2 10 ) 2 n + 9n (7 2) = n + 9n n = n ( 9 i 10 i 1 ) = n( i=0 1 9/10 ) = 10n

Counting Paths Between Vertices. Isomorphism of Graphs. Isomorphism of Graphs. Isomorphism of Graphs. Isomorphism of Graphs. Isomorphism of Graphs

Counting Paths Between Vertices. Isomorphism of Graphs. Isomorphism of Graphs. Isomorphism of Graphs. Isomorphism of Graphs. Isomorphism of Graphs Isomorphism of Grphs Definition The simple grphs G 1 = (V 1, E 1 ) n G = (V, E ) re isomorphi if there is ijetion (n oneto-one n onto funtion) f from V 1 to V with the property tht n re jent in G 1 if

More information

1 PYTHAGORAS THEOREM 1. Given a right angled triangle, the square of the hypotenuse is equal to the sum of the squares of the other two sides.

1 PYTHAGORAS THEOREM 1. Given a right angled triangle, the square of the hypotenuse is equal to the sum of the squares of the other two sides. 1 PYTHAGORAS THEOREM 1 1 Pythgors Theorem In this setion we will present geometri proof of the fmous theorem of Pythgors. Given right ngled tringle, the squre of the hypotenuse is equl to the sum of the

More information

CS 491G Combinatorial Optimization Lecture Notes

CS 491G Combinatorial Optimization Lecture Notes CS 491G Comintoril Optimiztion Leture Notes Dvi Owen July 30, August 1 1 Mthings Figure 1: two possile mthings in simple grph. Definition 1 Given grph G = V, E, mthing is olletion of eges M suh tht e i,

More information

Lecture 6: Coding theory

Lecture 6: Coding theory Leture 6: Coing theory Biology 429 Crl Bergstrom Ferury 4, 2008 Soures: This leture loosely follows Cover n Thoms Chpter 5 n Yeung Chpter 3. As usul, some of the text n equtions re tken iretly from those

More information

Convert the NFA into DFA

Convert the NFA into DFA Convert the NF into F For ech NF we cn find F ccepting the sme lnguge. The numer of sttes of the F could e exponentil in the numer of sttes of the NF, ut in prctice this worst cse occurs rrely. lgorithm:

More information

CS 360 Exam 2 Fall 2014 Name

CS 360 Exam 2 Fall 2014 Name CS 360 Exm 2 Fll 2014 Nme 1. The lsses shown elow efine singly-linke list n stk. Write three ifferent O(n)-time versions of the reverse_print metho s speifie elow. Eh version of the metho shoul output

More information

Welcome. Balanced search trees. Balanced Search Trees. Inge Li Gørtz

Welcome. Balanced search trees. Balanced Search Trees. Inge Li Gørtz Welome nge Li Gørt. everse tehing n isussion of exerises: 02110 nge Li Gørt 3 tehing ssistnts 8.00-9.15 Group work 9.15-9.45 isussions of your solutions in lss 10.00-11.15 Leture 11.15-11.45 Work on exerises

More information

Improper Integrals. The First Fundamental Theorem of Calculus, as we ve discussed in class, goes as follows:

Improper Integrals. The First Fundamental Theorem of Calculus, as we ve discussed in class, goes as follows: Improper Integrls The First Fundmentl Theorem of Clculus, s we ve discussed in clss, goes s follows: If f is continuous on the intervl [, ] nd F is function for which F t = ft, then ftdt = F F. An integrl

More information

Common intervals of genomes. Mathieu Raffinot CNRS LIAFA

Common intervals of genomes. Mathieu Raffinot CNRS LIAFA Common intervls of genomes Mthieu Rffinot CNRS LIF Context: omprtive genomis. set of genomes prtilly/totlly nnotte Informtive group of genes or omins? Ex: COG tse Mny iffiulties! iology Wht re two similr

More information

First Midterm Examination

First Midterm Examination 24-25 Fll Semester First Midterm Exmintion ) Give the stte digrm of DFA tht recognizes the lnguge A over lphet Σ = {, } where A = {w w contins or } 2) The following DFA recognizes the lnguge B over lphet

More information

CS 373, Spring Solutions to Mock midterm 1 (Based on first midterm in CS 273, Fall 2008.)

CS 373, Spring Solutions to Mock midterm 1 (Based on first midterm in CS 273, Fall 2008.) CS 373, Spring 29. Solutions to Mock midterm (sed on first midterm in CS 273, Fll 28.) Prolem : Short nswer (8 points) The nswers to these prolems should e short nd not complicted. () If n NF M ccepts

More information

Numbers and indices. 1.1 Fractions. GCSE C Example 1. Handy hint. Key point

Numbers and indices. 1.1 Fractions. GCSE C Example 1. Handy hint. Key point GCSE C Emple 7 Work out 9 Give your nswer in its simplest form Numers n inies Reiprote mens invert or turn upsie own The reiprol of is 9 9 Mke sure you only invert the frtion you re iviing y 7 You multiply

More information

Intermediate Math Circles Wednesday, November 14, 2018 Finite Automata II. Nickolas Rollick a b b. a b 4

Intermediate Math Circles Wednesday, November 14, 2018 Finite Automata II. Nickolas Rollick a b b. a b 4 Intermedite Mth Circles Wednesdy, Novemer 14, 2018 Finite Automt II Nickols Rollick nrollick@uwterloo.c Regulr Lnguges Lst time, we were introduced to the ide of DFA (deterministic finite utomton), one

More information

I1 = I2 I1 = I2 + I3 I1 + I2 = I3 + I4 I 3

I1 = I2 I1 = I2 + I3 I1 + I2 = I3 + I4 I 3 2 The Prllel Circuit Electric Circuits: Figure 2- elow show ttery nd multiple resistors rrnged in prllel. Ech resistor receives portion of the current from the ttery sed on its resistnce. The split is

More information

Lecture 3. XML Into RDBMS. XML and Databases. Memory Representations. Memory Representations. Traversals and Pre/Post-Encoding. Memory Representations

Lecture 3. XML Into RDBMS. XML and Databases. Memory Representations. Memory Representations. Traversals and Pre/Post-Encoding. Memory Representations Leture XML into RDBMS XML n Dtses Sestin Mneth NICTA n UNSW Leture XML Into RDBMS CSE@UNSW -- Semester, 00 Memory Representtions Memory Representtions Fts DOM is esy to use, ut memory hevy. in-memory size

More information

NFA DFA Example 3 CMSC 330: Organization of Programming Languages. Equivalence of DFAs and NFAs. Equivalence of DFAs and NFAs (cont.

NFA DFA Example 3 CMSC 330: Organization of Programming Languages. Equivalence of DFAs and NFAs. Equivalence of DFAs and NFAs (cont. NFA DFA Exmple 3 CMSC 330: Orgniztion of Progrmming Lnguges NFA {B,D,E {A,E {C,D {E Finite Automt, con't. R = { {A,E, {B,D,E, {C,D, {E 2 Equivlence of DFAs nd NFAs Any string from {A to either {D or {CD

More information

Global alignment. Genome Rearrangements Finding preserved genes. Lecture 18

Global alignment. Genome Rearrangements Finding preserved genes. Lecture 18 Computt onl Biology Leture 18 Genome Rerrngements Finding preserved genes We hve seen before how to rerrnge genome to obtin nother one bsed on: Reversls Knowledge of preserved bloks (or genes) Now we re

More information

22: Union Find. CS 473u - Algorithms - Spring April 14, We want to maintain a collection of sets, under the operations of:

22: Union Find. CS 473u - Algorithms - Spring April 14, We want to maintain a collection of sets, under the operations of: 22: Union Fin CS 473u - Algorithms - Spring 2005 April 14, 2005 1 Union-Fin We wnt to mintin olletion of sets, uner the opertions of: 1. MkeSet(x) - rete set tht ontins the single element x. 2. Fin(x)

More information

Surds and Indices. Surds and Indices. Curriculum Ready ACMNA: 233,

Surds and Indices. Surds and Indices. Curriculum Ready ACMNA: 233, Surs n Inies Surs n Inies Curriulum Rey ACMNA:, 6 www.mthletis.om Surs SURDS & & Inies INDICES Inies n surs re very losely relte. A numer uner (squre root sign) is lle sur if the squre root n t e simplifie.

More information

18.06 Problem Set 4 Due Wednesday, Oct. 11, 2006 at 4:00 p.m. in 2-106

18.06 Problem Set 4 Due Wednesday, Oct. 11, 2006 at 4:00 p.m. in 2-106 8. Problem Set Due Wenesy, Ot., t : p.m. in - Problem Mony / Consier the eight vetors 5, 5, 5,..., () List ll of the one-element, linerly epenent sets forme from these. (b) Wht re the two-element, linerly

More information

Area and Perimeter. Area and Perimeter. Solutions. Curriculum Ready.

Area and Perimeter. Area and Perimeter. Solutions. Curriculum Ready. Are n Perimeter Are n Perimeter Solutions Curriulum Rey www.mthletis.om How oes it work? Solutions Are n Perimeter Pge questions Are using unit squres Are = whole squres Are = 6 whole squres = units =

More information

Things to Memorize: A Partial List. January 27, 2017

Things to Memorize: A Partial List. January 27, 2017 Things to Memorize: A Prtil List Jnury 27, 2017 Chpter 2 Vectors - Bsic Fcts A vector hs mgnitude (lso clled size/length/norm) nd direction. It does not hve fixed position, so the sme vector cn e moved

More information

Regular expressions, Finite Automata, transition graphs are all the same!!

Regular expressions, Finite Automata, transition graphs are all the same!! CSI 3104 /Winter 2011: Introduction to Forml Lnguges Chpter 7: Kleene s Theorem Chpter 7: Kleene s Theorem Regulr expressions, Finite Automt, trnsition grphs re ll the sme!! Dr. Neji Zgui CSI3104-W11 1

More information

Minimal DFA. minimal DFA for L starting from any other

Minimal DFA. minimal DFA for L starting from any other Miniml DFA Among the mny DFAs ccepting the sme regulr lnguge L, there is exctly one (up to renming of sttes) which hs the smllest possile numer of sttes. Moreover, it is possile to otin tht miniml DFA

More information

Mid-Term Examination - Spring 2014 Mathematical Programming with Applications to Economics Total Score: 45; Time: 3 hours

Mid-Term Examination - Spring 2014 Mathematical Programming with Applications to Economics Total Score: 45; Time: 3 hours Mi-Term Exmintion - Spring 0 Mthemtil Progrmming with Applitions to Eonomis Totl Sore: 5; Time: hours. Let G = (N, E) e irete grph. Define the inegree of vertex i N s the numer of eges tht re oming into

More information

CS 573 Automata Theory and Formal Languages

CS 573 Automata Theory and Formal Languages Non-determinism Automt Theory nd Forml Lnguges Professor Leslie Lnder Leture # 3 Septemer 6, 2 To hieve our gol, we need the onept of Non-deterministi Finite Automton with -moves (NFA) An NFA is tuple

More information

Chapter 4 State-Space Planning

Chapter 4 State-Space Planning Leture slides for Automted Plnning: Theory nd Prtie Chpter 4 Stte-Spe Plnning Dn S. Nu CMSC 722, AI Plnning University of Mrylnd, Spring 2008 1 Motivtion Nerly ll plnning proedures re serh proedures Different

More information

Algorithms & Data Structures Homework 8 HS 18 Exercise Class (Room & TA): Submitted by: Peer Feedback by: Points:

Algorithms & Data Structures Homework 8 HS 18 Exercise Class (Room & TA): Submitted by: Peer Feedback by: Points: Eidgenössishe Tehnishe Hohshule Zürih Eole polytehnique fédérle de Zurih Politenio federle di Zurigo Federl Institute of Tehnology t Zurih Deprtement of Computer Siene. Novemer 0 Mrkus Püshel, Dvid Steurer

More information

Factorising FACTORISING.

Factorising FACTORISING. Ftorising FACTORISING www.mthletis.om.u Ftorising FACTORISING Ftorising is the opposite of expning. It is the proess of putting expressions into rkets rther thn expning them out. In this setion you will

More information

CMSC 330: Organization of Programming Languages

CMSC 330: Organization of Programming Languages CMSC 330: Orgniztion of Progrmming Lnguges Finite Automt 2 CMSC 330 1 Types of Finite Automt Deterministic Finite Automt (DFA) Exctly one sequence of steps for ech string All exmples so fr Nondeterministic

More information

CS415 Compilers. Lexical Analysis and. These slides are based on slides copyrighted by Keith Cooper, Ken Kennedy & Linda Torczon at Rice University

CS415 Compilers. Lexical Analysis and. These slides are based on slides copyrighted by Keith Cooper, Ken Kennedy & Linda Torczon at Rice University CS415 Compilers Lexicl Anlysis nd These slides re sed on slides copyrighted y Keith Cooper, Ken Kennedy & Lind Torczon t Rice University First Progrmming Project Instruction Scheduling Project hs een posted

More information

First Midterm Examination

First Midterm Examination Çnky University Deprtment of Computer Engineering 203-204 Fll Semester First Midterm Exmintion ) Design DFA for ll strings over the lphet Σ = {,, c} in which there is no, no nd no cc. 2) Wht lnguge does

More information

Linear Inequalities. Work Sheet 1

Linear Inequalities. Work Sheet 1 Work Sheet 1 Liner Inequlities Rent--Hep, cr rentl compny,chrges $ 15 per week plus $ 0.0 per mile to rent one of their crs. Suppose you re limited y how much money you cn spend for the week : You cn spend

More information

CARLETON UNIVERSITY. 1.0 Problems and Most Solutions, Sect B, 2005

CARLETON UNIVERSITY. 1.0 Problems and Most Solutions, Sect B, 2005 RLETON UNIVERSIT eprtment of Eletronis ELE 2607 Swithing iruits erury 28, 05; 0 pm.0 Prolems n Most Solutions, Set, 2005 Jn. 2, #8 n #0; Simplify, Prove Prolem. #8 Simplify + + + Reue to four letters (literls).

More information

Spacetime and the Quantum World Questions Fall 2010

Spacetime and the Quantum World Questions Fall 2010 Spetime nd the Quntum World Questions Fll 2010 1. Cliker Questions from Clss: (1) In toss of two die, wht is the proility tht the sum of the outomes is 6? () P (x 1 + x 2 = 6) = 1 36 - out 3% () P (x 1

More information

The University of Nottingham SCHOOL OF COMPUTER SCIENCE A LEVEL 2 MODULE, SPRING SEMESTER MACHINES AND THEIR LANGUAGES ANSWERS

The University of Nottingham SCHOOL OF COMPUTER SCIENCE A LEVEL 2 MODULE, SPRING SEMESTER MACHINES AND THEIR LANGUAGES ANSWERS The University of ottinghm SCHOOL OF COMPUTR SCIC A LVL 2 MODUL, SPRIG SMSTR 2015 2016 MACHIS AD THIR LAGUAGS ASWRS Time llowed TWO hours Cndidtes my omplete the front over of their nswer ook nd sign their

More information

Connected-components. Summary of lecture 9. Algorithms and Data Structures Disjoint sets. Example: connected components in graphs

Connected-components. Summary of lecture 9. Algorithms and Data Structures Disjoint sets. Example: connected components in graphs Prm University, Mth. Deprtment Summry of lecture 9 Algorithms nd Dt Structures Disjoint sets Summry of this lecture: (CLR.1-3) Dt Structures for Disjoint sets: Union opertion Find opertion Mrco Pellegrini

More information

6. Suppose lim = constant> 0. Which of the following does not hold?

6. Suppose lim = constant> 0. Which of the following does not hold? CSE 0-00 Nme Test 00 points UTA Stuent ID # Multiple Choie Write your nswer to the LEFT of eh prolem 5 points eh The k lrgest numers in file of n numers n e foun using Θ(k) memory in Θ(n lg k) time using

More information

NON-DETERMINISTIC FSA

NON-DETERMINISTIC FSA Tw o types of non-determinism: NON-DETERMINISTIC FS () Multiple strt-sttes; strt-sttes S Q. The lnguge L(M) ={x:x tkes M from some strt-stte to some finl-stte nd ll of x is proessed}. The string x = is

More information

1 Nondeterministic Finite Automata

1 Nondeterministic Finite Automata 1 Nondeterministic Finite Automt Suppose in life, whenever you hd choice, you could try oth possiilities nd live your life. At the end, you would go ck nd choose the one tht worked out the est. Then you

More information

I 3 2 = I I 4 = 2A

I 3 2 = I I 4 = 2A ECE 210 Eletril Ciruit Anlysis University of llinois t Chigo 2.13 We re ske to use KCL to fin urrents 1 4. The key point in pplying KCL in this prolem is to strt with noe where only one of the urrents

More information

5. (±±) Λ = fw j w is string of even lengthg [ 00 = f11,00g 7. (11 [ 00)± Λ = fw j w egins with either 11 or 00g 8. (0 [ ffl)1 Λ = 01 Λ [ 1 Λ 9.

5. (±±) Λ = fw j w is string of even lengthg [ 00 = f11,00g 7. (11 [ 00)± Λ = fw j w egins with either 11 or 00g 8. (0 [ ffl)1 Λ = 01 Λ [ 1 Λ 9. Regulr Expressions, Pumping Lemm, Right Liner Grmmrs Ling 106 Mrch 25, 2002 1 Regulr Expressions A regulr expression descries or genertes lnguge: it is kind of shorthnd for listing the memers of lnguge.

More information

CS103B Handout 18 Winter 2007 February 28, 2007 Finite Automata

CS103B Handout 18 Winter 2007 February 28, 2007 Finite Automata CS103B ndout 18 Winter 2007 Ferury 28, 2007 Finite Automt Initil text y Mggie Johnson. Introduction Severl childrens gmes fit the following description: Pieces re set up on plying ord; dice re thrown or

More information

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. NFA for (a b)*abb.

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. NFA for (a b)*abb. CMSC 330: Orgniztion of Progrmming Lnguges Finite Automt 2 Types of Finite Automt Deterministic Finite Automt () Exctly one sequence of steps for ech string All exmples so fr Nondeterministic Finite Automt

More information

APPENDIX. Precalculus Review D.1. Real Numbers and the Real Number Line

APPENDIX. Precalculus Review D.1. Real Numbers and the Real Number Line APPENDIX D Preclculus Review APPENDIX D.1 Rel Numers n the Rel Numer Line Rel Numers n the Rel Numer Line Orer n Inequlities Asolute Vlue n Distnce Rel Numers n the Rel Numer Line Rel numers cn e represente

More information

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. Comparing DFAs and NFAs (cont.) Finite Automata 2

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. Comparing DFAs and NFAs (cont.) Finite Automata 2 CMSC 330: Orgniztion of Progrmming Lnguges Finite Automt 2 Types of Finite Automt Deterministic Finite Automt () Exctly one sequence of steps for ech string All exmples so fr Nondeterministic Finite Automt

More information

Algorithm Design and Analysis

Algorithm Design and Analysis Algorithm Design nd Anlysis LECTURE 5 Supplement Greedy Algorithms Cont d Minimizing lteness Ching (NOT overed in leture) Adm Smith 9/8/10 A. Smith; sed on slides y E. Demine, C. Leiserson, S. Rskhodnikov,

More information

Equivalent fractions have the same value but they have different denominators. This means they have been divided into a different number of parts.

Equivalent fractions have the same value but they have different denominators. This means they have been divided into a different number of parts. Frtions equivlent frtions Equivlent frtions hve the sme vlue ut they hve ifferent enomintors. This mens they hve een ivie into ifferent numer of prts. Use the wll to fin the equivlent frtions: Wht frtions

More information

Trigonometry Revision Sheet Q5 of Paper 2

Trigonometry Revision Sheet Q5 of Paper 2 Trigonometry Revision Sheet Q of Pper The Bsis - The Trigonometry setion is ll out tringles. We will normlly e given some of the sides or ngles of tringle nd we use formule nd rules to find the others.

More information

Outline Data Structures and Algorithms. Data compression. Data compression. Lossy vs. Lossless. Data Compression

Outline Data Structures and Algorithms. Data compression. Data compression. Lossy vs. Lossless. Data Compression 5-2 Dt Strutures n Algorithms Dt Compression n Huffmn s Algorithm th Fe 2003 Rjshekr Rey Outline Dt ompression Lossy n lossless Exmples Forml view Coes Definition Fixe length vs. vrile length Huffmn s

More information

Homework 3 Solutions

Homework 3 Solutions CS 341: Foundtions of Computer Science II Prof. Mrvin Nkym Homework 3 Solutions 1. Give NFAs with the specified numer of sttes recognizing ech of the following lnguges. In ll cses, the lphet is Σ = {,1}.

More information

Finite State Automata and Determinisation

Finite State Automata and Determinisation Finite Stte Automt nd Deterministion Tim Dworn Jnury, 2016 Lnguges fs nf re df Deterministion 2 Outline 1 Lnguges 2 Finite Stte Automt (fs) 3 Non-deterministi Finite Stte Automt (nf) 4 Regulr Expressions

More information

Lesson 2.1 Inductive Reasoning

Lesson 2.1 Inductive Reasoning Lesson 2.1 Inutive Resoning Nme Perio Dte For Eerises 1 7, use inutive resoning to fin the net two terms in eh sequene. 1. 4, 8, 12, 16,, 2. 400, 200, 100, 50, 25,, 3. 1 8, 2 7, 1 2, 4, 5, 4. 5, 3, 2,

More information

Harvard University Computer Science 121 Midterm October 23, 2012

Harvard University Computer Science 121 Midterm October 23, 2012 Hrvrd University Computer Science 121 Midterm Octoer 23, 2012 This is closed-ook exmintion. You my use ny result from lecture, Sipser, prolem sets, or section, s long s you quote it clerly. The lphet is

More information

Properties of Integrals, Indefinite Integrals. Goals: Definition of the Definite Integral Integral Calculations using Antiderivatives

Properties of Integrals, Indefinite Integrals. Goals: Definition of the Definite Integral Integral Calculations using Antiderivatives Block #6: Properties of Integrls, Indefinite Integrls Gols: Definition of the Definite Integrl Integrl Clcultions using Antiderivtives Properties of Integrls The Indefinite Integrl 1 Riemnn Sums - 1 Riemnn

More information

XML and Databases. Exam Preperation Discuss Answers to last year s exam. Sebastian Maneth NICTA and UNSW

XML and Databases. Exam Preperation Discuss Answers to last year s exam. Sebastian Maneth NICTA and UNSW XML n Dtses Exm Prepertion Disuss Answers to lst yer s exm Sestin Mneth NICTA n UNSW CSE@UNSW -- Semester 1, 2008 (1) For eh of the following, explin why it is not well-forme XML (is WFC or the XML grmmr

More information

The DOACROSS statement

The DOACROSS statement The DOACROSS sttement Is prllel loop similr to DOALL, ut it llows prouer-onsumer type of synhroniztion. Synhroniztion is llowe from lower to higher itertions sine it is ssume tht lower itertions re selete

More information

Lecture 3: Equivalence Relations

Lecture 3: Equivalence Relations Mthcmp Crsh Course Instructor: Pdric Brtlett Lecture 3: Equivlence Reltions Week 1 Mthcmp 2014 In our lst three tlks of this clss, we shift the focus of our tlks from proof techniques to proof concepts

More information

CS 330 Formal Methods and Models Dana Richards, George Mason University, Spring 2016 Quiz Solutions

CS 330 Formal Methods and Models Dana Richards, George Mason University, Spring 2016 Quiz Solutions CS 330 Forml Methods nd Models Dn Richrds, George Mson University, Spring 2016 Quiz Solutions Quiz 1, Propositionl Logic Dte: Ferury 9 1. (4pts) ((p q) (q r)) (p r), prove tutology using truth tles. p

More information

Parse trees, ambiguity, and Chomsky normal form

Parse trees, ambiguity, and Chomsky normal form Prse trees, miguity, nd Chomsky norml form In this lecture we will discuss few importnt notions connected with contextfree grmmrs, including prse trees, miguity, nd specil form for context-free grmmrs

More information

CIT 596 Theory of Computation 1. Graphs and Digraphs

CIT 596 Theory of Computation 1. Graphs and Digraphs CIT 596 Theory of Computtion 1 A grph G = (V (G), E(G)) onsists of two finite sets: V (G), the vertex set of the grph, often enote y just V, whih is nonempty set of elements lle verties, n E(G), the ege

More information

PYTHAGORAS THEOREM WHAT S IN CHAPTER 1? IN THIS CHAPTER YOU WILL:

PYTHAGORAS THEOREM WHAT S IN CHAPTER 1? IN THIS CHAPTER YOU WILL: PYTHAGORAS THEOREM 1 WHAT S IN CHAPTER 1? 1 01 Squres, squre roots nd surds 1 02 Pythgors theorem 1 03 Finding the hypotenuse 1 04 Finding shorter side 1 05 Mixed prolems 1 06 Testing for right-ngled tringles

More information

Arrow s Impossibility Theorem

Arrow s Impossibility Theorem Rep Voting Prdoxes Properties Arrow s Theorem Arrow s Impossiility Theorem Leture 12 Arrow s Impossiility Theorem Leture 12, Slide 1 Rep Voting Prdoxes Properties Arrow s Theorem Leture Overview 1 Rep

More information

Lesson 2.1 Inductive Reasoning

Lesson 2.1 Inductive Reasoning Lesson 2.1 Inutive Resoning Nme Perio Dte For Eerises 1 7, use inutive resoning to fin the net two terms in eh sequene. 1. 4, 8, 12, 16,, 2. 400, 200, 100, 50, 25,, 3. 1 8, 2 7, 1 2, 4, 5, 4. 5, 3, 2,

More information

Solutions for HW9. Bipartite: put the red vertices in V 1 and the black in V 2. Not bipartite!

Solutions for HW9. Bipartite: put the red vertices in V 1 and the black in V 2. Not bipartite! Solutions for HW9 Exerise 28. () Drw C 6, W 6 K 6, n K 5,3. C 6 : W 6 : K 6 : K 5,3 : () Whih of the following re iprtite? Justify your nswer. Biprtite: put the re verties in V 1 n the lk in V 2. Biprtite:

More information

10. AREAS BETWEEN CURVES

10. AREAS BETWEEN CURVES . AREAS BETWEEN CURVES.. Ares etween curves So res ove the x-xis re positive nd res elow re negtive, right? Wrong! We lied! Well, when you first lern out integrtion it s convenient fiction tht s true in

More information

7.1 Integral as Net Change and 7.2 Areas in the Plane Calculus

7.1 Integral as Net Change and 7.2 Areas in the Plane Calculus 7.1 Integrl s Net Chnge nd 7. Ares in the Plne Clculus 7.1 INTEGRAL AS NET CHANGE Notecrds from 7.1: Displcement vs Totl Distnce, Integrl s Net Chnge We hve lredy seen how the position of n oject cn e

More information

CS 2204 DIGITAL LOGIC & STATE MACHINE DESIGN SPRING 2014

CS 2204 DIGITAL LOGIC & STATE MACHINE DESIGN SPRING 2014 S 224 DIGITAL LOGI & STATE MAHINE DESIGN SPRING 214 DUE : Mrh 27, 214 HOMEWORK III READ : Relte portions of hpters VII n VIII ASSIGNMENT : There re three questions. Solve ll homework n exm prolems s shown

More information

CS 311 Homework 3 due 16:30, Thursday, 14 th October 2010

CS 311 Homework 3 due 16:30, Thursday, 14 th October 2010 CS 311 Homework 3 due 16:30, Thursdy, 14 th Octoer 2010 Homework must e sumitted on pper, in clss. Question 1. [15 pts.; 5 pts. ech] Drw stte digrms for NFAs recognizing the following lnguges:. L = {w

More information

CSCI 340: Computational Models. Kleene s Theorem. Department of Computer Science

CSCI 340: Computational Models. Kleene s Theorem. Department of Computer Science CSCI 340: Computtionl Models Kleene s Theorem Chpter 7 Deprtment of Computer Science Unifiction In 1954, Kleene presented (nd proved) theorem which (in our version) sttes tht if lnguge cn e defined y ny

More information

set is not closed under matrix [ multiplication, ] and does not form a group.

set is not closed under matrix [ multiplication, ] and does not form a group. Prolem 2.3: Which of the following collections of 2 2 mtrices with rel entries form groups under [ mtrix ] multipliction? i) Those of the form for which c d 2 Answer: The set of such mtrices is not closed

More information

Digital Circuit Engineering

Digital Circuit Engineering Digitl Ciruit Engineering 5 INPUT MAPS (A) Loop squres with no friens, they n never shre. (B) Loop squres with no rothers, n simutneously loop their friens. Iterte: (A') Loop squres seperte from friens

More information

Digital Circuit Engineering

Digital Circuit Engineering Digitl Ciruit Engineering 5 IN UT P MAPS (A) Loop squres with no friens, they n never shre. (B) Loop squres with no rothers, n simutneously loop their friens. Iterte: (A') Loop squres seperte from friens

More information

Section 2.1 Special Right Triangles

Section 2.1 Special Right Triangles Se..1 Speil Rigt Tringles 49 Te --90 Tringle Setion.1 Speil Rigt Tringles Te --90 tringle (or just 0-60-90) is so nme euse of its ngle mesures. Te lengts of te sies, toug, ve very speifi pttern to tem

More information

Data Structures LECTURE 10. Huffman coding. Example. Coding: problem definition

Data Structures LECTURE 10. Huffman coding. Example. Coding: problem definition Dt Strutures, Spring 24 L. Joskowiz Dt Strutures LEURE Humn oing Motivtion Uniquel eipherle oes Prei oes Humn oe onstrution Etensions n pplitions hpter 6.3 pp 385 392 in tetook Motivtion Suppose we wnt

More information

Logic, Set Theory and Computability [M. Coppenbarger]

Logic, Set Theory and Computability [M. Coppenbarger] 14 Orer (Hnout) Definition 7-11: A reltion is qusi-orering (or preorer) if it is reflexive n trnsitive. A quisi-orering tht is symmetri is n equivlene reltion. A qusi-orering tht is nti-symmetri is n orer

More information

Homework Solution - Set 5 Due: Friday 10/03/08

Homework Solution - Set 5 Due: Friday 10/03/08 CE 96 Introduction to the Theory of Computtion ll 2008 Homework olution - et 5 Due: ridy 10/0/08 1. Textook, Pge 86, Exercise 1.21. () 1 2 Add new strt stte nd finl stte. Mke originl finl stte non-finl.

More information

Finite Automata-cont d

Finite Automata-cont d Automt Theory nd Forml Lnguges Professor Leslie Lnder Lecture # 6 Finite Automt-cont d The Pumping Lemm WEB SITE: http://ingwe.inghmton.edu/ ~lnder/cs573.html Septemer 18, 2000 Exmple 1 Consider L = {ww

More information

Assignment 1 Automata, Languages, and Computability. 1 Finite State Automata and Regular Languages

Assignment 1 Automata, Languages, and Computability. 1 Finite State Automata and Regular Languages Deprtment of Computer Science, Austrlin Ntionl University COMP2600 Forml Methods for Softwre Engineering Semester 2, 206 Assignment Automt, Lnguges, nd Computility Smple Solutions Finite Stte Automt nd

More information

Algorithm Design and Analysis

Algorithm Design and Analysis Algorithm Design nd Anlysis LECTURE 8 Mx. lteness ont d Optiml Ching Adm Smith 9/12/2008 A. Smith; sed on slides y E. Demine, C. Leiserson, S. Rskhodnikov, K. Wyne Sheduling to Minimizing Lteness Minimizing

More information

CS 310 (sec 20) - Winter Final Exam (solutions) SOLUTIONS

CS 310 (sec 20) - Winter Final Exam (solutions) SOLUTIONS CS 310 (sec 20) - Winter 2003 - Finl Exm (solutions) SOLUTIONS 1. (Logic) Use truth tles to prove the following logicl equivlences: () p q (p p) (q q) () p q (p q) (p q) () p q p q p p q q (q q) (p p)

More information

Surface maps into free groups

Surface maps into free groups Surfce mps into free groups lden Wlker Novemer 10, 2014 Free groups wedge X of two circles: Set F = π 1 (X ) =,. We write cpitl letters for inverse, so = 1. e.g. () 1 = Commuttors Let x nd y e loops. The

More information

where the box contains a finite number of gates from the given collection. Examples of gates that are commonly used are the following: a b

where the box contains a finite number of gates from the given collection. Examples of gates that are commonly used are the following: a b CS 294-2 9/11/04 Quntum Ciruit Model, Solovy-Kitev Theorem, BQP Fll 2004 Leture 4 1 Quntum Ciruit Model 1.1 Clssil Ciruits - Universl Gte Sets A lssil iruit implements multi-output oolen funtion f : {0,1}

More information

Finite Automata Theory and Formal Languages TMV027/DIT321 LP4 2018

Finite Automata Theory and Formal Languages TMV027/DIT321 LP4 2018 Finite Automt Theory nd Forml Lnguges TMV027/DIT321 LP4 2018 Lecture 10 An Bove April 23rd 2018 Recp: Regulr Lnguges We cn convert between FA nd RE; Hence both FA nd RE ccept/generte regulr lnguges; More

More information

Project 6: Minigoals Towards Simplifying and Rewriting Expressions

Project 6: Minigoals Towards Simplifying and Rewriting Expressions MAT 51 Wldis Projet 6: Minigols Towrds Simplifying nd Rewriting Expressions The distriutive property nd like terms You hve proly lerned in previous lsses out dding like terms ut one prolem with the wy

More information

For a, b, c, d positive if a b and. ac bd. Reciprocal relations for a and b positive. If a > b then a ab > b. then

For a, b, c, d positive if a b and. ac bd. Reciprocal relations for a and b positive. If a > b then a ab > b. then Slrs-7.2-ADV-.7 Improper Definite Integrls 27.. D.dox Pge of Improper Definite Integrls Before we strt the min topi we present relevnt lger nd it review. See Appendix J for more lger review. Inequlities:

More information

2.4 Linear Inequalities and Interval Notation

2.4 Linear Inequalities and Interval Notation .4 Liner Inequlities nd Intervl Nottion We wnt to solve equtions tht hve n inequlity symol insted of n equl sign. There re four inequlity symols tht we will look t: Less thn , Less thn or

More information

Chapter Five - Eigenvalues, Eigenfunctions, and All That

Chapter Five - Eigenvalues, Eigenfunctions, and All That Chpter Five - Eigenvlues, Eigenfunctions, n All Tht The prtil ifferentil eqution methos escrie in the previous chpter is specil cse of more generl setting in which we hve n eqution of the form L 1 xux,tl

More information

p-adic Egyptian Fractions

p-adic Egyptian Fractions p-adic Egyptin Frctions Contents 1 Introduction 1 2 Trditionl Egyptin Frctions nd Greedy Algorithm 2 3 Set-up 3 4 p-greedy Algorithm 5 5 p-egyptin Trditionl 10 6 Conclusion 1 Introduction An Egyptin frction

More information

If we have a function f(x) which is well-defined for some a x b, its integral over those two values is defined as

If we have a function f(x) which is well-defined for some a x b, its integral over those two values is defined as Y. D. Chong (26) MH28: Complex Methos for the Sciences 2. Integrls If we hve function f(x) which is well-efine for some x, its integrl over those two vlues is efine s N ( ) f(x) = lim x f(x n ) where x

More information

More on automata. Michael George. March 24 April 7, 2014

More on automata. Michael George. March 24 April 7, 2014 More on utomt Michel George Mrch 24 April 7, 2014 1 Automt constructions Now tht we hve forml model of mchine, it is useful to mke some generl constructions. 1.1 DFA Union / Product construction Suppose

More information

How do we solve these things, especially when they get complicated? How do we know when a system has a solution, and when is it unique?

How do we solve these things, especially when they get complicated? How do we know when a system has a solution, and when is it unique? XII. LINEAR ALGEBRA: SOLVING SYSTEMS OF EQUATIONS Tody we re going to tlk out solving systems of liner equtions. These re prolems tht give couple of equtions with couple of unknowns, like: 6= x + x 7=

More information

Using integration tables

Using integration tables Using integrtion tbles Integrtion tbles re inclue in most mth tetbooks, n vilble on the Internet. Using them is nother wy to evlute integrls. Sometimes the use is strightforwr; sometimes it tkes severl

More information

Discrete Structures, Test 2 Monday, March 28, 2016 SOLUTIONS, VERSION α

Discrete Structures, Test 2 Monday, March 28, 2016 SOLUTIONS, VERSION α Disrete Strutures, Test 2 Mondy, Mrh 28, 2016 SOLUTIONS, VERSION α α 1. (18 pts) Short nswer. Put your nswer in the ox. No prtil redit. () Consider the reltion R on {,,, d with mtrix digrph of R.. Drw

More information

Designing finite automata II

Designing finite automata II Designing finite utomt II Prolem: Design DFA A such tht L(A) consists of ll strings of nd which re of length 3n, for n = 0, 1, 2, (1) Determine wht to rememer out the input string Assign stte to ech of

More information

Nondeterminism and Nodeterministic Automata

Nondeterminism and Nodeterministic Automata Nondeterminism nd Nodeterministic Automt 61 Nondeterminism nd Nondeterministic Automt The computtionl mchine models tht we lerned in the clss re deterministic in the sense tht the next move is uniquely

More information

CS241 Week 6 Tutorial Solutions

CS241 Week 6 Tutorial Solutions 241 Week 6 Tutoril olutions Lnguges: nning & ontext-free Grmmrs Winter 2018 1 nning Exerises 1. 0x0x0xd HEXINT 0x0 I x0xd 2. 0xend--- HEXINT 0xe I nd ER -- MINU - 3. 1234-120x INT 1234 INT -120 I x 4.

More information

x dx does exist, what does the answer look like? What does the answer to

x dx does exist, what does the answer look like? What does the answer to Review Guie or MAT Finl Em Prt II. Mony Decemer th 8:.m. 9:5.m. (or the 8:3.m. clss) :.m. :5.m. (or the :3.m. clss) Prt is worth 5% o your Finl Em gre. NO CALCULATORS re llowe on this portion o the Finl

More information

Prefix-Free Regular-Expression Matching

Prefix-Free Regular-Expression Matching Prefix-Free Regulr-Expression Mthing Yo-Su Hn, Yjun Wng nd Derik Wood Deprtment of Computer Siene HKUST Prefix-Free Regulr-Expression Mthing p.1/15 Pttern Mthing Given pttern P nd text T, find ll sustrings

More information

6.5 Improper integrals

6.5 Improper integrals Eerpt from "Clulus" 3 AoPS In. www.rtofprolemsolving.om 6.5. IMPROPER INTEGRALS 6.5 Improper integrls As we ve seen, we use the definite integrl R f to ompute the re of the region under the grph of y =

More information