Decision Tables SEEM 3430 Tutorial LI Jing.

Slides:



Advertisements
Similar presentations
A useful testing technique and more…
Advertisements

Preparing a Decision Table
Extra tutorials.
4.3 Matrix Approach to Solving Linear Systems 1 Linear systems were solved using substitution and elimination in the two previous section. This section.
Example for calculating your final grade for this course
Chapter Four SOLVING FOR THE UNKNOWN Copyright © 2014 by The McGraw-Hill Companies, Inc. All rights reserved.McGraw-Hill/Irwin.
CSC 123 Systems Analysis & Design
Describing Process Specifications and Structured Decisions Systems Analysis and Design, 7e Kendall & Kendall 9 © 2008 Pearson Prentice Hall.
Week 7.  Two or more individuals combine their assets and skills to go into business.  Each individual is referred to as a partner.  Since multiple.
Decision Table Testing
Computer Aided Process Planning
LU - Factorizations Matrix Factorization into Triangular Matrices.
Copyright © 2011 Pearson Education, Inc. Publishing as Prentice Hall Process Specifications and Structured Decisions Systems Analysis and Design, 8e Kendall.
Goldstein/Schnieder/Lay: Finite Math & Its Applications, 9e 1 of 86 Chapter 2 Matrices.
Kendall & KendallCopyright © 2014 Pearson Education, Inc. Publishing as Prentice Hall 9 Kendall & Kendall Systems Analysis and Design, 9e Process Specifications.
1 Decision Tables. 2  Introduction  construction  Types of Decision Tables  Limited Entry  Extended Entry  Combining of Rules  General Rule  Q.
Chapter 1 Section 1.2 Echelon Form and Gauss-Jordan Elimination.
Decision Trees and Decision Tables
Kendall & KendallCopyright © 2014 Pearson Education, Inc. Publishing as Prentice Hall 9 Kendall & Kendall Systems Analysis and Design, 9e Process Specifications.
1. Copyright © 2006 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Systems of Equations CHAPTER 9.1Solving Systems of Linear Equations Graphically.
Solving Systems of Equations and Inequalities
CSCI 347 / CS 4206: Data Mining Module 03: Output Topic 02: Decision Tables.
MATRICES AND DETERMINANTS
Solving Systems of Equations and Inequalities Section 3.1A-B Two variable linear equations Section 3.1C Matrices Resolution of linear systems Section 3.1D.
Modeling and Design of Rule-Based Systems Yonglei Tao.
Jon Curwin and Roger Slater, QUANTITATIVE METHODS: A SHORT COURSE ISBN © Thomson Learning 2004 Jon Curwin and Roger Slater, QUANTITATIVE.
8. PROCESS DESCRIPTION System Analysis And Design Program: BSCS II (Advent Semester – 2014) Lecturer: Rebecca Asiimwe
Describing Process Specifications and Structured Decisions Systems Analysis and Design, 7e Kendall & Kendall 9 © 2008 Pearson Prentice Hall.
Concepts of Relational Databases. Fundamental Concepts Relational data model – A data model representing data in the form of tables Relations – A 2-dimensional.
Implementing an REA Model in a Relational Database
Computer Aided Process Planning (CAPP). What is Process Planning? Process planning acts as a bridge between design and manufacturing by translating design.
Step 1: Place x 2 term and constant into the box 2x 2 2 PROBLEM: 2x 2 + 5x + 2.
Seg3430A Tutorial 8 Decision Table. Logic Modeling Data flow diagrams do not show the logic inside the processes Logic modeling involves representing.
Extracting Information from an Excel List The purpose of creating a database, or list in Excel, is to be able to manipulate the data elements in ways that.
Boolean Algebra and Computer Logic Mathematical Structures for Computer Science Chapter 7 Copyright © 2006 W.H. Freeman & Co.MSCS Slides Boolean Logic.
Copyright © 2011 Pearson Education Process Specifications and Structured Decisions Systems Analysis and Design, 8e Kendall & Kendall Global Edition 9.
Logic Modelling Decision Tables. 2 Modeling Logic with Decision Tables Procedure for Creating Decision Tables Name the condition and the values that each.
Solving Systems of Equations Using Matrices
IS 334 information systems analysis and design
Logical Database Design and the Rational Model
Basics of Logic gates - Part 1
Implementing an REA Model in a Relational Database
Decision Tables - a brief overview
Process Specifications and Structured Decisions
5 Systems of Linear Equations and Matrices
Exponents Scientific Notation
Solving for the Unknown: A How-to Approach for Solving Equations
AS Computer Studies Finite State Machines 2.
Lecture 2 The Relational Model
Accounting Information Systems 9th Edition
Example Question–Is this relation Well Structured? Student
Database Design Using Normalization
REDCap Data Migration from CSV file
Chapter 3 The Relational Database Model
Solving for the Unknown: A How-to Approach for Solving Equations
Probability.
BASIC & COMBINATIONAL LOGIC CIRCUIT
Developing More Complex Decision Trees
Computer Aided Process Planning
Describing Process Specifications and Structured Decisions
Algebra
Spreadsheets, Modelling & Databases
N7 Prime factor decomposition, HCF and LCM
Databases and Information Management
Creating Additional Input Items
Decision Tables SEEM 3430 Tutorial Lanjun Zhou.
Presentation transcript:

Decision Tables SEEM 3430 Tutorial LI Jing

Overview A diagram of all the logic and possible outcomes associated with a particular process Conditions Condition Alternatives Actions Conditions Condition Alternatives Actions Action Entries 2019/2/28

Overview Conditions and Condition alternatives Actions Represent the specific rule when making a decision Actions Represent all possible courses of action associated with a given set of conditions 2019/2/28

Why decision table? 2019/2/28

Why decision table? Model complicated programming logic. Make it easy to see that all possible combinations of conditions have been considered. 2019/2/28

Developing decision tables You need to determine the maximum size of the table, eliminate any impossible situations, inconsistencies, or redundancies, and simplify the table as much as possible. 2019/2/28

Step 1 Determine the number of conditions that may affect the decision. Combine rows that overlap, for example, conditions that are mutually exclusive. The number of conditions becomes the number of rows in the top half of the decision table. Conditions Condition Alternatives Actions Action Entries 2019/2/28

Mutually exclusive conditions Gender Male and Female Education High school, Bachelor, Master and Doctor etc. Mutually exclusive conditions should be combined to be one condition with multiple alternatives 2019/2/28

Step 2 Determine the number of possible actions that can be taken. This becomes the number of rows in the lower half of the decision table. Conditions Condition Alternatives Actions Action Entries 2019/2/28

Step 3 Determine the number of condition alternatives for each condition. In the simplest form of decision table, there would be two alternatives (Y or N) for each condition. In an extended-entry table, there may be many alternatives for each condition. Conditions Condition Alternatives Actions Action Entries 2019/2/28

Step 4 Calculate the maximum number of columns in the decision table by multiplying the number of alternatives for each condition. If there are four conditions and two alternatives for each of them, there will be 2 4 =16 possibilities Conditions Condition Alternatives Actions Action Entries 2019/2/28

Step 5 Fill in the condition alternatives. Start with the first condition and divide the number of columns by the number of alternatives for that condition. 2019/2/28

Step 6~9 6. Complete the table by inserting an X where rules suggest certain actions. 7. Combine rules where it is apparent that an alternative does not make a difference in the outcome 8. Check the table for any impossible situations, contradictions, redundancies. 9. Rearrange the conditions and actions (or even rules) to make the decision table more understandable. 2019/2/28

An example A store wishes to program a decision on non- cash receipts for goods into their intelligent tills. 2019/2/28

Conditions 1. Transaction under £50 2. Pays by cheque with cheque card (guarantee £50) 3. Pays by credit card 2019/2/28

Possible actions 1. Ring up sale 2. Check credit card from local database 3. Call a supervisor 4. Automatic check of credit card company database 2019/2/28

Initial the decision table Some of the condition rules are invalid (Marked as red and blue) Customer cannot pay by cheque AND pay by credit card or not pay by either method 2019/2/28

Delete invalid condition rules 2019/2/28

Indicate the actions 2019/2/28

Check for completeness What if the customer has not shopped there before? Reconstructing the table! 2019/2/28

Adding a new condition to the existing table The action list remain the same, clean the action entries The number of condition rules increases by a multiple of 2 (number of alternatives for the new condition). 2019/2/28

Indicate the actions Under £50 Y N Pays by cheque Pays by credit card Unknown customer   Ring up sale X Check from local database Call Supervisor X  Check credit card database 2019/2/28

Delete mutually exclusive conditions Under £50 Y N Pays by cheque Pays by credit card - Unknown customer   Ring up sale X Check from local database Call Supervisor X  Check credit card database The dash in the Pays by credit card row indicates that it does not matter about the condition rule since if a customer pays by cheque they will not pay by credit card and vice versa ( mutually exclusive ). 2019/2/28

Combine possible situations according to actions Under £50 Y N Pays by cheque Pays by credit card - Unknown customer   Ring up sale X Check from local database Call Supervisor X  Check credit card database Y N Y - Y Y N N Y - N Y + = + = 2019/2/28

Remove the redundant Under £50 - Y N Pays by cheque Pays by credit card Unknown customer   Ring up sale X Check from local database Call Supervisor X  Check credit card database 2019/2/28

Combine identical actions Under £50 - Y N Pays by cheque Pays by credit card Unknown customer   Ring up sale X Check from local database Call Supervisor Check credit card database - Y N Y Y N Y N Y Can not merge !!! + = + + 2019/2/28

Wrong final version This final version is from Reference 2, which is wrong!!! This wrong final version can not deal with condition ‘YYY’ and ‘YNY’ 2019/2/28

Final Version Under £50 - Y N Pays by cheque Unknown customer   Ring up sale X Check from local database Call Supervisor Check credit card database Attention: This final version is different with reference 2 2019/2/28

Exercise When a burglar alarm sounds, if it is in one of students’ houses where alarm sounds every week, ignore it. Otherwise have a look outside and if the house looks not broken into and there is nobody moving inside it, ignore the alarm. Otherwise call police. (Answer: next slide) 2019/2/28

Solution for the exercise Possible answer for the exercise 2019/2/28

Exercise A marketing company wishes to construct a decision table to decide how to treat clients according to three characteristics: Gender, City Dweller, and age group: A (under 30), B (between 30 and 60), C (over 60). The company has four products (W, X, Y and Z) to test market. Product W will appeal to female city dwellers. Product X will appeal to young females. Product Y will appeal to Male middle aged shoppers who do not live in cities. Product Z will appeal to all but older females. 2019/2/28

Solution-step 1 Identify conditions and their alternative values. There are 3 conditions: gender, city dweller, and age group. Put these into table as 3 rows in upper left side. Gender’s alternative values are: F and M. City dweller’s alternative values are: Y and N Age group’s alternative values are: A, B, and C 2019/2/28

Solution-step 2 Compute maximum number of rules. Determine the product of number of alternative values for each condition: 2 x 2 x 3 = 12. Fill table on upper right side with one column for each unique combination of these alternative values. Label each column using increasing numbers 1-12 corresponding to the 12 rules. 2019/2/28

Solution-step 3-4 Identify possible actions Market product W, X, Y, or Z. Put these into table as 4 rows in lower left side. Define each of the actions to take given each rule. 2019/2/28

Solution-step 5 Simplify the table. Determine if there are rules (columns) that represent impossible situations. If so, remove those columns. There are no impossible situations in this example. Determine if there are rules (columns) that have the same actions. If so, determine if these are rules that are identical except for one condition and for that one condition, all possible values of this condition are present in the rules in these columns. 2019/2/28

Final Table 1 2 3 4 5 6 7 8 9 10 Gender F M City Y N Age A - B C W X Z 2019/2/28

References http://en.wikipedia.org/wiki/Decision_table http://www.cems.uwe.ac.uk/jharney/table.ht ml http://www.cs.nott.ac.uk/~nza/G53KRR07/ answer-decision-tables.pdf https://classes.soe.ucsc.edu/cmps115/Spring 05/supplements/DecisionTables.htm 2019/2/28

Q&A Thanks! 2019/2/28