Sale!

COMP9311 Assignment 2 solved

Original price was: $35.00.Current price is: $28.00.

Category:

Description

5/5 - (1 vote)

Question 1 (10 marks)

Consider a relation 𝑅(𝐴, 𝐡, 𝐢,𝐷, 𝐸, 𝐺, 𝐻,𝐼,𝐽,𝐾) and its FD set 𝐹 = {𝐴 β†’ 𝐡𝐢, 𝐸 β†’
𝐴𝐷, 𝐡𝐷 β†’ 𝐸, 𝐢𝐸 β†’ 𝐷𝐻, 𝐻 β†’ 𝐺, 𝐸𝐼 β†’ 𝐽}.
1) Check if 𝐢 β†’ 𝐽 ∈ F
+
. (1 marks)
2) Find a minimal cover πΉπ‘š for 𝐹. (2 marks)
3) Regarding F, is the decomposition R1 = {𝐴𝐡𝐢𝐷𝐸}, R2 = {𝐸𝐺𝐻}, R3 = {𝐸𝐼𝐽𝐾} of 𝑅
lossless-join? Please justify your answer. (2 marks)
4) List at least 5 super-keys for 𝑅. (2 marks)

5) Is it possible to decompose 𝑅 into a collection of BCNF relations and ensure the
decomposition is dependency-preserving and lossless-join? Please justify your answers.
(3 marks)

Question 2 (6 marks)

Following is the schedule A for transactions T1, T2, and T3:
Schedule A
Time T1 T2 T3
1 write(X)
2 read(Z)
3 write(X)
4 write(Z)
5 read(Z)
6 write(Y)
Transaction
7
8
9 write(X)
10 read(Y)

1) Assume that the system crashes at time 8, what should be done to recover the system? (3
marks)
2) Assume a checkpoint is made at time 7, what should be done to the three transactions
when the crash happens at time 8? (3 marks)
Note: We assume a transaction will be committed immediately after all the read/write
operations of it are done.

Question 3 (4 marks)

Give and justify the answers regarding the following problems:
1) Construct a scenario that First in First Out (FIFO) buffer replacement policy is better
than Most Recently Used (MRU) buffer replacement policy. (2 marks)
2) Construct a scenario that First in First Out (FIFO) buffer replacement policy is better
than Least Recently Used (LRU) buffer replacement policy. (2 marks)

Assignment Submission

We accept electronic submissions only. Please submit your assignments as follows:
β€’ The file name should be ass2.pdf.
β€’ Ensure that you are in the directory containing the file to be submitted. (note: we only
accept files with .pdf extension)
β€’ Type β€œgive cs9311 ass2 ass2.pdf” to submit.

β€’ Please keep a screen capture (including timestamp and the size of submitted file) for
your submissions as proof in case that the system is not working properly. If you are
not sure how, please have a look here.

Note:

1. If the size of your pdf file is larger than 2MB, the system will not accept the
submission. If you face this problem, try converting to compressed pdf.
2. If you have any problems in submissions, please email to kai.wang@unsw.edu.au.
3. We do not accept e-mail submissions, and the submission system will be immediately
closed after the deadline.
Late Submission Penalty
Zero mark