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 of paretheses to the set of bit-strigs (strigs cosistig of the digits 0 or 1 of legth 2 The ijectio here will be a very simple ecodig: sice a estig of pairs of paretheses is a strig of 2 idividual paretheses, we ca simply replace each ope-parethesis with a zero ad a close-parethesis with a 1, eg ( ( ( will be mapped to 001101 This is clearly a ijectio sice two differet parethesisestigs will have differet orderigs of ope- ad close-paretheses, ad will thus map to differet bit-strigs (b (3 poits Use this ijectio ad the ow size of its rage to reach a coclusio about the size of its domai, ie the umber of parethesis-estig arragemets We ow the domai of a ijectio is o larger tha its rage The rage here (the set of bit-strigs of legth 2 has size 2 2, so we ow that there are o more tha 2 2 parethesis-estigs (c (2 poits Demostrate that the fuctio described above is ot a bijectio How does this discovery affect the coclusio reached i part (b? This relatioship is o-bijective sice there are may bit-strigs which do ot correspod to a parethesis-estig; for istace, if there are a uequal umber of zeroes ad oes, the paretheses i a pre-image for such a strig would be ubalaced I additio, ay strig begiig with a oe would ot correspod to a parethesis-estig, sice a parethesis-estig must begi with a opeig parethesis We thus ow that 2 2 is i fact a quite sloppy boud, ad that the umber of parethesis-estigs is less tha 2 2 I fact, with this lie of argumet, you could (but eed ot i respose to this questio pare dow the rage to a cosiderably smaller set: istead of cosiderig all bit-strigs of legth 2, you could oly cosider those strigs with zeroes, oes, a zero at the begiig, ad a oe at the ed This set ca be see via selectio techiques to have size ( 2 2 1 2 (15 poits Let X {1, 2, 3,, 100}, ad let S be a subset of X (a (5 poits Demostrate that there is a set S with S 50 such that o elemet of S is a multiple of ay other elemet of S A simple example is {51, 52,, 100} Sice the ratio of every pair of elemets is less tha 1, o elemet is a positive multiple of ay other elemet (b (10 poits Prove that if S 51, the S must cotai two umbers such that oe of the umbers is a multiple of the other Let us defie a fuctio f mappig each iteger to its largest odd multiple (so, eg 84 would be mapped to 21 Note that it will always be the case that x is f(x Page 1 of 5 February 3, 2012
x a power of 2, sice if had ay odd factors larger tha 1, f(x would t be the f(x largest odd multiple of x Note that f maps itegers less tha or equal to 100 to odd itegers less tha or equal to 100, of which there are exactly 50 Thus sice S > 50, it is the case by the Pigeohole Priciple that f : S {1, 3, 5,, 99} is ot ijective, so there are two elemets x ad y of S with the same largest odd multiple r Sice both x ad y are powers of 2 times r, oe of x or y is a multiple of the other 3 (10 poits Let S be a uow set of 6 itegers Prove that it is possible, by addig ad subtractig a otrivial set of distict elemets of S, to get a multiple of 63 Let us classify subsets of S accordig to the value of the sum of their terms modulo 63, or alteratively, accordig to the remaider whe this sum is divided by 63 (recall that a b mod 63 whe a b is a multiple of 63 Sice S has 6 elemets, there are 64 distict subsets of S; sice there are 63 distict modular cogruece classes (or 63 possible remaiders from the divisio, two sets A ad B have sums that are equivalet modulo 63; thus, the differece of the sums of the terms of A ad the sums of the terms of B is a multiple of 63 Note that if A ad B overlap this arithmetic expressio may iclude the same umber twice, oce added ad oce subtracted; we may easily fix this expressio by simply removig both occurreces without affectig the sum Sice A ad B are distict, at least oe of them cotais a elemet ot appearig i the other, so the resultig arithmetic expressio is otrivial Basic Coutig Techiques 4 (10 poits Show by a casewise argumet that the umber of ways to put +2 ulabeled balls ito labeled boxes so that there is at least oe ball per box is + ( There are very few possible distributios, sice the umber of balls oly slightly exceeds the umber of boxes ad we are required to put at least oe ball i each box There are i fact oly two cases to be addressed: every box except for oe could cotai a sigle ball, while the remaiig box cotais three balls; or every box except for two could cotai a sigle ball, while the remaiig boxes each cotai two balls The first case compreheds differet possibilities, sice ay oe of the boxes could be selected as cotaiig three balls, while the secod case compreheds ( possibilities, sice we select two boxes to be otable i cotaiig two balls Thus, amog both cases, there are a total of + ( ways to distribute the balls 5 (5 poit bous Usig a awareess of which factors are couted by the factorcoutig techique see i class ad the text, determie a formula for the sum of the factors of p a q b, where p ad q are prime As see i class, a factor of p a q b is determied by its prime factorizatio p r q s, where r is a iteger betwee 0 ad a iclusive, ad s is a iteger betwee 0 ad b iclusive; thus we get (a + 1(b + 1 possible factors These factors are fairly easy to list our methodically: they are p 0 q 0, p 0 q 1,, p 0 q b, p 1 q 0, p 1 q 1,, p 1 q b, p 2 q 0, p 2 q 1,, p a q 0, p a q 1,, p a q b Page 2 of 5 February 3, 2012
Ad if we were to add them up, we ca group them as such ad factor out commo terms: (p 0 q 0 + p 0 q 1 + + p 0 q b + (p 1 q 0 + p 1 q 1 + + p 1 q b + + (p a q 0 + p a q 1 + + p a q b p 0 (q 0 + q 1 + + q b + p 1 (q 0 + q 1 + + q b + + p a (q 0 + q 1 + + q b (p 0 + p 1 + + p a (q 0 + q 1 + + q b ad this is a product of fiite geometric series, both of which have simple formulas, so the sum of all the factors of p a q b is pa+1 1 q b+1 1 p 1 q 1 This argumet is easily geeralized to show that if a umber has prime factorizatio p e 1 1 p e 2 2 p er r, the the sum of its factors is Biomials ad combiatorial proof (p e 1+1 1 1(p e 2+1 2 1 (p er+1 r 1 (p 1 1(p 2 1 (p r 1 6 (10 poits+5 bous Below are two combiatorial proofs (a (10 poits Usig combiatorial methods (ie showig both sides cout the same thig, prove that ( 2 1 We shall cosider two differet coutig methods for the followig structure: selectio of a sigle distiguished umber from {1,, } together with the selectio of ay subset of {1,, } ot cotaiig our distiguished umber Oe way we ca do this is to select our distiguished x i ay of differet ways, ad the select a subset S of {1,, } {x} i ay of 2 1 differet ways Thus, there are 2 1 ways to build this structure Coversely, we could build this structure by, for a size, cosiderig a subset A of {1,, } such that A, ad the selectig our distiguished x from A, ad pairig x with the subset S A {x} For each idividual, there are ( choices of A, ad the sice x is chose from A, there are choices of value for x Thus, for a specific value of, this procedure gives us ( ways to build this structure Sice ca tae o ay value from zero to, we add up all cases to get ( ways to build this structure Sice these two quatities are eumeratig the same set, it follows that ( 2 1 For your etertaimet although it s ot a aswer to the questio as ased here s a algebraic proof of the same result usig a bit of calculus ad the Page 3 of 5 February 3, 2012
biomial theorem: ( ( x 1 x1 ( d dx x x1 ( d ( x dx x1 ( x d dx x1 (1 + (1 + x 1 x1 2 1 (b (5 poit bous Geeralize your above result to argue that ( ( ( 2 l l l We shall cosider two differet coutig methods for the followig structure: selectio of a set S of l distiguished elemets of {1,, } together with the selectio of ay subset T of {1,, } disjoit from S Oe ( way we ca do this is to select our set S of l distiguished elemets i ay of l differet ways, ad the select the subset T of {1,, } S i ay of 2 l differet ways Thus, there are ( 2 l ways to build this structure Coversely, we could build this structure by, for a size, cosiderig a subset A of {1,, } such that A, ad the selectig S as a l-elemet subset of A, ad lettig T A S For each idividual, there are ( choices of A, ad the sice S is the result of choosig l elemets of A, from A, there are ( choices of subset S Thus, for a specific value of, this procedure gives us ( ( ways to build this structure Sice ca tae o ay value from zero to, we add up all cases to get ( ( ways to build this structure Sice these two quatities are eumeratig the same set, it follows that ( ( ( l 2 l A algebraic proof of this result is possible but quite ugly It is similar i spirit to the algebraic proof give for part (a but uses the fact that ( x l 1 d l x l! dx l 7 (5 poits Fid the umber of ways to wal from the lower left corer of the followig grid to the upper right corer with sequeces of up ad right moves: Page 4 of 5 February 3, 2012
This is a grid with a exclusio, so it is a matter of fidig the umber of gridwals from the lower left corer to the upper left which do ot visit the excluded poit That is, we wish to fid the umber of gridwals o the left grid below, ad subtract the illegal wals, which could be cosidered to be those o the right grid below: The umber of wals o the first grid is easily see to be ( 11 5, sice a wal o this grid is a sequece of 11 moves, exactly 5 of which are upwards ad 6 of which are rightwards A wal o the secod grid ca be costructed as a cocateatio of wals o two idividual grids: the lower left grid ca be traversed i ( 7 3 ways, ad the upper left is traversable i ay of ( ( 4 ways, so this grid has 7 4 3( possible traversals Sice our origial problem was aswerable by subtractig the umber of wals o the secod grid (all of which would have bee illegal o our origial grid from the umber of wals o the first grid, the aswer will be ( ( 11 5 7 4 3( 252 Ad NUH is the letter I use to spell Nutches Who live i small caves, ow as Nitches, for hutches These Nutches have troubles, the biggest of which is The fact there are may more Nutches tha Nitches Dr Seuss, O Beyod Zebra Page 5 of 5 February 3, 2012