Software Assignment
Software Assignment
Full Marks: 50
(Answer all questions)
1. Consider the Relation R = CSJDPQV and the set of FDs = {C→CSJDPQV, SD→P, 6+4
JP→C, J→S}. Identify the highest normal form of the relation R. If R is not in 3NF,
decompose it into a set of 3NF relations that preserve the dependencies, otherwise not.
Compute the canonical cover of the above relation R with the same set of FDs.
Find Prime and Non Prime Attributes for the relation R (ABCDEFGH) and the set of FDs
{E → G, AB → C, AC → B, AD → E,B → D, BC → A}.
2. Suppose a relation R (A, B, C, D) is given. For each of the following sets of FDs, briefly 4
explain whether decomposing the relation R into smaller relations is a good decomposition
or not.
a. AB → C, C → A, C → D; decompose into (ACD) and (BC)
b. A → BC, C → AD; decompose into (ABC) and (AD)
3. ‘A design solution which is difficult to understand would lead to increased development 5+5
and maintenance cost.’- Justify.
‘Software having passed all the three levels of testing, i.e., unit testing, integration testing
and system testing, can we claim that the software is free of errors’. - Justify.
4. Write the pre and post conditions to axiomatically specify the following function: 4+6
A function sort takes an integer array as its argument and sorts the input array in ascending
order.
Justify your answer with an example, how the results of small programs on analysis are
inaccurate although analysis of large number of programs performed by experimental
evidence matches with computed and actual length of the program.
5. Create a trigger ‘trig_A’ to enforce that the salary of an employee Satish cannot be 6
increased by more than 20% on table Employee. The trigger is fired whenever there is a
salary update on Employee table. Display a suitable message when the rule is violated.