Detecting- Incompleteness, Ambiguity,Contradictions and Redundancy in decision table specification
Detecting- Incompleteness, Ambiguity,Contradictions & Redundancy in decision table specification
LOGICAL CORRECTNESS OF DECISION TABLE (CONTD)
A decision table with 1 condition should have 2 elementary rules, each elementary rule must be distinct, each elementary rule must have distinct action, if a decision table with k conditions does not have 2k rules specified it is said to be incomplete.
For example : DT2 does not have the elementary rule C1:N, C2:N. It is thus incomplete.
If the decision table has the same elementary rule occurring more than once it is said to have multiplicity of specifications For Example: In DT2 The rule C1:Y,C2:Y occurs twice. Thus it has multiplicity of specification.
If action specified for multiple identical rules are different then it is called ambiguous specifications DT2 has an ambiguity. Rules R11 and R22 are identical but have different actions. Ambiguity may be apparent or real. It is said to be apparent if the rule leading to the ambiguity is logically impossible For example,(x>60)=Y and (x<40)=Y cannot occur simultaneously. Thus in DT2 rules R11 and R22 are apparently ambiguous rules Apparently ambiguous rules is not an error If an apparently ambiguous specification is real then it is a contradiction For example : If C1:(X > 60) = Y and C2:(X > 40) = Y then X = 70 will satisfy both inequalities.
As two actions are specified for (Cl = Y, C2 = Y) and they are different the rule is really ambiguous and is called Contradictory Specification.
If all 2k elementary rules are not present in a k condition decision table is said to be incomplete.
DT2 is incomplete as rule C1:N, C2:N is missing
Rule C1=N, C2:=N is logically possible as C1=N is X<=60
and C2=N is X >= 40. A value of X = 50 will make C1=N,C2=N
Thus DT2 has a real incomplete specification
A decision table which has no real ambiguities or real incompleteness is said to be logically correct. Decision table with logical errors should be corrected
USE OF KARNAUGH MAPS
KARNAUGH map abbreviated K-map is a 2 dimensional diagram with one square per elementary rule
The k-map of DT2 is
If more than one action is in one square it is an ambiguous rule
If a square is empty it signifies incomplete specification.
USE OF KARNAUGH MAPS
Structured English procedure:
Observe that the fact that the specification is incomplete is obvious in the Decision table whereas the structured English specification seems complete which is not.
DT4: DECISION TABLE-ARREARS MANAGEMENT
CORRECT DECISION TABLE
If users say that for rules C1C2C3C4:NYNY AND YYNY (marked with + in k-map) the action is A4 and for C1C2C3C4:NNNN also it is A4, the corrected map is
Question: Can the number of rules be reduced?
Answer : Yes, by combining rules with the same action
Action A1 can be represented by the Boolean expression:
C1C2C3C4 + C1C2C3C4 + C1C2C3C4 = C1C2C3C4 + C1C2C3 (C4+C4) =C1C2C3C4+C1C2C3 = C1C2C4 + C1C2C3
Comments
Post a Comment