1 / 8

MATH 310, FALL 2003 (Combinatorial Problem Solving) Lecture 3 6, Monday, December 1

MATH 310, FALL 2003 (Combinatorial Problem Solving) Lecture 3 6, Monday, December 1. 7. 2. Divide-and-Conquer Relations. Homework (MATH 310# 1 1M): Read 7. 2,7.3 Do 7.1,7.2: all odd numbere d problems Turn in 7. 2 : 2, 4,6,8. Divide-and-Conquer.

dominice
Download Presentation

MATH 310, FALL 2003 (Combinatorial Problem Solving) Lecture 3 6, Monday, December 1

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. MATH 310, FALL 2003(Combinatorial Problem Solving)Lecture 36, Monday, December 1

  2. 7.2. Divide-and-Conquer Relations • Homework (MATH 310#11M): • Read 7.2,7.3 • Do 7.1,7.2: all odd numbered problems • Turn in 7.2: 2,4,6,8

  3. Divide-and-Conquer • Divide the problem in two smaller parts, solve each subproblem nad combine solutions. • an = can/2 + f(n).

  4. Divide-and-Conquer • Divide the problem in two smaller parts, solve each subproblem nad combine solutions. • an = can/2 + f(n).

  5. Example 1: Rounds in a Tournament • Number of rounds in a tennis tournament. Number of players: n = 2k, for some k. • an = an/2 + 1. • an = log2n + A. • Observe that a1 = 0, and so A = 0. • On the left: n = 8, a8 = 3.

  6. Example 2: Finding the Largest and the Smallest Element in a Set • an = 2an/2 + 2 • a2 = 1 • an = (3/2)n – 2. m,M m2,M2 m1,M1 m= min{m1,m2} M= max{M1,M2}

  7. Example 3: Efficient Multidigit Multiplication • g = [g1,g2] = g1£ 10n/2 + g2. • h = [h1,h2] = h1£ 10n/2 + h2. • g £ h = (g1£ h1) £ 10n + (g1£ h2 + g2£ h1) £ 10n/2 +(g2£ h2). • We need only (g1£ h1), (g2£ h2) and (g1 + g2) £ (h1 + h2). • an = 3an/2. • an = nlog2 3 = n1.5849....

  8. Theorem • Let an = can/k + f(n) be recurrence relation with positive constant c and the positive function f(n). • (a) If for large n, f(n) grows proportional to n logk c, then an grows proportional to nlogk c log2 c. • (b) If for large n f(n) · pnq, where p is a positive constant and q < logk c, then an grows at most at rate proportional to nlogk c.

More Related