hw2sol - Computer Science 340 Reasoning about Computation...

Info icon This preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Computer Science 340 Reasoning about Computation Homework 2 Due at the beginning of class on Wednesday, October 3, 2007 Problem 1 Consider a convex n -gon (a polygon with n sides). A chord is a line segment between two non-adjacent vertices. If all chords are drawn, in how many interior points do they intersect? (Assume no three chords intersect at the same point.) Solution: Number the vertices of the polygon clockwise starting from 1. Let ( a 1 , a 2 , a 3 , a 4 ) be an ordered selection of 4 vertices. This tuple uniquely determines one chord intersection – namely the intersection of the chords ( a 1 , a 3 ) and ( a 2 , a 4 ). Conversely, each intersection is the intersection of exactly two chords and if we select any two intersecting chords ( a, b ) and ( c, d ) (without loss of generality a < b , c < d and a < c ), they uniquely determine an ordered tuple of the form ( a 1 , a 2 , a 3 , a 4 ), namely ( a, c, b, d ). Therefore there is a one-to-one correspondence between the chord intersections and the ordered selections of 4 vertices. (It is absolutely essential to argue the correspondence is 1-1.) There are ( n 4 ) such selections (since once we pick the 4 elements we can just order them) and the answer to the problem is ( n 4 ) .
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern