9 - © 2010 by Spencer Rugaber Behavior Modeling • Class...

Info iconThis preview shows pages 1–8. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: © 2010 by Spencer Rugaber Behavior Modeling • Class models express properties that are true of a system at all times • Although they are general, they fail to convey interesting behavioral aspects of systems – That is, how objects respond to external stimuli • A variety of alternative modeling techniques are available in UML for behavior modeling – Use case diagrams, sequence diagrams, statechart diagrams, activity diagrams, timing diagrams, interaction overview diagrams, communications/collaboration diagrams © 2010 by Spencer Rugaber Modeling Alternatives • Combinatorial Control – Decision tables – Decision trees • Sequential Control – State transition tables – Finite state machine • Concurrent Control – State charts – Petri Nets – Activity diagrams – Sequence diagrams – Collaboration diagrams – Temporal logic – Process algebra © 2010 by Spencer Rugaber Combinatorial Modeling • The simplest form of behavior modeling merely expresses the logic of simple combinatorial systems • In these systems, only the inputs, and not the history of previous states determines subsequent states • Two equivalent forms of combinatorial modeling are decision tables and decision trees © 2010 by Spencer Rugaber Decision Tables • One common way to model control is with decision tables - They are used when a number of possible input conditions hold and a number of responses are possible • The conditions are called inputs and the responses are called outputs • The input side of the table enumerates all possible combinations of conditions - For example, if each of three switches can have one of two possible values, "on" or "off", then the table will contain three columns and eight rows • Likewise, if the three switches control two output devices (one switch is a master override) then there will be two output columns (along with the eight rows from the input). 3 © 2010 by Spencer Rugaber Example Decision Table - 1 INPUT Output Master Control Light Switch Power Switch Lights Motor ON ON ON ON ON ON ON OFF ON OFF ON OFF ON OFF ON ON OFF OFF OFF OFF OFF ON ON OFF OFF OFF ON OFF OFF OFF OFF OFF ON OFF OFF OFF OFF OFF OFF OFF © 2010 by Spencer Rugaber Condensed Decision Table • Note that the last four rows of the output are identical - The table can be shortened by making use of "don't care" entries. - A don't care entry is indicated by dashes in an inp cell INPUT Output Master Control Light Switch Power Switch Light Motor ON ON ON ON ON ON ON OFF ON OFF ON OFF ON OFF ON ON OFF OFF OFF OFF OFF --- --- OFF OFF © 2010 by Spencer Rugaber Decision Trees • A decision tree contains the same information as a decision table, but in graphical form • There are two kinds of nodes – Diamonds denote decisions – Rectangles denote actions to be taken • Labeled arcs indicate the implications when a decision is answered in a particular way (affirmative or negative) • Note that some nodes may be duplicated...
View Full Document

This note was uploaded on 05/03/2010 for the course SA 5010 taught by Professor Spen during the Spring '10 term at Asian Institute of Management.

Page1 / 51

9 - © 2010 by Spencer Rugaber Behavior Modeling • Class...

This preview shows document pages 1 - 8. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online