Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Suppose you have a file with N 5 x 10' pages 1.1. (5 points) What is the total I/O cost of sorting the file using
Suppose you have a file with N 5 x 10' pages 1.1. (5 points) What is the total I/O cost of sorting the file using the two-way merge sort (with three buffer pages)? Now suppose you have B 129 buffer pages. Answer the following questions using the general external sorting algorithm outlined in section 13.3 of the textbook (page 424) Please write the formula you used in calculating the answers Q1.2. (5 points) How many runs will you produce in the first pass? Q1.3. (5 points) Now assume that we have a disk with an average seek time of 10ms, average rotation delay of 5ms and a transfer time of 1ms for each page. Assuming the cost of reading/writing a page is the sum of those values (i.e. 16ms) and do not distinguish between sequential and random disk-access - any access is 16ms, what is the total running time to sort the file? Q1.4. (5 points) With 129 buffer pages, what's the maximum size of the file (in number of pages) that we can sort with 3 passes? Suppose you have a file with N 5 x 10' pages 1.1. (5 points) What is the total I/O cost of sorting the file using the two-way merge sort (with three buffer pages)? Now suppose you have B 129 buffer pages. Answer the following questions using the general external sorting algorithm outlined in section 13.3 of the textbook (page 424) Please write the formula you used in calculating the answers Q1.2. (5 points) How many runs will you produce in the first pass? Q1.3. (5 points) Now assume that we have a disk with an average seek time of 10ms, average rotation delay of 5ms and a transfer time of 1ms for each page. Assuming the cost of reading/writing a page is the sum of those values (i.e. 16ms) and do not distinguish between sequential and random disk-access - any access is 16ms, what is the total running time to sort the file? Q1.4. (5 points) With 129 buffer pages, what's the maximum size of the file (in number of pages) that we can sort with 3 passes
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started