Modelling Logic
with
Decision Table
Presentation By:
Arjun Gautam
What is Logic
Modelling ?
Why do we need Logic
Modelling ?
•What we can't represent with DFD ?
• relationships among the resources, activities, outputs, outcomes, and impact for your
program
What we
Invest ?
What we
want ?
What we
need ?
Inputs Outputs Outcomes
ASSUMPTIONS
What we know ?
EXTERNAL FACTORS
What we can't control ?
Components of Logic Model :
Employee retention
Decision Tables
• Visual Representation for specifying which actions
to perform depending on given conditions .
• Use in both testing and requirements management .
• Dealing with complex business rules and
complicated logic .
ATM
•Business Rules :
• Customer should have sufficient funds in their
accounts .
• Credit Granted
Steps to create Decision Table
• Analyze the requirement and create first column
• Add columns
• Reduce table
• Determine actions
Step 1 : Analyze the requirement
Conditions
Conditions
Withdrawl amt<=balance
Credit Granted
Actions
Withdrawl Granted
Step 2 : Add columns
Conditions R1 R2 R3 R4
Withdrawl amt<=balance T F F F
Credit Granted T T F F
Actions
Withdrawl Granted
Step 3:Reduce the table
Conditions R1 R2 R3 R4
Withdrawl amt<=balance T F T F
Credit Granted - T - F
Actions
Withdrawl Granted
Invalid Combinations = "X" ,Infant and Senior
Step 4 :Determine cases:
Conditions R1 R2 R3
Withdrawl amt<=balance T F F
Credit Granted - T F
Actions
Withdrawl Granted T T F
Step 5 : Write test cases
• Test case with R1 : balance =…200... , requested withdrawl =200,
Expected result : withdrawl .....granted....
• Test case with R2 : balance =…100... , requested withdrawl = ….200.
,Expected result : withdrawl ....granted.....
• Test case with R3 : balance =…100... , requested withdrawl = …200..
,Expected result : withdrawl .....denied....
Advantages
• Generate the combinations of conditions that would
otherwise not have been found and therefore not tested
or developed .
• Requirement become much clearer .
References :
• Modern SAD
-Jeffery A. Hoffer
• System Analysis And
Design
-KEC Publication
• Youtube/QIO
Program

Modelling Logic with Decision Table

  • 1.
  • 2.
  • 3.
    Why do weneed Logic Modelling ? •What we can't represent with DFD ? • relationships among the resources, activities, outputs, outcomes, and impact for your program
  • 4.
    What we Invest ? Whatwe want ? What we need ? Inputs Outputs Outcomes ASSUMPTIONS What we know ? EXTERNAL FACTORS What we can't control ? Components of Logic Model :
  • 5.
  • 7.
    Decision Tables • VisualRepresentation for specifying which actions to perform depending on given conditions . • Use in both testing and requirements management . • Dealing with complex business rules and complicated logic .
  • 8.
    ATM •Business Rules : •Customer should have sufficient funds in their accounts . • Credit Granted
  • 9.
    Steps to createDecision Table • Analyze the requirement and create first column • Add columns • Reduce table • Determine actions
  • 10.
    Step 1 :Analyze the requirement Conditions Conditions Withdrawl amt<=balance Credit Granted Actions Withdrawl Granted
  • 11.
    Step 2 :Add columns Conditions R1 R2 R3 R4 Withdrawl amt<=balance T F F F Credit Granted T T F F Actions Withdrawl Granted
  • 12.
    Step 3:Reduce thetable Conditions R1 R2 R3 R4 Withdrawl amt<=balance T F T F Credit Granted - T - F Actions Withdrawl Granted Invalid Combinations = "X" ,Infant and Senior
  • 13.
    Step 4 :Determinecases: Conditions R1 R2 R3 Withdrawl amt<=balance T F F Credit Granted - T F Actions Withdrawl Granted T T F
  • 14.
    Step 5 :Write test cases • Test case with R1 : balance =…200... , requested withdrawl =200, Expected result : withdrawl .....granted.... • Test case with R2 : balance =…100... , requested withdrawl = ….200. ,Expected result : withdrawl ....granted..... • Test case with R3 : balance =…100... , requested withdrawl = …200.. ,Expected result : withdrawl .....denied....
  • 15.
    Advantages • Generate thecombinations of conditions that would otherwise not have been found and therefore not tested or developed . • Requirement become much clearer .
  • 16.
    References : • ModernSAD -Jeffery A. Hoffer • System Analysis And Design -KEC Publication • Youtube/QIO Program