Answer: D
To find the candidate keys of the relation R(A,B,C,D,E,H), we first identify the attributes that must be present in every candidate key.
Step 1: Identify Essential Attributes
An attribute that does not appear on the right-hand side (RHS) of any functional dependency must be part of every candidate key because it cannot be determined by any other attribute.
- The given functional dependencies are:
- A→B
- BC→D
- E→C
- D→A
- Attributes on the RHS: B,D,C,A
- Attributes not on the RHS: E and H
Thus, every candidate key must contain both E and H. This immediately eliminates options A and B.
Step 2: Test Closures of Combinations with E and H
Let's find the attribute closures for combinations of E and H with other attributes:
- For AEH:
(AEH)+={A,E,H}={A,B,E,H}(using A→B)={A,B,C,E,H}(using E→C)={A,B,C,D,E,H}(using BC→D)=R
Since (AEH)+ contains all attributes of R and no proper subset of AEH can determine R (as E and H are essential), AEH is a candidate key.
- For BEH:
(BEH)+={B,E,H}={B,C,E,H}(using E→C)={B,C,D,E,H}(using BC→D)={A,B,C,D,E,H}(using D→A)=R
Thus, BEH is a candidate key.
- For DEH:
(DEH)+={D,E,H}={A,D,E,H}(using D→A)={A,B,D,E,H}(using A→B)={A,B,C,D,E,H}(using E→C)=R
Thus, DEH is a candidate key.
Therefore, the candidate keys of R are AEH, BEH, and DEH.