Lecture 6
Lecture 6
1
Chapter 6 (Traditional Approach to
Requirements) -- Data Flow Diagrams (DFD)
2
3
Example of a Data Flow Diagram – fig. 6-4
• The square is an external agent
– A person or organization, outside the boundary of a
system that provides data inputs or accepts data outputs
• The rectangle with rounded edges is a process
– A symbol that represents an algorithm or procedure by
which data inputs are transformed into data outputs
• The lines are data flows
– Represents movement of data
• The flat three-sided rectangle are data stores (a file
or part of a database)
– A place where data is held
• Fig. 6-4 corresponds to event “Customer wants to
check item available” (see last lecture) 4
5
Data Flow Diagrams and Levels of
Abstraction
• Levels of abstraction
– Particular to any modeling technique that breaks the
system into a hierarchical set of increasingly more
detailed models
– Example above – a DFD fragment – showing one
process in response to one event
– Other diagrams show the processing at a higher level
(more general) or lower level (a more detailed view of
one process)
– Higher level processes in a DFD can be decomposed
into separate lower level DFD (or some other diagram)
6
Context Diagrams
DFD Fragment 3
17
Dividing the system into subsystems
22
23
Summary - Relationship of all these diagrams
31
32
• Limitations of structured English
– Good for representing processes such as those in
previous slide
– Not so good for showing complex decision logic – as
shown in next slide
– Not so good if there are few or no sequential steps
• Decision Table
– A tabular representation of processing logic containing
decision variables, decision variable values and actions
(or formulas)
• Decision Tree
– A graphical description of process logic that uses lines
organized like branches of a tree
33
34
Making a Decision Table (from the logic on
previous slide)
• Step 1
– Identify the decision variables
• Year to date purchases (YTD)
• Number of items ordered
• Delivery date
• Step 2
– Put variable with fewest possible value ranges in the
first row of the table
• In this example could put either YTD or number of items
35
• Table so far is just one row:
Delivery Day Next 2nd 7th Next 2nd 7th Next 2nd 7th Next 2nd 7th
37
38
Decision Tree
41
42
Data Flow Definitions
• Data flow – a collection of data elements
• Data flow definition – a textual description of a data
flow’s content and internal structure
– Lists all the elements- e.g. a “New Order” data flow consists of
• Customer –Name
• Customer-Address
• Credit-Card-Information
• Item-Number
• Quantity
– Most of these are stored and correspond to the attributes of data
entities
– In addition to just listing elements can use algebraic notation
• Data flow “equals” one element followed by another (repeating groups
43
can be shown in curly brackets)
44
45
46
47
Data Element Definitions
48
+int
9(4)
+9(6).99
String[50]
49
Data Store Definitions
50