Question

In: Computer Science

Consider a relation R (ABCDEFGH) with the following functional dependencies: ACD --> EF AG --> A...

Consider a relation R (ABCDEFGH) with the following functional dependencies:

ACD --> EF

AG --> A

B --> CFH

D --> C

DF --> G

F --> C

F --> D

Find minimal cover and identify all possible candidate keys. In order to receive full credit, please list each step taken and the rules that you applied.

Solutions

Expert Solution

Solution:

Given,

=>Relation = R(ABCDEFGH)

=>Set of functional dependencies = {ACD -> EF, AG -> A, B -> CFH, D -> C, DF -> G, F -> C, F -> D}

Explanation:

Finding minimal cover:

Step 1:

=>Remove trivial functional dependencies.

=>AG -> A is a trivial fiunctional dependency so remove it.

=>Reduced functional dependencies set = {ACD -> EF, B -> CFH, D -> C, DF -> G, F -> C, F -> D}

Step 2:

=>Split functional dependencies such that right hand side contains only one attribute in each functional dependency.

=>Reduced functional dependencies set = {ACD -> E, ACD -> F, B -> C, B->F, B -> H, DF -> G, F -> C, F -> D}

Step 3:

=>Removing unused functional dependencies

=>functional dependency B -> C is unused because we can derive it using B -> F and F -> C.

=>Reduced functional dependencies set = {ACD -> E, ACD -> F, B->F, B -> H, DF -> G, F -> C, F -> D}

Step 4:

=>Removing extraneous attributes from the left hand side of the functional dependencies.

=>There is no extraneous attribute.

Step 5:

=>Combining functional dependencies

=>Reduced functional dependencies set = {ACD -> EF, B->FH, DF -> G, F -> CD}

=>Hence minimal cover = {ACD -> EF, B->FH, DF -> G, F -> CD}

Finding candidate keys:

=>There is no attributes "A" and "B" at the right hand side part of any of the given functional dependencies hence attributes "A" and "B" must be present in every candidate key as candidate key has ability to derive all the attributes of the relation.

=>(AB)+ = ABCDEFGH

=>Attribute closure of AB contains all the attributes of the relation hence AB is only the candidate key and if we include any other attribute with AB then it wil form super key.

=>Hence candidate key = {AB}

I have explained each and every part with the help of statements attached to the answer above.


Related Solutions

For the relation R(A,B,C,D,E) with the following Functional Dependencies: A → B, A → C, BC...
For the relation R(A,B,C,D,E) with the following Functional Dependencies: A → B, A → C, BC → D, AC → E, CE → A, list all non-trivial FDs following from the above.    Generate all possible keys for R. Check whether R is in 3NF. If it is in 3NF, explain the criteria you used. If it is not in 3NF, convert it into 3NF, showing the new relations and their FDs.
Normalization: Answer all 4 questions. You are given the following relation R and some functional dependencies....
Normalization: Answer all 4 questions. You are given the following relation R and some functional dependencies. R(SID, Project, Code, ListOfSupplies, Name, Initials, Abbrev) Project → ListOfSupplies SID → Name Name → Initials Project, Initials → Abbrev SID, Project → Code Code → SID Is R in 1NF? If not, normalize R into a collection of 1NF relations. Is R in 2NF? If not, normalize R (or your collection of 1NF relations) into a collection of 2NF relations. Is R in...
Consider a relation R with five attributes ABCDE. You are given the following dependencies: A à...
Consider a relation R with five attributes ABCDE. You are given the following dependencies: A à B, BC à E, and ED à A. (1) List all candidate keys for R. Please show your steps. (4 points) (2) Is R in 3NF? Please explain your answer. (3 Points) (3) Is R in BCNF? Please explain your answer. (3 Points)
Consider the following functional dependencies: Z -> XYD, X -> Y. Find the minimal cover of...
Consider the following functional dependencies: Z -> XYD, X -> Y. Find the minimal cover of the above.
1. Consider the following functional dependencies: Z -> XYD, X -> Y Find the minimal cover...
1. Consider the following functional dependencies: Z -> XYD, X -> Y Find the minimal cover of the above. 2. Consider the following two sets of functional dependencies: F = {A -> C, AC -> D, E -> AD, E -> H} and G = {A -> CD, E -> AH}. Check whether they are equivalent.
Consider the following schema and functional dependencies: SHIPPING (ShipName, ShipType, VoyageID, Cargo, Port, ArrivalDate) Key: ShipName,...
Consider the following schema and functional dependencies: SHIPPING (ShipName, ShipType, VoyageID, Cargo, Port, ArrivalDate) Key: ShipName, ArrivalDate FD1: ShipName > ShipType FD2: VoyageID > ShipName, Cargo FD3: ShipName, ArrivalDate > VoyageId, Port 1.Please list the final set of 3NF schema including all its keys. 2.Do any of the finalized 3NF schema have determinates that are not candidate keys? If yes, explain - which schema(s)? Why?  
Determine the Functional Dependencies that exist in the following Orders table. This table lists customer and...
Determine the Functional Dependencies that exist in the following Orders table. This table lists customer and order data. Orders (SupplierNum, SupplierName, Supp_Phone, ProductNum, Description, Product_type, QuotedPrice) . Normalize the above relation to 3 rd normal form, ensuring that the resulting relations are dependency-preserving and specify the primary keys in the normalized relations by underlining them.
How do we know the following relation with the following dependencies is BCNF? course ( course_id...
How do we know the following relation with the following dependencies is BCNF? course ( course_id , title , dept_name , credits ) Functional Dependencies course_id → title , dept_name , credits building , room_number → capacity course_id , sec_id , semester , year → building , room_number , time_slot_id Choose what makes the statement BCNF and why: dept_name is a superkey course_id, dept_name is a superkey course_id is a candidate key course_id is a superkey
Normalize the following data by: a) identifying the functional dependencies, b) stating your assumptions, \ c)...
Normalize the following data by: a) identifying the functional dependencies, b) stating your assumptions, \ c) creating relations, and d) identifying primary and foreign keys. Customer Number| First Name |Last Name |Phone | Invoice Number| Date |Item Type |Quantity Item Price
a. Determine the functional dependencies that exist in the following table. Orders (OrderNum, OrderDate, ItemNum, Description,...
a. Determine the functional dependencies that exist in the following table. Orders (OrderNum, OrderDate, ItemNum, Description, NumOrdered, QuotedPrice) b. After determining the functional dependencies, perform 1nf, 2nf, 3nf.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT