Combinatorics. Stephan Wagner

Size: px
Start display at page:

Download "Combinatorics. Stephan Wagner"

Transcription

1 Combiatorics Stepha Wager Jue 207

2 Chapter Elemetary eumeratio priciples Sequeces Theorem. There are differet sequeces of legth that ca be formed from elemets of a set X cosistig of elemets (elemets are allowed to occur several times i a sequece. Proof: For every elemet of the sequece, we have exactly choices. Therefore, there are } {{... } times differet possibilities. Example. Give a alphabet of letters, there are exactly -letter words. For istace, there are 8 three-digit words (ot ecessarily meaigful that ca be formed from the letters S ad O: SSS, SSO, SOS, OSS, SOO, OSO, OOS, OOO. The umber of 00-letter words over the alphabet A,C,G,T is 4 00, which is a 6-digit umber; DNA strigs as they occur i cells of livig orgaisms are much loger, of course... Permutatios Theorem.2 The umber of possibilities to arrage (distiguishable objects i a row (so-called permutatios is! ( Proof: There are obviously choices for the first positio, the remaiig choices for the secod positio (as opposed to the previous theorem, 2 for the third positio, etc. Therefore, oe obtais the stated formula.

3 CHAPTER. ELEMENTARY ENUMERATION PRINCIPLES 2 Example.2 There are 6 possibilities to arrage the letters A,E,T i a row: AET, ATE, EAT, ETA, TAE, TEA. Remar: By defiitio,! satisfies the equatio! (!, which remais true if oe defies 0! (iformally, there is exactly oe possibility to arrage 0 objects, ad that is to do othig at all. Example.3 I how may ways ca eight roos be placed o a 8 8-chessboard i such a way that o horizotal or vertical row cotais two roos? I order to solve this problem, let us assig coordiates (a-h ad -8 respectively to the squares of the chessboard. A possible cofiguratio would the be a3, b5, c, d8, e6, f2, g4, h7 (for istace. Geerally, there must be exactly oe roo o each vertical row (a-h, ad aalogously oe roo o each horizotal row (-8. Each permutatio of the umbers to 8 correspods to exactly oe feasible cofiguratio (i the above case, , ad so there are exactly 8! possibilities. Sequeces without repetitios Theorem.3 The umber of sequeces of legth whose elemets are tae from a set X comprisig elemets is ( ( 2... ( +! (!. Proof: The proof is essetially the same as for Theorem.2: for the first elemet, there are possible choices, the for the secod elemet, etc. For the last elemet, there are + choices left. Remar: The case of permutatios is clearly a special case of Theorem.3, correspodig to. is called a fallig factorial (read: to the fallig. Choosig a subset Theorem.4 The umber of possibilities to choose a subset of elemets from a set of elemets (the order beig irrelevat is (!!(!. Proof: Let x be the umber of possibilities that we are looig for. Oce the elemets have bee chose (for which there are x possible ways, oe has! possibilities (by Theorem.2 to arrage them i a sequece. Therefore, x! is exactly the umber of possible sequeces of distict elemets, for which we have the formula x!! (!

4 CHAPTER. ELEMENTARY ENUMERATION PRINCIPLES 3 by Theorem.3, so that x is obtaied immediately. Remar: The differece betwee Theorem.3 ad Theorem.4 lies i the fact that the order plays a role i the former, which is does ot i the latter. Each subset correspods to exactly! sequeces: for istace, the subset {A, E, T } of the set {A, B,..., Z} correspods to the sequeces AET, ATE, EAT, ETA, TAE, TEA. The formula for the biomial coefficiet oly maes sese if 0. This is also quite ituitive as o subset ca comprise more elemets tha the origial set. It is ofte useful to defie ( 0 if either < 0 or >. Later we will also give a more geeral defiitio of the biomial coefficiets. Example.4 The umber of six-elemet subsets of {, 2,..., 49} (Lotto is ( 49 49! 6 6! 43! Remar: A obvious property of ( is the idetity ( (, which follows immediately from the formula. However, it also has a combiatorial meaig: choosig elemets is equivalet to ot choosig elemets. The geeralisatio of this priciple leads us to the so-called multiomial coefficiet. Dividig a set ito groups Theorem.5 The umber of possibilities to divide a set X ito groups X, X 2,..., X r whose sizes are prescribed to be, 2,..., r respectively (where r is give by (!, 2,..., r! 2!... r!. Proof: By iductio o r; for r, the statemet is trivial. For r 2, oe has ( choices for the elemets of X, ad by the iductio hypothesis, (! 2! 3!... r! possible ways to divide the remaiig elemets. Therefore, we have exactly ( (! 2! 3!... r!!!(! (! 2! 3!... r!!! 2!... r! possibilities, as claimed.

5 CHAPTER. ELEMENTARY ENUMERATION PRINCIPLES 4 Choosig a multiset Theorem.6 The umber of ways to choose elemets from a set of elemets, repetitios allowed, is ( +. Proof: Let X {x, x 2,..., x } be the set. A choice is characterised by the umber of times that each of the elemets is selected. If l i deotes the multiplicity of x i i our collectio, the the problem is equivalet to determiig the umber of solutios of l + l l, where l, l 2,..., l have to be o-egative itegers. Equivaletly, we ca write m i l i + ad as for the umber of positive iteger solutios to the equatio m + m m +. (. Let us imagie + dots i a row. Each solutio to the equatio (. correspods to a way of separatig the dots by isertig bars at certai places (Figure.. Sice there are + positios for the bars, oe has ( ( + + possible ways to place the bars. Figure.: Dots ad bars. Remar: A fiite sequece m, m 2,..., m of positive itegers summig to (that is, m + m m is called a compositio of ; the above argumet ( dots ad bars shows that every positive iteger has exactly ( compositios ito summads.

6 Chapter 2 A combiatorial view of biomial coefficiets The idetity ( ( is oe of may iterestig properties of biomial coefficiets, may of which ca also be iterpreted combiatorially. I this chapter, some of these properties are cosidered. 2. The recursio Theorem 2. The biomial coefficiets satisfy the recursive formula ( ( ( + (0. Proof: The formula ca be verified easily by algebraic maipulatios: ( ( (! + (!(! + (!!(! (! ( (! +!(!!(! ( (!!!(!!(!. However, a (perhaps simpler way is to argue as follows: let x be a elemet of a - elemet set X. If oe wats to choose a subset of elemets, oe ca first decide whether to iclude x or ot. I the former case, there are ( possibilities to choose the remaiig elemets. I the latter, we have ( possible choices, which already completes the proof. Remar: Note that the equatio remais correct if oe defies ( to be 0 if either < 0 or >. A classical way to illustrate the recursio for the biomial coefficiets is Pascal s triagle: the -th lie cotais the biomial coefficiets ( (0. 5

7 CHAPTER 2. A COMBINATORIAL VIEW OF BINOMIAL COEFFICIENTS It is apparet that each umber is the sum of the two umbers above it. If oe defies the biomial coefficiet ( α for arbitrary real (or eve complex umbers α by ( α : α(α (α 2... (α +,! Theorem 2. remais correct, eve without the direct combiatorial iterpretatio. The followig lemma relates the case of egative α to the more familiar case that α is positive: Lemma 2.2 For ay real umber α ad ay o-egative iteger, oe has ( ( α α + (. Proof: ( α α( α ( α 2... ( α +! ( α(α + (α (α +! ( α + (. 2.2 The biomial theorem revisited The biomial theorem is certaily the most importat theorem that ivolves the biomial coefficiets; it ca be stated as follows: Theorem 2.3 (Biomial Theorem For ay iteger 0, oe has (x + y ( x y. Proof: The classical proof proceeds by iductio. However, it ca also be prove combiatorially: suppose that we expad the product (x + y (x + y(x + y... (x + y x x... x + y x... x +....

8 CHAPTER 2. A COMBINATORIAL VIEW OF BINOMIAL COEFFICIENTS 7 Each summad is obtaied by choosig either x or y for each of the factors. Therefore, we ed ( up with summads of the form x y, ad each of these summads occurs exactly times (which is the umber of ways to select out of factors from which a x is tae. This readily proves the theorem. Remar: It should be oted that oe usually defies 0 0 i this cotext, so that the biomial theorem remais correct eve if y 0 (ad/or x 0. The biomial theorem has a geeralisatio to the case that is ot ecessarily a positive iteger, which is ow as the biomial series: ( α ( + x α x. (2. Note that this is simply the Taylor series of ( + x α at x 0. If α 0 is a iteger, the this formula reduces to the biomial theorem, sice all terms i the ifiite sum that correspod to > are 0 by defiitio. It is possible to deduce several iterestig idetities directly from the biomial theorem, such as the followig: Theorem 2.4 Oe has the followig relatios: ( ( ( ( for ay iteger 0, ( ( for ay iteger > 0, for ay iteger > 0. eve ( 0 ( ( ( ( 0 odd ( 2 Proof: The first equatio is obtaied by settig x y i the biomial theorem, the secod equatio for x ad y. The third equatio is obtaied by addig (subtractig the first two equatios ad otig that holds. + ( { 2 eve 0 odd resp. ( { 0 eve 2 odd Remar: Let us iterpret these equatios combiatorially: the sum i the first equatio is exactly the umber of subsets of a -elemet set (sice ( couts subsets of size. Therefore, oe immediately eds up with the followig result:

9 CHAPTER 2. A COMBINATORIAL VIEW OF BINOMIAL COEFFICIENTS 8 Corollary 2.5 A -elemet set has precisely 2 distict subsets. Example 2. The set {A,E,T} has 8 subsets: {}, {A}, {E}, {T}, {A,E}, {A,T}, {E,T}, {A,E,T}. Of course, this corollary ca be obtaied without depedig o the biomial theorem: each elemet ca either be selected as a member of the subset or ot, so that oe has exactly possible optios. I this way, a subset of a -elemet set correspods directly to a 0--sequece of legth. O the other had, it follows from Theorem 2.4 that ay fiite o-empty set has exactly as may subsets of eve cardiality as of odd cardiality. This is somewhat obvious if is eve (ote the symmetry i Pascal s triagle!, but maybe a little more surprisig if is odd. However, there is agai a combiatorial proof: If we distiguish a elemet x of the set, the oe has a bijectio betwee subsets of eve cardiality ad subsets of odd cardiality: two subsets are associated to each other if their oly differece is that oe of them cotais x while the other oe does ot. I this way, we obtai 2 pairs, each of which cotais exactly oe subset of eve cardiality ad oe subset of odd cardiality. Istead of cosiderig eve or odd cardialities, let us see what happes if we restrict the cardiality of subsets to be divisible by 3: Example 2.2 We prove the followig equatio for all positive itegers : ( 3 ( (. 3 3 I order to achieve this, we would lie to use the same tric as before. Istead of pluggig i y ±, we cosider the roots of uity Oe has ζ 3 ζ 3 2 as well as ζ,2 ± i 3 2 e ±2πi/3. ζ + ζ 2 + 0, ζ 2 ζ 2 ad ζ 2 2 ζ. If we ow tae x ad y, y ζ ad y ζ 2 respectively i the biomial theorem ad add the resultig equatios, we obtai 3 l0 Now if l 3 is divisible by 3, the ( 3 ( + ζ l + ζ l l ( + ζ 3 + ( + ζ ζ l + ζ l ,

10 CHAPTER 2. A COMBINATORIAL VIEW OF BINOMIAL COEFFICIENTS 9 if l 3 +, the ad if l 3 + 2, the + ζ l + ζ l 2 + ζ + ζ 2 + ζ + ζ 2 0, + ζ l + ζ l 2 + ζ 2 + ζ + ζ 2 + ζ 0. Therefore, we ed up with ( ( + ζ 3 + ( + ζ ζ,2 ± 3i are sixth roots of uity: it is easy to chec that ( + ζ 2,2 3 (ad thus ( + ζ,2 6. So it fially follows that ( 3 ( (. 3 3 This shows that the proportio of subsets whose cardiality is a multiple of 3 is approximately (it teds to as. Let us ow have a loo at aother importat idetity 3 3 that ivolves the biomial coefficiets. 2.3 The Vadermode idetity Theorem 2.6 (Vadermode idetity For itegers N, M, 0, oe has ( ( ( N M N + M. Proof: Sums of the form a b ca be related to products of polyomials: ideed, if two polyomials A(x N a x ad B(x M l0 b lx l are give, the the product of the two is A(x B(x N M a b l x +l. The coefficiet of x is ow obtaied as the sum of those summads for which + l, or i other words l. Therefore this coefficiet is equal to a b, l0

11 CHAPTER 2. A COMBINATORIAL VIEW OF BINOMIAL COEFFICIENTS 0 where a is tae to be 0 if the degree N of the polyomial A is less tha (ad aalogously b l 0, if l > M. Similar ideas will be used extesively i Chapter 5. I this specific case, we apply the biomial theorem to the polyomial ( + x N+M that ca also be writte as the product of ( + x N ad ( + x M : ( N ( ( N M ( M ( + x N+M ( + x N ( + x M x x l l l0 N M ( ( N+M N M ( ( N M x +l x. l Comparig coefficiets with we obtai the desired idetity. l0 ( + x N+M N+M ( N + M x, Oce agai it is possible to provide a proof by coutig argumets as well: a set of N + M elemets is divided ito two groups cosistig of N ad M elemets respectively. Choosig elemets from the set is equivalet to choosig elemets from the first group ad the remaiig elemets from the secod group, where ca be ay iteger betwee 0 ad. The umber of possible choices for fixed is clearly ( ( N M. Summig over all, we obtai the total umber of choices, which is ( N+M. The followig special case of the Vadermode idetity is quite remarable: Corollary 2.7 ( 2 I a similar vei, we ca prove the followig: ( ( ( 2. Theorem 2.8 For a o-egative iteger, oe has ( { 2 ( ( ( /2 eve, /2 0 odd. Proof: We use the same type of argumet as before, comparig coefficiets i the equatio ( ( ( ( ( x ( x (+x ( x ( x 2 ( x 2.

12 CHAPTER 2. A COMBINATORIAL VIEW OF BINOMIAL COEFFICIENTS The coefficiet of x o the right had side is ( /2( /2 if is eve, ad otherwise 0. The coefficiet o the left had side obtaied by expadig the product is ( ( ( ( 2 (.

13 Chapter 3 The priciple of iclusio ad exclusio 3. A simple example A frequetly occurrig problem is to determie the size of the uio or itersectio of a umber of sets, as i the followig example: Example 3. All secod-year sciece studets may choose either mathematics, or physics, or both. The mathematics course is atteded by 50 studets, the physics course by 30 studets. 5 studets atted both courses. How may secod-year sciece studets are there? Let M be the set of studets taig mathematics ad P the set of all studets who tae physics. By our coditios, the set of all studets is the uio S M P. If we add the sizes of the two sets, all studets who atted both courses are couted twice. Therefore, we have to subtract the size of M P, which yields the formula S M P M + P M P, where X is the umber of elemets of a set X studets. Pluggig i, we fid that there are This priciple ca be geeralised to uios (or itersectios of a arbitrary umber of sets. Before we discuss the geeral formula, let us exted Example 3.: Example 3.2 Third-year sciece studets also have the opportuity to atted chemistry, but every studet has to tae at least oe of the three courses. Altogether, there are 40 studets i the mathematics class, 25 who atted physics, ad 20 who atted chemistry. Furthermore, we ow that 0 studets do both mathematics ad physics, 8 both mathematics ad chemistry, ad 7 physics ad chemistry. There are two particularly ee studets who atted all three courses. How may third-year sciece studets are there? 2

14 CHAPTER 3. THE PRINCIPLE OF INCLUSION AND EXCLUSION 3 Let M, P, C deote the respective sets of studets attedig mathematics, physics ad chemistry. Oce agai, we are looig for the size of the uio M P C. To this ed, we first add M, P ad C. Studets taig both mathematics ad physics are double-couted, so we have to subtract M P. The same applies to M C ad P C. However, those two studets that atted all the three courses are added three times ad subtracted three times as well. Hece we have to add M P C to mae up for this. Formally, we have M P C M + P + C M P M C P C + M P C. This meas that there are third-year studets. 3.2 The geeral formula The simple example preseted i the previous sectio ca be geeralized to a arbitrary umber of sets as follows: Theorem 3. (Iclusio-exclusio Let X, X 2,..., X be arbitrary fiite sets. For a set I {, 2,..., }, we deote the itersectio of all sets X i with i I by i I X i. The the followig formula holds: X i ( I + X i, (3. i I {,...,} I where the sum is tae over all o-empty subsets of {, 2,..., }. Remar: The cases 2 ad 3 correspod to our two examples; for istace, the formula X X 2 X 3 X + X 2 + X 3 X X 2 X X 3 X 2 X 3 + X X 2 X 3 is obtaied for 3. Proof: By iductio o. For, the formula reduces to the trivial idetity X X. The iductio step from to + maes use of the special case 2 that was discussed i our first example: ( + M i M i M + i i ( M i + M + M i M + i i M i + M + (M i M + i i i I

15 CHAPTER 3. THE PRINCIPLE OF INCLUSION AND EXCLUSION 4 I {,...,} I I {,...,} I I {,...,+} + I,I I {,...,+} I This completes the iductio. ( I + M i + M + i I ( I + M i + M + i I ( I + M i + i I ( I + M i. i I I {,...,+} + I I {,...,} I I {,...,} I ( I + (M i M + ( I + i I ( I + M i i I i I {+} Remar: The same formula holds true if uio ad itersectio are iterchaged (the proof beig completely aalogous: X i ( I + X i. (3.2 i I {,...,} I Remar: A commo iterpretatio of the iclusio-exclusio priciple ivolves probabilities: suppose that X, X 2,..., X are subsets of a set X of outcomes. The P (X i X i X is the probability that oe of the evets i X i occurs. Dividig formulas (3. ad (3.2 by X, we obtai ( P X i ( ( I + P X i ad i I {,...,} I ( P X i i I {,...,} I i I i I ( ( I + P X i. ( Note that P i X i is the probability that at least oe of the evets associated to ( X, X 2,... occurs, while P is the probability that all of them occur. i X i Remar: If we tae X X 2... X {x} i (3. or (3.2, the all itersectios ad uios have size, so that we obtai aother proof of the idetity ( ( ( ( ( ( 0, 0 i I M i

16 CHAPTER 3. THE PRINCIPLE OF INCLUSION AND EXCLUSION 5 see Theorem 2.4. Quite frequetly, the sets X i are subsets of some base set, ad oe is iterested i the umber of elemets that are cotaied i oe of the X i or ot i all of the X i. I the former case, oe has to determie the cardiality of X \ (X X 2... X, which is equal to X ( I + X i. (3.3 I {,...,},I The secod problem amouts to determiig the cardiality of X \ (X X 2... X, which is give by X ( I + X i. (3.4 I {,...,},I Naturally, the sizes of the sets i I X i are ot always explicitly give as i our first two examples. However, they are ofte easier to obtai tha those that oe is actually iterested i. I the followig sectio, some applicatios are discussed. i I i I 3.3 Applicatios Example 3.3 How may -digit umbers are there that do ot cotai the digits 0,, 2, but have to cotai the three digits 3, 4, 5? By the stated coditios, the digits have to be tae from the set {3, 4,..., 9}; let M (D be the umber of all -digit umbers whose digits are tae from the set D. The the set whose size we wat to determie cosists of all umbers i M ({3, 4,..., 9} that are ot cotaied i ay of M ({4, 5,..., 9}, M ({3, 5,..., 9} or M ({3, 4, 6,..., 9} (oe of the digits 3, 4, 5 may be missig. Note also that M (D M (D 2 M (D D 2. By Theorem., we have M (D D (if 0 D; otherwise, oe would have to exclude leadig zeros. Therefore, the iclusio-exclusio priciple yields M ({3, 4,..., 9} \ (M ({4, 5,..., 9} M ({3, 5,..., 9} M ({3, 4, 6,..., 9} M ({3, 4,..., 9} M ({4, 5,..., 9} M ({3, 5,..., 9} M ({3, 4, 6,..., 9} + M ({5, 6,..., 9} + M ({4, 6,..., 9} + M ({3, 6,..., 9} M ({6, 7,..., 9} Euler s totiet fuctio Example 3.4 A classical applicatio of the iclusio-exclusio priciple stems from umber theory: Euler s totiet fuctio ϕ( is defied as the umber of itegers x such that

17 CHAPTER 3. THE PRINCIPLE OF INCLUSION AND EXCLUSION 6 0 x < ad x ad do ot have a commo divisor (other tha. If p, p 2,..., p are the prime factors of, the this occurs precisely if x is ot divisible by ay of p, p 2,..., p. Note ow that the umber of itegers 0 x < that are divisible by a specific prime factor p i is exactly /p i. Liewise, if I is ay subset of {, 2,..., }, the the umber of itegers 0 x < that are divisible by all p i with i I (ad thus by their product i I p i is exactly / i I p i. Therefore, formula (3.3 yields ϕ( + I {,...,},I ( I + I {,...,},I ( I i I ( pi i i I p i The last step follows from the fact that the term i I p i occurs i the expasio of ( ( p p2... ( p p i with a coefficiet of ( I. Geerally, the product ( x i ( x ( x 2... ( x i expads to x i, I {,...,}( I i I where the product over the empty set is tae to be, while the product ( + x i ( + x ( + x 2... ( + x i is simply x i. I {,...,} i I Deragemets Example 3.5 A deragemet is a permutatio of {, 2,..., } without fixed poits; that is, the umber i does ot occur i positio i ( i. For istace, 3425 is a deragemet, but 3245 is ot (sice 2 occurs i secod positio. The umber of deragemets

18 CHAPTER 3. THE PRINCIPLE OF INCLUSION AND EXCLUSION 7 ca be determied by the iclusio-exclusio priciple: for a subset I of {, 2,..., }, let p (I be the umber of permutatios for which all elemets of I (ad possible others are fixed poits, i.e., they occur i their respective positios. The, we are looig for the umber of permutatios that belog to oe of p ({}, p ({2},.... The size of p (I is clearly ( I! (the I remaiig elemets ca be arraged i ay order, so that (3.3 yields the followig formula for the umber of deragemets:! ( I + p (I. I {,...,},I There are exactly ( subsets I of size I, ad so this reduces to (! + ( (!! + (!!! (!. Therefore, the probability that a radomly selected permutatio of {, 2,..., } is a deragemet is (! ±!. As, this value approaches the ifiite sum (! e

19 Chapter 4 Coutig by recursio May coutig problems ca be solved by settig up recursios ad solvig them. We have already ecoutered the recursive relatio that is satisfied by the biomial coefficiets. I the followig, we discuss three examples that exhibit the basic idea. The followig chapter provides a geeral method to solve recursios as they occur i the study of eumeratio problems. Example 4. We draw lies i the plae i such a way that there are o parallel lies ad o itersectios of three or more lies. These lies divide the plae ito several regios; how may such regios are there? Let us first discuss some trivial cases: if there is o lie ( 0, the there is precisely oe regio; for, there are two regios; for 2 ad 3 we obtai four ad seve regios, respectively. Oe might cojecture ow that the umber of regios icreases by + if we add a lie to existig lies. Ideed, this is the case, as the followig argumet shows. If we add a additioal lie to lies i the plae, the we obtai exactly ew poits of itersectio that divide the ew lie ito + segmets. Each of these segmets divides oe of the old regios ito two ew regios, while all other regios remai the same. Therefore, if a deotes the total umber of regios, we have the recursio a + a + ( +. A explicit form ca be deduced immediately: a a + a ( a ( + ( 2... a ( + ( a 0 + ( by the well-ow formula for the sum , which solves the problem. Example 4.2 Tom gets a allowace of R00 every moth, which he speds etirely o ice cream (R5, chocolate (R0 or cooies (R0. Every day, he buys exactly oe of these 8

20 CHAPTER 4. COUNTING BY RECURSION 9 util he rus out of moey. I how may possible ways ca Tom sped his moey? His older brother Phil gets a allowace of R50, which he also speds o ice cream, chocolate ad cooies oly. How may possible ways does he have? We study a more geeral problem: if the allowace is 5 ( ay positive iteger; ote that the prices are all divisible by R5, how may ways are there? Let this umber be deoted by a ; the it is easy to see that a ad a 2 3. Next we deduce a recursio for a : the first thig that Tom buys ca be either ice cream (so that he is left with 5( ad has a possibilities for the rest or chocolate or cooies (i each of these cases, the remaiig amout is 5( 2, so that he is left with a 2 possibilities. This shows that a a + 2a 2 holds. Note that this eve remais true if we set a 0 (without moey, there is oly oe optio, which is to buy othig at all. Oe obtais the followig sequece: A explicit formula is give by a a 3 ( (, which ca be prove by meas of iductio. A method to determie such a explicit formula from a recursio will be discussed i the followig chapter. Pluggig i 20 ad 30 respectively, we fid that Tom has optios, while Phil has differet ways to sped his moey. Our fial example leads to the famous Fiboacci umbers: Example 4.3 All the houses o oe side of a certai street are to be paited either yellow or red. I how may ways ca this be doe if there are houses ad there may ot be two red houses ext to each other? Let a be the umber that we wat to determie. We distiguish two cases: If the first house is paited yellow, the the remaiig houses ca be paited i ay of the feasible a ways, the first house ca be eglected. If the first house is paited red, the the secod house must be paited yellow. Usig the same argumet as before, we see that there are a 2 possibilities for the remaiig houses. Hece we have the recursio a a + a 2 with iitial values a 2 ad a 2 3. This yields the sequece 2, 3, 5, 8, 3, 2, 34, 55, 89,... of so-called Fiboacci umbers. They are usually defied by f 0 0, f ad f f + f 2 ; it is easy to see that a f +2 i our example. There is also a explicit formula for the Fiboacci umbers, see the followig chapter.

21 Chapter 5 Geeratig fuctios 5. Solvig recursios Geeratig fuctios provide a method to solve recursios, but they are actually much more versatile, as we will see later. We associate a power series A(x a x to ay sequece a 0, a,... of real (or complex umbers; i the cotext of combiatorics, the coefficiets a are typically itegers. The -th coefficiet of such a power series A(x is also writte as a [x ]A(x. For ow, we do ot care too much about covergece ad mostly regard geeratig fuctios as formal objects. A typical example of a geeratig fuctio is the geometric series qx q x, which is the geeratig fuctio of a geometric sequece, q, q 2, q 3,.... I particular, the geeratig fuctio of,,,... is. As a first example of the use of geeratig x fuctios, let us discuss the recursio a a + 2a 2 with iitial vales a 0 a that we ecoutered i the previous chapter. If A(x deotes the associated geeratig fuctio, the we obtai A(x a x a 0 + a x + + x + 2 (a + 2a 2 x 2 a x + 2 a 2 x 20 2

22 CHAPTER 5. GENERATING FUNCTIONS 2 Solvig for A(x, we fid which ca also be writte as + x + a x a x +2 + x + x(a(x a 0 + 2x 2 A(x. A(x x 2x 2, A(x 2/3 2x + /3 + x, maig use of partial fractios. We expad the two summads ito geometric series to obtai A(x 2 2 x + ( x ( x, so that we ca simply read off the coefficiets: a [x ]A(x 2+ +(, as claimed. I 3 the very same style, oe fids Biet s formula for the Fiboacci umbers, whose geeratig fuctio is x : x x 2 f 5 (( + ( (5. for ay 0. The method ca actually be geeralised to the etire class of liear recursios, whose geeral form is a c a + c 2 a c r a r. To see how such a recursio ca be solved for arbitrary coefficiets c, c 2,..., c r, we eed the followig lemma: Lemma 5. The power series associated to the fuctio ( qx ( qx ( + q x. Proof: Combie the biomial series (2. with Lemma 2.2 to obtai ( qx ( ( qx ( ( + ( qx is give by Note that for fixed, ( + is a polyomial (i of degree : ( + ( + ( ( +, (! ( + q x.

23 CHAPTER 5. GENERATING FUNCTIONS 22 for istace ( + +, ( ( + 2( ,... Now we are ready to prove the followig theorem: Theorem 5.2 The geeral solutio of a liear recursio of the form is give by a c a + c 2 a c r a r a s P i (qi, i where q, q 2,..., q s are the (possibly complex solutios of the characteristic equatio q r c q r + c 2 q r c r ad P (, P 2 (,..., P s ( are polyomials. The degree of P i is strictly less tha the multiplicity of q i as a solutio of the characteristic equatio (that is, the umber of times the factor q q i occurs i the factorisatio of the polyomial q r c q r c 2 q r 2... c r. Proof: Let A(x a x be the geeratig fuctio of the sequece a 0, a,.... The we have r A(x a x + r a x + r a x + r a x + r a x + r a x + a x r (c a + c 2 a c r a r x r r j r j c j c j r r j a j x a x +j ( r c j a x +j j r c j x j A(x j r j r j r j c j a x +j a x +j. Now write r N(x a x r j r j c j a x +j

24 CHAPTER 5. GENERATING FUNCTIONS 23 ad D(x r c j x j. Both N(x ad D(x are polyomials; solvig the equatio for A(x gives A(x N(x D(x, so that A(x is ivariably a ratioal fuctio. Now factor the deomiator: j D(x ( q x l ( q 2 x l 2... ( q s x ls Note that a factor ( q i x l i i the factorisatio occurs if ad oly if D( q i 0, which is equivalet to r r 0 c j q j i q (q r r c j q r j i, j i.e., q i is a solutio of the characteristic equatio. The multiplicity of q i as a solutio is precisely the expoet l i. Now expad the geeratig fuctio A(x ito partial fractios: j a x A(x s l i K ij ( q i x. j i j We ca apply Lemma 5. to each of the summads to obtai a x ad comparig coefficiets yields s l i i j K ij ( + j qi x, j a s i ( li j ( + j K ij qi j s P i (qi i for certai polyomials P i whose degree is less tha l i (the highest degree that occurs is that of ( +l i l i, which is li. This proves the theorem. Kowig the geeral form of a solutio, oe ca solve a recursio by meas of the method of udetermied coefficiets without traslatig it to the world of geeratig fuctios; this is exhibited i the followig example: Example 5. Suppose we wat to determie a explicit formula for the sequece that is defied by a 5a 3a 2 9a 3 with iitial values a 0, a ad a 2 5.

25 CHAPTER 5. GENERATING FUNCTIONS 24 The characteristic equatio is q 3 5q 2 + 3q + 9 (q 3 2 (q + 0, so that q 3 ad q 2, the multiplicities beig 2 ad respectively. Therefore, Theorem 5.2 shows that the solutio must have the form a (A + B3 + C(. Pluggig i 0,, 2 yields the system of equatios B + C, 3A + 3B C, 8A + 9B + C 5, which leads to the solutio A, B 3, C 5, so that fially a 4A (. 8 Theorem 5.2 actually oly treats the homogeeous case; the method ca be exteded to o-homogeeous recursios of the form a c a + c 2 a c r a r + b, the oly differece beig the o-homogeeous term b. geeratig fuctio of b, the oe obtais If B(x b x is the A(x N(x + B(x D(x as i the proof of Theorem 5.2. If the o-homogeous term is of the form Q(q for a polyomial Q, the oe ca deduce a explicit formula for a oce agai (the proof beig similar to that of Theorem 5.2: Theorem 5.3 Suppose that b Q(q, where Q is a polyomial of degree d. If q is ot a solutio of the characteristic equatio, the the solutio of the liear recursio is of the form a c a + c 2 a c r a r + b a s P i (qi + P (q, i where q, q 2,..., q s are the (possibly complex solutios of the characteristic equatio q r c q r + c 2 q r c r ad P (, P 2 (,..., P s (, P ( are polyomials. The degree of P i is strictly less tha the multiplicity of q i as a solutio of the characteristic equatio, ad the degree of P ( is d.

26 CHAPTER 5. GENERATING FUNCTIONS 25 If, o the other had, q is a solutio of the characteristic equatio (without loss of geerality, q q, the the solutio has the form a s P i (qi, i q, q 2,..., q s ad P (, P 2 (,..., P s ( as before, except for the degree of P, which is equal to the multiplicity of q plus the degree of Q. A sum of o-homogeeous terms of this form gives rise to a sum i the solutio; let us discuss a modified versio of Example 5. to exhibit the method: Example 5.2 Suppose we wat to determie a explicit formula for the sequece that is defied by a 5a 3a 2 9a with iitial values a 0, a ad a 2 5. The summad ca be iterpreted as (4 + 4 ad gives rise to a liear term A+B i the solutio; sice 3 is a double solutio of the characteristic equatio ad 4 3 occurs i the o-homogeeous term, we must have a summad (C 2 + D + E 3 i the solutio; fially, is a solutio of the characteristic equatio, so that we ed up with Pluggig ito the recursio yields a A + B + (C 2 + D + E 3 + F (. A + B + (C 2 + D + E 3 + F ( 5 ( A( + B + (C( 2 + D( + E 3 + F ( 3 ( A( 2 + B + (C( D( 2 + E F ( 2 9 ( A( 3 + B + (C( D( 3 + E F ( ad after collectig terms ( 8 3 C (8A 4 + ( 28A + 8B 4 0. Therefore, we have A, B 9 ad C 3. Fially, the iitial values ca be used to determie D, E, F, ad the solutio is foud to be a ( ( (.

27 CHAPTER 5. GENERATING FUNCTIONS 26 Remar: The parts that belog to a solutio of the homogeeous equatio ca be left out i the first step (i the example above, this meas that oe simply plugs i A+B +C 2 3 ito the recursio formula, sice the other parts have to cacel ayway. This priciple ca be stated as follows: the geeral solutio of a o-homogeeous recursio is the sum of a particular solutio ad the solutio to the homogeeous equatio (compare this to liear differetial equatios!. 5.2 Geeral rules for geeratig fuctios Before we tur to more advaced applicatios of geeratig fuctios, let us describe the effect that certai operatios o sequeces have o the geeratig fuctio level. Theorem 5.4 If {a } ad {b } ( 0 are sequeces ad A(x ad B(x their associated geeratig fuctios, the. the sequece c a + b has geeratig fuctio C(x A(x + B(x, 2. the sequece c a b has geeratig fuctio C(x A(x B(x, 3. the sequece c αa has geeratig fuctio C(x αa(x (α ay costat, 4. the sequece c { a m m, 0 otherwise, has geeratig fuctio C(x x m A(x, 5. the sequece c a +m has geeratig fuctio C(x A(x m a x x m, 6. the sequece c a has geeratig fuctio C(x xa (x, 7. the sequece c { a > 0, 0 otherwise, has geeratig fuctio C(x x 0 A(t a 0 t dt, 8. the sequece c a has geeratig fuctio C(x A(x x. Proof: Each of the statemets ca be obtaied by simple arithmetic:

28 CHAPTER 5. GENERATING FUNCTIONS C(x C(x C(x (a + b x C(x a b x a x + b x A(x + B(x. a b x a x b x ( ( a x b l x l a x b l x l A(x B(x. l0 C(x a m x m a +m x l0 αa x α a x αa(x. a x +m x m a x m x m m m C(x a x x a x d x a dx x x d dx C(x a x C(x x a t dt a x 0 a x x x 0 a x x m A(x. a x A(x m a x x m. a t dt a x a x a a x xa (x. x 0 x + x A(x x. A(x a 0 t dt.

29 CHAPTER 5. GENERATING FUNCTIONS 28 Remar: Geeratig fuctios ca be regarded as formal objects without cosiderig covergece. The sum, differece, product or quotiet of two power series is a power series agai (for the quotiet, oe has to assume that the deomiator has a o-zero costat coefficiet. For istace, oe ca formally multiply (a 0 +a x+a 2 x (b 0 +b x+b 2 x a 0 b 0 +(a b 0 +a 0 b x+(a 0 b 2 +a b +a 2 b 0 x or divide a 0 + a x + a 2 x b 0 + b x + b 2 x c 0 + c x + c 2 x , where the coefficiets c 0, c, c 2,... ca be foud by comparig coefficiets i the idetity (b 0 + b x + b 2 x (c 0 + c x + c 2 x a 0 + a x + a 2 x , so that c 0 a 0 b 0, c a b 0 a 0 b, etc. b 2 0 A applicatio of rule 2. for products of geeratig fuctios was give i Sectio 2.3 (Vadermode idetity; let us ow discuss a applicatio of the last rule for cumulative sums, which is a extesio of Example 4.2: Example 5.3 Tom decides that he might ot sped his etire allowace of R00 ad perhaps save some part of it istead. How may ways does he have ow to sped his moey? I this settig, Tom ca sped othig, or R5, R0,..., R00. Geerally, if his allowace is 5 ( ay o-egative iteger, the the amout that he speds is of the form 5, 0 ; if a deotes the umber of ways to sped exactly 5 Rad, the the umber of ways to sped at most 5 is exactly c a. Recall that the geeratig fuctio of a is A(x. Therefore, Theorem 5.4 shows x 2x 2 that the geeratig fuctio of c is C(x. Maig use of ( x( x x 2 ( x(+x( 2x partial fractios oce agai, we fid C(x 4 3( 2x 2( x + 6( + x ad thus c [x ]C(x (. I particular, if 20 (which correspods to a amout of R00, the this umber is 3980.

30 CHAPTER 5. GENERATING FUNCTIONS Noliear recursios While liear recursios are usually solved more quicly by meas of the method of udetermied coefficiets, geeratig fuctios are actually far more versatile ad ca be applied to may o-liear recursios as well (which the method of udetermied coefficiets ca ot. I this sectio, we treat two such examples. Example 5.4 We wat to cout the umber of stacs that ca be formed from cotiguous rows of cois i such a way that (from the secod row o every coi touches the two cois below it, where the umber of cois i the first row is (see Figure 5., which illustrates the case 3. Figure 5.: Differet stacs i the case 3. Let a deote the umber of cofiguratios with cois i the bottom row. Each such cofiguratio that is ot just a sigle row of cois is obtaied by placig a cofiguratio whose bottom row cosists of cois i ay of possible positios (there are available positios for cois altogether, so the first of the cois ca be i either the first, or the secod,..., or the ( -th of these positios, where ca be ay umber betwee ad. This results i the recursio a + ( a for > (with the iitial value a. For coveiece, we set a 0 0 ad rewrite this recursio as a + ( a. Let A(x be the geeratig fuctio of the sequece a ; ote that ( a is the -th coefficiet i the product of A(x ad x x d dx x x d dx x x ( x. 2

31 CHAPTER 5. GENERATING FUNCTIONS 30 Therefore, we obtai the equatio A(x x x + ( x A(x x 2 x + x ( x A(x. 2 Solvig for A(x, we fid x( x A(x 3x + x. 2 If oe computes the first few elemets of the sequece, oe fids a 2 2, a 3 5, a 4 3, a 6 34,.... Oe otices that all of these umbers are Fiboacci umbers. Ideed, oe ca show that a f 2, where f deotes the -th Fiboacci umber as i Example 4.3: f 0 0, f,.... Oe possibility to prove the idetity is to determie a explicit formula for a from the geeratig fuctio (by meas of partial fractios ad compare it to Biet s formula (5.. However, we will go aother way: if F (x f x x x x 2 deotes the geeratig fuctio for the Fiboacci umbers, the we fid the geeratig fuctio for the odd-idexed Fiboacci umbers by the same method that was also applied i the proof of Theorem 2.4: f x odd ( ( f x f x 2 2 f ( x which shows that f 2 x 2 ( x 2 x x x 2 + x x 2 thus ad fially f 2 x 2 x2 ( x 2 3x 2 + x 4 f 2 x x( x 3x + x 2 x( x2 3x 2 + x 4, F (x F ( x, 2 upo replacig x 2 by x, which is exactly the geeratig fuctio A(x that we foud before. The followig example itroduces the Catala umbers, which will be treated i more detail i Sectio 7.. Example 5.5 Cosider 2 poits o a circle. How may ways are there to coect them by lies such that there are o poits of itersectio (ad each poit is coected to exactly oe other poit? Figure 5.2 shows all cofiguratios i the case 3 (thi of 2 people shaig hads.

32 CHAPTER 5. GENERATING FUNCTIONS 3 Figure 5.2: Coectig six poits o a circle. Let the poits be umbered from to 2. If poit is coected to poit, this leaves two groups of sizes 2 ad that caot be coected ay more; therefore, 2l must be eve. Now each of the two groups ca be treated separately. If a deotes the umber of possibilities, the we obtai the recursio a a l a l, l the iitial value beig a 0. Oce agai, we wat to traslate this to a fuctioal equatio for the geeratig fuctio A(x. Note that a l a l l m0 a m a m is exactly the coefficiet of x i A(x 2, which is the coefficiet of x i xa(x 2. Therefore, A(x xa(x 2 +, where the last summad taes the iitial value ito accout. Solvig the quadratic equatio, we fid A(x 4x. 2x The egative sig has to be chose to mae sure that A(0 a 0, as it should be. How ca this be tured ito a formula for the coefficiets a? Recall the biomial series (2. that we ca apply ow (i the specific case α : 2 A(x 4x 2x 2x 2x ( 4x/2 2x 2x ( /2 ( 4x

33 CHAPTER 5. GENERATING FUNCTIONS 32 ( /2 ( 4x 2x 2 ( /2 ( 4 m+ x m, 2 m + m0 which shows that a [x ]A(x 2 follows: 2 ( /2 ( 4 x ( /2 + ( 4 + ; however, this ca be simplified as ( /2 ( 4 + (/2 ( /2 ( 3/2 (/2 ( ( +! 2 2 ( 3 (2 ( 4 + ( +! 2 3 (2 2 (2! ( +! ( +! (2 2 (2! ( +! 2 2 (2! ( +!! + ( 2. The umbers +( 2 are ow as Catala umbers; the first few elemets of the sequece are a, a 2 2, a 3 5, a 4 4.

34 Chapter 6 The symbolic method The detour via recursios is ofte ot ecessary if oe wats to obtai the geeratig fuctio for a certai family of combiatorial objects; the symbolic method that will be preseted i this chapter wors for may importat combiatorial structures, such as words, permutatios, compositios, trees, ad may others, that also play a frequet role i computer sciece ad other scieces. 6. Ulabelled structures We cosider combiatorial structures that are made up of certai atoms. The size of such a object is defied as the umber of its atoms. For istace, the atoms of a word over a give alphabet are its letters, ad the size is its legth. For a tree (a commo data structure, see Figure 6., a ode is a atom, ad the size is the umber of odes, ad there are may other examples. If there are a elemets of size i a certai family A of combiatorial objects, the the associated geeratig fuctio is A(x a x. Figure 6.: A simple biary tree. 33

35 CHAPTER 6. THE SYMBOLIC METHOD 34 Example 6. Let us start with a trivial example: piles of cois. The atoms are the cois, ad the size of a pile is its height (the umber of cois; if the cois are idistiguishable, the there is exactly oe pile of every o-egative iteger size (if we cosider the empty pile of size 0 as well, so that the family P of piles ca be described as P {,,,,...}, where deotes a atom (a sigle coi, ad the associated geeratig fuctio is P (x x x. There are certai atural trasformatios that ca be performed o families of combiatorial objects: Uios If A ad B are disjoit families of combiatorial objects, the their uio A B cosists of all objects that are elemets of either A or B, ad it is obvious that the associated geeratig fuctio is A(x + B(x. The empty family (that does ot cotai aythig at all has associated geeratig fuctio 0 ad acts as the eutral elemet i this regard. Pairs If A ad B are families of combiatorial objects (ot ecessarily disjoit, the we ca form pairs (A, B of objects A A ad B B. The family of all such pairs is typically deoted by A B (Cartesia product of sets. The size of a pair (A, B is the sum of the sizes of A ad B, so if a pair (A, B is to have size, the the sizes of A ad B have to be ad respectively, where is ay iteger betwee 0 ad. Therefore, if a (b deotes the umber of elemets i A (B, respectively whose size is, ad c deotes the umber of pairs of size, we fid c a b, which is exactly the coefficiet of x i the product of the associated geeratig fuctios. Therefore, the geeratig fuctio for the family A B is exactly A(x B(x. Of course, this priciple ca be geeralised to triples, quadruples, etc. The family E that oly cotais oe object ϵ (of size 0 has geeratig fuctio ad acts as the eutral elemet. Sequeces This builds o the ideas of the previous costructio; if A is ay family, the A A is the family of pairs, A A A the family of triples, etc. altogether, we obtai the set of all fiite sequeces of elemets of A. If we iclude the empty sequece ϵ as a elemet of size 0, the we obtai the specificatio for sequeces Seq(A as follows: B Seq(A {ϵ} A (A A (A A A...

36 CHAPTER 6. THE SYMBOLIC METHOD 35 This traslates to the world of geeratig fuctios as follows: B(x + A(x + A(x 2 + A(x A(x. Here, A itself must be assumed ot to cotai elemets of size 0 to avoid redudacies. Oe ca also cosider restricted sequeces: for istace, A(x is the geeratig fuctio for sequeces of legth (for which we write Seq, + A(x + A(x 2 + A(x A(x A(x+ A(x is the geeratig fuctio for sequeces of size at most (deoted Seq, ad A(x + A(x + + A(x A(x A(x is the geeratig fuctio for sequeces of size at least (deoted Seq. Example 6.2 Recall from Chapter that a compositio of is a fiite sequece of positive itegers addig up to, such as , which is a compositio of 9. The geeratig fuctio for positive itegers I is obviously x + x 2 + x x x, ad so the geeratig fuctio for compositios C Seq(I is C(x x x x 2x Now we ca mae use of the geometric series oce agai: x 2x ( + ( + 2 x 2 2x x, which shows that there are exactly 2 compositios of if, a result that ca also obtaied by the dots ad bars argumet. If we are iterested i compositios of legth, the we fid the geeratig fuctio to be ( x x x ( x x ( x ( + x + ( x by virtue of Lemma 2.2. Therefore, the umber of compositios of legth of a positive iteger is give by ( (, compare Theorem.6 ad the remar thereafter. Compositios ito restricted sets of itegers ca be cosidered as well: for istace, if oly summads ad 2 are allowed, the the associated family is Seq({, 2}, ad the geeratig fuctio is, which yields yet aother iterpretatio of the Fiboacci umbers. x x 2

37 CHAPTER 6. THE SYMBOLIC METHOD 36 Example 6.3 Cosider words over the simple alphabet A {a, b}. The we ca regard a ad b as our atoms, so that the geeratig fuctio is simply A(x 2x. The family W of words over A is ow specified by W Seq(A Seq({a, b}, so that the geeratig fuctio is W (x (i accordace with the fact that there 2x are 2 words of legth, see Theorem.. For a geeral fiite alphabet of size, the associated geeratig fuctio for words is. x Let us ow cosider a restricted family of words: oly a-b-words that do ot cotai two adjacet letters b are allowed. Such a word starts with a arbitrary (possibly empty sequece of a s, followed by a b, followed by a o-empty sequece of a s, followed by a b, followed by aother o-empty sequece of a s, etc. After the last sequece of a s, we may attach either oe more b or othig at all. This leads to the specificatio Seq({a} Seq({b} Seq ({a} {ϵ, b}, where ϵ deotes a empty word (of legth 0. This ca be traslated to the geeratig fuctio x ( + x + x x2 x x, 2 x ad we fid that the umber of such words is a Fiboacci umber (ote that this example is essetially equivalet to Example 4.3. Example 6.4 How may differet ways are there to put 50 teis balls ito 5 boxes, if the first box ca oly hold at most 9 balls ad the secod box at most 7 balls? While the iclusio-exclusio priciple could be used for this purpose, geeratig fuctios are somewhat faster. If stads for a sigle ball, the our situatio is equivalet to the specificatio Seq 9 ({ } Seq 7 ({ } Seq({ } Seq({ } Seq({ }, for which the geeratig fuctio is x 0 x ( 3 x8 x x8 x 0 + x 8 x ( x 5 we are iterested i the coefficiet of x 50, which is [x 50 ] x8 x 0 + x 8 [x 50 ] ( x 5 ( x x 8 5 [x50 ] ( x x 0 5 [x50 ] ( x + x 8 5 [x50 ] ( x 5 [x 50 ] ( x 5 [x42 ] ( x 5 [x40 ] ( x + 5 [x32 ] ( x 5

38 CHAPTER 6. THE SYMBOLIC METHOD 37 i view of Theorem 5.4. Now, Lemma 2.2 ca be applied to fid that this umber is ( ( ( ( ( ( ( ( ( ( ( ( The followig costructios are somewhat more advaced, but they ofte prove useful as well: Powersets The powerset PSet(A of A cosists of all subsets of A; if the size of a subset is the sum of the sizes of all its elemets (as i the case of sequeces, the we fid that PSet(A A A{A, ϵ}, sice every elemet A ca either be preset or ot; if a is the umber of elemets i A of size (assume that a 0 0, the we fid that the geeratig fuctio of B PSet(A is ( B(x ( + z a exp a log( + z ( ( ( m ( m exp a m zm exp a z m m m m ( ( ( m exp m A(zm exp A(x A(x2 + A(x3..., 2 3 m maig use of the Taylor series for the logarithm. Multisets Multisets MSet(A are closely related to the powerset costructio; we cosider collectios of elemets of A, where each elemet is allowed to occur more tha oce as well. This is equivalet to the formal expressio MSet(A A A Seq({A}, which leads to the followig geeratig fuctio for B MSet(A: ( B(x ( z a exp a log( z

39 CHAPTER 6. THE SYMBOLIC METHOD 38 exp exp ( a m zm m ( m m A(zm exp ( m m a z m ( exp A(x + A(x2 + A(x Example 6.5 Formally, a laguage is a collectio of distict words (this otio of a laguage plays a role i computer sciece. If a alphabet A of letters is give, how may laguages are there that cotai a total umber of letters? The accordig specificatio is L PSet(Seq (A, givig rise to the geeratig fuctio ( L(x exp m ( m m x m x m ( + x. While oe caot derive a closed formula from this geeratig fuctio, it ca be used to determie the first few coefficiets (the sequece starts l 2, l 2 5, l 3 6, l 4 42,... i the case 2, ad further iformatio about the coefficiets (i particular, their growth ca be extracted by meas of aalytic methods (which are beyod the scope of this course. 6.2 Labelled structures I may istaces, oe is iterested i structures where the atoms are labelled: if a structure cosists of atoms, the these atoms receive distict labels from to. The most typical example are permutatios: a permutatio of ca be regarded as a sequece of atoms bearig labels from to ; the 6 3! permutatios of {, 2, 3} (see Theorem.2 are thus { 2 3, 3 2, 2 3, 2 3, 3 2, 3 2 }. I the cotext of labelled structures, it is useful to wor with expoetial geeratig fuctios: if a is a sequece, the its expoetial geeratig fuctio is defied by A(x a! x. The expoetial geeratig fuctio associated to permutatios is thus!! x x x, sice there are! permutatios of {, 2,..., }. Note that, o the other had, the ordiary geeratig fuctio!x is ot a elemetary fuctio, ad it is eve diverget for

40 CHAPTER 6. THE SYMBOLIC METHOD 39 all x 0. The ame expoetial is due to the fact that the expoetial geeratig fuctio of the sequece,,... is e x (the associated structure is sometimes called urs : a ur is merely a collectio of atoms labelled to (thi of balls mared with these labels without additioal structure. Example 6.6 I how may ways ca oe form cycles of the umbers, 2,...,? Figure 6.2 shows all possibilities i the case 4; geerally, if oe starts at, the there are (! possible orders for the remaiig umbers. Therefore, the associated expoetial geeratig fuctio is (! x! x log( x Figure 6.2: All cycles of legth 4. For istace, oe ca thi of these cycles as eclaces made of four beads i differet colours. Agai, there are several useful trasformatios o families of labelled objects: Uios As i the case of ulabelled structures, oe ca defie the uio of two disjoit families A ad B, ad the associated geeratig fuctio is exactly the sum of the geeratig fuctios of A ad B. Pairs The situatio is slightly differet to the ulabelled case, sice a ordiary pair of labelled objects does ot costitute a proper labelled object agai (sice labels are duplicated. If

41 CHAPTER 6. THE SYMBOLIC METHOD 40 oe combies two labelled object A ad B of sizes ad respectively to form a ew object of size, the oe first has to distribute the labels amog the two objects, which ca be doe i ( ways (choose the labels that are give to A. Therefore, if two families A ad B with expoetial geeratig fuctios A(x a! ad B(x b! are give, the the umber of pairs of size that ca be formed i this way is c which ca be rewritte as ( a b c! a!!!(! a b, b (!. Note that this is exactly the coefficiet of x i the product A(x B(x, so that the geeratig fuctio of the family C A B of pairs is exactly A(x B(x. This fact is oe of the mai reasos why expoetial geeratig fuctios are used i this cotext. Sequeces As i the case of ulabelled structure, oe ca exted the above reasoig to triples, quadruples, etc. Geerally, sequeces of legth of elemets from a family A with expoetial geeratig fuctio A(x have expoetial geeratig fuctio A(x (we deote this family by Seq (A, ad the expoetial geeratig fuctios for sequeces Seq (A of legth at most ad sequeces Seq (A of legth at least are A(x + A(x ad A(x A(x respectively. Arbitrary sequeces Seq(A have expoetial geeratig fuctio A(x. Example 6.7 Words over a alphabet of size ca also be regarded as labelled objects, amely sequeces of urs (the i-th ur records the positios i the word where the i-th letter occurs of legth. Therefore, the expoetial geeratig fuctio is (e x e x! x, i agreemet with the fact that there are words of legth. Sets Sets of elemets from a family A of combiatorial objects are somewhat easier to hadle i the labelled case tha i the ulabelled oe. This is due to the fact that objects are ow distiguishable by their labels: to every set of objects (amog which the labels

Math 155 (Lecture 3)

Math 155 (Lecture 3) Math 55 (Lecture 3) September 8, I this lecture, we ll cosider the aswer to oe of the most basic coutig problems i combiatorics Questio How may ways are there to choose a -elemet subset of the set {,,,

More information

Lecture Overview. 2 Permutations and Combinations. n(n 1) (n (k 1)) = n(n 1) (n k + 1) =

Lecture Overview. 2 Permutations and Combinations. n(n 1) (n (k 1)) = n(n 1) (n k + 1) = COMPSCI 230: Discrete Mathematics for Computer Sciece April 8, 2019 Lecturer: Debmalya Paigrahi Lecture 22 Scribe: Kevi Su 1 Overview I this lecture, we begi studyig the fudametals of coutig discrete objects.

More information

A sequence of numbers is a function whose domain is the positive integers. We can see that the sequence

A sequence of numbers is a function whose domain is the positive integers. We can see that the sequence Sequeces A sequece of umbers is a fuctio whose domai is the positive itegers. We ca see that the sequece,, 2, 2, 3, 3,... is a fuctio from the positive itegers whe we write the first sequece elemet as

More information

Math 475, Problem Set #12: Answers

Math 475, Problem Set #12: Answers Math 475, Problem Set #12: Aswers A. Chapter 8, problem 12, parts (b) ad (d). (b) S # (, 2) = 2 2, sice, from amog the 2 ways of puttig elemets ito 2 distiguishable boxes, exactly 2 of them result i oe

More information

Complex Numbers Solutions

Complex Numbers Solutions Complex Numbers Solutios Joseph Zoller February 7, 06 Solutios. (009 AIME I Problem ) There is a complex umber with imagiary part 64 ad a positive iteger such that Fid. [Solutio: 697] 4i + + 4i. 4i 4i

More information

Math 172 Spring 2010 Haiman Notes on ordinary generating functions

Math 172 Spring 2010 Haiman Notes on ordinary generating functions Math 72 Sprig 200 Haima Notes o ordiary geeratig fuctios How do we cout with geeratig fuctios? May eumeratio problems which are ot so easy to hadle by elemetary meas ca be solved usig geeratig fuctios

More information

Sequences, Mathematical Induction, and Recursion. CSE 2353 Discrete Computational Structures Spring 2018

Sequences, Mathematical Induction, and Recursion. CSE 2353 Discrete Computational Structures Spring 2018 CSE 353 Discrete Computatioal Structures Sprig 08 Sequeces, Mathematical Iductio, ad Recursio (Chapter 5, Epp) Note: some course slides adopted from publisher-provided material Overview May mathematical

More information

Sequences A sequence of numbers is a function whose domain is the positive integers. We can see that the sequence

Sequences A sequence of numbers is a function whose domain is the positive integers. We can see that the sequence Sequeces A sequece of umbers is a fuctio whose domai is the positive itegers. We ca see that the sequece 1, 1, 2, 2, 3, 3,... is a fuctio from the positive itegers whe we write the first sequece elemet

More information

( ) GENERATING FUNCTIONS

( ) GENERATING FUNCTIONS GENERATING FUNCTIONS Solve a ifiite umber of related problems i oe swoop. *Code the problems, maipulate the code, the decode the aswer! Really a algebraic cocept but ca be eteded to aalytic basis for iterestig

More information

Let us consider the following problem to warm up towards a more general statement.

Let us consider the following problem to warm up towards a more general statement. Lecture 4: Sequeces with repetitios, distributig idetical objects amog distict parties, the biomial theorem, ad some properties of biomial coefficiets Refereces: Relevat parts of chapter 15 of the Math

More information

Week 5-6: The Binomial Coefficients

Week 5-6: The Binomial Coefficients Wee 5-6: The Biomial Coefficiets March 6, 2018 1 Pascal Formula Theorem 11 (Pascal s Formula For itegers ad such that 1, ( ( ( 1 1 + 1 The umbers ( 2 ( 1 2 ( 2 are triagle umbers, that is, The petago umbers

More information

Chapter 7 COMBINATIONS AND PERMUTATIONS. where we have the specific formula for the binomial coefficients:

Chapter 7 COMBINATIONS AND PERMUTATIONS. where we have the specific formula for the binomial coefficients: Chapter 7 COMBINATIONS AND PERMUTATIONS We have see i the previous chapter that (a + b) ca be writte as 0 a % a & b%þ% a & b %þ% b where we have the specific formula for the biomial coefficiets: '!!(&)!

More information

Section 5.1 The Basics of Counting

Section 5.1 The Basics of Counting 1 Sectio 5.1 The Basics of Coutig Combiatorics, the study of arragemets of objects, is a importat part of discrete mathematics. I this chapter, we will lear basic techiques of coutig which has a lot of

More information

4 The Sperner property.

4 The Sperner property. 4 The Sperer property. I this sectio we cosider a surprisig applicatio of certai adjacecy matrices to some problems i extremal set theory. A importat role will also be played by fiite groups. I geeral,

More information

(ii) Two-permutations of {a, b, c}. Answer. (B) P (3, 3) = 3! (C) 3! = 6, and there are 6 items in (A). ... Answer.

(ii) Two-permutations of {a, b, c}. Answer. (B) P (3, 3) = 3! (C) 3! = 6, and there are 6 items in (A). ... Answer. SOLUTIONS Homewor 5 Due /6/19 Exercise. (a Cosider the set {a, b, c}. For each of the followig, (A list the objects described, (B give a formula that tells you how may you should have listed, ad (C verify

More information

(A sequence also can be thought of as the list of function values attained for a function f :ℵ X, where f (n) = x n for n 1.) x 1 x N +k x N +4 x 3

(A sequence also can be thought of as the list of function values attained for a function f :ℵ X, where f (n) = x n for n 1.) x 1 x N +k x N +4 x 3 MATH 337 Sequeces Dr. Neal, WKU Let X be a metric space with distace fuctio d. We shall defie the geeral cocept of sequece ad limit i a metric space, the apply the results i particular to some special

More information

NICK DUFRESNE. 1 1 p(x). To determine some formulas for the generating function of the Schröder numbers, r(x) = a(x) =

NICK DUFRESNE. 1 1 p(x). To determine some formulas for the generating function of the Schröder numbers, r(x) = a(x) = AN INTRODUCTION TO SCHRÖDER AND UNKNOWN NUMBERS NICK DUFRESNE Abstract. I this article we will itroduce two types of lattice paths, Schröder paths ad Ukow paths. We will examie differet properties of each,

More information

Solutions to Final Exam

Solutions to Final Exam Solutios to Fial Exam 1. Three married couples are seated together at the couter at Moty s Blue Plate Dier, occupyig six cosecutive seats. How may arragemets are there with o wife sittig ext to her ow

More information

Enumerative & Asymptotic Combinatorics

Enumerative & Asymptotic Combinatorics C50 Eumerative & Asymptotic Combiatorics Notes 4 Sprig 2003 Much of the eumerative combiatorics of sets ad fuctios ca be geeralised i a maer which, at first sight, seems a bit umotivated I this chapter,

More information

1 Generating functions for balls in boxes

1 Generating functions for balls in boxes Math 566 Fall 05 Some otes o geeratig fuctios Give a sequece a 0, a, a,..., a,..., a geeratig fuctio some way of represetig the sequece as a fuctio. There are may ways to do this, with the most commo ways

More information

Topic 5: Basics of Probability

Topic 5: Basics of Probability Topic 5: Jue 1, 2011 1 Itroductio Mathematical structures lie Euclidea geometry or algebraic fields are defied by a set of axioms. Mathematical reality is the developed through the itroductio of cocepts

More information

Axioms of Measure Theory

Axioms of Measure Theory MATH 532 Axioms of Measure Theory Dr. Neal, WKU I. The Space Throughout the course, we shall let X deote a geeric o-empty set. I geeral, we shall ot assume that ay algebraic structure exists o X so that

More information

Course : Algebraic Combinatorics

Course : Algebraic Combinatorics Course 8.32: Algebraic Combiatorics Lecture Notes # Addedum by Gregg Musier February 4th - 6th, 2009 Recurrece Relatios ad Geeratig Fuctios Give a ifiite sequece of umbers, a geeratig fuctio is a compact

More information

Sets. Sets. Operations on Sets Laws of Algebra of Sets Cardinal Number of a Finite and Infinite Set. Representation of Sets Power Set Venn Diagram

Sets. Sets. Operations on Sets Laws of Algebra of Sets Cardinal Number of a Finite and Infinite Set. Representation of Sets Power Set Venn Diagram Sets MILESTONE Sets Represetatio of Sets Power Set Ve Diagram Operatios o Sets Laws of lgebra of Sets ardial Number of a Fiite ad Ifiite Set I Mathematical laguage all livig ad o-livig thigs i uiverse

More information

Infinite Sequences and Series

Infinite Sequences and Series Chapter 6 Ifiite Sequeces ad Series 6.1 Ifiite Sequeces 6.1.1 Elemetary Cocepts Simply speakig, a sequece is a ordered list of umbers writte: {a 1, a 2, a 3,...a, a +1,...} where the elemets a i represet

More information

Injections, Surjections, and the Pigeonhole Principle

Injections, Surjections, and the Pigeonhole Principle Ijectios, Surjectios, ad the Pigeohole Priciple 1 (10 poits Here we will come up with a sloppy boud o the umber of parethesisestigs (a (5 poits Describe a ijectio from the set of possible ways to est pairs

More information

MT5821 Advanced Combinatorics

MT5821 Advanced Combinatorics MT5821 Advaced Combiatorics 1 Coutig subsets I this sectio, we cout the subsets of a -elemet set. The coutig umbers are the biomial coefficiets, familiar objects but there are some ew thigs to say about

More information

MAT 271 Project: Partial Fractions for certain rational functions

MAT 271 Project: Partial Fractions for certain rational functions MAT 7 Project: Partial Fractios for certai ratioal fuctios Prerequisite kowledge: partial fractios from MAT 7, a very good commad of factorig ad complex umbers from Precalculus. To complete this project,

More information

Recursive Algorithms. Recurrences. Recursive Algorithms Analysis

Recursive Algorithms. Recurrences. Recursive Algorithms Analysis Recursive Algorithms Recurreces Computer Sciece & Egieerig 35: Discrete Mathematics Christopher M Bourke cbourke@cseuledu A recursive algorithm is oe i which objects are defied i terms of other objects

More information

(k) x n. n! tk = x a. (i) x p p! ti ) ( q 0. i 0. k A (i) n p

(k) x n. n! tk = x a. (i) x p p! ti ) ( q 0. i 0. k A (i) n p Math 880 Bigraded Classes & Stirlig Cycle Numbers Fall 206 Bigraded classes. Followig Flajolet-Sedgewic Ch. III, we defie a bigraded class A to be a set of combiatorial objects a A with two measures of

More information

Generating Functions. 1 Operations on generating functions

Generating Functions. 1 Operations on generating functions Geeratig Fuctios The geeratig fuctio for a sequece a 0, a,..., a,... is defied to be the power series fx a x. 0 We say that a 0, a,... is the sequece geerated by fx ad a is the coefficiet of x. Example

More information

September 2012 C1 Note. C1 Notes (Edexcel) Copyright - For AS, A2 notes and IGCSE / GCSE worksheets 1

September 2012 C1 Note. C1 Notes (Edexcel) Copyright   - For AS, A2 notes and IGCSE / GCSE worksheets 1 September 0 s (Edecel) Copyright www.pgmaths.co.uk - For AS, A otes ad IGCSE / GCSE worksheets September 0 Copyright www.pgmaths.co.uk - For AS, A otes ad IGCSE / GCSE worksheets September 0 Copyright

More information

CIS Spring 2018 (instructor Val Tannen)

CIS Spring 2018 (instructor Val Tannen) CIS 160 - Sprig 2018 (istructor Val Tae) Lecture 5 Thursday, Jauary 25 COUNTING We cotiue studyig how to use combiatios ad what are their properties. Example 5.1 How may 8-letter strigs ca be costructed

More information

Lecture Notes for CS 313H, Fall 2011

Lecture Notes for CS 313H, Fall 2011 Lecture Notes for CS 313H, Fall 011 August 5. We start by examiig triagular umbers: T () = 1 + + + ( = 0, 1,,...). Triagular umbers ca be also defied recursively: T (0) = 0, T ( + 1) = T () + + 1, or usig

More information

UNIVERSITY OF NORTHERN COLORADO MATHEMATICS CONTEST. First Round For all Colorado Students Grades 7-12 November 3, 2007

UNIVERSITY OF NORTHERN COLORADO MATHEMATICS CONTEST. First Round For all Colorado Students Grades 7-12 November 3, 2007 UNIVERSITY OF NORTHERN COLORADO MATHEMATICS CONTEST First Roud For all Colorado Studets Grades 7- November, 7 The positive itegers are,,, 4, 5, 6, 7, 8, 9,,,,. The Pythagorea Theorem says that a + b =

More information

Homework 3. = k 1. Let S be a set of n elements, and let a, b, c be distinct elements of S. The number of k-subsets of S is

Homework 3. = k 1. Let S be a set of n elements, and let a, b, c be distinct elements of S. The number of k-subsets of S is Homewor 3 Chapter 5 pp53: 3 40 45 Chapter 6 p85: 4 6 4 30 Use combiatorial reasoig to prove the idetity 3 3 Proof Let S be a set of elemets ad let a b c be distict elemets of S The umber of -subsets of

More information

SNAP Centre Workshop. Basic Algebraic Manipulation

SNAP Centre Workshop. Basic Algebraic Manipulation SNAP Cetre Workshop Basic Algebraic Maipulatio 8 Simplifyig Algebraic Expressios Whe a expressio is writte i the most compact maer possible, it is cosidered to be simplified. Not Simplified: x(x + 4x)

More information

Bertrand s Postulate

Bertrand s Postulate Bertrad s Postulate Lola Thompso Ross Program July 3, 2009 Lola Thompso (Ross Program Bertrad s Postulate July 3, 2009 1 / 33 Bertrad s Postulate I ve said it oce ad I ll say it agai: There s always a

More information

subcaptionfont+=small,labelformat=parens,labelsep=space,skip=6pt,list=0,hypcap=0 subcaption ALGEBRAIC COMBINATORICS LECTURE 8 TUESDAY, 2/16/2016

subcaptionfont+=small,labelformat=parens,labelsep=space,skip=6pt,list=0,hypcap=0 subcaption ALGEBRAIC COMBINATORICS LECTURE 8 TUESDAY, 2/16/2016 subcaptiofot+=small,labelformat=pares,labelsep=space,skip=6pt,list=0,hypcap=0 subcaptio ALGEBRAIC COMBINATORICS LECTURE 8 TUESDAY, /6/06. Self-cojugate Partitios Recall that, give a partitio λ, we may

More information

TEACHER CERTIFICATION STUDY GUIDE

TEACHER CERTIFICATION STUDY GUIDE COMPETENCY 1. ALGEBRA SKILL 1.1 1.1a. ALGEBRAIC STRUCTURES Kow why the real ad complex umbers are each a field, ad that particular rigs are ot fields (e.g., itegers, polyomial rigs, matrix rigs) Algebra

More information

3. Z Transform. Recall that the Fourier transform (FT) of a DT signal xn [ ] is ( ) [ ] = In order for the FT to exist in the finite magnitude sense,

3. Z Transform. Recall that the Fourier transform (FT) of a DT signal xn [ ] is ( ) [ ] = In order for the FT to exist in the finite magnitude sense, 3. Z Trasform Referece: Etire Chapter 3 of text. Recall that the Fourier trasform (FT) of a DT sigal x [ ] is ω ( ) [ ] X e = j jω k = xe I order for the FT to exist i the fiite magitude sese, S = x [

More information

CSE 191, Class Note 05: Counting Methods Computer Sci & Eng Dept SUNY Buffalo

CSE 191, Class Note 05: Counting Methods Computer Sci & Eng Dept SUNY Buffalo Coutig Methods CSE 191, Class Note 05: Coutig Methods Computer Sci & Eg Dept SUNY Buffalo c Xi He (Uiversity at Buffalo CSE 191 Discrete Structures 1 / 48 Need for Coutig The problem of coutig the umber

More information

Discrete Mathematics for CS Spring 2007 Luca Trevisan Lecture 22

Discrete Mathematics for CS Spring 2007 Luca Trevisan Lecture 22 CS 70 Discrete Mathematics for CS Sprig 2007 Luca Trevisa Lecture 22 Aother Importat Distributio The Geometric Distributio Questio: A biased coi with Heads probability p is tossed repeatedly util the first

More information

FLOOR AND ROOF FUNCTION ANALOGS OF THE BELL NUMBERS. H. W. Gould Department of Mathematics, West Virginia University, Morgantown, WV 26506, USA

FLOOR AND ROOF FUNCTION ANALOGS OF THE BELL NUMBERS. H. W. Gould Department of Mathematics, West Virginia University, Morgantown, WV 26506, USA INTEGERS: ELECTRONIC JOURNAL OF COMBINATORIAL NUMBER THEORY 7 (2007), #A58 FLOOR AND ROOF FUNCTION ANALOGS OF THE BELL NUMBERS H. W. Gould Departmet of Mathematics, West Virgiia Uiversity, Morgatow, WV

More information

Worksheet on Generating Functions

Worksheet on Generating Functions Worksheet o Geeratig Fuctios October 26, 205 This worksheet is adapted from otes/exercises by Nat Thiem. Derivatives of Geeratig Fuctios. If the sequece a 0, a, a 2,... has ordiary geeratig fuctio A(x,

More information

Chapter 6. Advanced Counting Techniques

Chapter 6. Advanced Counting Techniques Chapter 6 Advaced Coutig Techiques 6.: Recurrece Relatios Defiitio: A recurrece relatio for the sequece {a } is a equatio expressig a i terms of oe or more of the previous terms of the sequece: a,a2,a3,,a

More information

Polynomial identity testing and global minimum cut

Polynomial identity testing and global minimum cut CHAPTER 6 Polyomial idetity testig ad global miimum cut I this lecture we will cosider two further problems that ca be solved usig probabilistic algorithms. I the first half, we will cosider the problem

More information

Chapter 1 : Combinatorial Analysis

Chapter 1 : Combinatorial Analysis STAT/MATH 394 A - PROBABILITY I UW Autum Quarter 205 Néhémy Lim Chapter : Combiatorial Aalysis A major brach of combiatorial aalysis called eumerative combiatorics cosists of studyig methods for coutig

More information

6 Integers Modulo n. integer k can be written as k = qn + r, with q,r, 0 r b. So any integer.

6 Integers Modulo n. integer k can be written as k = qn + r, with q,r, 0 r b. So any integer. 6 Itegers Modulo I Example 2.3(e), we have defied the cogruece of two itegers a,b with respect to a modulus. Let us recall that a b (mod ) meas a b. We have proved that cogruece is a equivalece relatio

More information

Recurrence Relations

Recurrence Relations Recurrece Relatios Aalysis of recursive algorithms, such as: it factorial (it ) { if (==0) retur ; else retur ( * factorial(-)); } Let t be the umber of multiplicatios eeded to calculate factorial(). The

More information

62. Power series Definition 16. (Power series) Given a sequence {c n }, the series. c n x n = c 0 + c 1 x + c 2 x 2 + c 3 x 3 +

62. Power series Definition 16. (Power series) Given a sequence {c n }, the series. c n x n = c 0 + c 1 x + c 2 x 2 + c 3 x 3 + 62. Power series Defiitio 16. (Power series) Give a sequece {c }, the series c x = c 0 + c 1 x + c 2 x 2 + c 3 x 3 + is called a power series i the variable x. The umbers c are called the coefficiets of

More information

CSE 1400 Applied Discrete Mathematics Number Theory and Proofs

CSE 1400 Applied Discrete Mathematics Number Theory and Proofs CSE 1400 Applied Discrete Mathematics Number Theory ad Proofs Departmet of Computer Scieces College of Egieerig Florida Tech Sprig 01 Problems for Number Theory Backgroud Number theory is the brach of

More information

Exercises 1 Sets and functions

Exercises 1 Sets and functions Exercises 1 Sets ad fuctios HU Wei September 6, 018 1 Basics Set theory ca be made much more rigorous ad built upo a set of Axioms. But we will cover oly some heuristic ideas. For those iterested studets,

More information

Putnam Training Exercise Counting, Probability, Pigeonhole Principle (Answers)

Putnam Training Exercise Counting, Probability, Pigeonhole Principle (Answers) Putam Traiig Exercise Coutig, Probability, Pigeohole Pricile (Aswers) November 24th, 2015 1. Fid the umber of iteger o-egative solutios to the followig Diohatie equatio: x 1 + x 2 + x 3 + x 4 + x 5 = 17.

More information

LINEAR ALGEBRAIC GROUPS: LECTURE 6

LINEAR ALGEBRAIC GROUPS: LECTURE 6 LINEAR ALGEBRAIC GROUPS: LECTURE 6 JOHN SIMANYI Grassmaias over Fiite Fields As see i the Fao plae, fiite fields create geometries that are uite differet from our more commo R or C based geometries These

More information

REVIEW FOR CHAPTER 1

REVIEW FOR CHAPTER 1 REVIEW FOR CHAPTER 1 A short summary: I this chapter you helped develop some basic coutig priciples. I particular, the uses of ordered pairs (The Product Priciple), fuctios, ad set partitios (The Sum Priciple)

More information

Math 2784 (or 2794W) University of Connecticut

Math 2784 (or 2794W) University of Connecticut ORDERS OF GROWTH PAT SMITH Math 2784 (or 2794W) Uiversity of Coecticut Date: Mar. 2, 22. ORDERS OF GROWTH. Itroductio Gaiig a ituitive feel for the relative growth of fuctios is importat if you really

More information

Course : Algebraic Combinatorics

Course : Algebraic Combinatorics Course 18.312: Algebraic Combiatorics Lecture Notes # 18-19 Addedum by Gregg Musier March 18th - 20th, 2009 The followig material ca be foud i a umber of sources, icludig Sectios 7.3 7.5, 7.7, 7.10 7.11,

More information

MT5821 Advanced Combinatorics

MT5821 Advanced Combinatorics MT5821 Advaced Combiatorics 9 Set partitios ad permutatios It could be said that the mai objects of iterest i combiatorics are subsets, partitios ad permutatios of a fiite set. We have spet some time coutig

More information

The Random Walk For Dummies

The Random Walk For Dummies The Radom Walk For Dummies Richard A Mote Abstract We look at the priciples goverig the oe-dimesioal discrete radom walk First we review five basic cocepts of probability theory The we cosider the Beroulli

More information

[ 11 ] z of degree 2 as both degree 2 each. The degree of a polynomial in n variables is the maximum of the degrees of its terms.

[ 11 ] z of degree 2 as both degree 2 each. The degree of a polynomial in n variables is the maximum of the degrees of its terms. [ 11 ] 1 1.1 Polyomial Fuctios 1 Algebra Ay fuctio f ( x) ax a1x... a1x a0 is a polyomial fuctio if ai ( i 0,1,,,..., ) is a costat which belogs to the set of real umbers ad the idices,, 1,...,1 are atural

More information

Counting Well-Formed Parenthesizations Easily

Counting Well-Formed Parenthesizations Easily Coutig Well-Formed Parethesizatios Easily Pekka Kilpeläie Uiversity of Easter Filad School of Computig, Kuopio August 20, 2014 Abstract It is well kow that there is a oe-to-oe correspodece betwee ordered

More information

Lecture notes for Enumerative Combinatorics

Lecture notes for Enumerative Combinatorics Lecture otes for Eumerative Combiatorics Aa de Mier Uiversity of Oxford Michaelmas Term 2004 Cotets Subsets, multisets, ad balls-i-bis 3. Words ad permutatios............................. 3.2 Subsets ad

More information

4.3 Growth Rates of Solutions to Recurrences

4.3 Growth Rates of Solutions to Recurrences 4.3. GROWTH RATES OF SOLUTIONS TO RECURRENCES 81 4.3 Growth Rates of Solutios to Recurreces 4.3.1 Divide ad Coquer Algorithms Oe of the most basic ad powerful algorithmic techiques is divide ad coquer.

More information

Combinatorially Thinking

Combinatorially Thinking Combiatorially Thiig SIMUW 2008: July 4 25 Jeifer J Qui jjqui@uwashigtoedu Philosophy We wat to costruct our mathematical uderstadig To this ed, our goal is to situate our problems i cocrete coutig cotexts

More information

SOLVED EXAMPLES

SOLVED EXAMPLES Prelimiaries Chapter PELIMINAIES Cocept of Divisibility: A o-zero iteger t is said to be a divisor of a iteger s if there is a iteger u such that s tu I this case we write t s (i) 6 as ca be writte as

More information

Linear Regression Demystified

Linear Regression Demystified Liear Regressio Demystified Liear regressio is a importat subject i statistics. I elemetary statistics courses, formulae related to liear regressio are ofte stated without derivatio. This ote iteds to

More information

The Binomial Theorem

The Binomial Theorem The Biomial Theorem Robert Marti Itroductio The Biomial Theorem is used to expad biomials, that is, brackets cosistig of two distict terms The formula for the Biomial Theorem is as follows: (a + b ( k

More information

Properties and Tests of Zeros of Polynomial Functions

Properties and Tests of Zeros of Polynomial Functions Properties ad Tests of Zeros of Polyomial Fuctios The Remaider ad Factor Theorems: Sythetic divisio ca be used to fid the values of polyomials i a sometimes easier way tha substitutio. This is show by

More information

Math 220A Fall 2007 Homework #2. Will Garner A

Math 220A Fall 2007 Homework #2. Will Garner A Math 0A Fall 007 Homewor # Will Garer Pg 3 #: Show that {cis : a o-egative iteger} is dese i T = {z œ : z = }. For which values of q is {cis(q): a o-egative iteger} dese i T? To show that {cis : a o-egative

More information

MATH 304: MIDTERM EXAM SOLUTIONS

MATH 304: MIDTERM EXAM SOLUTIONS MATH 304: MIDTERM EXAM SOLUTIONS [The problems are each worth five poits, except for problem 8, which is worth 8 poits. Thus there are 43 possible poits.] 1. Use the Euclidea algorithm to fid the greatest

More information

CHAPTER 10 INFINITE SEQUENCES AND SERIES

CHAPTER 10 INFINITE SEQUENCES AND SERIES CHAPTER 10 INFINITE SEQUENCES AND SERIES 10.1 Sequeces 10.2 Ifiite Series 10.3 The Itegral Tests 10.4 Compariso Tests 10.5 The Ratio ad Root Tests 10.6 Alteratig Series: Absolute ad Coditioal Covergece

More information

The Boolean Ring of Intervals

The Boolean Ring of Intervals MATH 532 Lebesgue Measure Dr. Neal, WKU We ow shall apply the results obtaied about outer measure to the legth measure o the real lie. Throughout, our space X will be the set of real umbers R. Whe ecessary,

More information

The Riemann Zeta Function

The Riemann Zeta Function Physics 6A Witer 6 The Riema Zeta Fuctio I this ote, I will sketch some of the mai properties of the Riema zeta fuctio, ζ(x). For x >, we defie ζ(x) =, x >. () x = For x, this sum diverges. However, we

More information

distinct distinct n k n k n! n n k k n 1 if k n, identical identical p j (k) p 0 if k > n n (k)

distinct distinct n k n k n! n n k k n 1 if k n, identical identical p j (k) p 0 if k > n n (k) THE TWELVEFOLD WAY FOLLOWING GIAN-CARLO ROTA How ay ways ca we distribute objects to recipiets? Equivaletly, we wat to euerate equivalece classes of fuctios f : X Y where X = ad Y = The fuctios are subject

More information

Basic Counting. Periklis A. Papakonstantinou. York University

Basic Counting. Periklis A. Papakonstantinou. York University Basic Coutig Periklis A. Papakostatiou York Uiversity We survey elemetary coutig priciples ad related combiatorial argumets. This documet serves oly as a remider ad by o ways does it go i depth or is it

More information

Product measures, Tonelli s and Fubini s theorems For use in MAT3400/4400, autumn 2014 Nadia S. Larsen. Version of 13 October 2014.

Product measures, Tonelli s and Fubini s theorems For use in MAT3400/4400, autumn 2014 Nadia S. Larsen. Version of 13 October 2014. Product measures, Toelli s ad Fubii s theorems For use i MAT3400/4400, autum 2014 Nadia S. Larse Versio of 13 October 2014. 1. Costructio of the product measure The purpose of these otes is to preset the

More information

6.3 Testing Series With Positive Terms

6.3 Testing Series With Positive Terms 6.3. TESTING SERIES WITH POSITIVE TERMS 307 6.3 Testig Series With Positive Terms 6.3. Review of what is kow up to ow I theory, testig a series a i for covergece amouts to fidig the i= sequece of partial

More information

1. By using truth tables prove that, for all statements P and Q, the statement

1. By using truth tables prove that, for all statements P and Q, the statement Author: Satiago Salazar Problems I: Mathematical Statemets ad Proofs. By usig truth tables prove that, for all statemets P ad Q, the statemet P Q ad its cotrapositive ot Q (ot P) are equivalet. I example.2.3

More information

SOLUTIONS TO PRISM PROBLEMS Junior Level 2014

SOLUTIONS TO PRISM PROBLEMS Junior Level 2014 SOLUTIONS TO PRISM PROBLEMS Juior Level 04. (B) Sice 50% of 50 is 50 5 ad 50% of 40 is the secod by 5 0 5. 40 0, the first exceeds. (A) Oe way of comparig the magitudes of the umbers,,, 5 ad 0.7 is 4 5

More information

Ma 530 Infinite Series I

Ma 530 Infinite Series I Ma 50 Ifiite Series I Please ote that i additio to the material below this lecture icorporated material from the Visual Calculus web site. The material o sequeces is at Visual Sequeces. (To use this li

More information

P1 Chapter 8 :: Binomial Expansion

P1 Chapter 8 :: Binomial Expansion P Chapter 8 :: Biomial Expasio jfrost@tiffi.kigsto.sch.uk www.drfrostmaths.com @DrFrostMaths Last modified: 6 th August 7 Use of DrFrostMaths for practice Register for free at: www.drfrostmaths.com/homework

More information

Chapter 6 Overview: Sequences and Numerical Series. For the purposes of AP, this topic is broken into four basic subtopics:

Chapter 6 Overview: Sequences and Numerical Series. For the purposes of AP, this topic is broken into four basic subtopics: Chapter 6 Overview: Sequeces ad Numerical Series I most texts, the topic of sequeces ad series appears, at first, to be a side topic. There are almost o derivatives or itegrals (which is what most studets

More information

Discrete Mathematics for CS Spring 2005 Clancy/Wagner Notes 21. Some Important Distributions

Discrete Mathematics for CS Spring 2005 Clancy/Wagner Notes 21. Some Important Distributions CS 70 Discrete Mathematics for CS Sprig 2005 Clacy/Wager Notes 21 Some Importat Distributios Questio: A biased coi with Heads probability p is tossed repeatedly util the first Head appears. What is the

More information

PROPERTIES OF THE POSITIVE INTEGERS

PROPERTIES OF THE POSITIVE INTEGERS PROPERTIES OF THE POSITIVE ITEGERS The first itroductio to mathematics occurs at the pre-school level ad cosists of essetially coutig out the first te itegers with oe s figers. This allows the idividuals

More information

THE ASYMPTOTIC COMPLEXITY OF MATRIX REDUCTION OVER FINITE FIELDS

THE ASYMPTOTIC COMPLEXITY OF MATRIX REDUCTION OVER FINITE FIELDS THE ASYMPTOTIC COMPLEXITY OF MATRIX REDUCTION OVER FINITE FIELDS DEMETRES CHRISTOFIDES Abstract. Cosider a ivertible matrix over some field. The Gauss-Jorda elimiatio reduces this matrix to the idetity

More information

Solutions. tan 2 θ(tan 2 θ + 1) = cot6 θ,

Solutions. tan 2 θ(tan 2 θ + 1) = cot6 θ, Solutios 99. Let A ad B be two poits o a parabola with vertex V such that V A is perpedicular to V B ad θ is the agle betwee the chord V A ad the axis of the parabola. Prove that V A V B cot3 θ. Commet.

More information

DIVISIBILITY PROPERTIES OF GENERALIZED FIBONACCI POLYNOMIALS

DIVISIBILITY PROPERTIES OF GENERALIZED FIBONACCI POLYNOMIALS DIVISIBILITY PROPERTIES OF GENERALIZED FIBONACCI POLYNOMIALS VERNER E. HOGGATT, JR. Sa Jose State Uiversity, Sa Jose, Califoria 95192 ad CALVIN T. LONG Washigto State Uiversity, Pullma, Washigto 99163

More information

Problem Set 2 Solutions

Problem Set 2 Solutions CS271 Radomess & Computatio, Sprig 2018 Problem Set 2 Solutios Poit totals are i the margi; the maximum total umber of poits was 52. 1. Probabilistic method for domiatig sets 6pts Pick a radom subset S

More information

Combinatorics and Newton s theorem

Combinatorics and Newton s theorem INTRODUCTION TO MATHEMATICAL REASONING Key Ideas Worksheet 5 Combiatorics ad Newto s theorem This week we are goig to explore Newto s biomial expasio theorem. This is a very useful tool i aalysis, but

More information

INEQUALITIES BJORN POONEN

INEQUALITIES BJORN POONEN INEQUALITIES BJORN POONEN 1 The AM-GM iequality The most basic arithmetic mea-geometric mea (AM-GM) iequality states simply that if x ad y are oegative real umbers, the (x + y)/2 xy, with equality if ad

More information

The multiplicative structure of finite field and a construction of LRC

The multiplicative structure of finite field and a construction of LRC IERG6120 Codig for Distributed Storage Systems Lecture 8-06/10/2016 The multiplicative structure of fiite field ad a costructio of LRC Lecturer: Keeth Shum Scribe: Zhouyi Hu Notatios: We use the otatio

More information

Some Basic Counting Techniques

Some Basic Counting Techniques Some Basic Coutig Techiques Itroductio If A is a oempty subset of a fiite sample space S, the coceptually simplest way to fid the probability of A would be simply to apply the defiitio P (A) = s A p(s);

More information

Addition: Property Name Property Description Examples. a+b = b+a. a+(b+c) = (a+b)+c

Addition: Property Name Property Description Examples. a+b = b+a. a+(b+c) = (a+b)+c Notes for March 31 Fields: A field is a set of umbers with two (biary) operatios (usually called additio [+] ad multiplicatio [ ]) such that the followig properties hold: Additio: Name Descriptio Commutativity

More information

18th Bay Area Mathematical Olympiad. Problems and Solutions. February 23, 2016

18th Bay Area Mathematical Olympiad. Problems and Solutions. February 23, 2016 18th Bay Area Mathematical Olympiad February 3, 016 Problems ad Solutios BAMO-8 ad BAMO-1 are each 5-questio essay-proof exams, for middle- ad high-school studets, respectively. The problems i each exam

More information

The Growth of Functions. Theoretical Supplement

The Growth of Functions. Theoretical Supplement The Growth of Fuctios Theoretical Supplemet The Triagle Iequality The triagle iequality is a algebraic tool that is ofte useful i maipulatig absolute values of fuctios. The triagle iequality says that

More information

Disjoint Systems. Abstract

Disjoint Systems. Abstract Disjoit Systems Noga Alo ad Bey Sudaov Departmet of Mathematics Raymod ad Beverly Sacler Faculty of Exact Scieces Tel Aviv Uiversity, Tel Aviv, Israel Abstract A disjoit system of type (,,, ) is a collectio

More information

Dirichlet s Theorem on Arithmetic Progressions

Dirichlet s Theorem on Arithmetic Progressions Dirichlet s Theorem o Arithmetic Progressios Athoy Várilly Harvard Uiversity, Cambridge, MA 0238 Itroductio Dirichlet s theorem o arithmetic progressios is a gem of umber theory. A great part of its beauty

More information

Zeros of Polynomials

Zeros of Polynomials Math 160 www.timetodare.com 4.5 4.6 Zeros of Polyomials I these sectios we will study polyomials algebraically. Most of our work will be cocered with fidig the solutios of polyomial equatios of ay degree

More information

Mathematics review for CSCI 303 Spring Department of Computer Science College of William & Mary Robert Michael Lewis

Mathematics review for CSCI 303 Spring Department of Computer Science College of William & Mary Robert Michael Lewis Mathematics review for CSCI 303 Sprig 019 Departmet of Computer Sciece College of William & Mary Robert Michael Lewis Copyright 018 019 Robert Michael Lewis Versio geerated: 13 : 00 Jauary 17, 019 Cotets

More information