# hw 5 answers.pdf - Fall 2018 COT 3100 Section 1 Homework 8...

• 6

Course Hero uses AI to attempt to automatically extract content from documents to surface to you and others so you can study better, e.g., in search results, to enrich docs, and more. This preview shows page 1 - 2 out of 6 pages.

Fall 2018 COT 3100 Section 1 Homework 8 Solutions1) Consider an ant that is walking on a Cartesian grid, starting at (0,0) and ending at (15, 18). The antalways chooses to walk exactly one unit either up or to the right (towards his destination) whenever hearrives at a Lattice point. (A Lattice point is a point with integer coordinates.) Thus, from (0,0) he eitherwalks to (1, 0) or (0, 1). If the ant is not allowed to go to the points (6, 8) and (11, 15), how manydifferent paths can he take on his walk?SolutionWithout any forbidden points, we know the ant must take 33 "steps" of which he must choose 15 to go tothe right (positive x-axis). Thus, with the forbidden positions there are(3315)ways for the ant to walk thedesired path. From this number, we must subtract out the number of forbidden paths.The number of forbidden paths are the number of paths through (6, 8) or (11, 15). We can count thesepaths separately, but in doing so, we will have counted paths that go through both points twice, so wemust subtract out all of those paths that go through both paths twice, via the Inclusion-Exclusionprinciple. In general, given a point (x, y) where 0 ≤ x ≤ 15 and 0 ≤ y ≤ 18, there are(? + ??)ways to getto point (x, y) and(33 − ? − ?15 − ?)ways to get from (x, y) to (15, 18). Since we can pair up any of the firstset of paths with any of the second pair of paths, the product of these two terms is the total number ofpaths from (0, 0) to (15, 18) that go through (x, y). It follows that the number of paths through (6, 8) is(146) (199)and the number of paths through (11, 15) is(2611) (74). Finally, we must calculate the numberof paths from (0, 0) to (15, 18) that go through both (6, 8) and (11, 15), since these were subtracted outtwice and need to be added back in. All of these paths can be broken down into 3 sub-paths, ones that gofrom (0, 0) to (6, 8), then (6, 8) to (11, 15) and then from (11, 15) to (15, 18). We want to count thenumber of ways to take each of these subpaths and multiply all three of the terms. This yields:(146) (125) (73)paths that go through both forbidden points, which now need to be added in. Our finalresult is:(????) − (???) (???) − (????) (??) + (???) (???) (??)

Course Hero member to access this document

Course Hero member to access this document

End of preview. Want to read all 6 pages?