0% found this document useful (0 votes)
17 views42 pages

Lesson DFD

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views42 pages

Lesson DFD

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 42

DDaattaa FFllooww

DDiiaaggrraammss
((DDFFDD))
&& CCoonntteexxtt
ddiiaaggrraammss
OBJECTIVES
By the end of this lesson, students will be able to:
 Understand the purpose and importance of DFDs
and Process Flow diagrams.
 Identify the components of both diagrams.
 Differentiate between different levels of DFDs.
 Construct a simple DFD and Process Flow diagram.
INTRODUCTION
A Data Flow Diagram (DFD) and Process Flow
Diagram are graphical representations used to
visualize the movement of data and processes within a
system. DFDs focus on how data flows between
different components, while Process Flow diagrams
illustrate the sequence of steps in a process.
Data Flow Diagrams
⚫ A graphical tool, useful for
communicating with users, managers,
and other personnel.
⚫ Used to perform structured analysis to
determine logical requirements.
⚫ 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
Why DFD ?
⚫ Provides an overview of-
⚫ What data a system processes
⚫ What transformations are performed
⚫ What data are stored
⚫ What results are produced and where they
flow
⚫ Graphical nature makes it a good
communication tool between-
⚫ User and analyst
⚫ Analyst and System designer
DFD elements
⚫ Source/Sinks (External
entity)
⚫ Processes

⚫ Data Stores

⚫ Data flows
Symbols Used:
Gane & DeMarco &
Symbol
Sarson Yourdan
Symbol Symbol

External Entity

Process

Data store

Data flow
5
Descriptions :
🞇External Entity - people or organisations
that send data
into the system or receive data from the system.

🞇 Process - models what happens to the data


i.e. transforms incoming data into outgoing
data.

🞇 Data Store - represents permanent data that is


used by the system.

🞇Data Flow - models the actual flow of the data


between
6
the other elements.
Symbol naming

🞇External Entity 
Noun

🞇Data Flow  Names


of data

🞇 Process  verb phrase

🞇Data Store  Noun


7
External Entities
⚫ They either supply or receive data
• Source – Entity that supplies
data to the system.
• Sink – Entity that receives data
from the system.
⚫ They do not process data
Processes Types:
- Black hole
1.
- Miracle
STOR
- Grey Hole
1. ES
0
Grade Grade
Detail Report
Produc
e
Grade
Report

⚫ Work or actions performed on data (inside the


system)
⚫ Straight line with incoming arrows are input data
flows
⚫ Straight lines with outgoing arrows are output
data flows
Processes
⚫ Canhave more than one outgoing
data flow or more than one
incoming data flow
1.
Graded
0
Submitted Work
Grade
Work Studen Student
t Work Grade

3.
Hours 0
Worked Gross Pay
Calculate
Pay
d Gross
Rate Pay
Processes
⚫ Can connect to any other symbol (including
another process symbol)
⚫ Contain the business logic, also called
business rules
⚫ Referred to as a black box

1. 2. Inventor
Order 0 Accepted 0 y
Order Change
Verif Assembl
y e
Orde Order
r
Data Stores
Data store

D1 Data D1 Data D1 Data


Stores StoresWritin Stores Readin
Data g g
store

⚫ 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
Data Flows Data Flow

⚫ Data in motion
⚫ Marks movement of data through the
system
- a pipeline to carry data.
⚫ Connects the processes, external
entities and data stores.
Data Flow
⚫ Generally unidirectional, If same data
flows in both directions, double-
headed arrow can be used.
⚫ Can represent flow between process
and data store by two separate
arrows
2.
Payment
1
Detail
D Accounts
Invoice Receivabl
Post 1
Detail
Paymen e
t
Decomposition Of DFD

Levels Description Explanation

Contains only one


Level 0 Context diagram
process
Utilizes all four
Level 1 Overview diagram
elements
A breakdown
Level 2 Detailed diagram of a level 2
process

There is no rule as to how many levels of DFD that can be


used.
Rules for Level 0 Diagram :
🞇 1 process represents the entire system.

🞇 Data arrows show input and output.

🞇Data Stores NOT shown. They are within the


system.

1
Layers of DFD Abstraction for Course Registration System

1
8
A Context Diagram (Level 0)
⚫ The major information flows between the
entities and the system.

⚫ A Context Diagram addresses only one


process.

1
Rules for Level 1 Diagram :
🞇 Level 1 DFD, must balance with the context
diagram it describes.

🞇 Input going into a process are


different from outputs leaving the process.

🞇 Data stores are first shown at this level.

2
Rules for Level 2 Diagram :
🞇Level 2 DFD must balance with the Level 1 it
describes.

🞇 Input going into a process are


different from outputs leaving the process.

🞇 Continue to show data stores.

2
Numbering
🞇 On level 1 processes are numbered 1,2,3…

🞇 On level 2 processes are numbered x.1, x.2,


x.3… where x is the number of the parent
level 1 process.

🞇Number is used to uniquely identify


process not to
represent any order of processing

🞇 Data store numbers usually D1, D2, D3...

2
Rules of Data Flow
⚫ Data can flow from ⚫ Data cannot flow
from
 External entity to ⚫ External entity to
process external entity
 Process to external ⚫ External entity to
entity store
 Process to store and ⚫ Store to external
back entity
 Process to process ⚫ Store to store
Common errors in DFD

2
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
⚫ Only previously stored data can be read
⚫ A process can only transfer input to output.
It cannot create new data
⚫ Data stores cannot create new data
Creating DFDs
⚫ Create a preliminary Context Diagram.
⚫ Identify Use Cases, i.e. the ways in which
users most commonly use the system.
⚫ Create DFD fragments for each use case.
⚫ Create a Level 0 diagram from fragments.
⚫ Decompose to Level 1,2,…
⚫ Validate DFDs with users.
Creating the Context Diagram
⚫ Draw one process
representing the entire
system (process 0)
⚫ Find all inputs and outputs
that come from or go to
external entities; draw as
data flows.
⚫ Draw in external entities
as the source or
destination of the data
flows.
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 use 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
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.
Validating DFD

⚫ Check for syntax errors


to assure correct DFD
structure.
⚫ Check for semantics
errors to assure
accuracy of DFD relative
to actual/desired
system.
DFD for University Admission
System
Context
Diagram

Student Report
Information 0 Request

Student Universi Staff


ty
Admissio
n
Admission System Repor
Approval or t
Rejection
Level 0

Studen Report
t Request
Studen
Informati t Name
1 3 Data
on & ID Item
Admission Perfor Generat Promp
Student Approval or t Staff
m Intak e Dat
Rejection e Dat Report a
Procedur a s Item
e Prior Quer s Repor
Approve Applicatio y Dat t
d n Data a
Applicatio D1 Student
n Data
Verified
Approve
2 d
Applicatio
Maintai n
n Stude Other Student
nt Data
Informati Request for
on Student Information
Maintenance
Level 1 Process 1, Perform Intake Procedure

Studen
t
Informati Admission
on 1. 1.
1 Application 2
Student Receive Verify
Student Admissio
Admissio Name n
n and ID Applicati
Applicatio on
n Verified
Prior Admissio
Applicatio D1 Student n
n Data Data Applicati
Applicatio on
Applicati n
on Data
Reques 1.
Application
t 3
Approval or Approved
Rejection Review
Application
Admissio
n
Applicatio
n
Level 1 Process 2, Maintain
Student
Information

Approved 2.
Application 2
to Add Add
New
Stude Verified
nt Verified Approved
Changed Applicatio
2.
3 Student n
Approved Approved Application to Edit Data
Application 2. Edit
1 Existing
Request for Determi ID of Studen D1 Student Data
Student Information ne Student t
Maintenance 2.
Operatio to 4
n Delete Verified ID
Delet
e of Student to
Existin Delete
g
2.
Stude 5
nt
Determination Cance
to Cancel l
Operation Operatio
n
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
PROCESS FLOW
A Process Flow Diagram (PFD) represents the
sequence of actions, decisions, and interactions in a
process. Unlike DFDs, which focus on data movement,
PFDs focus on the workflow and procedural steps.
Components of a Process Flow Diagram

1. Start/End – Represented by ovals, indicating the


beginning and conclusion of a process.
2. Process Steps – Represented by rectangles, showing
individual tasks or actions.
3. Decision Points – Represented by diamonds,
indicating points where decisions are made, leading
to different outcomes.
4. Arrows – Show the flow of steps in the process.
Uses of a Process Flow Diagram
 Helps in understanding and improving workflow
efficiency.
 Identifies bottlenecks in a process.
 Serves as documentation for business processes.
Questions
? ??
Thanks for
your
Cooperation

You might also like