Data Flow Diagrams (DFDS)

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 48

DATA FLOW

DIAGRAMS
(DFDs)
Data Flow Diagrams
A graphical tool, useful for communicating with
users, managers, and other personnel.
Useful for analyzing existing as well as proposed
systems.
Focus on the movement of data between external
entities and processes, and between processes and
data stores.
A relatively simple technique to learn and use.
Why DFD ?
Provides an overview of-
What data a system processes
What transformations are performed
What data are stored
What results are produced
Graphical nature makes it a good communication tool
between-
User and analyst
Analyst and System designer
DFD elements

Source/Sinks (External entities)


Data flows
Processes
Data Stores
External Entities
External
A Rectangle represents Entities
an external entity
They either supply or
receive data • Source – Entity that
They do not process supplies data to the
system.
data • Sink – Entity that
receives data from the
system.
Data Flows
Marks movement of data
through the system - a pipeline
to carry data.
Connects the processes, external Data Flow
entities and data stores.
 Generally unidirectional, If
same data flows in both
directions, double-headed
arrow can be used.
Delivery Slip

Processes Stores demand


note
1.
STORES
Issue Slip

A circle represents a process


Straight line with incoming arrows are input data
flows
Straight lines with outgoing arrows are output
data flows
Labels are assigned to Data flow.
Data Stores
D1 Data Stores D1 Data Stores D1 Data Stores

Writing Reading

A Data Store is a repository of data


Data can be written into the data store. This is
depicted by an incoming arrow
Data can be read from a data store. This is depicted
by an outgoing arrow
External entity cannot read or write to the data
store
Rules of Data Flow
Data can flow from Data cannot flow from

External entity to External entity to


process external entity
Process to external entity External entity to store
Process to store and back Store to external entity
Process to process Store to store
Data Flow Diagrams
An alternate notation is often used:

3 Label
A Process Store
Name
Issue

A Data Store D1 Data Stores Name

Label
Good Style in Drawing DFD
Use meaningful names for data flows, processes and
data stores.
Use top down development starting from context
diagram and successively levelling DFD
A process can only transfer input to output.
Decomposition of DFDs
A system is too complex to be shown on a single
DFD.
Decomposition is the iterative process of exploding
data flow diagrams to create more detail.
Level 0 data flow diagrams may be exploded into
successive low levels of detail. The next level of detail
would be a level 1 data flow diagram.
The DFDs become linked together in
a hierarchy, which would fully
document the system.
Why Level DFD
If a DFD is too detailed it will have too many
data flows and will be large and difficult to
understand
Start from a broad overview. Expand to details –
Idea similar to using procedures and linking
these with a main program
Each DFD must deal with one aspect of a big
system
Levels of DFD
Context diagram
Level-0 diagram (System diagram)

Level-n diagram
- Detail of one process from next
highest level

Primitive diagram (Lowest level DFD)


Levelling Rules
If a process p is expanded, the process at the next
level are labelled as p.1, p.2 etc.
All data flow entering or leaving p must also enter or
leave it’s expanded version
Expanded DFD may have data stores
No external entity can appear in expanded DFD
Keep the number of processes at each level less than 7
Creating Level 0 Diagram
Combine the set of
DFD fragments into
one diagram.
Generally move from
top to bottom, left to
right.
Minimize crossed
lines.
Creating Level 1 Diagram
Each case is turned into its own DFD.
Take the steps listed on the use case and depict
each as a process on the level 1 DFD.
Inputs and outputs listed on use case become
data flows on DFD.
Include sources and destinations of data flows to
processes and stores within the DFD.
May also include external entities for clarity.
When to stop decomposing
DFDs?
Ideally, a DFD has at least
three levels.
When the system becomes
primitive i.e. lowest level
is reached and further
decomposition is useless.
DFD for University Admission System
Context Diagram

Student Information Report Request


0

Student University Staff


Admission
System
Admission Approval Report
or Rejection
Level 1

Student Report Request


Information Student
Name & ID
1 3
Admission Approval Perform Generate
Student Staff
or Rejection Intake Reports Data
Procedure Items

Approved Data
Application
D1 Student Data
Verified
Approved
2 Application

Maintain
Student
Information
Request for Student
Information Maintenance
Level 2 Process 1, Perform Intake Procedure

Student
Information
Admission Application
1.1 1.2
Student Receive Verify
Admission Student Name Admission
Application and ID Application

Verified
Admission
D1 Student Data
Application

Application
Request
Application Approval 1.3
or Rejection Approved Application
Review
Admission
Application
Logical and Physical DFD
DFDs considered so far are called logical DFDs
A physical DFD is similar to a document flow diagram
It specifies who does the operations specified by the
logical DFD
Physical DFD may depict physical movements of the
goods
Physical DFDs can be drawn during fact gathering
phase of a life cycle
Cash

Token

Clerk
Cheque Cashier
Verify A/C
CUSTOMER Verify Token
Signature Update Cheque with Take Signature
Balance
Token number
Token

Bad Cheque

Customer Accounts Store cheques Entry in Day Book


???
In a DFD external entities are represented by a
a. Rectangle
b. Ellipse
c. Diamond shaped box
d. Circle
External Entities may be a
a. Source of input data only
b. Source of input data or destination of results
c. Destination of results only
d. Repository of data
A data store in a DFD represents
a. A sequential file
b. A disk store
c. A repository of data
d. A random access memory
By an external entity we mean a
a. Unit outside the system being designed which can be controlled by an analyst
b. Unit outside the system whose behaviour is independent of the system being
designed
c. A unit external to the system being designed
d. A unit which is not part of DFD
A data flow can
a. Only enter a data store
b. Only leave a data store
c. Enter or leave a data store
d. Either enter or leave a data store but not both
A circle in a DFD represents
a. A data store
b. A an external entity
c. A process
d. An input unit
Design Patterns
Standard solutions to commonly recurring
problems
Provides a good solution to model
Pattern has some important parts
 The problem
 The solution
Types of patterns
1. Architectural Patterns: high level strategies that
concern with overall solutions to large scale
problems.
2. Design Patterns: Medium level strategies, describe
str. and behaviour of entities.
3. Idioms: low level strategies and language specific
programming solutions.
Pros and Cons of design patterns
It provides standard vocabulary
Help designer to produce flexible, efficient and well
maintained design.
Improve design productivity and reduce overall
efforts.
Commonly Made Errors in DFD
Making more than one bubble in context
diagram.
Use of external entities in upper levels
Either too few or too many bubbles in a DFD.
Leaving DFD unbalanced.
Try to represent control and other
information in DFD
User Interface Design
Characteristics of a user interface
1. Speed of learning: A good user interface should be
easy to learn and it should not require its users to
memorize commands.
2. Attractiveness. A good user interface should be
attractive to use. In this respect, graphics-based user
interfaces have a definite advantage over text-based
interfaces.
3. Consistency. The commands supported by a user
interface should be consistent. Consistency facilitates
speed of learning
Characteristics of a user interface
4. Feedback. A good user interface must provide feedback
to various user actions.
5. Error recovery (undo facility). While issuing
commands, even the expert users can commit errors.
Therefore, a good user interface should allow a user to
undo a mistake committed by him while using the
interface.
6. User guidance and on-line help. Users seek guidance
and on-line help when they either forget a command or
are unaware of some features of the software. Whenever
users need guidance or seek help from the system, they
should be provided with the appropriate guidance and
help.
Characteristics of a user interface
7. Speed of use

8. Speed of recall

9. Error prevention
Graphical User Interface vs. Text-
based User Interface
In a GUI multiple windows with different information
can simultaneously be displayed on the user screen.
This is perhaps one of the biggest advantages of GUI
over text-based interfaces.
Iconic information representation and symbolic
information manipulation is possible in a GUI
A GUI usually supports command selection using an
attractive and user-friendly menu selection system.
In a GUI, a pointing device such as a mouse or a light
pen can be used for issuing commands. The use of a
pointing device increases the efficacy issue procedure.
On the other hand, a text-based user interface can be
implemented even on a cheap alphanumeric display
terminal.
Graphics terminals are usually much more expensive
than alphanumeric terminals.
Types of user interfaces
User interfaces can be classified into
the following three categories:
1. Command language based interfaces
2. Menu-based interfaces
3. Direct manipulation interfaces
Command Language-based Interface
is based on designing a command language which the user
can use to issue the commands.
The user is expected to frame the appropriate commands
in the language and type them in appropriately whenever
required.
Command language-based interfaces allow fast interaction
with the computer and simplify the input of complex
commands.
Examples
Menu-based Interface
An important advantage of a menu-based interface
over a command language-based interface is that a
menu-based interface does not require the users to
remember the exact syntax of the commands.
A menu-based interface is based on recognition of the
command names, rather than recollection.

Types of menues:
 Scrolling menu
 Walking Menu
 Hierarchical Menu
Examples
Direct Manipulation Interfaces
Direct manipulation interfaces present the interface to the
user in the form of visual models (i.e. icons or objects).
For this reason, direct manipulation interfaces are
sometimes called as iconic interface.
In this type of interface, the user issues commands by
performing actions on the visual representations of the
objects, e.g. pull an icon representing a file into an icon
representing a trash box, for deleting the file.
Examples
Examples
Important advantages of iconic interfaces include the
fact that the icons can be recognized by the users very
easily, and that icons are language-independent.
Thanks for
your
Cooperation

You might also like