1 / 4

Permuting Lower Bound

Permuting Lower Bound. Permuting N elements according to a given permutation takes I/ Os in “indivisibility” model Indivisibility model: Move of elements only allowed operation Note: We can allow copies (and destruction of elements)

cheung
Download Presentation

Permuting Lower Bound

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. I/O-efficient Algorithms and Data Structures Permuting Lower Bound Permuting N elements according to a given permutation takes I/Os in “indivisibility” model • Indivisibility model: Move of elements only allowed operation • Note: • We can allow copies (and destruction of elements) • Bound also a lower bound on sorting • Proof: • View memory and disk as array of N tracks of B elements • Assume all I/Os track aligned (assumption can be removed) D M

  2. I/O-efficient Algorithms and Data Structures Permuting Lower Bound • Array contains permutation of N elements at all times • We will count how many permutations can be reached (produced) with t I/Os • Input: • Choose track: N possibilities • Rearrange ≤ B element in track and place among ≤ M-B elements in memory: • possibilities if “fresh” track • otherwise  at most permutations after t inputs • Output: Choose track: N possibilities D M

  3. I/O-efficient Algorithms and Data Structures Permuting Lower Bound • Permutation algorithm needs to be able to produce N! permutations (using Stirlings formula and ) • If we have • If we have and thus    

  4. I/O-efficient Algorithms and Data Structures Sorting lower bound • Similar argument but assuming comparison model in internal memory • Initially N! possible orderings • Count how may possible after t I/Os  Sorting N elements takes I/Os in comparison model   

More Related