Assignment 1 - CS120a Due Tuesday, February 7, 10:40 AM ---------------------------------- 1. a) Compute r |x s (r semi-join s) for the relations shown below: +---+---+---+ +---+---+---+ | A | B | C | | C | D | E | +---+---+---+ +---+---+---+ | 1 | 2 | 3 | | 3 | 4 | 5 | | 4 | 5 | 6 | | 3 | 6 | 8 | | 1 | 2 | 4 | | 2 | 3 | 2 | | 5 | 3 | 2 | | 1 | 4 | 1 | | 8 | 9 | 7 | | 1 | 2 | 3 | +---+---+---+ +---+---+---+ r s b) For any relations t and u, under what conditions does (t |x u) = (u |x t)? 2. Suppose a 10 Mbps (megabits per second) network transmits 1024 byte packets that include 132 bytes of headers and trailer. If a workstation on the LAN is guaranteed to be able to transmit at least one packet every X time units (since the network is shared with other workstations), what maximum amount of time, as a function of X, should be required (based only on these factors) to transfer a 3 MB file from a server to a workstation? What is the effective transfer rate from the server to the workstation? 3. A disk is being utilized 30% of the time, and the average time to service a disk request is 20 msec. If on average, 60 disk requests are being serviced or in the queue at any one time, what is the average response time per disk request? 4. Consider a RAID-7 disk that distributes data across 6 disks (i.e., a stripe group consists of 6 stripe units), leaving one disk for storing the parity. For n = 1, 2, 3, 4, 5 and 6, compute the minimum number of stripe units (rw (n)) that must be read as a result of a request to write n stripe units, so as to update parity. Explain each of your answers. 5. To allow for greater enrollment without adding building space, the Brandeis Computer Science department adds an internship component to its undergraduate degree. Under this program, students work in industry for one semester for every two semesters that they take courses. Suppose that on average, 100 students do an internship every semester, and that on average, students complete their degree (including internships) in 6 years. a) On average, how many students graduate the program every semester? b) On average, how many students are enrolled in Computer Science at the start of a semester? (You may assume that the average number of new enrollments each semester is equal to the number of graduating students each semester.)