Reasoning About FDs (Contd.)
Computing the closure of a set of FDs can be expensive. (Size of closure is exponential in # attrs!)
Typically, we just want to check if a given FD X Y is in the closure of a set of FDs F. An efficient check:
- Compute attribute closure of X (denoted ) wrt F:
- Set of all attributes A such that X A is in
- There is a linear time algorithm to compute this.
- Check if Y is in
Does F = {A B, B C, C D E } imply A E?
- i.e, is A E in the closure ? Equivalently, is E in ?