0% found this document useful (0 votes)
365 views

Learning Material - System Analysis and Design

The syllabus covers 16 modules on system analysis and design: 1. The first module distinguishes between data and information, and covers different types of information needed at various management levels and functions. 2. Module 2 discusses the systems analysis and design life cycle, including requirements determination, feasibility analysis, system design, implementation, and evaluation. 3. Modules 3-16 cover additional topics like information gathering techniques, feasibility analysis tools, structured and object-oriented analysis, security, electronic commerce systems, and a case study applying the full life cycle.

Uploaded by

taurus_vadivel
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
365 views

Learning Material - System Analysis and Design

The syllabus covers 16 modules on system analysis and design: 1. The first module distinguishes between data and information, and covers different types of information needed at various management levels and functions. 2. Module 2 discusses the systems analysis and design life cycle, including requirements determination, feasibility analysis, system design, implementation, and evaluation. 3. Modules 3-16 cover additional topics like information gathering techniques, feasibility analysis tools, structured and object-oriented analysis, security, electronic commerce systems, and a case study applying the full life cycle.

Uploaded by

taurus_vadivel
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 697

System Analysis and Design

Syllabus

SYSTEM ANALYSIS AND DESIGN


Module 1: Data and Information (3)
Types of information: operational, tactical, strategic and statutory why do we need
information systems management structure requirements of information at different
levels of management functional allocation of management requirements of
information for various functions qualities of information small case study.
Module 2: Systems Analysis and Design Life Cycle (3)
Requirements determination requirements specifications feasibility analysis final
specifications hardware and software study system design system implementation
system evaluation system modification. Role of systems analyst attributes of a
systems analyst tools used in system analysis
Module 3: Information gathering (3)
Strategies methods case study documenting study system requirements
specification from narratives of requirements to classification of requirements as
strategic, tactical, operational and statutory. Example case study
Module 4: Feasibility analysis (3)
Deciding project goals examining alternative solutions cost benefit analysis
quantifications of costs and benefits payback period system proposal preparation for
managements parts and documentation of a proposal tools for prototype creation
Module 5: Tools for systems analysts (3)
Data flow diagrams case study for use of DFD, good conventions leveling of DFDs
leveling rules logical and physical DFDs software tools to create DFDs
Module 6: Structured systems analysis and design (3)
Procedure specifications in structured English examples and cases decision tables for
complex logical specifications specification oriented design vs procedure oriented
design
Module 7: Data oriented systems design (3)
Entity relationship model E-R diagrams relationships cardinality and participation
normalizing relations various normal forms and their need some examples of
relational data base design.
Module 8: Data input methods (3)
Coding techniques requirements of coding schemes error detection of codes
validating input data input data controls interactive data input
Module 9: Designing outputs (2)
Output devices designing output reports screen design graphical user interfaces
interactive I/O on terminals.

V.Rajaraman/IISc, Bangalore

V1/1-6-04/1

System Analysis and Design

Syllabus

Module 10: Object oriented systems modeling (4)


What are objects? Why objects? Objects and their properties classes inheritance
polymorphism how to identify objects in an application how to model systems using
objects some cases of object oriented system modeling
Module 11: Control audit and security of information systems (4)
Audit and security of information systems why controls are needed objectives of
control techniques used in control auditing information systems auditing around,
through and with the computer testing information systems types of tests how to
generate tests security of information systems disaster recovery business process
continuity
Module 12: Systems analysis and design in the era of electronic commerce (3)
B2B, B2C and C2C e-commerce advantages and disadvantages of e-commerce. Ecommerce system architecture physical networks, logical network, World Wide Web,
web-services html, XML.
Module 13: Electronic data interchange (2)
EDI standards virtual private networks XML and EDI.
Module 14: Security of e-commerce transactions, firewalls (3)
Encryption methods symmetric and asymmetric encryption digital signature
certifying authorities for signatures legal status of e-commerce transactions
Module 15: Payment systems in e-commerce (2)
Cheque payment, credit card payments, e-cash payments.
Module 16: Complete system analysis and design case studies (5)
A system for journal acquisition in libraries walk through the entire life cycle

V.Rajaraman/IISc, Bangalore

V1/1-6-04/2

System Analysis and Design

Syllabus

Lecture Plan
Modules
1. Data and
Information

1.
2.

3.

2. Systems
Analysis and
Design Life
Cycle

3. Information
gathering

4. Feasibility
analysis

5. Tools for
systems analysts

4.
5.

Learning Units
Types of information: operational, tactical,
strategic and statutory
Why do we need information systems,
management structure, requirements of
information at different levels of management
Functional allocation of management,
requirements of information for various
functions
Qualities of information small case study
Systems Analysis and Design life Cycle:
Requirements determination, requirements
specifications

6. Feasibility analysis, final specifications,


hardware and software study, system design,
system implementation, system evaluation,
system modification.
7. Role of systems analyst attributes of a
systems analyst tools used in system analysis
8. Information gathering, strategies, methods
9. Case study/documenting study, system
requirements specification, from narratives of
requirements to classification of requirements
as strategic, tactical, operational and statutory.
Example case study
10. How to formulate project goals and quantify
them
11. Examining alternative solutions and evaluating
proposed solutions
a) Technical feasibility
b) Operational feasibility
c) Economic feasibility
12. Cost benefit analysis, Documenting feasibility
report
13. Developing Data Flow Diagrams (DFD)
a) What are DFDs?
b) Symbols used in DFD
c) Rules of data flow
d) Good style in drawing DFD
14. Describing systems with DFD & Leveling
DFD
15. Logical & Physical DFDs

V.Rajaraman/IISc, Bangalore

Hours
per topic
0.5

Total
Hours

1
3
1

0.5
1
3
1

1
1
3
2

3
1

1.5
3
1
0.5

V1/1-6-04/3

System Analysis and Design

6. Structured
systems analysis
and design

16. Structured English specification


17. Decision table based specification
18. Detecting
19. Incompleteness
20. Ambiguity
21. Contradictions
22. Redundancy
23. in decision table specification
24. Eliminating redundancy in specifications
25. Decision trees for specification

7. Data oriented
systems design

8. Data input
methods

9. Designing
outputs

10. Object
oriented systems
modeling

11. Controlaudit and


security of
information
systems

26. Entity-relationship (E-R) modeling


27. of data elements of an application
28. Organization of data as relations
29. Normalization of relations
30. Creation of logical relational database
31. Objectives of database management system
(DBMS)
32. Overview of DBMS
33. Data input methods, coding techniques,
requirements of coding schemes
34. Error detection of codes, validating input data
35. Input data controls interactive data input
36. Designing outputs, output devices, designing
output reports
37. Screen design, graphical user interfaces,
Interactive I/O on terminals.
38. Object oriented systems modeling
39. What are objects? Why objects?
40. Objects and their properties, classes,
inheritance, polymorphism
41. How to identify objects in an application, how
to model systems using objects
42. Some cases of object oriented system
modeling
43. Control, audit and security of information
system
44. Why controls are needed, objectives of control,
techniques used in control
45. Auditing information systems, auditing
around, through and with the computer
46. Testing information systems, types of tests,
how to generate tests

V.Rajaraman/IISc, Bangalore

Syllabus

1
1

4.5

1
0.5
1
0.5
1
1

1
0.5
1
1

1
1
1

0.5
0.5
1
1

1
0.5
0.5
1

V1/1-6-04/4

System Analysis and Design

12. Systems
analysis and
design in the era
of electronic
commerce

13. Electronic
data interchange
14. Security of ecommerce
transactions,
firewalls

15. Payment
systems in ecommerce
16. Complete
system analysis
and design case
studies

47. Security of information systems, disaster


recovery, business process continuity
48. Systems analysis and design in the era of
electronic commerce
49. B2B, B2C and C2C e-commerce, advantages
and disadvantages of e-commerce.
50. E-commerce system architecture
51. Physical networks, logical network, world
wide web, web-services html, XML
52. Electronic data interchange, EDI standards
53. Virtual private networks XML and EDI.
54. Security of e-commerce transactions, firewalls,
encryption methods, symmetric and
asymmetric encryption,
55. Digital signature, certifying authorities for
signatures, legal status of e-commerce
transactions
56. Payment systems in e-commerce, cheque
payment, credit card payments, e-cash
payments.
57. Complete system analysis and design case
studies, a system for journal acquisition in
libraries, walk through the entire life cycle

V.Rajaraman/IISc, Bangalore

Syllabus

1
0.5
0.5
4
1
2
1
1

1.5
3
1.5

V1/1-6-04/5

System Analysis and Design/ Data and Information

Learning Objectives

Learning Objectives
Distinction between Data and Information
Description of types of Information: Tactical, Operational, Strategic and
Statutory.
Division of Management into different hierarchical levels.
Type of Information needed at different levels of management.
Division of organizations into several functional areas and their information
Requirements
Attributes of Information.

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design / Data and Information

Motivation

Motivation
Large number of jobs today for computer science and engineering graduates is in
creating information systems for managing organizations we thus need methods to
design complex systems.
Students should know what information is and how it is different from data.
Should know types of information needed to manage organizations.
Should know nature of organizations and their structure to design appropriate
information system.
Should know management structure and needs of each level of management.
Should know functional areas of management information needs for each area.

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

Data and Information


Data : Raw Material
Data collection costs money
Collect only necessary and sufficient data
Data is generally used by machines
Data is useless unless it is processed to
create Information

V.Rajaraman

SAD/M1/LU1/V1/2004

Data and Information

Information : Processed data


Data processed by machines giving information
Information is used to run an organization efficiently
Information used by managers to initiate actions

V.Rajaraman

SAD/M1/LU1/V1/2004

Example of Information
needed by a Shopkeeper
Daily sales account
List of low stock items to be re-ordered
List of overstock items
Long overdue payments
Profit and loss account
Used to streamline day to day operations called
Operational information

V.Rajaraman

SAD/M1/LU1/V1/2004

Example of Information
needed by a Shopkeeper (Contd)
Slow or fast moving items
Reliable supplier of items
Sales trends
Used to improve profitability of shop called
Tactical information

V.Rajaraman

SAD/M1/LU1/V1/2004

Example of Information
needed by a Shopkeeper (Contd)
Whether to stock different varieties of items
Whether to diversify
Whether to start a new branch in a different locality
Whether to start an e-shop
Information to expand business and explore new opportunities
Known as Strategic Information

V.Rajaraman

SAD/M1/LU1/V1/2004

Example of Information
needed by a Shopkeeper (Contd)
Income tax account
Sales tax account
Used to provide information to the government
Known as Statutory Information

V.Rajaraman

SAD/M1/LU1/V1/2004

Types of Information

Strategic : Needed for long range planning and directions.


This is less structured.
Tactical : Needed to take short range decisions to improve
profitability and performance.

V.Rajaraman

SAD/M1/LU1/V1/2004

Types of Information
Operational : Needed for day to day operations
of the organization.
Eg: Daily Sales, Billing.
Statutory : Needed by law to sent to government
authorities.
Eg: Sales tax return.

V.Rajaraman

SAD/M1/LU1/V1/2004

Management Hierarchy and


Information Needs
Volume of
Information
Low
condensed
Medium
moderately
processed

Type of
Information
Unstructured
Moderately
structured

Top
Managers
Middle
Managers

Tactical
Short range improvement

Line managers

Operational
Day to day policies

Large
Highly
Detailed Reports structured

V.Rajaraman

StrategicLong range planning

SAD/M1/LU1/V1/2004

Need for
Information Systems
Increasing size of organizations thus data volume increases
Timely processing for fast action
Better competitiveness with better information
Increasing of complexity of organizations require
innovative processing
Distributed organizations
Same data can be processed in different ways

V.Rajaraman

SAD/M1/LU2/V1/2004

Management Structure
Chief Executive (Strategical)
(Tactical)
Production
manager

Marketing
manager

Materials
manager

Finance
manager

Human
Resource
manager

(Operational)
Line managers

V.Rajaraman

SAD/M1/LU2/V1/2004

Management Structure
(Contd)
Top Management

Chief Executive known as CEO


Executive Directors for each functional areas such as
Production, Finance, HRD etc.
Take strategic decisions

V.Rajaraman

SAD/M1/LU2/V1/2004

Management Structure
(Contd)
Middle Management

General managers, divisional managers, Vice presidents etc


Each functional area may have 2 to 3 middle level
managers reporting to top management
Take Tactical decisions

V.Rajaraman

SAD/M1/LU2/V1/2004

Management Structure
(Contd)
Line Managers
Group managers, Assistant Group managers, Assistant managers
Each functional area may have several line managers reporting to
middle level managers.
Take Operational decisions

V.Rajaraman

SAD/M1/LU2/V1/2004

Management Structure
(Contd)
Functional Areas
Production
Marketing
Materials Purchase, Stores
Finance Accounts
Human Resource Development (hrd)
Research And Development (R&D)
V.Rajaraman

SAD/M1/LU3/V1/2004

Management Structure
(Contd)
Functional Areas
All organizations need not have identical functional areas
However some are common such as
- Marketing
- Finance
- Human Resource Development (hrd)
V.Rajaraman

SAD/M1/LU3/V1/2004

Information for Management


Production Management
Strategic Information
Yearly and monthly production quotas and alternate
schedules
Policies on machine replacement, augmentation,
and modernization.
Identifying best product mix.
V.Rajaraman

SAD/M1/LU3/V1/2004

Information for Management


Production Management
Tactical Information
Identifying and controlling areas of high cost.
Identifying critical bottlenecks in production.
Identifying alternate production schedules based on tools,
machines etc.
Performance measures of machines to decide replacement.

V.Rajaraman

SAD/M1/LU3/V1/2004

Information for Management


Production Management
Operational Information
Monitoring up to date production information by examining
assemblies, detecting likely shortages and giving early warning.
Scheduling better production dynamically.
Preventive maintenance schedules.
Monitoring tool, machine and personnel availability
V.Rajaraman

SAD/M1/LU3/V1/2004

Information for Management


Marketing Management
Strategic Information
Search for new markets and marketing strategies.
Analysis of competitors strategy.
Technology and demographic forecasts and
product changes.

V.Rajaraman

SAD/M1/LU3/V1/2004

Information for Management


Marketing Management
Tactical Information
Advertising techniques and analysis of their impact.
Customer preference surveys.
Correlation of prices and sales.
Sales force deployment and targets.
Exploring alternate marketing channels.
Timing of special sales campaigns.
V.Rajaraman

SAD/M1/LU3/V1/2004

Information for Management


Marketing Management
Operational Information
Sales analysis by regions, customer class, sales person.
Sales target versus achievement.
Market share and trends.
Seasonal variations.
Effect of model changes.
Performance of sales outlets
Costs of campaigns and benefit.
V.Rajaraman

SAD/M1/LU3/V1/2004

Information for Management


Material Management
Strategic Information
Developing vendors for critical items.
Determining optimal levels of inventory
Determining proportion of material needed
Reducing varieties of inventory.
V.Rajaraman

SAD/M1/LU3/V1/2004

Information for Management


Material Management
Tactical Information
Developing vendor performance measures.
Determining optimal reorder levels.
Determining issues of items to shops versus standard needs.
Controlling high value of inventory.
Determining impact on material cost and procurement with
design changes and new product introduction.
V.Rajaraman

SAD/M1/LU3/V1/2004

10

Information for Management


Material Management
Operational Information
List of excess & deficient items received.
List of items rejected.
Critical items received.
Stores in transit and in inspection.
Value of inventory in hand.
Goods received, rejected and issued.
V.Rajaraman

SAD/M1/LU3/V1/2004

11

Information for Management


Finance Management
Strategic Information
Methods of financing.
Pricing policies.
Tax planning.

V.Rajaraman

SAD/M1/LU3/V1/2004

12

Information for Management


Finance Management
Tactical Information
Variations between budget and expenses.
Large outstanding payments/Receipts.
Credit and payment status.
Cost increases and pricing.
Impact of taxation on pricing

V.Rajaraman

SAD/M1/LU3/V1/2004

13

Information for Management


Finance Management
Operational Information
Periodic financial report.
Budget status to all functional managers.
Tax returns.
Share transfers.
Profit and loss account.
Payments and receipts.
Payroll, provident fund accounts.
V.Rajaraman

SAD/M1/LU3/V1/2004

14

Information for Management


Human Resource Management
Strategic Information
Long range human resource requirements
at different levels.
Policies on human resource development and training
Policies on personnel welfare and facilities

V.Rajaraman

SAD/M1/LU3/V1/2004

15

Information for Management


Human Resource Management
Tactical Information
Performance appraisal.
Demographic make-up of personnel and its
impact on retirement.
Production incentives.
Morale of personnel.
Absentee reduction.
Leave and overtime policies.
Personnel deployment policies.
V.Rajaraman

SAD/M1/LU3/V1/2004

16

Information for Management


Human Resource Management

Operational Information
Routine assessment.
Skills inventory.
Loan/advances and recoveries.
Leave record.

V.Rajaraman

SAD/M1/LU3/V1/2004

17

Information for Management


Research Design & development Management
Strategic Information
Which products are to be developed?
What types of improvements are required?
What long range research is more promising?
What technical collaboration would be appropriate?
V.Rajaraman

SAD/M1/LU3/V1/2004

18

Information for Management


Research Design & development Management
Tactical Information
Setting intermediate goals.
Checking availability of equipment & appropriate selection
Determining proportions of resources to be allocated to
different projects.
Deployment of personnel to projects.
Information on similar and related research
projects undertaken by other companies
V.Rajaraman

SAD/M1/LU3/V1/2004

19

Information for Management


Research Design & development Management

Operational Information
Progress against goals.
Budgeted expenses versus actual expenses.
Status of outstanding orders for equipment and
components.

V.Rajaraman

SAD/M1/LU3/V1/2004

20

Qualities of Information

Quality

How to ensure quality

Accurate

Ensure correct input and processing rules.

Complete

Include all data.

Timely

Give at right time

V.Rajaraman

SAD/M1/LU4/V1/2004

Qualities of Information
Quality
Trustworthy

How to ensure quality


Do not hide unpleasant
information.

Relevant

Understand user needs.

Brief

Summarize relevant
information.

V.Rajaraman

SAD/M1/LU4/V1/2004

Qualities of Information
Quality

How to ensure quality

Up-to-date

Include all data up to


present time.

Significance

Use attractive format &


graphical charts.

V.Rajaraman

SAD/M1/LU4/V1/2004

Varieties of
Information Systems
Business Data processing
Operational information
Management information system
Tactical information
Decision support system(DSS)
Strategic information

V.Rajaraman

SAD/M1/LU5/V1/2004

Business Data
Processing System
Enter data to be processed
Edit, check input data
Control check to see if the data is correct and
reasonable
Store clean data as an organized data base in a storage

V.Rajaraman

SAD/M1/LU5/V1/2004

Business Data Processing


There are 2 methods of business data processing
1. On-line transaction processing (OLTP)
2. Batch processing
OLTP is used for query processing and rapid actions to requests
Example: Finding balance in ones bank account
Booking railway tickets
Batch processing used for periodic data processing of massive data
Example: Processing university exam results at the end of
each semester
Payroll computation each month
V.Rajaraman

SAD/M1/LU5/V1/2004

Online
Transaction Processing
Database (or master file) available online on disk
Request in specified format accepted from requestor
Check request for validity
Retrieve record from database
Take appropriate action

V.Rajaraman

SAD/M1/LU5/V1/2004

Batch Processing
Collect a batch of requests
Key in
Validate
Create request file
Called transaction file
Update master file using transaction file
Create result file
Print responses for requests

V.Rajaraman

SAD/M1/LU5/V1/2004

OLTP Vs Batch
Response time
Throughput
(No of transaction/unit time)
Enquiry systems
Periodic Processing

Once a day
Once a month

V.Rajaraman

OLTP Fast

Batch High
Online
Batch

- Stores Issues
- Payroll

SAD/M1/LU5/V1/2004

Management
Information System
Analyze outputs of routine data processing using
statistical or operations research tools
Eg: -Observe periodic demands by statistical analysis &
use for tactical decisions
- Use operations research tools to decide product mix
using demand and cost data to maximize profit

V.Rajaraman

SAD/M1/LU5/V1/2004

Decision Support System

Unstructured and difficult to obtain precise information


Use of analytical and simulation models
Aids to conceptualise through graphs ,animation etc
Use of archival data to infer trends and rules
Some artificial intelligence tools may be used

V.Rajaraman

SAD/M1/LU5/V1/2004

Decision Support System


Data mining a useful tool
What is data mining?
Data collected during routine data processing archived
over a long period-massive amount (Tera Bytes)
Some hypothetical rules guessed by experienced managers
and correlated with archival data-called data mining

V.Rajaraman

SAD/M1/LU5/V1/2004

Decision Support System


Example of data mining
From archival data a rule guessed by managers
that in some months there are long waiting lists for sleeper
berths is verified-Data mining gives precise quantitative data
Action
Increase number of sleeper coaches
or
Introduce special trains
Unexpected results of analysis of archival data more
valuable for DSS
V.Rajaraman

SAD/M1/LU5/V1/2004

10

System Analysis and Design/Systems Analysis and Design Life Cycle

Learning Objectives

Learning Objectives

Nine Steps in designing Information Systems

Tasks performed in each step.

Nature of tasks performed by Systems Analysts.

The attributes of Systems Analysts.

The tools used by Systems Analysts

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/System Analysis and Design Life Cycle

Motivation

Motivation
Designing Information system for an organization is very complex job.
Students should know how to logically divide a complex job into smaller
manageable steps.
Each step must have a logical beginning and end and must be self contained.
Division of large jobs into logical steps will
Enable one to assess progress at the end of each step
Steps may be assigned to persons with specialized competence
Allocation of human and financial resources appropriate for each step can
be planned

V. Rajaraman

//V1/July 04/1

Life Cycle Of Systems


Analysis And Design
Steps involved in Analysis and Design
1. Requirements Determinations
2. Requirements Specifications
3. Feasibility Analysis
4. Final Specifications
5. Hardware Study
6. System Design
7. System Implementation
8. System Evaluation
9. System Modification

V.Rajaraman

SAD/M2/LU1/V1/2004

Life Cycle Of Systems


Analysis And Design
Step 1 : Requirements Determination
Arrived at by a consensus among managers
Priorities among applications determined
Pick high priority applications.

V.Rajaraman

SAD/M2/LU1/V1/2004

Life Cycle Of Systems


Analysis And Design
Step 2 : Requirements Specification
Known as System Requirements Specification (SRS)
Understand the existing System
Applications where a system is required are listed
Arrive at the specifications of the users Requirements
after discussions with the user
A system may encompass several applications

V.Rajaraman

SAD/M2/LU1/V1/2004

Life Cycle Of Systems Analysis And


Design
Step 3 : Feasibility Analysis
Formulate Goals of the system and quantify goals
Find alternative methods of meeting the goals
For each alternative assess resources needed
- Human Resources
- Time and Money
- Equipment needed
Assess cost of each alternative
Find the best alternative method subject to resource
constraints
V.Rajaraman
V.Rajaraman

SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004

Life Cycle Of Systems


Analysis And Design
Step 4 : Final Specifications
Specifications would state what the system would
achieve.
Specification drawn up are improved for
implementation.
SRS written- given to user and agreement
reached

V.Rajaraman
V.Rajaraman

SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004

Life Cycle Of Systems Analysis And


Design
Step 5 : Hardware Study
Determine Hardware and Software required
to execute the application.
Determine Response time,Volume of data to
be processed, Frequency of reports etc & then
pick the hardware.

V.Rajaraman
V.Rajaraman

SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004

Life Cycle Of Systems Analysis And


Design
Step 6 : System Design
Logical Design of the System
Objects Identified
Database Designed
Program Specification drawn up
Implementation Plan Drawn up
Test Plan

V.Rajaraman
V.Rajaraman

SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004

Life Cycle Of Systems Analysis And


Design
Step 7 : System Implementation
Write Programs
Create Database
Document System
Train Users
Trial run of the system
Test and Accept

V.Rajaraman
V.Rajaraman

SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004

Life Cycle Of Systems Analysis And


Design
Step 8 : System evaluation
Find out from Users whether the System
meets specified requirements.
List areas of dissatisfaction and find reasons
Suggest if there has to be any improvements to
the system

V.Rajaraman
V.Rajaraman

SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004

Life Cycle Of Systems Analysis And


Design
Step 9 : System Modification
Fix errors
Add/Delete features as required by users
Tune the Syste
Continuously monitor system and assess
performance

V.Rajaraman
V.Rajaraman

SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004

System Life Cycle Diagram


Requirements
Determination
Decision to
Design Information
System
System
Implementation
System

User
Requirements

Revised Prioritized
Requirements Specifications

Test Plan
Logical
Design

System
Design

Configuration
Data

System
Evaluation
Revised
Requirements

Functional
Specifications

Feasibility
Study

System
Specification
Analysis

Physical
Requirements

Hardware
Study

System
Maintenance
V.Rajaraman
V.Rajaraman

Feasibility
Analysis

Requirements
Specification

Budget & schedule

Improved System
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004

Role Of Systems Analyst


Defining Requirements
- Involves Interviewing Users
Prioritizing Requirements
- Obtain Users Consensus
Fact Gathering
- Data, Facts, Opinions of Managers
- Lower level Users should be consulted

V.Rajaraman

SAD/M2/LU3/V1/2004

Role Of Systems Analyst


Analysis and evaluation
- Arrive at appropriate system
Solving problems
- Hazy requirements converted into specific requirements
- Suggest many alternative solutions
- Quantify cost and benefits

V.Rajaraman

SAD/M2/LU3/V1/2004

Role Of Systems Analyst


Drawing up specifications
- Functional Specifications
- Understood by users and programmers
- Accepted by users
- Precise and detailed
- Account for possible changes

V.Rajaraman

SAD/M2/LU3/V1/2004

Role Of Systems Analyst


System Design
Logical design of system
- Objects identification
- Normalizing database
- Test plan
Design must be modular to accommodate change

V.Rajaraman

SAD/M2/LU3/V1/2004

Role Of Systems Analyst


Evaluating Systems
- Evaluation after use for sometime
- Plan periodicity for evaluation
- Modify as needed

V.Rajaraman

SAD/M2/LU3/V1/2004

Attributes Of A Systems Analyst

Knowledge Of Organisation
- Knowing users jargon & practices
- Know Management functions.
Knowledge Of Computers And Software
- Knowledge of system design tools
- Keep abreast of modern developments

V.Rajaraman

SAD/M2/LU3/V1/2004

Attributes Of A Systems Analyst


Good Interpersonnal Relations
- Need to work as team member
- Lead smaller teams
- Interface with programmers & Users
- Motivator.
Ability To Communicate
- Oral Presentation
- Report Writing
- Answer queries
V.Rajaraman

SAD/M2/LU3/V1/2004

Attributes Of A Systems Analyst


Analytical Mind
- Problem solving attitude
- Ability to assess trade offs
- Sound commonsense
- Curiosity to learn about new organizations
Breadth Of Knowledge
- Broad Liberal Knowledge
- Variety of jobs to be tackled in diverse organizations

V.Rajaraman

SAD/M2/LU3/V1/2004

Tools Used By Systems Analyst


Data Flow Diagram
Decision Tables
Modeling Language such as UML
Normalization of Databases
Testing tools
ISO/CMM procedure manuals

V.Rajaraman

SAD/M2/LU3/V1/2004

System Analysis and Design/ Information gathering

Learning Objectives

Learning Objectives

Strategy to gather information for computerization.

Various sources of information.

Methods of searching for information.

Interviewing techniques to gather information from line managers to top


management.

Methods of consensus for formulating requirements.

Use of document flow diagrams to depict flow of documents in an organization

Specification of Operational, tactical and strategic information which will be


provided by the system

Use of dataflow diagrams to specify flow of records and how they will be
processed to create reports

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/Information Gathering

Motivation

Motivation

The Information system designed for an organization must meet the requirements
of the end users of the organization.

To obtain what an end user expects from the Information System the designer
must gain complete knowledge of the organizations working.

It is important for the student to know the information gathering techniques so


that no information is overlooked and the nature and functions of an organization
are clearly understood

The main purpose of gathering information is to determine the information


requirements of an organization.

Information requirements are often not stated precisely by management.

Analysts responsibility to prepare a precise Systems Requirement Specifications


understood (SRS) by users.

SRS document is a vital document before starting a project.

V. Rajaraman

//V1/July 04/1

Information
Gathering Strategies

Identify Information sources


Evolve a method of obtaining information from
the identified sources.
Use Information flow model of organization.

V. Rajaraman

SAD/M3/LU1/V1/2004

Information Sources
Users of System
Forms and Documents used in the organization
Procedure manuals, rule books etc.
Reports used by the organization
Existing computer programs(If Any).
V. Rajaraman

SAD/M3/LU1/V1/2004

Information Sources
Interviews are very important
Use organization chart
Understand the importance of the people who
operate the system-Clerks,Line managers.
Gather information from Middle level persons who have lot of
experience
Gather both qualitative and quantitative
information & Observe how the organization works.
V. Rajaraman

SAD/M3/LU1/V1/2004

Information
Gathering Methods
Searching for information

Individual Interviews
Group discussions
Several Interviews needed.

V. Rajaraman

SAD/M3/LU2/V1/2004

Planning an Interview

Make a list of people to be interviewed and in what order


Plan and note down a list of questions to be asked
Plan several interviews with same person-mainly to
clarify doubts
Interview groups as appropriate

V. Rajaraman

SAD/M3/LU2/V1/2004

Interviewing Technique
Make appointment
Allot time
Read background material
State purpose of interview
Be punctual and pay attention to what user says
Do not use computer jargon

V. Rajaraman

SAD/M3/LU2/V1/2004

Interviewing Technique

Obtain both quantitative and qualitative Information


Discriminate between essential and desirable requirements
State what you understand and get it confirmed
Do not prolong interview
Summarize information gathered and get it checked by the
interviewee
V. Rajaraman

SAD/M3/LU2/V1/2004

Use of Questionnaires
Questionnaires useful for statistical data collection
Useful when large number of persons have to respond
Make questionnaires short
Design questionnaires by enumerating objectives and
data needed to meet the objectives
Several follow-ups/personal interviews may be required to
get questionnaires back from respondents
V. Rajaraman

SAD/M3/LU2/V1/2004

Information
Gathering other Methods
Existing system(If any)
Systems in similar organization
Observe workflow in workplace
Case repository in own organization

V. Rajaraman

SAD/M3/LU2/V1/2004

System
Requirements Specification
System requirements specification specifies what
Information requirements will be provided.
It does not specify how the system will be designed
SRS is obtained after excessive discussions with the user.
Developing SRS is most important and difficult task of
a Systems analyst
V. Rajaraman

SAD/M3/LU3/V1/2004

System Requirements
Specification
How SRS is Developed
Analyst examines the current system if any.
Analyst finds out the shortcomings of the system as
seen by the user.
Analysts aim is to develop SRS which is understandable by the
user and which can be used for detailed design of the system.

V. Rajaraman

SAD/M3/LU3/V1/2004

System Requirements
Specification
Ideal characteristics of SRS
Complete and Unambiguous.
Specifies operational,tactical, and strategic information
requirements
Eliminates possible later disputes between users and Analyst
Uses Graphical aids understood by users who are not
computer literate and will also be useful in design.
Jargon Free.
V. Rajaraman

SAD/M3/LU3/V1/2004

From Word
Statement to Srs
Narratives of requirements by users too long and imprecise
Needs conversion to precise specifications
Step1: Analyse statement
Step2: Identify physical entities such as vendors,
receiving office, Inspection office etc.
Step3: Identify documents which are received/sent by
each office
Step4: Draw a physical document
V. Rajaraman

SAD/M3/LU3/V1/2004

Developing a
Document Flow Diagram
Example Word Statement:
Our company receives many items from several vendors each
accompanied by a delivery note. A receiving office receives the
item and checks the delivery note with corresponding order.
Any discrepancy is reported to purchase office. The items received
along with items received note (with details of items) is sent to the
inspection office.
V. Rajaraman

SAD/M3/LU3/V1/2004

Developing a
Document Flow Diagram

Entities Identified - Vendors, Receiving office, Inspection office


Documents Identified - Delivery note, discrepancy note, Items
Received note.
Using these a document flow diagram is drawn

V. Rajaraman

SAD/M3/LU3/V1/2004

System Requirements
Specification
Graphical Specification Tools
Physical document flow diagram.
Logical Data flow Diagram (abbreviated as DFD)
Document flow diagram depicts various entities or offices &
documents generated/transmitted by these entities

V. Rajaraman

SAD/M3/LU3/V1/2004

System
Requirements Specification
Entities represented by Rectangles, Document flow by lines,
direction is shown by arrows.
Document flow lines are labeled by name of the document
Dashed lines used to depict flow of physical items.
Document flow diagram depicts various entities and
documents generated and/or transmitted by these entities

V. Rajaraman

SAD/M3/LU3/V1/2004

Document Flow Diagram


Delivered Items
Receiving
Office

Vendor

Delivery note
Discrepancy
note

Inspection office
Items
Received
note

Purchase Office

Entities in the Document flow diagram given above are Vendor,


receiving office, Inspection office and purchase office
Documents are:Delivery note,items received note and discrepancy note
Physical flows are delivered items

V. Rajaraman

SAD/M3/LU3/V1/2004

Document
Flow Diagram (Contd)
Delivered Items

Vendor
Delivery note

Delivered Items

Receiving
Office

Discrepancy
note

Inspection office
Items
Received
note

Purchase Office

V. Rajaraman

SAD/M3/LU3/V1/2004

10

Document
Flow Diagram (Contd)
The diagram is interpreted as follows:
1) Vendors deliver items to receiving office accompanied
by a delivery note
2) Receiving Office sends items to inspection office along
with an items received note
3) Receiving office sends discrepancy note to Purchase
office
Entities: Vendor,Receiving office,Inspection office and
purchase office
Documents : Delivery note,Items received note and
discrepancy note
V. Rajaraman

SAD/M3/LU3/V1/2004

11

Data Flow Diagram (Dfd)


DFD also has entities and data flows
Besides this DFD specifies processing performed by some of the
entities
Data flow diagrams specify which entities generate documents
Details of documents and their flow
Processing performed by some entities
Data stores which are referred while processing data and in
which processed data may be written or stored
V. Rajaraman

SAD/M3/LU3/V1/2004

12

Data Flow Diagram (Dfd)

Vendor

Delivery
note

Items
Received
note

Receiving
Process

Orders

Inspection
Office

Purchase
Office
Discrepancy
note

V. Rajaraman

SAD/M3/LU3/V1/2004

13

Data Flow
Diagram (Dfd) Contd.
Entities are, originators of data and consumers of data
Vendor, Inspection office and purchase office are entities in
the above diagram
Data flows are delivery note, items received note
and discrepancy note
A circle is used to depict a process
A pair of parallel lines depict a store
V. Rajaraman

SAD/M3/LU3/V1/2004

14

Data Flow Diagram (Contd)

Vendor

Delivery
note

Receiving
Process

Items
Received
note

Orders

Inspection
Office

Purchase
Office
Discrepancy
note

V. Rajaraman

SAD/M3/LU3/V1/2004

15

Data Flow Diagram (Contd)


1) Data in a store may be read by a process
2) Processed data may also be written in a store
3) Circles depicting process are detailed separately
using Structured English Algorithms Or decision tables
4) Data flows are expanded to detail the data elements
5) Contents of the data stores are also detailed

V. Rajaraman

SAD/M3/LU3/V1/2004

16

Data Elements
in Data Flow & Store
Delivery note:
Order no,Vendor code,Vendor name and address,Item name,
Item code, Delivery date,Quantity supplied,units.
Items Received note:
Order no, Item name, Item code, Delivery date, quantity
supplied, units.

V. Rajaraman

SAD/M3/LU3/V1/2004

17

Data Elements
in Data Flow & Store
Discrepancy note:
Order no,Vendor code, Vendor name and address, Item name,
Item code,Order date, Delivery date, quantity supplied, units,
excess/deficiency, No of days late/early.
Receiving office order file:
Order no, Order date, Item name, Item code,
Vendor code, Vendor
Name and address, Quantity ordered, delivery period.
V. Rajaraman

SAD/M3/LU3/V1/2004

18

Processing Rule
English statement
1. Compare order no in delivery note with that in order file. If no
match return item to vendor.
2. If order no matches then compare item codes, if no match return
item to the vendor.
3. If order number matches compare qty delivered with quantity
ordered. If excess or deficient send discrepancy note to purchase
office.
V. Rajaraman

SAD/M3/LU3/V1/2004

19

Processing Rule

4. If order number matches compare date of delivery with


expected date. If late or early send discrepancy note to
purchase office.
In case3 and case4 send items received note to inspection
office.
The above statements are shown to the user for his approval.

V. Rajaraman

SAD/M3/LU3/V1/2004

20

Operational, Tactical
and Strategic Information
For this simple examples are:
Operational: Automatic checking of delivery against order and create
discrepancy note.Note discrepancy (if any) of each order.
Tactical: Evolve vendor performance index based on discrepancy in
supplies and quality inspection.
Strategic: Use performance index to decide proportion of order for an
item to be placed with each vendor.Develop new vendors if
all existing vendors performance are poor.

V. Rajaraman

SAD/M3/LU4/V1/2004

Steps In System Analysis


and Design
User stated
requirements

Study
current
system
Physical document flow diagram
Design
Logical
system
Logical data flow diagram

Feasibility
document
Descriptive
Statement of
Information
V. Rajaraman

New
System
model

New logical
DFD
Data Dictionary

Processing
rules
SAD/M3/LU4/V1/2004

Modularizing Requirements
Specifications
SRS Document
SRS Document now consists of:
Document flow diagrams (as many as needed).
Data Flow Diagrams.
Data elements of each data flow and Data Store

V. Rajaraman

SAD/M3/LU4/V1/2004

Modularizing Requirements
Specifications
SRS Document ( Continued)
Processing rules carried out in each circle of DFD.
A descriptive statement of operational,tactical,strategic
information will be provided
A data dictionary which consolidates all data elements
in the document and data store.

V. Rajaraman

SAD/M3/LU4/V1/2004

System Analysis and Design/ Feasibility analysis

Learning Objectives

Learning Objectives

How to formulate the goals to be met by the information system to be designed

How to quantify the goals

How to obtain alternative solutions to satisfy the goals

How to assess the feasibility of implementing alternative solutions.

How to compute cost vs benefits of each alternative feasible solution

How to prepare a system proposal for the potential users of the system

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/ Feasibility analysis

Motivation

Motivation

Before a management decides to implement a computer based system they should


know the goals which will be met by the system

These goals should primarily be quantitative goals so that when the system is
implemented it is possible to compare quantitatively the achievements with the
original goals set.

Analysts should also be able to estimate what hardware and human resources will
be needed to implement a system to meet the goals

Analyst must examine alternative methods to implement the system and their
resource needs.

A cost-benefit analysis should be carried out for each alternative and given to the
management

This analysis will be essential for a management to decide which solution they
would like to implement

Feasibility of meeting goals with available technology and human resource and
cost/benefit are important parameters for informed management decision making.

V. Rajaraman/IISc, Bangalore

//V1/July 04/1

Feasibility Analysis
The following are the results of the Information gathering phase:
Deficiency of the current system are found
Consensus is arrived at on requirements
SRS Document is prepared

V.Rajaraman

SAD/M4/LU1/V1/2004

Steps In Feasibility Analysis

Evaluate feasibility of alternative solutions taking into account


constraints on resources.
Rank order alternatives and discuss with user.
Prepare a system proposal for management approval

V.Rajaraman

SAD/M4/LU1/V1/2004

Feasibility Analysis (Contd.)

Send bill within 5 days of month end


Find out whether it is possible to meet these goals.
Determine the cost of meeting each goal
Find cost benefit if quantified

V.Rajaraman

SAD/M4/LU1/V1/2004

Guidelines For Searching Goals

Identify the deficiency by pinpointing


-Missing Functions
-Unsatisfactory performance
-Excessive cost of operations
Set Goals to remove deficiency and provide competitive
advantage

V.Rajaraman

SAD/M4/LU1/V1/2004

Characterstics Of a Goal
Must be quantified
Realizable with the constraints of the organization and the
system
Broken down into Sub-Goals
Agreeable to all concerned
In general goals must not only remove deficiency but also give a
system which is superior to those of the competitors of the
organization

V.Rajaraman

SAD/M4/LU1/V1/2004

Case Study-hostel
Information System
(Detailed description of case is given in module3)
DEFICIENCIES OF CURRENT SYSTEM IDENTIFIED
MISSING FUNCTIONS
1.1 Stores requirement not forecast
1.2 Purchases not consolidated
1.3 Daily rate calculation not frequently updated
1.4 Menu not planned for balanced nutrition and low cost

V.Rajaraman

SAD/M4/LU1/V1/2004

Case Study-hostel
Information System
DEFICIENCIES (BAD PERFORMANCE)
UNSATISFACTORY PERFORMANCE
2.1 Billing not accurate and prompt
2.2 Student bills not itemized
2.3 Stores issue to cooks arbitrary
2.4 Payments to vendors not prompt
2.5 Large variations in mess bills every month

V.Rajaraman

SAD/M4/LU1/V1/2004

Case Study-hostel
Information System
DEFICIENCIES (HIGH OPERATIONAL COST)
3.1Unpaid and long outstanding bills from students
3.2 Extras and rebates not reflected in stores issues
3.3 Frequent small purchases at high cost
3.4 High transport cost due to not consolidating stores
requirements

V.Rajaraman

SAD/M4/LU1/V1/2004

Case Study-hostel
Information System
FORMULATIOIN OF GOALS
MAIN GOALS
Ml . Send bill to students within 5 days of the end of month
M2. Control inventory of items in stores & issues to cooks to
bring down mess bill by 10%
M3. Balance menu to meet nutritional requirements
M4. Cost of new menu not to exceed current cost

V.Rajaraman

SAD/M4/LU1/V1/2004

Case Study-hostel
Information System
Formulation Of Sub-goals
S1.1 Itemize bills showing extras and rebates with dates
S1.2 Ensure less than 5% variations of bills from month to month
SI.3 Bills not paid within 10 days of issue brought to the attention
of chief warden
S1.4 Update daily rates every day
Main goals M1 and sub-goals S1.1,S1.2,S1.3 remove deficiencies
1.3,2.1,1.2.2,2.5,3.1

V.Rajaraman

SAD/M4/LU1/V1/2004

10

Case Study-hostel
Information System
FORMULATION OF SUB-GOALS
S2.1 Ensure payment to vendors within five days of
supply of items

S2.2 Maximum 4 trips per month for purchases.


Cartage less than 1% of item cost
V.Rajaraman

SAD/M4/LU1/V1/2004

11

Case Study-hostel Information


System (Contd.)
S2.3 Reduce inventory level. Level not more than 10% of
requirements in a month
52.4 Issue to cooks every day not to exceed 5% of calculated
values
Main goals M1& sub-goals above remove deficiencies
1.1,1.2,2.3,2.4,3.2,3.3,3.4

V.Rajaraman

SAD/M4/LU1/V1/2004

12

Examining
Alternative Solutions
HOSTEL INFORMATION SYSTEM

ALTERNATIVE SOLUTIONS
A: Improve manual system
B: Use PC based periodic update system
C: An on-line system with server and several clients

V.Rajaraman

SAD/M4/LU2/V1/2004

Solution A:
Manual System (Contd.)
Calculate standard quantities needed and use for vendor order
Track student payments to find overdue payments
Solution does not ensure reduction in bill variations and
prompt payment to vendors
Solution not scalable to large student population

V.Rajaraman

SAD/M4/LU2/V1/2004

Solution B
Use a single PC to
Prepare students bills-itemize bills
Prepare number of members who will eat for next two days
Alert warden when bill not paid within 10 days of issue
Vendor order generation
Inventory control of store
Menu planning
V.Rajaraman

SAD/M4/LU2/V1/2004

Solution B (Contd.)
PC configuration needed based on data base sizes
PC with 20 MB disk, 1.2 MB floppy sufficient
However minimum configuration available today(2004) is PC
with 128 MB main memory, 40 GB disk 1.2MB floppy & CD R/W
costs Rs. 25,000.Systems software(Windows XP+MSOffice+antivirus) will cost around Rs.25,000.
Total cost=Rs 50,000
Need PC+ printer+uninterrupted power supply cost Rs. 70,000
V.Rajaraman

SAD/M4/LU2/V1/2004

Solution C
Use a server which is accessed by 3 clients one each in the mess,
the stores and the accounts sections; perform on-line transaction
processing.
Advantage: Up to the minute status can be found
Number of transactions small and does not justify 4 computers
Solution unnecessarily expensive and rejected 0

V.Rajaraman

SAD/M4/LU2/V1/2004

Evaluating
Alternative Solutions
Determine Technical feasibility of each solution,in other words is
technology mature to implement a solution
Determine Operational feasibility of each solution.In other
words,for a given organizational structure will the solution fit in.Will
it provide right information at the right time to users

V.Rajaraman

SAD/M4/LU2/V1/2004

Evaluating
Alternative Solutions (Contd.)

Determine Economic feasibility of each solution.In other


words, are finances available to implement system?Will it be
cost effective?Will the money spent be recovered by savings
or by better services to users

V.Rajaraman

SAD/M4/LU2/V1/2004

Technical And
Operational Feasibility
Solution B is selected for further consideration
It is technically feasible as PC of necessary configuration is easily
available.
It is also operationally feasible as clerks in hostel office can be
easily trained to use a PC. The necessary problems will be written
by system analyst/ programmer hired for this purpose.

V.Rajaraman

SAD/M4/LU2/V1/2004

Cost-benefit Analysis

Needed to find economic feasibility of proposed solution


Objective to find whether returns by implementing a system

justify the cost


Found by listing all costs direct and indirect

V.Rajaraman

SAD/M4/LU1/V1/2004

Cost-benefit Analysis (Contd.)

Direct cost- Cost of computer, software, space, human resource,


material, travel, training etc.
Indirect cost- Time spent by persons and data gathering
Benefit- Tangible- measurable
Intangible - better management
- better user satisfaction

V.Rajaraman

SAD/M4/LU1/V1/2004

Benefits
Direct - Savings due to reduced inventory, early collection of
outstanding payments, reduced wastage,faster production, increased
production
Indirect Increased work done with same human resource
Intangible - better service to customers
- superior product quality
- accurate,reliable,timely and up-to-date
strategic,tactical and operational information to
management
V.Rajaraman

SAD/M4/LU1/V1/2004

Cost Benefits Analysis

CASE STUDY OF HOSTEL INFORMATION SYSTEM


COST : PC,UPS,Printer+Systems analyst+programmer
Capital

70,000

+60,000 =1,30,000

Cost(Recurring) : Stationery, maintenance,floppy etc.


Rs. 2000 per month

V.Rajaraman

SAD/M4/LU1/V1/2004

Cost Benefits Analysis (Contd.)

Benefits : - Inventory reduction 5% of mess bill of 400


students
Daily rate=Rs 45
Savings= 45*0.05*30*400=Rs 27,000
- Transport cost saving=Rs 800 per month
- Savings due to early payment
=material cost*1.2%=37.5*400*30*0.012=Rs 5400
- Savings due to early collection =40*1350*0.01=Rs 540
V.Rajaraman

SAD/M4/LU1/V1/2004

Cost Benefits Analysis


Direct saving=33740
Indirect benefit : student satisfaction due to itemized bill,
predictable daily rate,better menu
Net Direct Saving per month= 33740-2000
=R31740
Total capital cost=l,30,000

V.Rajaraman

SAD/M4/LU1/V1/2004

Pay Back Period


SIMPLE: Cost 1,30,000
Saving 31,740 per month
Cost recovered in 130000/31740 = 4.1 months
Using interest on capital:
Monthly interest=0.015* 1,30,000
=Rs 1950 per month
Saving per month=31740-1950=29790
Cost recovered in 130000/29790 = 4.4 months
V.Rajaraman

SAD/M4/LU1/V1/2004

Present Value Method


Accounts for the fact that a benefit accruing n months later will be
lower today as the money if available today would have earned
interest
If r = Interest rate in % per month.
n = number of months
x = benefit
Present value of benefit accruing n months later is:
Present value = x/(1+r)n
V.Rajaraman

SAD/M4/LU1/V1/2004

System Analysis and Design/ Tools for systems analysts

Learning Objectives

Learning Objectives

What are Data Flow Diagrams (DFDs)?

Why they are useful?

How are they developed?

How to level DFDs?

Good style conventions in developing DFDs

Difference between Logical and Physical DFDs

Tools available to draw DFDs

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/ Tools for systems analysts

Motivation

Motivation

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
Structure of DFD allows starting from a broad overview and expand it to a hierarchy of
detailed diagrams

V. Rajaraman/IISc, Bangalore

//V1/July 04/1

Data Flow Diagrams


WHAT ARE DATA FLOW DIAGRAMS?
DFDs models the system by depicting
External entities from which the data flows and where
results terminate
Processes which transform data flows
Data stores from which the data are read or into
which data are written by the processes.
V.Rajaraman

SAD/M5/LU1/V1/2004

Symbols Used In Dfd


PROCESS
Stores demand
note

1.
STORES Issue Advice

Delivery slip

A circle represents a process


Straight lines with incoming arrows are input data flows
Straight lines with outgoing arrows are output data flows
Processes are given serial numbers for easy reference
Labels are assigned to Data flow.These aid documentation
V.Rajaraman

SAD/M5/LU1/V1/2004

Symbols Used In Dfd


EXTERNAL ENTITIES

VENDOR

Invoice

Order
Customer
Bill

A Rectangle represents an external entity


They either supply data or receive data
They do not process data

V.Rajaraman

SAD/M5/LU1/V1/2004

Symbols Used In Dfd


DATA STORES
Inventory

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
Two data stores cannot be connected by a data flow
V.Rajaraman

SAD/M5/LU1/V1/2004

Rules Of Data Flow


Data can flow from
-external entity to process
-process to external entity
-process to store and back
-process to process
Data cannot flow from
-external entity to external entity
-external entity to store
-store to external entity
-store to store
V.Rajaraman

SAD/M5/LU1/V1/2004

Data Flow Diagrams


An alternate notation is often used
3
Store
Issue

A Process

A Data store

DS1

Inventory

Label
Nam
e

Nam
e
Label

V.Rajaraman

SAD/M5/LU1/V1/2004

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 leveling 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

V.Rajaraman

SAD/M5/LU1/V1/2004

Describing A System With A DFD

An entire system is represented by one DFD which gives the


systems overview
It is called a context diagram
It gives little detail & is also known as the top level DFD
Context diagram of mess management is shown in the next
transparency

V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Context Diagram Of
Mess Management System
Extras Note

Students

Vendors

Requisitions

Payments
Payments
Bills

Perishable
Items

Supplies

Mess
Management
Daily rate
System

Mess secretary

Menu
Item needed
Each day

Mess manager

Overdue Bills
Overdue
Payments

Chief warden

Observe this diagram gives very little detail


V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Levelling DFD
A context diagram gives an overview
It should be split into major processes which give greater
detail.
Each major process is further split to give more detail.
This process of giving more detail at a finer level is called
levelling of DFD

V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

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

V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Expanded Dfd For Hostel Mess


Management
Mess
Secretary

Students
Payments
Itemized bills
at end of month

Chief Warden

Update daily
rate
1
Items used each
Billing day
system

Unpaid bills

Extras/Rebates
Expenses

Student billing
Information +
No of meals
bills
(today +3)

Mess manager

Going to next process (Continued in next slide)


V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Expanded DFD For


Hostel Mess Management
Continued
Vendor supplies

Vendors
Order nonperishable

2
Stores issue
and
Control
system

Low stock (today+2)


Items to be issued
(today +2)

Items used
today

Menu
(today +2)

Vendor data
Stores
inventory
Perishable order

V.Rajaraman

V.Rajaraman

Orders
(perishable)

Order data

3
Perishable
ordering
SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Mess
Manager

Mess
Secretary

Vegetables and perishable


requisition
Vendor data
(perishable)

Expanded
DFD-billing System
Payments

Itemized
1.2
bills
Calculate
Mess
Secretary
Extras/Rebates

No of meals
(today + 2)

1.3
Students
Reconcile
bills
payments
Students data

V.Rajaraman

Chief
warden
Students data

Daily rate average


(upto date)

1.4
Find no
Of meals
to cook

Students data

V.Rajaraman

Bills

Unpaid
bills

1.1
Calculate
Daily rate

Mess
Manager

Expenses data
Items rate data

Observe numbering
of processes
SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Levelling Rules

If process p is expanded, the process at the next level are


labeled as p.1,p.2 etc.
All data flow entering or leaving p must also enter or leave
its 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.
V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Illegal
Constructs In DFD
No loops are allowed in DFD
A process cannot be a pure decision
Actual rate > Standard rate

Actual daily rate

Compare
Standard daily rate

Actual rate <= Standard rate

A single data flow should not be split into many flows with
different labels
No data flow allowed between data stores
V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Illegal
Constructs In DFD
Record

Get students
Calculate
extra/rebates
Bill
record
Ask for next record

Extra/rebate store
Not correct as loop is formed
V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

10

10

Levelling Examples
Low stock item
(today +2)
Mess manager

Items to be used
on (today +2)

No of meals to
be cooked
(today +2)

Items issued
Low message stock
Order for items

2
Stores issue
and
control system

Mess secretary

Menu for
(Today +2)

Vendor supplies
Order
Vendor

V.Rajaraman

V.Rajaraman

Stores inventory

Vendor

Stores issueSAD/M5/LU2/V1/2004
control system process
SAD/M5/LU2/V1/2004

11

11

Levelling Examples
2.1
Inventory update
And
low stock warning

Mess manager
Items used
today

Low stock
item

2.2
Create order
for vendor

Items needed
From 2.3
Vendor

Vendor
supplies

Stores inventory

Order

Vendor data

Order to vendor

Mess secretary

2.3
Calculate Items
needed

Menu
(today +2)

2.4
Check Item
availability

Items needed
No of meals to
(today +2)

V.Rajaraman

V.Rajaraman

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

Low stock items


(today+2)
Stores
inventory
12

12

Levelling Examples
Top
Level process

Ext A

Ext A

Ext B

F1

F4

Ext B

3
Process 1
Ext A

1.1

1.2

Process 2
1.4

2.1

2.2

2.3

F1
1.3

3.1

3.2

3.4

Ext B

4.3

4.1

4.2

F4
V.Rajaraman

V.Rajaraman

3.3

SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004

13

13

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
V.Rajaraman

SAD/M5/LU3/V1/2004

Physical DFD For Encashing Cheque


Cash

Token

Clerk
Customer

Cheque
Token

Verify A/C
Signature
Update
Balance

Cashier
Verify Token

Cheque with Take Signature


Token number
Store cheques

Bad Cheque

Entry in
Day Book

Customer
Accounts
V.Rajaraman

SAD/M5/LU3/V1/2004

Logical DFD For Cheque Encashment

Retrieve
Customer
Record

Cheque

Check Cheque with


Store
Balance, Token
Token no
Issue
& cheques
token

Cheque

Token Slip
Or cheque

Customer
accounts

Search
Update
& match
Daily
token Cheque with cash book
token

Customer
Token Slip
Cash
V.Rajaraman

Cheque store
With token no.

SAD/M5/LU3/V1/2004

Day book

System Analysis and Design/ Structured systems analysis and design

Learning Objectives

Learning Objectives

In this module we will learn

How to use structured English to precisely specify processes

The terminology used in structured English

Terminology of decision tables and how it is used to


specify complex logic

How to detect errors in decision table specifications

Terminology and use of decision trees

Comparison of structured English, decision tables and


decision trees

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/ Structured systems analysis and design

Motivation

Motivation

Before designing a system an analyst must clearly understand the logic to be


followed by each process block in a DFD

An analysts understanding must be cross checked with the user of the


information system.

A notation is thus needed to specify process block in detail which can be


understood by a user.

Notation used must be appropriate for the type of the application to be modeled.

Different notations are needed to represent repetition structures,complex decision


situation and situations where sequencing of testing of conditions is important

For complex logical procedures a notation is needed which can also be used to
detect logical errors in the specifications.

A tabular structure for representing logic can be used as a communication tool and
can be automatically converted to a program.

V. Rajaraman/IISc, Bangalore

//V1/July 04/1

Process Specification
Once a DFD is obtained the next step is to precisely specify
the process.
Structured English, Decision tables and Decision Trees are
used to describe process.
Decision tables are used when the process is logically
complex involving large number of conditions and alternate
solutions
Decision Trees are used when conditions to be tested must
follow a strict time sequence.
V.Rajaraman

SAD/M6/LU1/V1/2004

Structured English
Structured English is similar to a programming language such
as Pascal
It does not have strict syntax rules as programming language
Intention is to give precise description of a process
The structured English description should be understandable
to the user

V.Rajaraman

SAD/M6/LU1/V1/2004

Structured English
if customer pays advance
then Give 5% Discount
else
if purchase amount >=10,000
then
if the customer is a regular customer
then Give 5% Discount
else No Discount
end if
else No Discount
end if
end if
V.Rajaraman

SAD/M6/LU1/V1/2004

Decision
Table-example
Same structured English procedure given as decision table
CONDITIONS
Advance payment made
Purchase amt >=10,000
Regular Customer?

RULE1
Y
-

RULE2
N
Y
Y

RULE3
N
Y
N

RULE4
N
N
-

ACTIONS
Give 5% Discount
Give No Discount

V.Rajaraman

X
-

X
-

SAD/M6/LU1/V1/2004

Decision
Table-explanation
Conditions are questions to be asked
Y is yes,N is no & - is irrelevant
A X against the action says the action must be taken
A - against the action says the action need not be taken
Rule 2 in decision table DISCOUNT states:
if no advance payment and purchase amount >=10000
and regular customer then give 5% discount
V.Rajaraman

SAD/M6/LU1/V1/2004

Structured English

Imperative sentences- Actions to be performed should be


precise and quantified
Good Example: Give discount of 20%
Bad Example: Give substantial discount

V.Rajaraman

SAD/M6/LU1/V1/2004

Structure English (Contd.)

Operators -Arithmetic : +, -, /, *
Relational : >, >=, <, <=, =, !=
Logical : and, or, not
Keywords : if, then, else, repeat, until, while, do, case,
until, while, do, case, for, search, retrieve, read, write
Delimiters {, }, end, end if, end for

V.Rajaraman

SAD/M6/LU1/V1/2004

Decision
Tree-example
The structured English procedure given in 6.1.3 is expressed as a
Decision tree below
Give 5% Discount
Y

Y
C1

C3

Y
C2

Give 5% Discount

N
No Discount

N
No Discount

C1: Advance payment made


C2: Purchase amount >=10,000
C3: Regular Customer
V.Rajaraman

SAD/M6/LU1/V1/2004

Y = Yes
N = No

Structured
English-decision Structures
If condition
then
{ Group of statements }
else
{ Group of statements }
end if
Example: if(balance in account >= min.balance)
then honor request
else reject request
end if
V.Rajaraman

SAD/M6/LU1/V1/2004

Structured
English-case Statement
Case (variable)
Variable = P: { statements for alternative P}
Variable = Q: { statements for alternative Q}
Variable = R: { statements for alternative R}
None of the above: { statements for default case}
end case
Example : Case(product code)
product code =1 : discount= 5%
product code =2 : discount =7%
None of the above : discount=0
end case
V.Rajaraman

SAD/M6/LU1/V1/2004

10

STRUCTURED
ENGLISH-REPETITION STRUCTURE
for index = initial to final do
{ statements in loop }
end for
Example : Total =0
for subject =1 to subject =5 do
total marks=total marks +marks(subject)
write roll no,total marks
end for

V.Rajaraman

SAD/M6/LU1/V1/2004

11

STRUCTURED
ENGLISH-WHILE LOOP
while condition do
{ statements in loop }
end while
Example : while there are student records left to do
read student record
compute total marks
find class
write total marks, class, roll no
end while

V.Rajaraman

SAD/M6/LU1/V1/2004

12

Example
Update inventory file
for each item accepted record do
{ search inventory file using item code
if successful
then { update retrieved inventory record;
write updated record in inventory file using accepted
record}
else { create new record in inventory file;
enter accepted record in inventory file}
end if
end for
V.Rajaraman

SAD/M6/LU1/V1/2004

13

Decision Table-motivation

A procedural language tells how data is processed


Structured English is procedural
Most managers and users are not concerned how data is processedthey want to know what rules are used to process data.
Specification of what a system does is non-procedural.
Decision Tables are non-procedural specification of rules used in
processing data

V.Rajaraman

SAD/M6/LU2/V1/2004

Advantages Of Decision Table

Easy

to understand by non-computer literate users and managers

Good documentation of rules used in data processing.


Simple representation of complex decision rules .

V.Rajaraman

SAD/M6/LU2/V1/2004

Advantages OF Decision Table (Contd.)

Tabular representation allows systematic validation of


specification detection of redundancy,incompleteness &
inconsistency of rules
Algorithms exist to automatically convert decision tables to
equivalent computer programs.
Allows systematic creation of test data

V.Rajaraman

SAD/M6/LU2/V1/2004

Method Of Obtaining
Decision Table From
Word Statement Of Rules
EXAMPLE
A bank uses the following rules to classify new accounts
If depositor's age is 21 or above and if the deposit is Rs 100 or more,
classify the account type as A If the depositor is under 21 and the deposit
is Rs 100 or more, classify it as type B If the depositor is 21 or over and
deposit is below Rs 100 classify it as C If the depositor is under 21 and
deposit is below Rs 100 do-not open account
Identify Conditions: Age >= 21 Cl
Deposits >= Rs 100: C2
Identify Actions : Classify account as A, B or C
Do not open account
V.Rajaraman

SAD/M6/LU2/V1/2004

Decision Table
From Word Statement
Condition Stub
CODITIONS

Rule 1

Rule 2

Rule 3

Rule 4

C1 : Age >= 21

C2: Deposit >=100

A1: Classify as A

A2: Classify as B

A3: Classify as C

ACTIONS

A4: Do not open


Account
Action Stub
V.Rajaraman

SAD/M6/LU2/V1/2004

Decision Table
Notation Explained
CONDITION
STUB

CONDITION ENTRIES

ACTION
STUB

ACTION ENTRIES
RULE

4 Quadrants-demarcated by two double lines


CONDITION STUB LISTS ALL CONDITIONS TO BE CHECKED
ACTION STUB LISTS ALL ACTIONS TO BE CARRIED OUT
LIMITED ENTRY DECISION TABLE:ENTRIES ARE Y or N or -.Y-YES,NNO,-IRRELEVANT(DONT CARE)
X against action states it is to be carried out.
-against action states it is to be ignored.
Entries on a vertical column specifies a rule
V.Rajaraman

SAD/M6/LU2/V1/2004

Decision Table Notation -Contd

ORDER OF LISTING CONDITIONS IRRELEVANT


i.e. CONDITIONS MAY BE CHECKED IN ANY ORDER
ORDER OF LISTING ACTIONS IMPORTANT
ACTIONS LISTED FIRST CARRIED OUT FIRST
SEQUENTIAL EXECUTION OF ACTIONS
RULES MAY BE LISTED IN ANY ORDER
V.Rajaraman

SAD/M6/LU2/V1/2004

Interpreting
Decision Table-else Rule
C1: Is applicant sponsored
C2: Does he have min
qualification
C3: Is fee paid?
A1: Admit letter
A2: Provisional Admit
letter
A3: Regret letter

V.Rajaraman

R1

R2

SAD/M6/LU2/V1/2004

ELSE

Interpreting Decision Table-else Rule


(Contd.)
Interpretation
R1: If applicant sponsored and he has minimum qualifications
and his fee is paid Send Admit letter
R2: If applicant sponsored and has minimum qualifications
and his fee not paid send provisional admit letter
ELSE: In all cases send regret letter.The else rule makes a
decision table complete
V.Rajaraman

SAD/M6/LU2/V1/2004

Decision Table For Shipping Rules


C1: Qty ordered <= Quantity
in stock?
C2: (Qty in stock-Qty ordered)
<=reorder level
C3: Is the partial shipment ok?
A1:Qty shipped=Qty ordered
A2:Qty shipped=Qty in stock
A3:Qty shipped=0
A4:Qty in stock=0
A5:Back order=qty orderedqty shipped
A6:Initiative reorder procedure
A7: Qty in stockQty in
stock-Qty shipped
V.Rajaraman

R1

R2

R3

R4

X
X

X
-

SAD/M6/LU2/V1/2004

10

Extended Entry Decision Table


Condition Entries not necessarily Y or N
Action entries not necessarily X or Extended Entry Decision Tables(EEDT) more concise
EEDT can always be expanded to LEDT
Example

R1

R2

R3

R4

R5

R6

C1 : Product code

C2 : Customer code

C3 : Order amount

Discount =
V.Rajaraman

<=500 <=500

5%

7.5%

SAD/M6/LU2/V1/2004

>500

7.5%

>500

10%

6%

5%
11

Mixed Entry Decision Table


Can mix up Yes, No answers with codes
Rl

R2

R3

R4

R5

Cl : Product code = 1?
C2: Customer code =
C3: Order amount < 500?

A
Y

Y
B
Y

Y
A
N

Y
B
N

Y
C
-

Discount =

5%

7 5%

7 5%

10%

6%

R6
N
5%

Choice of LEDT, EEDT, MEDT depends on ease of communication with user,


software available to translate DTs to programs, ease of checking etc.
V.Rajaraman

SAD/M6/LU2/V1/2004

12

Linked Decision Table

Decision table 2

Decision table 1
Salary point=6
Conduct OK?
Diligence OK?
Efficiency OK?

N
Y
Y
Y

e
l
s
e

Go to table 2
No promotion

X
-

V.Rajaraman

Salary point>2
1 yr as class 1
officer
Departmental test
Passed?
Advance to next
salary point
No promotion
Go to Table3
SAD/M6/LU2/V1/2004

N
Y

N
N

N
-

Y
-

Y -

N -

X - X

13

Linked Decision Table

Decision table3
Complete departmental
Course
1 yr since last increment
Advance to next salary
point
No promotion

V.Rajaraman

Y
else

1.Observe that one can branch


between tables

Y
X

SAD/M6/LU2/V1/2004

2. Whenever complex rules are


given it is a good idea to break
them up into manageable parts

14

14

Logical Correctness Of Decision Table

Consider decision table DTI:


Cl: x>60
C2:x<40

Rl
Y
-

R2
.
Y

Al
A2 :

X
-

V.Rajaraman

We can expand decision table by


replacing each by Y & N

SAD/M6/LU3/V1/2004

Logical Correctness Of
Decision Table (Contd.)
A decision table with 1 condition should have 2 elementary rules
Each elementary rule must be distinct
Each elementary rule must have distinct action
If a decision table with k conditions does not have 2k rules
specified
it is said to be incomplete
For example : DT2 does not have the elementary rule C1:N,

V.Rajaraman

SAD/M6/LU3/V1/2004

Logical Correctness
Of Decision Table (Contd.)
C2:N.
It is thus incomplete.
If the decision table has the same elementary rule occurring
more than once it is said to have multiplicity of specifications
For Example:In DT2 The rule C1:Y,C2:Y occurs twice.Thus it
has multiplicity of specification

V.Rajaraman

SAD/M6/LU3/V1/2004

Logical Correctness
Of Decision Table (Contd.)
If action specified for multiple identical rules are different then it
is called ambiguous specifications
DT2 has an ambiguity.Rules R11 and R21 are identical but have
different actions
Ambiguity may be apparent or real

V.Rajaraman

SAD/M6/LU3/V1/2004

Logical Correctness
Of Decision Table (Contd.)
If an apparently ambiguous specification is real then it is a
contradiction
For example : If C1:(X > 60) = Y and C2:(X > 40) = Y
then X = 70 will satisfy both inequalities.
As two actions are specified for (Cl = Y, C2 = Y) and they
are different the rule is really ambiguous and is called
Contradictory Specification.
V.Rajaraman

SAD/M6/LU3/V1/2004

Logical Correctness
Of Decision Table (Contd.)
If all 2k elementary rules are not present in a k condition
decision table is said to be incomplete.
DT2 (PPT 6.3.1) is incomplete as rule C1:N, C2:N is missing
Rule C1=N, C2:=N is logically possible as C1=N is X<=60
and C2=N is X >= 40. A value of X = 50 will make C1=N,C2=N

V.Rajaraman

SAD/M6/LU3/V1/2004

Logical Correctness
Of Decision Table (Contd.)
Thus DT2 has a real incomplete specification
A decision table which has no real ambiguities or real
incompleteness is said to be logically correct
A decision table with logical errors should be corrected

V.Rajaraman

SAD/M6/LU3/V1/2004

Use Of Karnaugh Maps


KARNAUGH map abbreviated K-map is a 2 dimensional
diagram with one square per elementary rule
The k-map of DT2 is
C1

C2

A2

Al
A1,A2

If more than one action is in one square it is an ambiguous


rule
If a square is empty it signifies incomplete specification
V.Rajaraman

SAD/M6/LU3/V1/2004

Use Of Karnaugh Maps


Structured English procedure:
If carbon content<0.7
then if Rockwell hardness>50
then if tensile strength>30000
then steel is grade 10
else steel is grade 9
end if
else steel is grade 8
end if
else steel is grade 7
end if
V.Rajaraman

SAD/M6/LU3/V1/2004

Use Of
Karnaugh Maps
Decision table-Grading steel

C1:Carbon content <0.7


C2:Rockwell hardness>50
C3 tensile strength>30000
Grade

V.Rajaraman

Y Y Y N Y N N N
Y Y N N N Y Y N
Y N N N Y Y N Y
10 9 8 7 ? ? ? ?

SAD/M6/LU3/V1/2004

10

Karnaugh
Maps Grading Steel
C1 C2
NN
C3
N
7
Y

NY

YY

YN

10

The 3 conditions are independent


The decision table is thus incomplete
Observe that in the Structured English specifications
the incompleteness is not obvious
V.Rajaraman

SAD/M6/LU3/V1/2004

11

Decision TableArrears Management


R1 R2 R3

C1:Payment in current month


>min.specified payment
C2:Payment in current month>0
C3:Any payment in last 3 months
C4: Actual arrears > 3(min.
Specified payment per month)
A1 : Send letter A
A2 : Send letter B
A3 : Send letter C
A4 : Send letter D
A5 : Send letter E
V.Rajaraman

SAD/M6/LU3/V1/2004

R4

R5 R6

N N

Y
-

Y
-

N
Y

N
Y

Y N

X
-

X
-

X - X
-

X
12
1

Karnaugh Map
C1C2
C3C4
NN
NN
?

NY

YY

YN

A3

A1

A1*

NY

A4

A2A4+

A1A4+

A1A4*

YY

A4

A2

A1

A1A4*

YN

A5

A3

A1

A1A5*

K Map for decision table


V.Rajaraman

SAD/M6/LU3/V1/2004

13

Karnaugh Map

C1 : x>m C2:x>0 C3:y>0 C4:z>3m


C3,C4 independent of C1,C2

m>0

C1,C2 dependent

C1: Y C2: Y x>m, x>0 possible


C1: Y C2: N x>m, x<=0 not logically possible
C1: N C2: Y x<=m,x>0 possible

V.Rajaraman

SAD/M6/LU3/V1/2004

14

Karnaugh Map
C1: N C2: N x<=m,x<=0 possible
Thus C1,C2,C3 C4:NNNN incomplete specification
BOXES MARKED * NOT LOGICALLY POSSIBLE
Rules C1 C2 C3 C 4 : NYNY and YYNY logical errors
Errors to be corrected after consulting users who formulated
the rules

V.Rajaraman

SAD/M6/LU3/V1/2004

15

Correct Decision Table


If users say that for rules C1C2C3C4:NYNY AND NYNY
(marked with + in k-map) the action is A4 and for
C1C2C3C4:NNNN also it is A4, the corrected map is
C1C2
C3C4

NN

NY

YY

NN

A4

A3

A1

NY

A4

A4

A4

YY

A4

A2

A1

YN

A5

A3

A1

V.Rajaraman

SAD/M6/LU3/V1/2004

YN

Impossible rules

16

CORRECTED
DECISION TABLE
C1

C2

C3

C4

A1

A1

A1

A2 A3

A3

A4

A4

A4

A5

Action

V.Rajaraman

SAD/M6/LU3/V1/2004

A4 A4

17

Corrected Decision Table


(Contd.)
Question: Can the number of rules be reduced
Answer : Yes, by combining rules with the same action
Action A1 can be represented by the Boolean expression:
C1C2C3C4 + C1C2C3C4 + C1C2C3C4
= C1C2C3C4 + C1C2C3 (C4+C4)
= C1C2C3C4+C1C2C3 = C1C2C4 + C1C2C3

V.Rajaraman

SAD/M6/LU3/V1/2004

18

Redundancy
Elimination
Redundancy can be eliminated by systematically applying four
identities of Boolean Algebra
These identities are
A + A=1
l.A = A
A+A=A
1+A=1
V.Rajaraman
V.Rajaraman

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

1
1

Redundancy
Elimination (Contd.)

K-map assists in identifying Boolean terms in which One or


more variables can be eliminated
K-map is constructed in such a way that two boxes which are
physically adjacent in it are also logically adjacent

V.Rajaraman
V.Rajaraman

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

2
2

Karnaugh
Map Reduction
C1 C2
NN NY YY YN
C3 C4
NN
NY

C1 C2
NN
C3 C4

A4

NN

A4

NY

V.Rajaraman

A4

A4

YN

YN

V.Rajaraman

A4

YY

YY

A4=C1C2C3(C4+C4)=C1C2C3

A4

NY YY YN

A4=C3C4(C1C2+C1C2+C1C2+C1C2)=C3C4
SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

3
3

Karnaugh
Map Reduction

Combining 2 adjacent boxes eliminates 1 variable


Combining 4 adjacent boxes eliminates 2 variable
Combining 8 adjacent boxes eliminates 3 variable
First and last columns of k-map are logically adjacent
First and last rows are also logically adjacent

V.Rajaraman
V.Rajaraman

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

4
4

Karnaugh
Map Reduction
C1C2
NN
C3 C4

A1

NY YY YN
A1

NN
NY
YY

C1C2
NN NY YY YN
C3 C4
A2

A2

A1

YN A1

V.Rajaraman
V.Rajaraman

A1
A1
A1

A2

A2

NY
YY
YN

NY YY YN

NN

NN
A1

C3 C4

C1C2
NN

A3

A3

A3

A3

NY
A2

A2

YY
A2

A2

YN

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

5
5

Karnaugh
Map Reduction (Contd.)
A1=(C3C4+C3C4+C3C4+C3C4).(C1C2+C1C2)=C2(C3+C3)=C2
A2=(C1C2+C1C2)(C3C4+C3C4+C3C4+C3C4)=C2
A3=C1C2C3C4+C1C2C3C4+C1C2C3C4+C1C2C3C4
=C2C3C4(C1+C1)+C2C3C4(C1+C1)
=C2C4(C3+C3)=C2C4
V.Rajaraman
V.Rajaraman

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

6
6

Reducing Decision
Tables-use Of K-map
This is the K-map corresponding to DT of 6.3.12
C1C2
NN NY
C3C4
NN A4 A3

YY
A1

A4

A4

A4

YY

A4

A2

A1

YN

A5

A3

A1

NY

V.Rajaraman
V.Rajaraman

YN

Boxes marked X correspond to impossible rules.


They can be used if they are useful in reducing rules
Using k-map reduction rules we get
A1 : C1C4+C1C3
A2 : C1C2C3C4
A3 : C1C2C4
A4 : C3C4+C2C3+C2C4
A5 : C2C3C4
SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

7
7

Reducing
Decision Tables
REDUCED DECISION TABLE for DT of 6.3.12
C1: Payment in current month >
min specified payment
C2: Payment in current month>0
C3: Any payment in last 3 months
C4: Actual arrears> 3(minimum specified
payment per month)

A: Send letter A
B: Send letter B
C: Send letter C
D: Send letter D
E: Send letter E
V.Rajaraman
V.Rajaraman

Y
-

Y
Y

N N
Y Y
Y -

- - N
N N

N
-

N
Y

Y N

X
-

X
-

X
-

X
-

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

- X - X
- - -

- - X - X

8
8

Example-reduction
Of Rules In Word Statement

Rules : Insure Driver if following rules are satisfied


1.
2.
3.
4.
5.

Drivers annual income > 20000 & is married male


Drivers annual income > 20000 & is married and over 30
Drivers annual income <= 20000 & she is married female
Driver is male over 30
Driver is married and age is not relevant
Else do not insure

V.Rajaraman
V.Rajaraman

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

9
9

Example-reduction
Of Rules In Word Statement
Conditions:
C1 : Annual income > 20000
C2 : Male
C3 : Married
C4: Age > 30
Action: Insure or do not insure

V.Rajaraman
V.Rajaraman

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

10
10

Decision Table
For Insurance Rules
Cl : Annual income> 20000
C2: Male
C3: Married
C4: Age > 30

Y
Y
Y
-

A1:Insure
A2 :Do not insure

X
C1C2
NN
C3C4

Y
Y
Y

N
N
Y
X
-

Y
Y

X
-

X
-

Y
N
X
-

E
L
S
E
X

NY YY YN

NN
A1

NY

V.Rajaraman
V.Rajaraman

A1

A1=C3+C2.C4

YY

A1

A1

A1

A1

YN

A1

A1

A1

A1

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

11
11

Reduced
Decision Table
C2 : Male

C3 : Married

C4 : Age > 30

Al : Insure
A2 : Do not Insure

ELSE

Reduced rules : Insure if married or male over 30


Observe 5 rules simplified to 2 and 1 condition removed
V.Rajaraman
V.Rajaraman

SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004

12
12

Decision Trees

Used when sequence of testing condition is important


It is more procedural compared to Decision trees.

Book by II AC on 4/8/04 if available else book by II AC on 5/8/04.If


both not available book by sleeper on 4/8/04 if available else book on
5/8/04 by sleeper.If none available return.

V.Rajaraman

SAD/M6/LU5/V1/2004

Example Decision
Tree To Book Train Ticket
Book II AC

C1
N

Book II AC

C2

Book sleeper

C3

Book ticket

C4
N
Return

V.Rajaraman

SAD/M6/LU5/V1/2004

Example Decision
Tree To Book Train Ticket

V.Rajaraman

C1: Is II AC ticket available on 4/8/04


C2: Is II AC ticket available on 5/8/04
C3: Is sleeper available on 4/8/04
C4: Is sleeper available on 5/8/04
Observe in the tree sequencing of conditions which is
important in this example

SAD/M6/LU5/V1/2004

Decision Trees
Decision trees are drawn left to right
Circles used for conditions
Conditions labelled and annotation below tree
Conditions need not be binary
For example:
C1

>=60

GRADE A

>=50

GRADE B

>=40

GRADE C

else

GRADE F

Sometimes Decision trees are more appropriate to explain


to a user how decisions are taken
V.Rajaraman

SAD/M6/LU5/V1/2004

Decision Trees
Decision tree for decision table of 6.2.9 [Slide number 25]

Discount=7.5%

YES
C3
A
B

C2
C

Discount=10%

NO

Discount=7.5%
Discount=6%

V.Rajaraman

Discount=5%

YES
C3

1
C1

NO

Discount=5%

SAD/M6/LU5/V1/2004

Decision Trees

C1 : PRODUCT CODE
C2 : CUSTOMER CODE
C3 : ORDER AMOUNT >500?
Observe that the 3 alternatives for connection C2 shown as
three branching lines
SOME PEOPLE FIND DECISION TREE EASIER TO
UNDERSTAND
V.Rajaraman

SAD/M6/LU5/V1/2004

Decision Trees
Decision tree equivalent of structured English procedure of 6.3.7
(SLIDE 37) is given below
NO

Grade 7

C1
Grade 8

YES

C1

NO
YES

C1

Grade 9
NO

YES
Grade 10

V.Rajaraman

SAD/M6/LU5/V1/2004

Decision Trees
C1 : Carbon < 0.7
C2 : Rockwell hardness > 50
C3: Tensile strength > 3000

Observe incompleteness evident in the equivalent Decision


Table is not evident in the Decision tree
If the testing sequence is specified and is to be strictly
followed the Decision tree is simple to understand.

V.Rajaraman

SAD/M6/LU5/V1/2004

Comparison Of
Structured English,
Decision Tables And Decision Trees
CRITERION
FOR
COMPARISON
ISOLATING
CONDITIONS
& ACTIONS

NOT GOOD

SEQUENCING
CONDITIONS
BY PRIORITY

GOOD

CHECKING FOR
COMPLETENES
S,
CONTRADICTIO
N&
AMBIGUITIES
V.Rajaraman

STRUCTURE
D
ENGLISH

NOT GOOD

SAD/M6/LU5/V1/2004

DECISION
TABLES

BEST

NOT
GOOD
BEST

DECISION
TREES

GOOD

BEST

GOOD

When To Use
Structured English,
Decision Tables And Decision Trees
Use Structured English if there are many loops and actions are
complex
Use Decision tables when there are a large number of conditions
to check and logic is complex
Use Decision trees when sequencing of conditions is important
and if there are not many conditions to be tested

V.Rajaraman

SAD/M6/LU5/V1/2004

10

System Analysis and Design/ Structured systems analysis and design

Worked Examples

WORKED EXAMPLES

6.1 A bank has the following policy on deposits: On deposits of Rs. 5000 and
above and for three years or above the interest is 12%. On the same deposit
for a period less than 3 years it is 10%. On deposits below Rs. 5000 the
interest is 8% regardless of the period of deposit. Write the above process
using
(i) Structured English
(ii) A decision table
(i) for each deposit do
if deposit >=5000
then if period >= 3 years
then interest =12%
else interest =10%
end if
else interest =8%
end if
end for
(ii)
Deposit >= 5000
Y Y
Period >= 3 years
Y N
Interest

12

10

6.2 An organization maintains an employee file in which each record has


following data:
{ Employee No., employee name, employee gross pay}.
It has been decided to increase the pay as per the following formula:
For pay of Rs. 1000 or less increase 15%.
For pay of more than Rs. 1000 but up to Rs. 2500 increase 10%.
For pay over Rs. 2500 increase 5%.
(i) Write a structured English processing rule corresponding to the above
policies.
(ii) Express the policies as a decision table.
(i)
While employee records left in file do
Read Number, name , gross pay
if gross pay <=1000
then increase = gross pay * 0.15
else if gross pay <= 2500
then increase = gross pay * 0.1
else increase = gross pay * .05
V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/ Structured systems analysis and design

Worked Examples

end if
end if
Gross pay = gross pay + increase
Write Number, name, gross pay
end while
(ii) While employee records left in file do
Read Number, name, gross pay
do Table
Gross pay <= 1000
Gross pay <= 2500
Percent increase

N
Y

N
N

15

10

end table
Gross pay = gross pay*(1+percent increase/100)
Write Number, name, gross pay
end while
6.3 An offshore gas company bills its customers according to the following rate
schedule:
First 500 litres Rs. 10 (flat)
Next 300 litres Rs. 1.25 per 100 litres
Next 30,000 litres Rs. 1.20 per 100 litres
Next 100,000 litres Rs. 1.10 per 100 litres
Above this Re. 1.00 per 100 litres
The input record has customer identification, name and address, meter
reading, past and present. Write a structured English procedure to obtain a
bill for the customer.
While record left in customer file do
Read customer id, name, address, past meter reading, new meter reading
Consumption = new meter reading old meter reading
if consumption <= 500 then charge =10
else if consumption <=800
then charge = 10 + (consumption 500) * 0.0125
else
if consumption <= 30800
then charge = 13.75
+(consumption 800) * 0.012
else
if consumption <=130800
then charge = 373.75 + (consumption 30800) * 0.011
else charge = 1473.75 + (consumption 130800) * 0.01
end if
V. Rajaraman/IISc. Bangalore

//V1/June 04/2

System Analysis and Design/ Structured systems analysis and design

Worked Examples

end if
end if
end if
write customer id, name, address, past meter reading, new meter reading,
consumption, charge
end while
6.4 Refer to users requirements stated in exercise 6.4 of Question bank. Develop
the processing rules in structured English for the stores process shown in Fig.
5.8.
for each customer requisition do
if (qty. requested < qty. in stock ) then
{
qty. issued = qty. requested.
qty. in stock = qty. in stock qty. issued
send( customer id , qty. issued ) to accounts process}
end if
if (qty. in stock <= reorder level) then
send reorder request to purchase.
end if
if (qty. requested = qty. in stock) then
{
qty. issued = qty. requested
qty in stock = 0;
send (customer id, qty issued) to accounts
send reorder request to purchase }
end if
if (qty. requested > qty. in stock) then
if (partial qty. acceptable)
then {
qty issued = qty. requested
qty in stock = 0;
send (customer id , qty issued) to accounts
send reorder request to purchase.
write (customer id, (qty. requested qty. issued ))
in file}
else
{qty. issued = 0;
send reorder request to purchase
write (customer id, qty requested) in back order file }
end if
end if
end for
V. Rajaraman/IISc. Bangalore

//V1/June 04/3

System Analysis and Design/ Structured systems analysis and design

Worked Examples

for each item (with specified item code and qty. accepted note) received from
inspection do
qty. in stock ( item code)
= qty. in stock ( item code) + qty. accepted
end for
6.5 Refer to Exercise 6.4 in Question Bank. Develop the processing rules in
structured English for the purchase process of Fig. 5.9.
for each discrepancy note received from the receiving office do
{ intimate specified vendor
enter discrepancy in the discrepancy file }
end for
for each goods rejected note received from the inspection office do
{ intimate specified vendor
enter rejected items note in items rejected file }
end for
for each reorder advice or new requisition received for an item from stores do
{ Refer to item file to find vendor details and order qty.
send order to specified vendor
enter order in order file }
end for
6.6. State the processing rules in structured English for the various processes in
the data flow diagram for the hostel DFD described in Module 5
Mess Process
for each absence note do
Read student charge record from student charge file (using student number
as key)
Add absence days to absence field
Write student charge record in student charge file
end for
for each extras note do
Read student charge record
Append extras code and quantity to record
Write student charge in student charge file
end for
Billing Process
While student charge records left in student charge file do
Read student charge record from student charge file
No. of days to charge = no. of days in a month no. of days absent.
Monthly charge = no. of days to charge * daily rate
Total extras charge = 0
for each extra item do
V. Rajaraman/IISc. Bangalore

//V1/June 04/4

System Analysis and Design/ Structured systems analysis and design

Worked Examples

extras charge (code) = extra qty. * charge (code)


end for
Add extra charge to total extra charge
Amount to be billed = no. of days to charge * daily rate + total extras
charge
Student bill record = student charge record + daily rate, no. of days
charged, monthly charge, extras charge (code) , total extras charge ,
grand total to pay
Write student bill record
end while
(Note: It is assumed that the daily rate, no. of days in a month and extras charge
for each extras code is stored in the billing process as an internal data record.)
Payment Reconciliation Process
for each student Bill record do
Store student Bill record in Bill file
end for
for each payment received do
Read bill record of student from Bill file
if amount paid = grand total to pay
then balance due = 0
else balance due = (grand total to pay amount paid)
Store bill record in unpaid bill file
end if
end for
On payment due date, (due date + 10), (due date + 20) do
While records left in unpaid Bill file do
if balance due > 0
then send overdue notice,
end if
end while
On (payment due date + 30) do
While records left in unpaid bill file do
if balance due > 0
then send message to warden
end if
end while

6.7

The policy followed by a company to process customer orders is given by the


following rules:
(i) If the customer order <= that in stock and his credit is OK, supply his
requirement.
(ii) If the customer credit is not OK do not supply. Send him an intimation.

V. Rajaraman/IISc. Bangalore

//V1/June 04/5

System Analysis and Design/ Structured systems analysis and design

Worked Examples

(iii) If the customer credit is OK but items in stock are less than his order,
supply what is in stock. Enter balance to be sent in back-order file.
Obtain a decision table for above policy
Order <= stock
Credit OK

Y
Y

Y
N

N
Y

N
N

Supply order
Credit not OK
Do not supply
Supply stock
Enter (order stock)
In back Order file

Observe that the last rule is not specified in the statement of rules. This has been
added to complete the table.
6.8 Obtain a decision table to decide whether on a given date an employee in an
organization has completed one years service or not.
Let date of joining be DJ/MJ/YJ (Day/Month/Year)
Let todays date be DT/MT/YT (Day/Month/Year)
If (YT YJ)
If (MT MJ)

>1

=1
>0

=1
=0

If (DT DJ)

>= 0

E
L
S
E

Yes

Yes

No

One years service Yes

6.9 Obtain a decision table corresponding to the structured English procedure given
in worked example 6.4of decision table
for each customer requisition do decision table
decision table
V. Rajaraman/IISc. Bangalore

//V1/June 04/6

System Analysis and Design/ Structured systems analysis and design

Worked Examples

qty requested < qty in stock


qty requested = qty in stock
qty requested > qty in stock
(qty in stock qty requested)
<= reorder level
Partial order OK?

qty issued = qty requested


qty issued = qty in stock
qty in stock = (qty in stock qty issued)
qty in stock = 0
Send customer id,qty issued to account process
qty issued = 0
Send reorder request to purchase process
Write (customer id, qty requested qty issued)
in back order file
Write (customer id, qty requested) in back
order file


X
X
X
X X

X
X

for each item with specified item code and qty accepted note
received from inspection do
qty in stock ( item code) =
qty in stock ( item code) + qty. accepted
end for

6.10 Obtain a decision table for an automatic stamp vending machine with the
following specifications:
(i) To dispense 20, 15, 10, 5 paise stamps
(ii) To accept 50, 25, 10, 5 paise coins
(iii) Do not return change if it is necessary to return more than two coins of
the same denomination. In such a case return the customers coin and
turn on no change light.
The machine should dispense a stamp, the right amount of change tendered,
no stamp available, no change available, etc.

Table 1: Select Stamp


Amount tendered
Stamp requested available?
Amount insufficient
V. Rajaraman/IISc. Bangalore

< Stamp cost = Stamp cost > Stamp cost

Y
Y
X

//V1/June 04/7

System Analysis and Design/ Structured systems analysis and design

Return amount
No stamp light on
Dispense stamp
Go to Table 2
Stop

Worked Examples

X
X

X
X

Table 2: Make Change


Amount tendered
Stamp cost
25 ps. Available?
10 ps. Available?
5 ps. Available
No of 25 ps. Returned
No of 10 ps. Returned
No of 5 ps. Returned
Dispense stamp
No. change light on
Return amount
Stop

50
20
>=1

>=1

50
20

>=2
>=2

50
15
>=1
>=1

50
15
>=1

>=2

1
X

2
2
X

1
1

2
X

50 50 50 25 25
10
5
5 20 15
>=1 >=1 >=1
>=1 >= 2 >=1 >=1
>=1 >=2 >=1
1
1
1
X

1
2

1
1
2
X

1
X

25
15

>=2

25
10

>=1
>=1

25
5

>=2

25
5

>=1
>=2

10
5

>=1

E
L
S
E

2
X

1
1
X

1
2
X

1
X

X
X
X

6.11 Obtain the decision table to be used by a person to enter the office of a manager.
The conditions to be checked are:
Door open? Ring sign on? Enter sign on? Door locked?
The actions a person takes are:
Ring bell, enter, wait, leave.
After obtaining the decision table, ensure that it has no logical errors and
that it is in minimal form.

C1: Door open?


C2: Ring sign on?
C3: Enter sign on?
C4: Door locked?
Ring bell

R1
N
N
N
N

R2
N
N
N
Y

V. Rajaraman/IISc. Bangalore

R3
N
N
Y
N

R4
N
N
Y
Y

R5
N
Y
N
N

R6
N
Y
N
Y

R7
N
Y
Y
N

R8
N
Y
Y
Y

R9
Y
N
N
N

R10 R11 R12 R13 R14 R15


Y Y Y Y Y Y
N N N Y Y Y
N Y Y N N Y
Y N Y N Y N
?

R16
Y
Y
Y
Y
?

//V1/June 04/8

System Analysis and Design/ Structured systems analysis and design


Enter
Wait
Leave

X
A1

X
A1

X
X
X X
A2 A1 A3 A1

A4

X
A1

Worked Examples

? X ? ? X
? ? X ?
X ? ? ?
A1
A2
A3
A4

?
?
?

Rules R10, R12, R14, R16 have conditions Door open and Door locked
simultaneously true. These rules are thus impossible. Observe these are four
distinct actions. The table is mapped on a K-map (Fig. S6.11)
NN

NY

YY

YN

NN

A1

A3

A3

A1

NY

A1

A1

YY

A1

A1

YN

A2

A4

A4

A2

Fig S6.11 k-map for solution 6.11


Decision table with redundancies removed
Decision Table with removed (Condition C1 redundant)
C2: Ring on?
C3: Enter on?
C4: Door locked?

N
N

N
Y
N

Y
N
N

Y
Y
N

Ring bell
Enter
Wait
Leave

X
A1

X
A1

A2

A3

X
X

A4

6.12 In installment buying where payments are made on a weekly basis the action taken on
an account goes into arrears is a crucial aspect of the operation. Table
S6.12 illustrates a simplified arrears procedure. Answer the following
questions:
(i) Are all elementary rules logically possible?
V. Rajaraman/IISc. Bangalore

//V1/June 04/9

System Analysis and Design/ Structured systems analysis and design

(ii)
(iii)
(iv)
(v)
(vi)

Worked Examples

Is the table complete?


Has the table any ambiguities?
Are there logical errors in the table? If yes, point them out.
Use reasonable assumptions and correct the table.
Remove any redundancies in the corrected table (Table S6.12).
Table S6.12 A Simplified Arrears Procedure

C1: This weeks cash > weekly rate


C2: This weeks cash > 0
C3: Any cash during last month
C4: Arrears . >2 * weekly rate
C5: Arrears >4 * weekly rate

N
Y

Y
N

N
Y

N
Y
N

N
Y
Y
N

N
Y

Send arrears letter A


Send arrears letter B
Send arrears letter C
Send arrears letter D
Notify accounts
Take special action

A1 A2 A3 A1 A4 A5 A1 A6 A5

K-map for the decision table


C1C2

C1C2

YY

NN NY
A4
A1
A4
A4
A3
A4
A6
A3

YN

A1

C3C4

NN
NY

YY
A1
A4
A1
A4
A1

A1

C3C4

YN

NN

NY

YY

A5

A5

A5

A2
A5
A2

YN

NN
NY
YY

A1

YN

C5 = N
C5=Y
Fig S6.12
Assume weekly rate >0
Impossible rule: C1 = Y

C2 = N

Impossible rule: C4 = N

C5 = Y

K- map (Fig. S 9.10) has incompleteness marked by ?


C1

C2

C3

V. Rajaraman/IISc. Bangalore

C4

C5
//V1/June 04/10

System Analysis and Design/ Structured systems analysis and design

Worked Examples

Logically contradictory rules


C1

C2

C3

C4

C5

N
N
Y
Y
Y

Y
Y
Y
Y
Y

N
N
N
N
N

N
Y
N
Y
Y

N
N
N
N
Y

If in all these cases we take action to notify accounts (Action A1) then the K- map becomes the
one shown in Fig. S9.11
A1 = C3. C4 + C1 . C5 + C2 . C3 . C5 + C1 . C3 + C1 . C2 . C3 . C5
A2 = C1 . C3 . C5
A3 = C1 . C2 . C3 . C4 . C5
A4 = C2 . C3 . C5
A5 = C1 . C3 . C5 + C2 . C4 . C5
A6 = C2 . C3 . C4 . C5

C1C2
C3C4
NN
NY

YY
YN

NN

NY

YY

A4

A1

A1

A4

A1

A1

A6
A1

A3
A1

YN

A1
A1

C5=N
Fig S.6.13
C1C2
C3C4

NN

NY

YY

YN

NN
NY

V. Rajaraman/IISc. Bangalore
YY

//V1/June 04/11

System Analysis and Design/ Structured systems analysis and design

A5

A5

A1

A5

A1

A2

Worked Examples

C5=Y
FigS6.14
C1: This weeks cash > weekly rate
C2: This weeks cash > 0
C3: Any cash during last month
C4: Arrears . > 2 * weekly rate
C5: Arrears > 4 * weekly rate

Y
N

Y
N

N
Y
Y

N
Y
Y
Y
N

N
N

Y
Y

N
Y
Y
N

Send arrears letter A


Send arrears letter B
Send arrears letter C
Send arrears letter D
Notify accounts
Take special action

6.13 The policy followed by a company to process customer orders is given by the
following rules:
(i)
If the customer order that in stock and his credit is OK, supply his
requirement.
(ii)
If the customer credit is not OK do not supply. Send him an intimation.
(iii) If the customer credit is OK but items in stock are less than his order, supply
what is in stock. Enter the balance to be sent in a back-order file.
Obtain a decision table for the above policy.

C1 : Customer order <= Item in the stock


C2 : Customer credit ok
Y
V. Rajaraman/IISc. Bangalore

Supply requirement
//V1/June 04/12

System Analysis and Design/ Structured systems analysis and design

Worked Examples

C2
Y

Do not supply send intimation

C1
N

Supply what is in the stock. Enter balance in


the back order file

Y
N

C2

Do not supply send intimation

6.14 Obtain a decision tree to be used by a person to enter the office of a manager.
The conditions to be checked are:
Door open? Ring sign on? Enter sign on? Door locked?
The actions a person takes are:
Ring bell, enter, wait, leave.
After obtaining the decision table, ensure that it has no logical errors and that it is
in minimal form.
C1 : Door open
C2 : Ring sign on
C3 : Enter sign on
C4 : Door locked
Y

Ring bell and enter

C3
Y

N
N

C2

Y
C1

N
C3
N

C4
Y

Ring bell and wait


Enter

Leave

Leave

Observe that C1 is not relevant and not clear in the Decision tree

V. Rajaraman/IISc. Bangalore

//V1/June 04/13

System Analysis and Design/ Structured systems analysis and design

Worked Examples

6.15 A University has the following rules for a student to qualify for a degree with
Physics as the main subject and Mathematics as the subsidiary subject:
(i)
he should get 50% or more marks in Physics and 40% or more marks in
Mathematics.
(ii)
If he gets < 50% marks in Physics, he should get 50% or more marks in
Mathematics. He should, however, get at least 40% marks in Physics.
(iii) If he gets < 40% marks in Mathematics and 60% or more marks in Physics,
he is allowed to reappear in Mathematics examination only so that he can
qualify.
Obtain a decision tree for the above problem

Pass
Y
C2
Y
N
C1

C4

Appear in mathematics

Y
N

Y
C3

Fail
C5

Pass

Fail

N
Fail

V. Rajaraman/IISc. Bangalore

//V1/June 04/14

System Analysis and Design/ Structured systems analysis and design

Worked Examples

Pass

>=50
>=50

C2

>=40

Pass

< 40
Repeat math
C1
>=40

>=60
< 40

Fail

(An incorrect tree. This is not correct as rule ii not correctly interpreted)

C1 : Physics Marks
C2 : Math marks
C3 : Math marks >=50%
CORRECTED DECISION TREE

>=50
C1

Pass
Fail

C2

>=40

Pass
C3
Fail

>=60
C2
<40

Pass
Repeat math
Fail

V. Rajaraman/IISc. Bangalore

//V1/June 04/15

System Analysis and Design/ Structured systems analysis and design

Worked Examples

6.16 You want to go to Delhi from Bangalore. There are three flights per day; early
morning, late morning and evening. You would like to go on 21.4.04 by early
morning flight. If it is not available you will take the late morning flight or evening
flight in that order. If neither is available you are willing to take any flight on
22.4.04 but prefer early and late morning flights., Obtain a decision tree for this
word statement. Is decision table suitable for this problem? If not why?

Book ticket
C1
N

Y
Book ticket
Y

C2

Book ticket
N

C3

Book ticket
N

C4

Book ticket
N

C5

Book ticket
N

C6
N

No ticket available

C1 : Is ticket available on early morning flight on 21/4/04


C2 : Is ticket available on late morning flight on 21/4/04
C3 : Is ticket available on evening flight on 21/4/04
C4 : Is ticket available on early morning flight on 22/4/04
C5 : Is ticket available on late morning flight on 22/4/04
C6 : Is ticket available on evening flight on 22/4/04

V. Rajaraman/IISc. Bangalore

//V1/June 04/16

System Analysis and Design/Data Oriented Systems Design

Learning Objectives

Learning Objectives

The Entity-Relationship(ER) modeling to develop a conceptual model of data.


How to organize data required in an application as relations.
The need for normalizing relations.
The various normal forms and their relevance.
How to normalize relations to successive higher normal forms to form a relational
database.
The need for an integrated database in organizations.
The goals of Data Base Management systems (DBMS).
The structure and organization of DBMS.

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/ Data Oriented Systems Design

Motivation

Motivation
When a DFD is developed we have knowledge of all data elements required by an
application.
Data dictionary lists all data elements but does not say anything about
relationships between data elements.
Relationships are needed to logically group data elements into related sets or
tables.
Such an organization
o Reduces data duplication
o Simplifies adding, deleting and updating data
o Simplifies retrieval of desired data
Logical databases give conceptual model..
Logical databases need to be stored in physical media such as a hard disk for use
by applications.
A system is needed to map the logical database to a physical medium, which is
transparent to an application program..
Database management systems achieve this purpose.

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

What is Data Dictionary


Data dictionary is a catalogue of all data used in an application, In
other words it is data about data which is called metadata
Data dictionary gives a single point reference of data repository of
an organization
It is thus an important documentation which would be useful to
maintain a system
V.Rajaraman

SAD/M7/LU1/V1/2004

How is Data
Dictionary Developed?

Starting point is DFD


Example :
Consider the Receiving office process described in Module 3.
DFD is reproduced below.

V.Rajaraman

SAD/M7/LU1/V1/2004

How is Data
Dictionary Developed? (Contd.)
Vendor

Delivery
note

Receiving
Process

Orders

Items
Received
note

Inspection
Office

Purchase
Office
Discrepancy
note

We will recall the word statement from requirement


specification now.
V.Rajaraman

SAD/M7/LU1/V1/2004

Word Statement
of Requirements
Vendor sends items with a delivery note while
fulfilling an order (along with the physical items) to a
receiving office.
Receiving office compares a delivery note against
order placed.If there is a discrepancy a discrepancy
note is sent to purchase office.
Actual items received note is sent to the inspection
office along with items received.
V.Rajaraman

SAD/M7/LU1/V1/2004

Data Elements in Data Flow


From word statement we derive data elements in each data flow.
1. Delivery note
Order no,Vendor name, Vendor address, item name, delivery
date, quantity supplied, units
Item name and Vendor name may not be unique to ensure
uniqueness we assign unique codes for them.
V.Rajaraman

SAD/M7/LU1/V1/2004

Data Elements
in Data Flow (Contd.)
Name is however still kept to aid people.
Thus delivery note is:
Delivery note = Order no + Vendor code +
Vendor name + Vendor address + item code +
item name + delivery date + quantity supplied
+ units.
V.Rajaraman

SAD/M7/LU1/V1/2004

Data Elements in Data Flow


Discrepancy note : Order no + Vendor code + Vendor name +
Vendor address + item code + item name + delivery date + quantity
supplied + units + excess/deficiency + no of days late/early.
Items received note = Delivery note
Data in data store
Order records = order no + vendor code + vendor name + vendor
address + item code + item name + order date + qty ordered + units
+ delivery period.
V.Rajaraman

SAD/M7/LU1/V1/2004

Data Dictionary Format


Data dictionary gives in detail the characteristics of a data element.
Typical characteristics are:
Data name : Should be descriptive and self explanatory.This
will help in documentation and maintenance
Data description : What it represents
Origin : Where the data originates
V.Rajaraman

SAD/M7/LU1/V1/2004

Data Dictionary
Format (Contd.)
e.g. input from forms, comes from receiving office, keyed in by
user etc.
Destination : Where data will flow and will be used (if any)
Data Type : numeric, alphanumeric,letters(or text),binary(0 or 1;
True or False), Integer, Decimal fixed point, real (floating point),
currency unit, date
V.Rajaraman

SAD/M7/LU1/V1/2004

Typical Characteristics
of Data Elements(contd)
Length : no of columns needed
Limits on value : (if relevant)
e.g. upper and lower bounds of value (age>0,<100)
Remarks : (if any)
V.Rajaraman

SAD/M7/LU1/V1/2004

10

Example of
Data Dictionary Entry
Name : Order number
Description : Used to identify order given to vendor
Origin : Part of delivery note from vendor
Destination : Receiving process
Data type : Numeric Integer
Length : 8 digits
Limits on value : >000,<=99999999
Actual value not relevant.Used only as unique identifier
Remarks: It is a key field.
V.Rajaraman

SAD/M7/LU1/V1/2004

11

Example of Data
Dictionary Entry (Contd)
Name : Delivery date
Description : Date item is to be delivered
Origin : Part of delivery note from vendor.Is also in orders data
store which is input to receiving process
Destination : Receiving process
Data type : Numeric Integer
V.Rajaraman

SAD/M7/LU1/V1/2004

12

Example of Data
Dictionary Entry (Contd)
Length : 8 digits
Limits on value : Date field in the form DDMMYYYY.
Should satisfy constraints of a date in calendar
Remarks: Blank fields not allowed.
e.g. 05082004 is ok but not 582004
V.Rajaraman

SAD/M7/LU1/V1/2004

13

Data Dictionary Uses


Data dictionary can be enormous in size.Requires careful
development. However,it is centralized reference document.
Invaluable resource to design
Input forms and screens
Data checking programs
Process specification
Database
Very useful in understanding and maintaining system
V.Rajaraman

SAD/M7/LU1/V1/2004

14

Data Input Methods


On-line - User directly Enters data using
screen prompts
Off-line -Forms filled by users- for
example-candidates for admission to a college
fill forms
Data from forms keyed in by a data entry
operator

V.Rajaraman

SAD/M7/LU2/V1/2004

Error Sources

Errors in on-line data entry due to poor screen design. System


should inform the user immediately when wrong data is input
Errors in off-line data entry due to bad form design and
human errors by users and data entry operator

V.Rajaraman

SAD/M7/LU2/V1/2004

Error Sources
System should prevent user making mistakes by
Good form design by leaving enough space
for writing legibly
Clear instructions to fill form
System should prevent data entry operator making mistakes by
Good form design
Reducing key strokes
Immediate error feedback
V.Rajaraman

SAD/M7/LU2/V1/2004

Off Line
Data Entry - Problems
Forms batched
Desirable for the machine to give message when input is
wrong. Not always possible
Error found after elapse of time
Need good controls to automatically detect and if possible
correct errors
V.Rajaraman

SAD/M7/LU2/V1/2004

Batch Data Entry


Data entered
in forms

Keyboard
Data entry

Input
batch

Input file

Error
batch
Error
report

Output report

V.Rajaraman

Data validation
program

Data processing
program

SAD/M7/LU2/V1/2004

Update
program

Data
store

Batch Data Entry


Name

Address

Bad design : Tendency will be to fill


name on top line. Not enough space for
letters of address

Tick as applicable
Individual
Hindu undivided family
Parent/Guardian of minor

V.Rajaraman

Bad design : Choices are not codified.


Data entry operator will be confused.

SAD/M7/LU2/V1/2004

Batch Data Entry


Enter date

Enter date

Day Month Year


(Bad design)

(Good design)

V.Rajaraman

Enter time
Hr Min Sec

Enter time

(Good design)

(Bad design)

SAD/M7/LU2/V1/2004

Batch Data Entry


Enter name and address using capital letters
Use one box for each alphabet
Tick any of the following
Shri

Smt
1

Kum
2

Name
Only address (do not
Repeat name)

V.Rajaraman

Pin

SAD/M7/LU2/V1/2004

Batch Data Entry (Contd.)


I am applying as:
Tick one of the boxes below
Individual

Hindu undivided
family

Parent or guardian
Of minor

Clear instructions . Enough space for entry manually.


Data entry operator can be simple instructions for data entry
V.Rajaraman

SAD/M7/LU2/V1/2004

Computer Readable Forms


As manual data input from forms are slow and expensive
attempts have been made to automate form reading using
scanners
Needs hand writing recognition and correct form alignment
Not very successful
However if forms require just darkening some pre-defined
areas they can be machine read and interpreted.
Example Multiple choice questions in exams where specific
boxes are darkened based on the choice.
V.Rajaraman

SAD/M7/LU2/V1/2004

10

Interactive Data Input


Advent of PCs and client/server model in computer
networks, interactive data input is now widely used
Advantages are instant response when data is input so
that errors are immediately corrected.
Flexibility in screen design which minimizes manual
effort
Use of mouse and icons simplifies pre-determined
choices of data
V.Rajaraman

SAD/M7/LU2/V1/2004

11

Interactive Data Input

Three main models of interactive data input :


Menus
Templates
Commands

V.Rajaraman

SAD/M7/LU2/V1/2004

12

Models of Data Input


Menus:
User Presented Several Alternatives And Asked To Type
His/Her Choice
Example
Select Alternative
Type 1 For entering new student record
Type 2 For deleting student record
Type 3 For changing student record
Your choice
V.Rajaraman

SAD/M7/LU2/V1/2004

13

Models of Data Input


Template:
Template analogous to form
Has features to reject incorrect data input using built-in program
User friendly visual presentation
Example:
Roll no
Name
FIRST NAME/INTIALS

V.Rajaraman

LAST NAME

SAD/M7/LU2/V1/2004

14

Models of Data Input (Contd.)

Dept code

CE

CS

ME EE IT

Year
Hostel code

CODES
B
C

Pre-programmed to reject incorrect Roll no, Dept code,


Year, Hostel code

V.Rajaraman

SAD/M7/LU2/V1/2004

15

Models of Data Input


Interactive commands guides user through alternatives
Example
Computer : Did you request deletion of record ?
Type Y or N
User
:Y
Computer : Give student roll no
User
: 56743
Computer : Is name of the student A.K.Jain?
Type Y or N
User
:Y
Computer : Is he 1st year student
Type Y or N
User
:Y
Computer : Shall I delete name?
User
:Y
V.Rajaraman
SAD/M7/LU2/V1/2004

16

Models of Data Input


Normally all three models will occur together in application .
In other words Menu, Forms and Commands are not mutually
exclusive.
Graphical user interface design very rich area-languages such as
Visual Basic simplifies design of user interface.
We have given only a flavor of the topic.
V.Rajaraman

SAD/M7/LU2/V1/2004

17

Why do we need Codes?


Need for Coding:
Unique Identifier
- Example Roll no instead of name
Cross Referencing Between Applications
- Unique Roll no may be used in examination
records,accounts, health centre
Efficient Storage And Retrieval
- Codes concise- a long name will have a shorter
roll no
V.Rajaraman

SAD/M7/LU3/V1/2004

What are the Requirements


of a Good Code?
Concise - Smallest length to reduce storage and data input effort
Expandable - Add new members easily
Meaningful- Code must convey some information about
item being coded
Comprehensive - Include all relevant characteristics of item
being coded
Precise - Unique, unambiguous code
V.Rajaraman

SAD/M7/LU3/V1/2004

What methods
do we use to Code
1) Serial No: Assign serial number to each item
2) Block Codes: Blocks of serial numbers assigned to different
categories.
3) Group Classification Code- Groups of digits/characters
assigned for different characteristics
V.Rajaraman

SAD/M7/LU3/V1/2004

What methods do
we use to Code (Contd.)
Roll no

87

05

Year
admitted

Term
admitted

Dept

Status
UG/PG

Serial No
in Dept

CS

UG

465

(use
meaningful
characters) 87

V.Rajaraman

SAD/M7/LU3/V1/2004

465

What Methods do
we use to Code (Contd)
4) Significant Codes - Some Or All Parts Given Values
Roll no

BA

95

Banian Male Chest


Size
(cms)

V.Rajaraman

Cotton

SAD/M7/LU3/V1/2004

Style
Color
(Round (blue)
neck)

Error Detection Code


Incorrect data entry can lead to chaos
Mistakes occur as volume of data processed is large
Need to detect and if possible correct errors in data entry
Error detected by introducing controlled redundancy in codes
Error control digits added based on statistics of types of
errors normally committed during data entry
V.Rajaraman

SAD/M7/LU3/V1/2004

Modulus 11
Check Digit System
Error detection digit added at the end of a numeric code
Code designed in such a way as to detect all single transcription
and single transposition errors which is 95% of all errors
Single transcription error 4968748687
Single transposition error 4568748657

V.Rajaraman

SAD/M7/LU3/V1/2004

Modulus 11
Check Digit System
Given code 49687 modulus check digit obtained as
follows: Multiply each digit by
Weights of 2,3,4 etc starting with least significant digit
7*2+8*3+6*4+9*5+4*6=131
131/11=11,remainder 10; or 131 mod (11) =10;
(11-10)=1 append it to the code
The code with check digit=496871
If remainder is 1 then append(11-1)=10 code as X
V.Rajaraman

SAD/M7/LU3/V1/2004

Error Detection
496871
Correct code

486871
Code as entered

Error detection - 1*1 + 7*2 + 8*3 + 6*4 + 8*5 + 4*6


= 127/11 Remainder != 0 => Error
496871
Error detection -

416879
9*1 + 7*2 + 8*3 + 6*4 + 1*5 + 4*6
= 100/11 Remainder != 0 => Error

V.Rajaraman

SAD/M7/LU3/V1/2004

Why does Modulus


11 Check Digit Work

Given dn, dn-1,..d1 where d1 is the check digit


n
(Widi ) mod N=0 by design
i=1
What should be the values of N & Wis
Single transcription error: dk become t

(Widi ) = (Widi ) + t Wk - Wk dk
i=1
i=1

V.Rajaraman

SAD/M7/LU3/V1/2004

10

Why does Modulus


11 Check Digit Work (Contd.)
As (Widi ) mod N=0 (t- dk ) Wk mod N = 0
(t- dk ) Wk = p.N where p is any integer
Conditions
1. integer not a prime => N a prime
2. Smallest 0<Wk<N
3. As [t-dk] < 10 and Wk < N, N>10
4. Product of prime > 10 =11 => N=11
V.Rajaraman

SAD/M7/LU3/V1/2004

11

Why does Modulus


11 Check Digit Work

Given dn,dn-1,..d1 where d1 is the check digit

n
(Widi ) mod N=0 by design
i=1
What should be the values of N & Wis
Single transcription error: dk become t
n
n
(Widi ) = (Widi ) + t Wk - Wk dk
i=1
i=1
As (Widi ) mod N=0 (t - dk ) Wk mod N = 0
(t-dk ) Wk = p. N where p is any integer
V.Rajaraman

SAD/M7/LU3/V1/2004

12

Why does Modulus


11 Check Digit Work
Single transposition error
Let dk and dm get interchanged
n

[ Wi,di + (dkWm + dmWk - dkWk - dmWm )] mod N = 0


i=1

Or (dk-dm)(Wm-Wk) = p.N
1. (Wm - Wk) = 0 => Weights distinct
2. (dk- dm) <10 If N> 10 equation satisfied
3. If N prime product cannot be prime
therefore N =11 satisfies conditions
V.Rajaraman

SAD/M7/LU3/V1/2004

13

Other Checking Systems


Use modulo n check with n prime > largest code
character value
For hexadecimal codes symbols = 16, n =17
For alphanumeric codes

26 letters
10 digits
36 symbols

Therefore n=37.

V.Rajaraman

SAD/M7/LU3/V1/2004

14

Validating Input Data


When large volume of data is input special precautions
needed to validate data
Validation checks :
Sequence Numbering - Detects Missing Record
Batch Control - Use Batch Totals
Data Entry And Verification-dual Input
Record Totals-add Individual Values For checking
Modulus 11 Check Digit
V.Rajaraman

SAD/M7/LU3/V1/2004

15

Checks on Individual Fields


Radix errors - For example seconds field cannot exceed
60,month field cannot exceed 12
Range check - Fields should be within specified range
Reasonableness check - Telephone bill cannot be more
than 10 times average bill of last few months
Inconsistent data - For example : 31-04-99
V.Rajaraman

SAD/M7/LU3/V1/2004

16

Checks on
Individual Fields (Contd.)
Incorrect data- Batch total checks this
Missing data - Batch control data checks this
Inter field relationship check For example - Student of 8lh class cannot have age > 25

V.Rajaraman

SAD/M7/LU3/V1/2004

17

System Analysis and Design/ Data Input Methods

Learning Objectives

Learning Objectives
The need for a data dictionary for an application.
How to develop a data dictionary for an application.
Design of forms and screens for data input.
Need and methods of coding data elements.
Coding schemes for automatic error detection while inputting data.
Need for and design of input data validation methods.

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design / Data Input Methods

Motivation

Motivation
During systems analysis it is essential for an analyst to decide the necessary and
sufficient data for designing an application.
DFD gives the data flows and stores of a system
Individual data elements of data flows and stores can be catalogued
Such a catalogue with description of each element and their types will be an
invaluable aid while designing a system.
A catalogue will also bring out if any data is duplicated/missed
A catalogue will also be an invaluable documentation of a system
Such a catalogue is called Data dictionary-It is actually metadata, i.e., data about
data.
After data dictionary is designed one needs to determine how the data is to be
input.
Data input methods depend on whether the data is filled in by customers in forms
manually and later input by data entry operators or data is directly input by users
on PCs.
We thus need to understand both these methods.
Unless data input is correct, results will be unreliable
Information systems normally have a large volume of data
Because of large volume special controls are needed to ensure correctness of data
input - otherwise it is difficult to find which data is incorrect
Thus it is important to design appropriate data input methods to prevent errors
while entering data

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

System Analysis and Design / Data Input Methods

Motivation

Key data elements are important to identify records. They need to be unique,
concise and understandable by users. Thus we need to study methods of coding
key data element

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

Logical Database
Design-introduction

Purpose to develop conceptual model of data


This model specifies relationships among data items

Using this, raw data are organized into tables of related data
These tables are organized in such a way that:
a. Duplication of data is reduced
b. Operations of adding,deleting, changing data(together
know as updating data) is simplified and systematized
c. Systematization reduces accidental errors
d. Retrieval of data is facilitated
Collection of these tables are called the database for the application
SAD/M8/LU1/V1/2004

V.Rajaraman

V.Rajaraman

Logical Database
Design-introduction
Loosely one may call organization of related data put in a
table as a RELATION
Systematization by which related data are put in a table is
called NORMALIZATION
A method called entity-relationship analysis facilitates
creation of relations

SAD/M8/LU1/V1/2004

V.Rajaraman

V.Rajaraman

Entity-relationship Model
Entity: Specifies Distinct Real World Items In An
Application
For example: vendor,item,student,course,teachers
Relationship: Meaningful Dependencies Between Entities
For example: vendor supplies items
teacher teaches courses
Relationships are underlined above

SAD/M8/LU1/V1/2004

V.Rajaraman

V.Rajaraman

Entity Sets

An entity set is collection of similar entities


Examples : * Set of all vendors of an organization is a vendor set
* Set of all items in a store is an item set
Every member of an entity set is described by its attributes

SAD/M8/LU1/V1/2004

V.Rajaraman

V.Rajaraman

Attributes
Attributes specify properties of members of entity set
Attributes also specify properties of relationships
Examples:
Entity : Vendor
Attributes : vendor code,vendor name,address
Relationship : supplies
Attributes : vendor code, item code,order no., qty. supplied,date of
supply, price/unit
SAD/M8/LU1/V1/2004

V.Rajaraman

V.Rajaraman

Entities And Attributes


Example
Entity : Teacher
Attributes : Teacher code,teacher name,department,building,room
no,phone no.
Relationship : Teaches
Attributes : Teacher code,Course no,course name,semester offered,
credits, prerequisites

SAD/M8/LU1/V1/2004

V.Rajaraman

V.Rajaraman

Entity-relationship Diagram
Some entities depend on one another
For example: entity vendor and entity items are related as
vendors supply items
These relationships are described by entity-relationship diagrams
(or ER diagrams)
In an ER diagram entities are represented by rectangles and
relationships by diamond shaped boxes

SAD/M8/LU1/V1/2004

V.Rajaraman

V.Rajaraman

Examples

ENTITY

VENDOR

ORDERS

SUPPLIES

PLACED
WITH

RELATIONSHIP
ENTITY
ITEMS

SAD/M8/LU1/V1/2004

V.Rajaraman

VENDOR

V.Rajaraman

How To Identify Entities


And Relationships
No algorithms to identify entities and relationship
When a word statement is used to describe an applications nouns
normally are entities and verbs relationships
Students attend courses
Noun
ENTITY

Verb
RELATIONSHIP

Noun
ENTITY

Teachers teach Courses


Noun
ENTITY

Verb
RELATIONSHIP
SAD/M8/LU1/V1/2004

V.Rajaraman

Noun
ENTITY
9

V.Rajaraman

Entity-relationship Diagrams
One Entity May Be Related To Many Other Entities By
Multiple Relationships
Order no
Order date

ORDERS
Order no
Item code

Placed
for

Placed
with

Order no
Vendor code
Item code
Qty ordered
Price/unit

Item code
Item name

Vendor code
items

vendors

Vendor name
address

Underlined attributes are unique identifiers


SAD/M8/LU1/V1/2004

V.Rajaraman

10

V.Rajaraman

Relation Cardinality

Relation cardinality - number of relationships in which an entity


can appear
An entity may appear in
- Only one relationship or
- In fixed number of relationships or
- In a variable number of relationships

SAD/M8/LU1/V1/2004

V.Rajaraman

11

V.Rajaraman

Relation Cardinality(contd.)
V1

i1
i2
i3
i4
i5

V2
V3
Vendor

supplies

items

Vendor1 supplies
items il,i3,i5
Vendor2 supplies
items il and i2
Vendor3 supplies
items i4 and i5

Observe a vendor can supply many items


Observe also that many vendors can supply the
same item
SAD/M8/LU1/V1/2004

V.Rajaraman

12

V.Rajaraman

Relation Cardinality
Representation
vendor

vendor
N

supplies

N
supplies
6

items

items

A vendor cannot supply more


than 6 items
N vendors can supply a
given item

vendor
2
supplies

An item cannot be supplied by


more than 2 vendors

items

SAD/M8/LU1/V1/2004

V.Rajaraman

13

V.Rajaraman

Examples
Teacher id
teacher
1

Name
Dept
address

Teacher id
student id

advises
N

students

Student id
Name
Dept
address

1 Teacher advises N students


Observe that in the advises relationship the identifier need not be
composite
If it is N : M relationship then the relationship will have the
identifier of both participating entities sets
SAD/M8/LU1/V1/2004

V.Rajaraman

14

V.Rajaraman

EXAMPLES (CONTD)
Not all teachers may be required to advise
A teacher can advise not more than 3 students
Represented by ER diagram , small open circle specifies
that some teachers may not participate in advises
relationship
Teacher
1
advises
3

students
SAD/M8/LU1/V1/2004

V.Rajaraman

15

V.Rajaraman

Why Is Finding
Cardinality Necessary
The identifier of the relationship will be composite if cardinality is
N:M
It will be single if cardinality is 1:M
If an entity has

attached to it ,not all entities in the set may be

present in the relationship


Will be useful later in designing data base

SAD/M8/LU1/V1/2004

V.Rajaraman

16

V.Rajaraman

Relations
Entity sets and relationship sets are useful in designing data bases
Entity - relationship sets may be put as a table of values. This is
called a relation
Relation name is entity name
A row of a relation has a member of an entity or a relationship set

V.Rajaraman
V.Rajaraman

SAD/M8/LU2/V1/2004
SAD/M8/LU2/V1/2004

Examples Of A Relation

VENDOR CODE
1456
1685
1284
1694

V.Rajaraman
V.Rajaraman

VENDOR NAME
Ram & co
Gopal & sons
Sivaraj brother
Gita ltd

ADDRESS
112, 1st cross Bangalore-12
452,4th main, Delhi-8
368 M.G Road, Pune-8
495 N.S.C Road,Calicut

SAD/M8/LU2/V1/2004
SAD/M8/LU2/V1/2004

Examples Of A Relation
RELATION name: Vendor (same name as entity name)
RELATION ATTRIBUTES: Vendor code, vendor name address
Row of relation is called a tuple
In a RELATION rows can be in any order
columns can be of any order
No two rows are identical
No two columns are identical
V.Rajaraman
V.Rajaraman

SAD/M8/LU2/V1/2004
SAD/M8/LU2/V1/2004

Relation Notation
Relation is an entire table
However a concise notation used
Notation uses: relation name and attributes
Vendor relation:
Vendor (Vendor code, Vendor name,address )

Relation Relation
name
Identifier
V.Rajaraman
V.Rajaraman

Relation attributes
4

SAD/M8/LU2/V1/2004
SAD/M8/LU2/V1/2004

Examples Of Relations
Item (Item code, Item name)
Supplies (vendor code, Item code ,order no ,
qty supplied ,date of supply ,price/unit)
Relationship
Teacher (Teacher_id ,name ,dept ,address )
Advises (Teacher_id ,student_id)
Student (Student_id ,name ,dept ,,address)
Bold faced attributes are key attributes
V.Rajaraman
V.Rajaraman

SAD/M8/LU2/V1/2004
SAD/M8/LU2/V1/2004

Why Relation ?
Ease of storage of entity set as flat file in a computer's storage
Sound theory of relations allows systematic design of relational
data base
Theory of normalizing relations
Reduces duplication of data
Tries to eliminate errors in adding, deleting, altering items in a
data base
Simplifies retrieval of data
V.Rajaraman
V.Rajaraman

SAD/M8/LU2/V1/2004
SAD/M8/LU2/V1/2004

Normalizing Relations
What is normalization of relations ?
Why normalize relations ?
How are relations normalized ?
Normalizing is the process of restructuring relations to a form
which:* Minimizes duplication of data in a database
* Operations of adding, deleting,modifying data in a database
do not lead to inconsistent data in a database
* Retrieval of data simplified
V.Rajaraman

SAD/M8/LU3/V1/2004

Why Normalize ?
A collection of relations relevant for an application constitute a
relational database
Relations are normalized to ensure that:
Collection of relations do not unnecessarily hold duplicate data
When a data item is modified it is modified in all relations
where it appears - no inconsistency is there
When data is deleted accidentally, required data is not deleted
Simplifies retrieval of required data
V.Rajaraman

SAD/M8/LU3/V1/2004

How Are
Relations Normalized ?
UNNORMALIZED RELATION
Order no

Order date

Item lines
Item code

Qty

Price/unit

1456

26021999

3687
4627
3214

52
38
20

50.40
60.20
17.50

1886

04031999

4629
4627

45
30

20.25
60.20

1788

04111999

4627

40

60.20

V.Rajaraman

SAD/M8/LU3/V1/2004

How Are
Relations Normalized?(Contd.)
1. Observe order for many items
2. Item lines has many attributes-called composite attributes
3. Each tuple has variable length
4. Difficult to store due to non-uniformity
5. Given item code difficult to find qty-ordered
6. Called Unnormalized relation

V.Rajaraman

SAD/M8/LU3/V1/2004

First
Normal Form
Identify composite attributes
Convert composite attributes to individual attributes
Duplicate common attributes as many times as lines in
composite attribute
Every attribute describes single property -no composite
attribute
Some data duplicated
This is called First normal form (1NF) also called flat file
V.Rajaraman

SAD/M8/LU3/V1/2004

First
Normal Form (Contd.)
FIRST NORMAL FORM 1NF
Order No

Order date

1456

26021999

1456

Qty

Price/unit

3687

52

50.40

26021999

4627

38

60.20

1456

26021999

3214

20

17.50

1886

04031999

4629

45

20.25

1886

04031999

4627

30

60.20

1788

04111999

4627

40

60.20

V.Rajaraman

Item code

SAD/M8/LU3/V1/2004

Higher
Normal Forms
First normal form is first essential step in normalization
Higher normal forms known as 2NF,3NF,BCNF,4NF,5NF exist
Each is an improvement of the preceding one
A higher normal form also satisfies requirements of a lower
normal form

V.Rajaraman

SAD/M8/LU3/V1/2004

Higher Normal
Forms (Contd.)
5NF
4NF
BCNF
3NF
2NF
1NF

V.Rajaraman

SAD/M8/LU3/V1/2004

Higher
Normal Forms
Higher normalization steps based on :
Detecting dependence between attributes
Identifying key attributes
Detecting multivalued dependency between attributes

V.Rajaraman

SAD/M8/LU3/V1/2004

Functional
Dependency
Given X,Y as two attributes in a relation
Given X if only one value of Y corresponds to it
then Y is functionally dependent on X
X

e.g. Given Item code - Item name known

V.Rajaraman

SAD/M8/LU3/V1/2004

10

Functional
Dependency (Contd.)
Therefore Item code

Item name

Functional dependence may be based on a


composite attribute
X,Z

composite attribute
Order no. ,item code --------- Qty , price
composite attribute
V.Rajaraman

SAD/M8/LU3/V1/2004

11

Dependency Diagram
Student (Roll no, name, address, dept., year of study )
Name
Address
Roll no
Department
Called relation key

Year of study

Roll no. determines uniquely values of all other


attributes in the relation
Therefore it is called a key

V.Rajaraman

SAD/M8/LU3/V1/2004

12

Dependency Diagram
Qty.supplied

Vendor code

Date of supply

Item code

Price/unit
Composite key

Composite key enclosed in one box in diagram

V.Rajaraman

SAD/M8/LU3/V1/2004

13

Why Normalize
Relations-revisited
To ensure that while operating on data base we do not
- Lose data
- Introduce inconsistencies
Operations on data base
Insertion of new data should not force leaving blank fields for
some attributes
Deletion of a tuple should not delete vital information
Updating - changing value of an attribute should be possible
without exhaustively searching all tuples of relation
V.Rajaraman

SAD/M8/LU3/V1/2004

14

Example To Show
Need For Normalization
FIRST NORMAL FORM 1NF

Order No

Order date

Item code

Qty

1456

26021999

3687

52

50.40

1456

26021999

4627

38

60.20

1456

26021999

3214

20

17.50

1886

04031999

4629

45

20.25

1886

04031999

4627

30

60.20

1788

04111999

4627

40

60.20

V.Rajaraman

SAD/M8/LU3/V1/2004

Price/unit

15

Example To Show Need


For Normalization (Contd.)
INSERTION : Enter new item with code 3945 and price 30.50 for
which no order has been placed. Inserted tuple will have no
values(i.e have to be left blank) for order no and order date
DELETION: If order no1886 is deleted the fact that item code
4629 costs 20.25 is lost
UPDATE: If price of item 4627 is changed, all instances of this
item code
have to be changed by exhaustive search-errors possible
V.Rajaraman

SAD/M8/LU3/V1/2004

16

Ideal Normalization
At the end of normalization a normalized relation
Should have no data values duplicated in rows
Every attribute in a row must have a value
Deletion of a row must not lead to accidental
loss of information
Adding a row should not affect other rows
A value of an attribute in a row can be changed independent
of other rows

V.Rajaraman

SAD/M8/LU3/V1/2004

17

Second Normal
Form (2nf)
A relation is in 2NF if
It is in 1NF
Non key attributes functionally dependent on key attribute
If key composite then no non-key attribute can functionally
depend on one part of the key.

V.Rajaraman

SAD/M8/LU3/V1/2004

18

2nf Form
Normalization-example
INF : item order (Order no,Item code, Order date,Qty,Price/unit)
Composite key

Dependency diagram

Order no
Item code

Order date
Qty
Price/unit

V.Rajaraman

SAD/M8/LU3/V1/2004

19

2nf Form
Normalization-example (Contd.)
Not in 2NF as non key attribute dependent on part of a key
attribute (Price/unit dependent on Item code)
2NF relations are Order(order no,order date)
Prices(item code,price/unit)
Order details(order no,item code,qty)
Observe a single 1NF relation split into three 2NF relations

V.Rajaraman

SAD/M8/LU3/V1/2004

20

2nf Form
1 NF Orders Relation
Order No

Order date

Item code

Qty

Price/unit

1456
1456
1456
1886
1886
1788

26021999
26021999
26021999
04031999
04031999
04041999

3687
4627
3214
4629
4627
4627

52
38
20
45
30
40

50.40
60.20
17.50
20.25
60.20
60.20

V.Rajaraman

SAD/M8/LU3/V1/2004

21

2nf Form
2 NF Relations
ORDERS
Order No Order date
1456
26021999
1886
04031999
1788
04041999
PRICES
Item code Price/unit
3687
50.40
4627
60.20
3214
17.50
4629
20.25
V.Rajaraman

ORDER DETAILS
Order No
Item code Qty
1456
3687
52
1456
4627
38
1456
3214
20
1886
4629
45
1886
4627
30
1886
4627
40

SAD/M8/LU3/V1/2004

22

Advantages Of 2nf
* NON KEY ATTRIBUTES WHOLLY DEPENDENT ON KEY
Repetition of order date removed
If order 1886 for item 4629 is cancelled the price/unit is
lost in INF as the whole tuple would be deleted
In 2NF item price not lost when order 1886 for item 4629
cancelled. Only row 4 in order details deleted
Duplication of data in a relation is not there
V.Rajaraman

SAD/M8/LU3/V1/2004

23

Third Normal Form


Relation in 2NF
There is functional dependence between some Non-key attributes
This needs further normalization as the non-keys being dependent
leads to unnecessary duplication of data
EXAMPLE: Student( Roll no, name, dept, year, hostel name )
- If students in a given year are all put in one hostel then year and the
hostel are functionally dependent
- Year implies hostel-hostel name unnecessarily duplicated
- If all students of the year 1 changed to another hostel many tuples
need change
24
V.Rajaraman

SAD/M8/LU3/V1/2004

24

Normalization To 3nf
Student( Roll no, name, dept, year )
Hostel (year, hostel)
This is in 3NF
Example : Employee (empcode,name,salary,project no,termination
date of project)
* termination date (non-key attribute)
Dependent on project no. another non-key attribute
Thus needs normalization
3NF relations : Employee(empcode,name,salary,projectno)
Project( Projectno ,termination date of project)
V.Rajaraman

SAD/M8/LU3/V1/2004

25

Normalization To 3nf
Passenger(Ticket code,Passenger name,Train no,Departure time,Fare)
Train no. and departure time are non-key attributes and are
functionally dependent
3NF Relations :
Passenger(Ticket code ,Passenger name,Train no, Fare)
Train details (Train no., departure time)

V.Rajaraman

SAD/M8/LU3/V1/2004

26

Boyce-codd Normal Form


Assume
* Relation has more than 1 possible key
* Keys composite
* Composite keys have common attribute
* Non-key attributes not dependent on one another
Thus relation in 3NF, still there could be problems due to
unnecessary duplication and loss of data accidentally
V.Rajaraman

SAD/M8/LU3/V1/2004

27

Example
EXAMPLE
Professor (Prof code, Dept, Head of Dept, Percent time)
RELATION
Professor code
P1
P1
P2
P2
P3
P4
P4

V.Rajaraman

Dept
Physics
Maths
Chem
Physics
Maths
Maths
Physics

Head of dept
Ghosh
Krishnan
Rao
Ghosh
Krishnan
Krishnan
Ghosh

SAD/M8/LU3/V1/2004

Percent time
50
50
25
75
100
30
70

28

Example (Contd.)
Observe two possible composite keys (Prof code, Dept) or
(Prof code,Head of Dept)
Observe Head of dept name is repeated
If professor P2 resigns the fact that Rao is Head of Chemistry
is lost as lines 3 & 4 will be deleted

V.Rajaraman

SAD/M8/LU3/V1/2004

29

Example (Contd)
The dependency diagrams are:
Prof code

Percent time

Dept

Head of Dept

Dept

V.Rajaraman

Head of Dept

SAD/M8/LU3/V1/2004

30

Example (Contd)
Head of Dept

Percent time

Prof code

Dept

Percent time a Prof.spends in the department is dependent on


Prof code and Department
Head of Dept depends on department

V.Rajaraman

SAD/M8/LU3/V1/2004

31

Need For Bcnf


Observe the given relation is in 3NF as non key attributes are
independent of one another and wholly dependent on key
However there are problems pointed out
Problem due to the fact that there are two possible
composite keys
An attribute of one of the composite key depends on a
attribute of the other possible composite key
This leads to the problem indicated
V.Rajaraman

SAD/M8/LU3/V1/2004

32

Normalizing To Bcnf
Identify the dependent attributes in the possible composite keys
Remove them and create anew relation
EXAMPLE
Composite keys
1. Prof code ,Dept
Dependency : Dept

2. Prof code,Head of Dept


Head of dept

New relations
Professor (Prof code, Dept, Percent time )
Department ( Dept, Head of Dept)
V.Rajaraman

SAD/M8/LU3/V1/2004

33

Normalized Bcnf Relations


Professor code
P1
P1
P2
P2
P3
P4
P4

Dept
Physics
Maths
Chem
Physics
Maths
Maths
Physics

Percent time
50
50
25
75
100
30
70

Dept
Physics
Maths
Chem

Head of Dept
Ghosh
Krishnan
Rao

Observe there is no redundancy


If P2 resigns information of Head of dept of chemistry is not lost
V.Rajaraman

SAD/M8/LU3/V1/2004

34

Fourth Normal Form


Needed when there are multi-valued dependencies
Example : (Vendor, Project, Item) relations
Assumptions :
-A vendor capable of supplying many items to
many projects
-A project needs many items
-Project may order the same item from many
vendors
V.Rajaraman

SAD/M8/LU3/V1/2004

35

Fourth Normal Form

Vendor
Project

Items

Item

P
Multivalued dependency

Vendor-Project-Item supply capability relation

V.Rajaraman

SAD/M8/LU3/V1/2004

36

Fourth Normal Form (Contd)


Vendor code

Project code

Item code

VI

PI

I1

VI

PI

I2

VI

P3

I1

VI

P3

I2

V2

PI

I2

V2

PI

I3

V3

PI

I1

V3

P2

I1

V.Rajaraman

SAD/M8/LU3/V1/2004

37

Problems
Item I1 duplicated for VI and also for V3
If VI is to supply to project P2 but the item to be supplied is
not decided
there will be blank in item column
Relation in BCNF but still has above problem and
need normalization to 4NF

V.Rajaraman

SAD/M8/LU3/V1/2004

38

Normalization To 4nf
Split vendor-project-item relation into two relations
Resulting relation must have not more than one independent
multivalued dependency
RESULTING RELATIONS
Vendor
VI

Item
11

VI

12

V2

12

V2

13

V3

11

Project

Item

P1
P1
P1
P2
P3
P3

I1
I2
I3
I1
I1
I2

OBSERVE NO UNNECESSARY DUPLICATION


V.Rajaraman

SAD/M8/LU3/V1/2004

39

Need For 5nf


In 4NF relations vendor capability to supply items and projects
need for items are there.
They are obtained by splitting the given relation
Looking at relation project-item we see that project P2 requires
item I1
From vendor item relation we see that I1 is supplied by V1.

V.Rajaraman

SAD/M8/LU3/V1/2004

40

Need For 5nf


This would lead us to infer that(V1,P1,I1)must be a tuple in the
original relation but it is not.In other words V1 does not supply
item I1 to project P2.
This spurious tuple has occurred because vendor V1 may not be
allowed to supply item I1 to project P2
Similarly another spurious tuple is (V3,P3,I1)
We thus need a third relation which specifies the vendors who
are allowed to supply to projects
V.Rajaraman

SAD/M8/LU3/V1/2004

41

Obtaining 5nf Relations


We add a third relation to the two 4NF relations
This is vendor-project relation shown below

VENDOR CODE
V1
V1
V2
V3
V3

V.Rajaraman

PROJECT NO
P1
P3
P1
P1
P2

SAD/M8/LU3/V1/2004

42

Obtaining 5nf
Relations (Contd.)
With this relation added we will not get the spurious tuples
(V1,P2,I1),(V3,P3,I1)
The two 4NF relations together with the vendor-project relation
called 5NF relations obtained by decomposing the original vendorproject-item relation which has a BCNF relation

V.Rajaraman

SAD/M8/LU3/V1/2004

43

Examples Of
Data Base Design
Order - Vendor - Items Ordered Example In Case Study
Information on dependencies given :
Orders for item placed with many vendors
A given order no is only to one vendor
Many items supplied against a given order no
A vendor has capacity to supply many items but only some
items may be ordered
V.Rajaraman

SAD/M8/LU4/V1/2004

Relations-unnormalized
Relations-unnormalized
1. ORDERS(Order no,Order date)
2. ORDERS PLACED FOR(Order no,item code,qty
ordered,delivery time allowed)
3. ORDERS PLACED WITH(order no,vendor code,item
code)
4. VENDOR(Vendor code,vendor name,vendor address)
5. ITEM( item code,item name,price/unit)
6. SUPPLIES(vendor code,item code,order
no,qty.supplied,date of supply)
V.Rajaraman

SAD/M8/LU4/V1/2004

NORMALIZATION:
Relation 1,4,5 are in 3NF and need no change
Relation 2 has a composite key,attributes of composite key
not related.
Non key attributes dependent on composite key,need no
change.
Relation 3: order no and item code have multivalued
dependency.Relation2
already has order no,item code as composite key.Relation 3
is reduced to:
V.Rajaraman

SAD/M8/LU4/V1/2004

Normalization Of
Supplies Relation
7. ORDER PLACED WITH (order no,vendor code)
Consider relation 6 :
6. SUPPLIES (vendor code, item code, order no, qty supplied,
date of supply)
It has a composite key with three attributes
Attributes item code and order no have multi-valued
dependency as many items can be supplied in one order
Need normalization to 4NF
V.Rajaraman

SAD/M8/LU4/V1/2004

Normalization Of
Supplies Relation (Contd.)
Normalized to
8. ACTUAL SUPPLIES (order no, item code, qty
supplied, date of supply)
9. VENDOR CAPABILITY (vendor code, item
code )
The second relation may have items not yet ordered
with a vendor but which could be supplied by vendor
The Normalized relations are : 1,2,4,5,7,8,9
V.Rajaraman

SAD/M8/LU4/V1/2004

Student-teacher-courses
Example
Information on dependence
A teacher may teach more than one course in a semester
A teacher belongs to only one dept.
A student may take many courses in a semester
A course may have many sections taught by different
teachers
V.Rajaraman

SAD/M8/LU4/V1/2004

Student-teacher-courses
Example (Contd.)
E-R Diagram
Teacher

Students
K

Teaches

Attends

Courses
V.Rajaraman

SAD/M8/LU4/V1/2004

Relation-unnormalized
1 TEACHER (Teacher code,teacher name, address, rank, dept)
2 TEACHER_COURSES (Teacher code,Course no,no of
students, section no )
3 COURSE (Course no , semester taught ,Course name, credits)
4 STUDENT (Student no, student name, dept, year )
5 STUDENT COURSES (Student no, Course no, semester no )
V.Rajaraman

SAD/M8/LU4/V1/2004

Relationunnormalized (Contd.)
a) Relations 1,3,4 in 3NF
b) Relations 2 and 5 have multi-attribute key which has multivalued dependency but do not need normalization
c) However information on which teacher teaches a given student
a specified course cannot be found from relations 1 to 5
Therefore Add relation
TEACHER_STUDENT (Teacher code, Student no, Course no)
THIS SET NORMALIZED
V.Rajaraman

SAD/M8/LU4/V1/2004

Conclusions
We have seen how data relevant to applications are organized
logically into set of relations
The process of normalization depends on the semantics, i.e,
meanings of data and an understanding of how various data
elements are related
It is thus a human intensive activity-it cannot be automated

V.Rajaraman

SAD/M8/LU4/V1/2004

10

Conclusions (Contd)
In most problems in practice one is satisfied with 3NF.Higher
normal forms are theoretically important and in some cases
becomes essential.
There is a mathematical theory which underpins the idea of
relations and normalization giving it a sound basis. We have not
discussed it in this module.
A full fledged course in Data Base will describe in detail the
mathematical basis and methods of querying a database
V.Rajaraman

SAD/M8/LU4/V1/2004

11

Problems With
File Based Systems
If programs and files independently developed for each
application in the organization it leads to the following
problems
Data Redundancy-Some data may be duplicated in many
files.
e.g.: Address of customer
Lack Of Data Integrity- Duplicated data may be different
in different files (New address in one file and old address
in another file)
V.Rajaraman

SAD/M8/LU5/V1/2004

Problems With
File Based Systems
Data Availability- May require search of number of files to access
a specified data
Control By Management
-Difficult as data scattered across files.
-All files should be accessed to find specified data
-Aim of data base management systems is to reduce above
problems
V.Rajaraman

SAD/M8/LU5/V1/2004

Problems With
File Based Systems
Data Base - A Collection of related data necessary to manage
an organization (Excludes transient data)
- Models data resource and is independent of
applications
Data Base Management- A set of procedures that manage the database and
provides access to the database in the form required by
the application program
V.Rajaraman

SAD/M8/LU5/V1/2004

Database
Management System
Application1
Application2
Application1

Database
Management
System
DBMS

Database
Organized collection of data
for several applications

Procedures to provide data in the form required by


applications. Applications need not know physical
organization of data
V.Rajaraman

SAD/M8/LU5/V1/2004

Objectives Of A
Database Management System
Data is an organizational resource. It should be
collected, validated, protected, logically organized and
stored with controlled redundancy. This is the
organizational database
One of the main objectives of DBMS is to facilitate
sharing of a database by current and future applications
DBMS must ensure data independence for programs
V.Rajaraman

SAD/M8/LU5/V1/2004

Objectives Of DBMS
Data independence to be provided to application programs
Data independence allows
-Change of database without affecting application programs
-Change of hardware or system software without affecting
application programs
-Sharing of data by different applications by providing views
appropriate for the application
V.Rajaraman

SAD/M8/LU5/V1/2004

Objectives Of DBMS
Control of Redundancy - Avoid unnecessary duplication
Relations between data items specified
Data integrity - Preserve consistency of data values
Data Security - Permit access to data to authorized users only
Performance - Provide timely information when needed
Ensure management control on addition, deletion, change and
dissemination of data
V.Rajaraman

SAD/M8/LU5/V1/2004

Overview Of DBMS
Data needs of current and possible future applications determined
Using E-R data modelling conceptual data model found
Converted to relations if Relational DBMS used
- called logical data model
Application programmers access subset of logical data model
- called external data model
Logical model mapped to physical model for storage in disk store
- called internal model
External data model kept invariant
V.Rajaraman

SAD/M8/LU6/V1/2004

Various Terms Used


In Describing Dbms
Current
applications
Future
Applications

1
2
p
q

Application
programs

V.Rajaraman

Conceptual
model

1
2
p
q

External
Model

SAD/M8/LU6/V1/2004

logical
model

Internal
Model

Database

Components Of Dbms
Data Definition Languages (DDL) to define conceptual, logical
and external models
Data manipulation and query language called Structured Query
Language (SQL)
Features to implement security
Checkpointing and roll back recovery procedures
Record of accesses. Audit trail of changes
V.Rajaraman

SAD/M8/LU6/V1/2004

Database Administrator
Database Administrators responsibilities
Controller of data recourse
Ensure integrity,security and privacy
Maintenance of data dictionary
Coordination of development and maintenance of data
base
Determining access rights

V.Rajaraman

SAD/M8/LU6/V1/2004

Steps In Designing Database


INPUTS
E-R Diagram based on existing
and potential applications
Features of DBMS to be used
Data on frequency of access,
Volume Additions/deletion

DESIGN STEPS
Design conceptual model
Of database
Design logical model of
Data base

User
Feedback
to
Design physical model of database improve
Evaluate performance of physical
model
Implement

V.Rajaraman

SAD/M8/LU6/V1/2004

Characteristics Of A
Good Data Base Design

Satisfy current and future needs of organization

Cater to unanticipated user requirements in the best possible way

Expandable with growth and changes in organization

Easy to change when hardware and software change

Ensure data security by allowing only authorized persons to access


and modify database

V.Rajaraman

SAD/M8/LU6/V1/2004

System Analysis and Design/ Designing Outputs

Learning Objectives

Learning Objectives
Review characteristics of devices used to output information from computers
Objectives of output design
Design of reports
Design of screens
Role of graphics in output design

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design /Designing Outputs

Motivation

Motivation
Presenting results of processing in an attractive and easily understood form is
important
Management requires these reports to initiate actions and thus the significance of
outputs must be easily perceived
Must be aware of new output devices being introduced to use them appropriately
Must also be aware of changes in output delivery with the emergence of systems
such as intranets/internet.
Must also cater to newer applications such as e-commerce which uses the World
Wide Web.

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

Desirable Properties
Of Components
Each subsystem or component must
Have clearly defined responsibility
Acts when requested by an "order"
How the component does its task need not be known to other
components
What the component does should be known

V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

1
1

Object Oriented Modeling


Use of component oriented design
Facilitates changes in the system at low cost
Promotes reuse of components
Problem of integrating components to configure
large system simplified
Simplifies design of distributed systems

V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

2
2

Object And Their Properties


All tangible entities in an application can normally be modelled as
objects
For example: A student,a cycle,a train ticket
Some intangible entities may also be modelled as objects
For example: a bank account, stack data structure
Objects with similar meaning and purpose grouped together as
CLASS
A member of a class is an object instance
V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

3
3

Characteristics Of Objects
All objects have attributes
Example : student : Name
Roll no
Address
Year
Department

V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

4
4

Characteristics Of Objects
All objects have a state
Example Ticket : reserved, waiting list
Student : present, absent
All objects have set of OPERATIONS which can
be performed on them
Operations determine object behavior
Example : Admit student
Cancel ticket
V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

5
5

Class Diagram UML Notation


Universal Modeling Language (UML) is an industry standard
notation to represent a class
Example of UML notation for a Class
Vendor
Vendor id
Name
Address
Vendor type
Add vendor
Delete vendor
Find address
Change address
Find vendor type
V.Rajaraman
V.Rajaraman

CLASS NAME

LIST OF ATTRIBUTES

OPERATIONS OR (METHODS)

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

6
6

Instance Diagram
UML Notation
Shows an object instance's attributes and values
Class name

Example
A 2546 : VENDOR

VENDORNAME = AD SINGH & CO

Vendor id

VENDOR TYPE = DISTRIBUTOR


VENDOR ADDRESS = 5, MALL

Object name
and its Class
name
Attributes
and their
values

ROAD,KANPUR 208001

V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

7
7

Operation Types On Objects


Constructor-creating new instances of a class
Deleting existing instance of class
Example : add new vendor
Query - accessing state without changing value
- has no side effects
Example : find vendor address

V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

8
8

Operation Types On Objects

Update - changes value of one or more attributes


- affect state of object
- has side effects
example : change address of vendor
Implementation of operations on objects called
methods

V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

9
9

Implementation Of Classes
TERMINOLOGY USED IN OBJECT ORIENTED MODELLING
ABSTRACTION

Picking necessary operation and attributes to specify objects


ENCAPSULATION
Hiding implementation details of
methods from outside world

V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

10
10

Implementation
Of Classes (Contd.)
encapsulation al.so known as information hiding
information hiding allows improvement
or modification of methods used by objects
without affecting other parts of a system

V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

11
11

View Of Objects
As Contractors
1) Objects can be thought of contractors who carry out assigned
contracts for clients
2) Clients need not know how the contractor carries out its
contracts
3) Contractors can modify/improve methods they use to carry
out contracts without informing clients
4) External interface presented to clients remain same
V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

12
12

Inheritance
New classes are created from current classes by using the idea of
inheritance
New classes inherit attributes and/or operations of existing
classes
Inheritance allows both generalisation and specialisation in
modeling
Specialisation - given student class, arts students and science
student are two subclasses
-Subclasses inherit properties of parents and in addition may
have their own special attributes and operations
V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

13
13

Example Of Inheritance
Class name

College student
Roll no
Name
Address
Year of study

Attributes
Operations

Science student
Roll no
Name
Address
Year of study
Department
Laboratory name
Admit
Promote
Calculate laboratory fee

V.Rajaraman

V.Rajaraman

Admit
Promote

Class Name

Attributes

Operations
SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

Arts student
Roll no
Name
Address
Year of study
Department
Admit
Promote
Calculate field trip fee
14
14

Generalisation/Specialisation
Given a class Eye surgeon we can generalize it to surgeons which
will inherit most of the attributes and operations of the eye surgeon
A general class School, will inherit many properties of middle
school, primary school
Given a class Doctor we can obtain subclasses : Surgeon, Physician,
General Practitioner, Consulting Doctor.All these will inherit many
properties of doctor and will have their own new attributes and
operations
V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

15
15

Polymorphism
By polymorphism we mean ability to manipulate objects of
different distinct classes knowing only their common properties
Consider classes hospital & school
For both the operation admit will be meaningful
- they will be interpreted differently by each class
Advantage of polymorphism is ease of understanding by a
client
A client gives a generic request - each contractor interprets
and executes request as appropriate to the circumstances
V.Rajaraman
V.Rajaraman

SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004

16
16

Identifying Objects

Simple method
- identify nouns in Requirements specification. These are potential
objects
- Identify verbs in requirements specification. These are potential
operations

V.Rajaraman

SAD/M9/LU2/V1/2004

Criteria For Picking Objects


1) We remind that an object class has many objects as members
2) Wherever there is no possibility of confusion we use them
synonymously
3) Objects should perform assigned services.In other words they
must have responsibilities specified by us.
4) Objects must have relevant attributes which are necessary
to perform service. Attributes must have Non-Null values.

V.Rajaraman

SAD/M9/LU2/V1/2004

Criteria For Picking Objects


5) A class must be essential for functioning of the system
6) Must have common set of attributes and operations
which are necessary for all occurrences of the objects in
the class
7) Objects should be independent of implementation of the
system.

V.Rajaraman

SAD/M9/LU2/V1/2004

How To Select Objects


1) Potential objects selected from word statement primarily by
examining noun phrases
2) All Noun phrases need not be objects
3) If there are some objects whose attributes do not change during
the functioning of a system we reject them
-They are probably external entities
4) We will illustrate selecting objects using examples

V.Rajaraman

SAD/M9/LU2/V1/2004

Example 1 Word Statement


ESSENTIALS OF AN ADMISSION PROCESS TO A
UNIVERSITY ARE
Applicants send applications to a university registrars office
A clerk in the registrar's office scrutinizes applications to see if
mark list is enclosed and fee paid
If scrutiny successful applications passed on to the relevant
department

V.Rajaraman

SAD/M9/LU2/V1/2004

Example 1 Word Statement


Departmental committee scrutinizes applications sent to
it. Applications are ranked. Depending on the seats available
decides to admit, wait list or reject.The application is returned
with the message to the registrars office clerk.
Registrar's office clerk informs the applicant the result of his
applications

V.Rajaraman

SAD/M9/LU2/V1/2004

Example 1
Identification Of Objects
POTENTIAL OBJECTS
1. APPLICANT
2. APPLICATION
3. REGISTRARS OFFICE CLERK
4. DEPARTEMENTAL (COMMITTEE)

How to select relevant objects?

Decision based on answers to following questions

Does it have attributes?

Are operations performed on the attributes?


V.Rajaraman

SAD/M9/LU2/V1/2004

Example 1
Identification Of Objects
ANSWERS FOR EXAMPLE 1
1.

Applicant has attributes. However no operations performed


on it.It is not an object in this problem.

2. Application has attributes operations are performed using


attributes of application. Result conveyed to applicant.Admit
it as an object

V.Rajaraman

SAD/M9/LU2/V1/2004

Example 1
Identification Of Objects (Contd.)
Registrars office clerk has attributes, performs operations on
application, attributes and not on clerks attributes. Thus
reject.
4. Department taken as potential object. It has attributes.
Operations are performed using attributes. Operations are
performed using attributes of application object and also
using attributes of department. Thus admit department as
an object
V.Rajaraman

SAD/M9/LU2/V1/2004

Attributes And Operations


Performed By Identified Objects
CLASS NAME
APPLICATION
ATTRIBUTES
APPLICATION NUMBER
APPLICANT NAME
APPLICANT ADDRESS
MARKS SHEET
FEE PAID RECEIPT
DEPT. APPLIED CODE
APPLN STATUS
CLERK CODE
OPERATIONS
SCRUTINIZE
SEND APPLICATION TO DEPT
SEND RESPONSE
ADMIT/W.L/REJECT TO APPLICANT
V.Rajaraman

SAD/M9/LU2/V1/2004

10

CLASS NAME
DEPARTMENT
ATTRIBUTES
DEPARTMENT CODE
DEPARTMENT NAME
COURSE
NO OF STUDENTS TO BE ADMITTED
NO ON WAIT LIST
MIN. ENTRY QUALIFICATION
STATUS OF APPLICATION

OPERATIONS
SCRUTINIZE APPLICATION
SEND APPLICATION STATUS
V.Rajaraman

SAD/M9/LU2/V1/2004

11

Example 2 : Receiving
Items Ordered
ABSTRACT OF WORD STATEMENTS
Receiving office receives several items from vendors
Receiving office checks delivery note against orders and
detects excess/deficient deliveries if any
Discrepancy note (if any) sent to purchase office
Receiving office sends items received note to inspection office
Inspection office physically inspects items received and accepts
good items.Bad items returned to vendor
Candidate objects underlined
V.Rajaraman

SAD/M9/LU2/V1/2004

12

Example 2 : Receiving
Items Ordered (Contd.)
Items accepted note sent to stores office
Discrepancy note sent to purchase office
Stores office updates inventory based on items
accepted note
Stores office sends taken into stock report to the
accounts office for payment to vendor
Accounts office sends payments to vendors
Candidate objects underlined
V.Rajaraman

SAD/M9/LU2/V1/2004

13

Picking Relevant Objects


POTENTIAL OBJECTS (UNDERLINED IN LAST PPT) ARE:
1. RECEIVING OFFICE
2. ITEMS
3. VENDORS
4. DELIVERY NOTE 5. ORDERS
6. DISCREPANCY NOTE
7. PURCHASE OFFICE 8. ITEMS RECEIVED NOTE
9. INSPECTION OFFICE 10. ACCEPTED ITEMS NOTE
11.STORES OFFICE 12. INVENTORY 13. GOODS TAKEN
IN STOCK REPORT 14. ACCOUNTS OFFICE
15. PAYMENT VOUCHER

V.Rajaraman

SAD/M9/LU2/V1/2004

14

OBJECTS NOT RELEVANT TO THIS APPLICATION


Items
Orders
As no operations on these
Inventory
Goods taken in stock
Payment voucher
RELEVANT OBJECTS
Receiving office Even though its own attributes are not
relevant,its functional attributes are important.These are:
-Delivery note and order to vendor
It thus derives its attributes from these
V.Rajaraman

SAD/M9/LU2/V1/2004

15

Relevant Objects
VENDORS
No operations on this object are needed in this
application.However its attributes are necessary as the Accounts
office makes payment to vendors
CLASS : VENDORS
ATTRIBUTES :
Vendor code
Vendor name
Vendor address
VENDOR is actually an external object.We have thus given only
attributes relevant to this application.In general design one would
usually define this object more comprehensively
V.Rajaraman

SAD/M9/LU2/V1/2004

16

Attributes Of Delivery
Note And Order To Vendor
CLASS : DELIVERY NOTE
Attributes :
Receiving clerk id
Order no
Vendor code
Delivery date
Item code
Qty supplied
Units

V.Rajaraman

CLASS : ORDER TO VENDOR


Attributes :
Order no
Vendor code
Item code
Item name
Qty ordered
Units
Price/Unit
Order date
Delivery period

SAD/M9/LU2/V1/2004

17

Receiving Office Object


Receiving office is selected as an object.Its attributes are attributes
derived from delivery note and order to vendor
The class diagram is give below
CLASS
RECEIVING OFFICE
Is Part of

Is Part of

DELIVERY
NOTE
V.Rajaraman

ORDER TO
VENDOR
SAD/M9/LU2/V1/2004

18

Receiving Office Object


CLASS : RECEIVING OFFICE
Attributes : Derived as shown in the previous slide
Operations :
Compare order no,item code, qty,etc in delivery note
with that in order to vendor
Send discrepancy note (if any) to purchase office and
vendor. If no discrepancy send delivery note to
purchase
Send delivery note to inspection office(object)

V.Rajaraman

SAD/M9/LU2/V1/2004

19

Other Relevant Objects


CLASS : STORES OFFICE
Attributes : Attributes of inspection office + qty in stock
Operations :
Update inventory by adding no of items accepted to
qty in stock
Send advice to accounts object to make payment
for qty accepted

V.Rajaraman

SAD/M9/LU2/V1/2004

20

Next Object Is
Inspection Office
Class : Inspection Office
Attributes : Derived attributes from delivery note +
no of items accepted
Operations :
Send information an accepted items to store
and accounts
Send discrepancy note( if any) to purchase
office and vendor

V.Rajaraman

SAD/M9/LU2/V1/2004

21

Other Objects Are


Class : Accounts Office
Attributes : Derived from inspection office
attributes + price/unit of item
Operations :
Calculate amount to be paid
Print cheque
Request vendor object for vendor address
Print vendor address label
Dispatch payment to vendor
Intimate Purchase office of payment

V.Rajaraman

SAD/M9/LU2/V1/2004

22

Object Oriented
Modelling-crc Method
Steps in object oriented modelling
1) Find objects and their classes
2) Determine responsibilities of each object
3) State responsibilities, that is, actions. It can can carry out on
its own using its knowledge
4) Determine objects with whom they collaborate.

V.Rajaraman

SAD/M9/LU3/V1/2004

Object Oriented
Modelling-crc Method (Contd.)
5) State contracts each object assigns to its
collaborations
6) A collaborator either performs a requested action or
gives information
7) Document each class its responsibilities,its
collaborators and their
responsibilities
8) Develop an object interaction/collaboration graph

V.Rajaraman

SAD/M9/LU3/V1/2004

Crc Team Idea


CRC TEAM : user's representative
System analyst(s)
project coordinator
RESPONSIBILITY : Identify objects
Specify responsibility
Specify collaborators and their
responsibilities
Prepare a card for each class called class index cards
V.Rajaraman

SAD/M9/LU3/V1/2004

Crc Methodology
1. Make CRC Card for each class
CRC CARD
CLASS NAME :
SUPER CLASSES AND SUBCLASSES :
SHORT DESCRIPTION OF CLASS :
COLLABORATORS :
PRIVATE RESPONSIBILITIES OF CLASS :
CONTARCTS WITH COLLABORATORS :
Develop a graph to show interaction between classes
V.Rajaraman

SAD/M9/LU3/V1/2004

Crc Model - Example


For Example1 of last learning unit the CRC model is given below
Class : APPLICATION
Super class : None
Sub class : None
Collaborators : DEPARTMENT
Description : This class represents applications
received for admission to a university
V.Rajaraman

SAD/M9/LU3/V1/2004

Crc Model - Example


Private Responsibilities :
Scrutinize : Applications are scrutinized to see if fee
is paid and marks sheet is enclosed. If yes,
applications is sent to department class.Else a
rejected letter is sent to the applicant
Contract(s) and Collaborator(s):
Forward application to department : When it
passes scrutiny else send reject to applicant
Send letter to applicant : When Department notifies
decision (Admit,Reject,Waitlist) send appropriate
letter to the applicant
V.Rajaraman

SAD/M9/LU3/V1/2004

Crc Model Example (Contd)


Class : DEPARTMENT
Super class : None
Sub class : None
Collaborators : APPLICATION
Description : This class represents departments
whose responsibility is to admit, reject or place an
waiting list on application
V.Rajaraman

SAD/M9/LU3/V1/2004

Crc Model Example (Contd)


Private Responsibilities :
Rank order applications based on selection
criteria.Mark in application:admitted,rejected or in
waiting list depending o available seats
Contract(s) and Collaborator(s):
Send reply to applicationclass on admitted, rejected
or wait list

V.Rajaraman

SAD/M9/LU3/V1/2004

Collaboration Graph

Examine application
CLASS
Admit/reject/ APPLICATION

wait list
Applicant

V.Rajaraman

CLASS
DEPARTMENT
Application status

SAD/M9/LU3/V1/2004

Collaboration Graph For Example2


Delivery
Vendor

CLASS
RECEIVING OFFICE

Inspect

CLASS
INSPECTION OFFICE

Payment

Update
Inventory

Delivery copy
Discrepancy note

CLASS
CLASS
PURCHASE OFFICE Payment ACCOUNTS OFFICE Make

payment

copy

V.Rajaraman

CLASS
STORES OFFICE

SAD/M9/LU3/V1/2004

10

System Analysis and Design / Object Oriented Systems Modeling

Motivation

Motivation
Information Systems are becoming very complex.
We thus need methods to design complex systems.
Main method is to break up a large system into a number of cooperation
components and designing each component or subsystem separately.
Question: How do we do this?
The main purpose of this module is to answer this question.

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

Output Devices
Hard Copy Devices - Printers
Soft Devices - Video Display Devices
Text
Multimedia

Audio - speech synthesizer


Graphics
Video

V. Rajaraman

SAD/M10/LU1/V1/2004

Hard Copy Devices


Printers used when - there is large volume of data
- several copies normally needed
Types of printers
Line Printers
Impact

Dot matrix character printers

Laser printer
Non-Impact

V. Rajaraman

Inkjet printer
SAD/M10/LU1/V1/2004

Printer Characteristics
Line Printers

- Large volume output


- Fast - entire line printed
- Multiple copies
- High capital cost but low running cost

V. Rajaraman

SAD/M10/LU1/V1/2004

Printer Characteristics
Dot Matrix Printers
- Slow
- Inexpensive ( per copy cost)
- Multiple copies with carbon paper
- Poor graphics

V. Rajaraman

SAD/M10/LU1/V1/2004

Printer Characteristics
Inkjet Printers

- Characters + graphics
- Multicolour
- Capital cost low compared to laser printer
- Recurring cost high

V. Rajaraman

SAD/M10/LU1/V1/2004

Printer Characteristics
Laser Printers
- Characters + graphics
- Multicolour expensive
- Excellent quality
- Capital cost high
- Recurring cost lower than inkjet

V. Rajaraman

SAD/M10/LU1/V1/2004

Soft Copy Media


Used to distribute manuals, massive reports, user
documents, software.
Alternatives
Floppy Disk
CD Rom
DVD Rom
Flash Memory
(Semi Conductor)

V. Rajaraman

SAD/M10/LU1/V1/2004

Soft Copy Media (Contd)


Floppy Disk
- Inexpensive
- Easy to mail/transport
- Low capacity 1.4MB
- Read/write
- Contact recording number of
read/writes limited

V. Rajaraman

SAD/M10/LU1/V1/2004

Soft Copy Media (Contd)


CDROM
- Inexpensive Medium
- Read only cheaper/safer
- High capacity 600MB
- Easy to transport/mail
- Primarily used for Text/Graphics

V. Rajaraman

SAD/M10/LU1/V1/2004

Soft Copy Media (Contd)

DVDROM
- Read only cheaper/safer
- Very high capacity upto
8GB
- Easy to transport
- Useful for storing high
quality video such as full length
movies
V. Rajaraman

SAD/M10/LU1/V1/2004

10

Soft Copy Media (Contd)


Flash Memory
- Read/Write
- Small size and weight
- No moving parts thus very reliable
- Needs USB port on PC
- Size 128KB to 2GB
- Low Power needs
- Expensive

V. Rajaraman

SAD/M10/LU1/V1/2004

11

Speech Output Devices


Audio such as beeps used for alerting users
Device used is a speaker
- Very small and inexpensive for beeps
- Inexpensive for speech quality
Useful when eyes are busy,for example, while driving,pilots etc.
Pre-recorded speech is output in such cases
Text-to-speech also useful for giving instructions where manuals
cannot be read.

V. Rajaraman

SAD/M10/LU1/V1/2004

12

Objectives Of Output Design


While designing output format and picking output devices
the following should be taken into account
The user group
Proposed use
Volume of output
Periodicity of output
Timely delivery when required

V.Rajaraman

SAD/M10/LU2/V1/2004

Nature Of Output Reports


Top Management
Summary highlighting important results
Graphical Output - Pie charts
- Bar charts
- Maps
Needed for strategic management

V.Rajaraman

SAD/M10/LU2/V1/2004

Nature Of Output Reports


Middle Management
- Exception reports
- Reduced output volume
- Needed for tactical management

V.Rajaraman

SAD/M10/LU2/V1/2004

Nature Of Output Reports


Operational Management
Details Needed
For example:
- Payroll
- Grade sheets
- Cheque

V.Rajaraman

SAD/M10/LU2/V1/2004

Periodicity Of Output Reports (Contd)


Top Management
-Whenever there are any significant changes
-Give option to ask for specific details
-Periodic quarterly
Middle Management
-Send daily exceptions
-Provide summary on terminal with option to look at
greater details on request
V.Rajaraman

SAD/M10/LU2/V1/2004

Periodicity Of Output Reports (Contd)


Operational Management
-Regular periods
-Periods depend on application
-Example : Payroll monthly

V.Rajaraman

SAD/M10/LU2/V1/2004

Designing Of Operational Output Reports


Structure of a report - Headings
Report heading
Page heading - appears in each page
Detailed heading for each column
Set of records forming a logical group called control
group and is given a control heading

V.Rajaraman

SAD/M10/LU3/V1/2004

Designing Of Operational Output Reports


(Contd)
Structure of a report - Footings
Labels used to describe information contained in a
control group are called control footings
Labels printed at the end of each page of a report is
called page footing

V.Rajaraman

SAD/M10/LU3/V1/2004

Designing Of Operational Output


Reports (Contd)
Label used to give the control information for
the whole report is called final control footing
Label printed at the end of the entire report is
called report footing

V.Rajaraman

SAD/M10/LU3/V1/2004

Example Of Terminology
Report heading
Page heading
Control heading
Detail lines

INDIAN INSTITUTE OF SCIENCE - ACADEMIC ROLL LIST


ROLL LIST OF STUDENTS SEM 1/2000-2001

LIST OF STUDENTS IN AEROSPACE ENGG DEPT


Roll No
97101115
97101125
97101135
.

Name
A.B.BHATTACHARYA
A.K.CHANDRA
R.K.GUPTA

97201198

P.R.RAO

..

Control footing

TOTAL NO OF STUDENTS
Roll No
97102105
97102121
.

Name
A.C.ARVIND
L.S.BHATIA

97102131

P.R.ZAVERI

..

Control footing
Final control
footing
Report footing
V.Rajaraman

TOTAL NO OF STUDENTS IN CHEMICAL ENGG.DEPT = 63


TOTAL NO OF STUDENTS IN SEM 1/200-2001 = 852
END OF IISc BANGALORE ROLL LIST FOR SEM 1/2000-2001
SAD/M10/LU3/V1/2004

Print Chart
Print chart used by analyst to develop paper report format
Languages available to describe format of report and a report
generation program creates report

V.Rajaraman

SAD/M10/LU3/V1/2004

General Principles Of Designing


Reports
Should be able to read left to right, top to bottom
Easy to find important items such as keys
All pages numbered and has heading. Report date essential
All columns labelled

V.Rajaraman

SAD/M10/LU3/V1/2004

General Principles Of Designing


Reports (contd.)
Keep essential details only
Proper use of control footings
Page and report footing useful
Space for end of report signature if
needed

V.Rajaraman

SAD/M10/LU3/V1/2004

Design Of Screens
Screen display convenient for interactive use
Screen size normally smaller than printer - usually 80 cols per
line and 24 lines per screen
Principle of layout similar - Primarily ease of reading

V.Rajaraman

SAD/M10/LU4/V1/2004

Design Of Screens
Provision made at bottom of screen to
continue, get details or exit
Nowadays screens are designed with
buttons which can be clicked using a
mouse to get details, continue or exit from
screen

V.Rajaraman

SAD/M10/LU4/V1/2004

Examples Of Screens
Screen For General Student Information
Indian institute of science
Student information system
ROLL NO
9501325
9602415
9602325
9701425
9702112

NAME
A.B.Bhattacharya
A.P.Das
P.Ganapathy
G.Hari
H.Jai Singh

Details

DEPT
Aerospace
CSA
EE
MET
Civil

Continue

YEAR
ME 1
Ph.D
M.Sc
ME II
Ph.D

Exit

Click button as required


V.Rajaraman

SAD/M10/LU4/V1/2004

Examples Of Screens
Screen For Detailed Student Information
Indian Institute Of Science
Student Information System
05-05-2000
ROLL NO
NAME
YEAR
GUARDIAN
ADDRESS

9701425
G.HARI
ME II
P.GANESHAN
41 OLIVER STREET
MYLAPORE
MADRAS 600 004

Details
V.Rajaraman

Return
SAD/M10/LU4/V1/2004

Business Graphics
Shows Information In Pictorial Form Which Is Easy To Understand
Usual Pictures Are
Bar Charts - Relative Distribution Easy To See
Pie Charts - %Use Of Resources Easy To See
X-y Graphs - Trends Easy To See
Maps - Geographical Distribution Easy To See

V.Rajaraman

SAD/M10/LU4/V1/2004

Total sales of textiles (in lakhs)

Use Of Graph
140
120
100
80
60
40
20
0
0

85

86

87

88

89

90

Year
V.Rajaraman

SAD/M10/LU4/V1/2004

Bar Chart

No of employees

350
300
250
200
150
100
50
0
0

20

25

30

35

40

45

50

55

60

Age
V.Rajaraman

SAD/M10/LU4/V1/2004

Pie Chart
Dividends
15%

Equipment
10%
Tax
10%

R& D
5%
Misc
15%

Interest payment
15%

Raw material
20%
Salaries
20%
V.Rajaraman

SAD/M10/LU4/V1/2004

System Analysis and Design/ Control audit and Security of


Information Systems

Learning Objectives

Learning Objectives
Why controls are necessary in Information systems
Methods of controlling Information systems
How controls are introduced in Information systems
Why Information systems need auditing
How are systems audited
The methods used to test Information systems
How the security of an Information system is ensured

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/ Control audit and Security of


Information Systems

Motivation

Motivation for Controls


It is very important to ensure the reliability of reports produced by an information
system
If unreliability is seen by users the entire credibility of the system is lost
Ensuring reliability is not difficult for small systems but when a system has to
handle massive data it is a challenge
Systematic controls are thus essential when a system is designed
Motivation for Audits
Many organizations are now entirely dependent on computer based information
system
These information systems contain financial data and other critical procedures
It is essential to protect the systems against frauds and ensure that sound
accounting practices are followed
It is necessary to trace the origin and fix responsibilities when frauds occur
Audit methods primary purpose is to ensure this.
Motivation for Testing
Systems contain many individual subsystems
Usually sub-systems and programs are individually tested
However when a whole system is integrated unforeseen errors may be seen
Thus before releasing a system the entire operational system should be tested for
correctness and completeness
Motivation for Security
Systems contain sensitive data about the organization and also about persons
working in the organization
Sensitive data should be protected from spies, thieves or disgruntled employees.
Thus access should be carefully controlled and provided only on a need to know
basis
When computers are networked corruption/erasure may take place due to viruses
Services may be disrupted due to denial of service attacks
Thus systems should be designed with appropriate security measures.

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

System Analysis and Design/ Control audit and Security of


Information Systems

Motivation

Motivation for Disaster Recovery


Organizations depend on Information systems for their entire operations
It is thus essential to ensure continuity of service when unforeseen situations
such as disk crashes, fires, floods and such disasters take place.
Thus it is essential to ensure quick recovery from disasters and ensure
continuity of service.

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

The internet
and
The World Wide Web

V.Rajaraman

SAD/M11/LU1/V1/2004

Computer Networks
Now-a-days no computer has an isolated existence
Computers in an organization are interconnected by local area
networks (LAN)
Home computers are connected to Public Switched Telephone
Network (PSTN) which provide a connection to an Internet
Service Provider (ISP)
LANs of organizations connected to LANs of other
organizations via PSTN using routers

V.Rajaraman

SAD/M11/LU1/V1/2004

Logical Network-internet
Internet is the network of networks and interconnects millions of
computers all over the world
Internet is used to exchange electronic mail, exchange files and
log into remote computers
Common set of rules used by computers connected to the internet
to communicate - called Internet Protocol (IP)

V.Rajaraman

SAD/M11/LU1/V1/2004

Logical Network-internet

Each computer connected to the


internet has a unique address
called IP address
IP address is 4 bytes long
IP addresses are a scarce resource

V.Rajaraman

SAD/M11/LU1/V1/2004

Internet-continued
IP address converted to strings of characters which are easy to
remember
Group of characters combined as domains
Hierarchy of addressing facilitates expansion

V.Rajaraman

SAD/M11/LU1/V1/2004

Internet (Contd)
Internet breaks up messages sent from source to destination
into a number of packets
Packet structure :
Control
Bits for
Checking

Serial no
Of the
Packet

Source
Address

Destination
Address

Message

Payload

Header (20 bytes)

(upto 1kb)

V.Rajaraman

SAD/M11/LU1/V1/2004

Internet (Contd)
Packets need not be of fixed length. Maximum
length of a packet is 1 KB
Message packetised to allow different packets to go
along different paths - called packet switching

V.Rajaraman

SAD/M11/LU1/V1/2004

Packet Switching Advantages And


Disadvantages
Each packet can pick free (cheapest) path to take
Finally packets reassembled using serial no.
Packet switching less expensive and adaptive as faulty paths can
be avoided
Major disadvantage of packet switching is the difficulty in
predicting time taken by different packets to travel from source to
destination

V.Rajaraman

SAD/M11/LU1/V1/2004

Packet Switching Advantages And


Disadvantages
Variable packet delivery time does not matter for e-mail and text
files
Speed unpredictability however reduces effectiveness of audio
and video traffic
Major advantage diverse machines and LANs may be
interconnected if they use common protocol called TCP/IP

V.Rajaraman

SAD/M11/LU1/V1/2004

Intranet And Extranet


A network of computers within an organization using TCP/IP
protocol an use all internet facilities such as e-mail, file transfer,
remote login etc called an intranet or corporate intranet
Two corporate intranets may be interconnected using a leased line
from PSTN such a network is called an extranet
Extranet between cooperating organizations can provide internet
services such as e-mail,file transfer among them

V.Rajaraman

SAD/M11/LU1/V1/2004

10

World Wide Web Services


World Wide Web (WWW) is a world wide multimedia information
service available on the internet
www contains web pages created using a language called HTML
(Hyper Text Markup Language)
HTML has features to embed links within web pages to point to other
pages we can thus navigate through links and search for required
information

V.Rajaraman

SAD/M11/LU1/V1/2004

11

World Wide Web


Web page located using a scheme known as Uniform
Resource Locator(URL)
Example of URL
http://www.freesoft.org/connected/index.html

Protocol used

Domain name
Of server
Having web page

Folder with
Required
information

Required document formatted


Using hypertext markup
language

Web browsers is a program on ones PC used to search for


required information

V.Rajaraman

SAD/M11/LU1/V1/2004

12

Search Engines
Browsers use search engines - that is programs which will navigate
web pages using links
Navigation based on search terms given by user
All organizations now maintain web pages t o establish their "web
presence"
Web presence important to publicize organization for primarily
advertising their services

V.Rajaraman

SAD/M11/LU1/V1/2004

13

Documents and the


World Wide Web

V.Rajaraman

SAD/M11/LU2/V1/2004

What Is A Document?
A document has three parts
1. Content: The string of characters normally coded in ASCII or
UNICODE
- A document now-a-days also includes, besides text,
pictures, audio and video-all bit strings when digitized.
- We will however be primarily concerned with textual
data in this module.

V.Rajaraman

SAD/M11/LU2/V1/2004

What Is A Document? (contd.)

2. Presentation: How the data looks like to a human userpresentation may be on a video screen or on paper.
3. Structure: Helps interpretation of data by a computer
Information such as type of data (Numeric,
Alphanumeric) and its nature, for example an invoice,
a purchase order, a recipe etc.

V.Rajaraman

SAD/M11/LU2/V1/2004

How Are Documents Processed By


Computers

Text processors add special annotations primarily to help format


the resulting print outs
Examples are: Paragraphing, Font selection, Placing titles,
pagination,Tabulation etc.
Examples: WORD, TEX etc.
These are primarily presentation aids which take raw content and
transform them to neat looking documents when displayed on
VDU screen or printed on paper.
They have no idea of the type of document and what they mean.

V.Rajaraman

SAD/M11/LU2/V1/2004

Text Processing By Computers

Word processors primarily used for applications such as


-Preparation of manuals
-Preparation of catalogues
-Routine office correspondence
-Desk top publishing

Report Generators (Discussed in Module10) are special variety


which use a special language to generate and format reports.

These are primarily for linear texts and not meant for linked text
known as hypertext

V.Rajaraman

SAD/M11/LU2/V1/2004

Documents On World Wide Web

In the world wide web documents located in many computers are


linked

Each document called a web page. Each web page has a unique
path to retrieve it.

Documents to be used in web pages need special annotations or


markups mainly for formatting and for linking them to other
documents in the web

V.Rajaraman

SAD/M11/LU2/V1/2004

Documents On World Wide Web

These annotations are called MARKUPS.

As documents on the world wide web are linked to many


documents they are called hypertext.

The markup used to link documents called Hyperlink.

V.Rajaraman

SAD/M11/LU2/V1/2004

Documents On World Wide Web


Web pages are retrieved from the host computers where
they are located by a program called web browser
running on a client.
Clients use a communication protocol called Hyper Text
Transfer Protocol (HTTP) to retrieve web pages
HTTP recognizes a language called Hyper Text Markup
Language (HTML)

V.Rajaraman

SAD/M11/LU2/V1/2004

Hyper Text Markup Language

An HTML Document has the following general layout


<HTML Version =4.0>
{Version optional}
<HEAD>
<!.The headings and their tags are placed here.>
</HEAD>
<BODY>
<!.Elements such as text with formatting
tags,links,tables,images etc go here>
</BODY>
</HTML>
( ! Is symbol used for comments)

V.Rajaraman

SAD/M11/LU2/V1/2004

Example Of An Html Documents


<HTML>
<HEAD>
<TITLE> Description of a book on Information Technology
</TITLE>
</HEAD>
<BODY>
<H1> Introduction o Information technology </H1>
<H2> A first level book in I.T </H2>
<P> Publisher : <I> Prentice Hall of India </I></P>
<P> Year of publication: <B> 2003 </B></P>
</BODY>
</HTML>

V.Rajaraman

SAD/M11/LU2/V1/2004

10

Display Of Html Document


When the document is viewed using a browser it will appear as shown
below

Introduction to Information technology


A first level book in I.T
Publisher : Prentice Hall of India
Year of publication: 2003

V.Rajaraman

SAD/M11/LU2/V1/2004

11

Explanation Of Tags In Html


<HTML> tells it is an HTML document
End of HTML documents is indicated by </HTML>
<HTML version = 4.0 > version optional
<TITLE> used to identify the document in the browsers title bar
and is stored as the bookmark of this document
<H1>,<H2> indicate headings. <H1> to <H6> available H1
highest size bold face and H6 lowest
<P> indicates paragraphing
<I> Italics and <B> bold face font
<Observe all tags in this example here has end tag indicated by
</tag>
Stand alone tags are also there in HTML.
V.Rajaraman

SAD/M11/LU2/V1/2004

12

Linking Documents
HTML can link to documents in other files.For Example to link
an image we use :
<IMG src = mypicture.gif>
IMG indicates image and src the source (Observe the tag IMG
is standalone and does not have end tag </IMG>
HTML has feature to list items with serial number or bullets
HTML can also display tables and forms
HTML is as rich as some word processors.
V.Rajaraman

SAD/M11/LU2/V1/2004

13

Hyperlinking Html Documents


HTML allows a web page to refer to other web pages
When a reference link in the page is clicked the browser switches
to the referenced site.
The specification is
<A href = http:// www.iisc.ernet.in> </A> where A is called
anchor tag.
Linking can also be to other files
Automatic conversion of word documents to HTML is possible
using a tool

V.Rajaraman

SAD/M11/LU2/V1/2004

14

Shortcomings of Html
HTML is the earliest markup language which made it possible to
retrieve documents stored in the world wide web
HTML is primarily to facilitate presentation of contents of a web
page.
HTML does not have any means of specifying what the documents
represents. Is it an invoice? A purchase order, book description etc.
It also has no means of specifying the type of data to allow
manipulation of data by browser.
We thus need a markup language which is richer and is more
descriptive of structure of a document and what it represents
V.Rajaraman

SAD/M11/LU2/V1/2004

15

EXtensible Markup Language


A document has CONTENT, it has a STRUCTURE and it needs to
be PRESENTED for ease of reading
Word processors and HTML emphasize presentation of content and
have no means of specifying structure (or what the data actually
represents)
XML is a new markup language which is capable of specifying
what a document really represents
XML is a proper subset of an international standard known as
STANDARD GENERALISED MARKUP LANGUAGE (SGML).It
is open standard and not proprietary

V.Rajaraman

SAD/M11/LU2/V1/2004

16

Parts Of XML System


XML defines the structure of a document
Unlike HTML it has tags which are user defined.This allows easy
understanding of the nature of the document and assists in its
processing.
Formatting and presentation are not part of XML unlike HTML
which has tags for bold face,italics etc.This is delegated to a
companion language called XSL (Extensible Style Language).
Linking documents to create hypertext is also not integrated in
XML unlike HTML where tag <A> is a general purpose linking tag.
Much more powerful linking is enabled by separating it to a
companion language called XLL (Extensible Link Language).
V.Rajaraman

SAD/M11/LU2/V1/2004

17

Example Of XML Document


A purchase order is represented in XML as below
< purchase_order >
< order_no > B55567 </order_no>
< date>
< year > 2004 </year>
< month > 10 </month>
< day > 9 </day>
</date>
<purchaser>
<name> ABC Traders </name>
<address>
<street> 201 MG Road </street>
<city> Bangalore </city>
<pin_code> 560001 </pin_code>
</address>
</purchaser>
V.Rajaraman

SAD/M11/LU2/V1/2004

18

Example Of XML Document (Contd)

<item>
<item_name> C Programming </item_name>
<item_code> ISBN 81-203-0859-X </item_code>
<quantity> 50 </quantity>
</item>
<supplier>
<name> P-H India </name>
</supplier>
</purchase_order>

V.Rajaraman

SAD/M11/LU2/V1/2004

19

Example Of XML Document


Observe that the tags used have a syntax similar to HTML. The
tags are, however, meaningful to a human reader
The XML definition clearly brings out the structure of an
invoice.
However to interpret such a document and process it by a
computer a companion document called Document Type
Definition (DTD) is needed.
DTD has its own syntax . We give DTD for this XML document
in the next transparency.
V.Rajaraman

SAD/M11/LU2/V1/2004

20

Document Type Definition (DTD)


DTD of XML document of 11.2.15 is given below
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!
<!

V.Rajaraman

ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT
ELEMENT

DTD Statements
purchase order (entry +) >
order_no (#PC DATA) >
date (year, month ,day)
year (#PC DATA)>
month(#PC DATA)>
day (#PC DATA)>
purchaser (name,address)>
name (#PC DATA)>
address (street,city,pin-code)>
street (#PC DATA)>
city (#PC DATA)>
pin-code (#PC DATA)>
item (item_name,item_code,quantity)>
item_name (#PC DATA)>
item_code (#PC DATA)>
quantity (#PC DATA)>
supplier (name)>
name(#PC DATA)>

SAD/M11/LU2/V1/2004

21

Explanation Of Document Type Definition


Each statement in DTD declares the elements of XML

program
<! ELEMENT purchase order (entry +) > states that purchase
order is the top level element with one or more entry following
it
2 statements are introduced at the start of XML definition
which specifies the version of XML and the file name of DTD
specification

V.Rajaraman

SAD/M11/LU2/V1/2004

22

Explanation Of Document Type


Definition (contd.)
Assuming DTD is in a file purchase_order.dtd
the declarations are
<? XML Version =1.0>
<! DOCTYPE purchase_order SYSTEM
purchase order.dtd>
The tags used in XML definition are then
specified.

V.Rajaraman

SAD/M11/LU2/V1/2004

23

Explanation Of Document Type


Definition
<! ELEMENT order_no (#PC DATA) specifies that the tag
order_no is a string of characters.
<! ELEMENT date (year,month,day) specifies that the tag date
is a higher level tag which consists of three tags- year, month
and day.
The description of each of the next level tags follow, for
example:
<! ELEMENT year (#PC DATA) declares year as a string of
characters.
The rest of DTD is self explanatory
V.Rajaraman

SAD/M11/LU2/V1/2004

24

Some Application Of XML


XMLs main use is in creating documents for the World Wide
Web which can be retrieved by browsers at client computers.
User defined tags give several advantages including use in
- Push Technology In this application time varying data
specified by users e.g. Hourly stock prices of specified shares
are automatically sent to the clients browser
- Online banking A standard XML format known as
financial exchange initiative is used to obtain information such
as bank statements.
V.Rajaraman

SAD/M11/LU2/V1/2004

25

Some Application Of XML


Software and database updates
XML adaptable to many natural languages such as Kannada
as it uses Unicode standard.
Use in Scientific Publications Markup languages based on
XML have been developed for chemistry CML (Chemistry
Markup Language) and MML (Mathematical Markup
Language)

V.Rajaraman

SAD/M11/LU2/V1/2004

26

Controls in Information
systems

V.Rajaraman

SAD/M12/LU1/V1/2004

Control Techniques
Organizational Measures
Well defined responsibility for input preparation, delivery output
use, operation and maintenance
- Changes in program and data (if any) should be documented
- Performance of task and recording must be by different
persons to prevent frauds

V.Rajaraman

SAD/M12/LU1/V1/2004

Need Of Controls
Information systems handle massive amounts of data
accidents such as not including some data can cause
serious damage
Incorrect data entry can lead to high monetary losses
Credibility in the information system may be lost if errors
are found in operational systems

V.Rajaraman

SAD/M12/LU1/V1/2004

Objectives Of Controls
To make sure data entering the computer are correct
Check clerical handling of data before it is input to a
computer
Provide means of detecting and tracing errors which occur
due to bad data or bad program
Ensure legal requirements are met
To guard against frauds
V.Rajaraman

SAD/M12/LU1/V1/2004

Control Techniques
Organizational Measures
Well defined responsibility for input preparation, delivery
output use, operation and maintenance
- Changes in program and data (if any) should be
documented
- Performance of task and recording must be by
different persons to prevent frauds
V.Rajaraman

SAD/M12/LU1/V1/2004

Control Techniques
Input Preparation Control
- Sequence numbering
- Batch controls
- Data entry and verification
- Record totals
- Self checking digits, (Covered in Module 7)

V.Rajaraman

SAD/M12/LU1/V1/2004

Processing Controls
Proof Figures An additional data element introduced to
detect data entry/processing error
Example:item code,qty supplied,cost/unit,proof cost(proof
cost is additional data introduced.
Proof cost=(H-cost/unit)where H is a constant > maxcost
Check if H qty = qty *proof cost + qty * cost/unit
If two sides are not equal, there is an error.
V.Rajaraman

SAD/M12/LU1/V1/2004

Processing Controls

Two Way Check Calculate same qty in two


different ways and they should be equal
Example : gross pay - deductions = net pay
Relationship Check We know relation between
variable.
Example : Rebate total = Sales * discount percent
V.Rajaraman

SAD/M12/LU1/V1/2004

Processing Controls
Checkpoint Restart Periodical storing of process
state. If there is a failure roll back to saved state and
restart computation.
Check Points also useful to check intermediate
results in long and complex calculations. Region
where an error occurred can thus be isolated

V.Rajaraman

SAD/M12/LU1/V1/2004

Auditing Of Information Systems


Objectives
Ensure computer based financial and other information
reliable
Ensure all records included while processing
Ensure protection from frauds

V.Rajaraman

SAD/M12/LU2/V1/2004

Audit Methods
Auditing Around Computer
Take sample inputs and manually apply processing
rules and compare outputs with computer outputs
Auditing Through The Computer
-Establish audit trail which allows examining selected
intermediate results
-Control totals provide intermediate checks
V.Rajaraman

SAD/M12/LU2/V1/2004

Auditing Through The Computer


Facility to trace transaction value and print
intermediate results
Selective printing of records meeting criteria specified
by the auditor
For example :Inactive accounts,overactive accounts,
accounts with high balance

V.Rajaraman

SAD/M12/LU2/V1/2004

Auditing Through The Computer


(contd)
Comparing

credit and debit balances

Ensure logs are kept of who did what in critical


data entry and processing to fix responsibility.
Called an Audit trail.
Auditors own check inputs and expected outputs.

V.Rajaraman

SAD/M12/LU2/V1/2004

Auditing With The Computer


Use special audit packages to check system
Audit package allows
Extracting data based on the specified criterion for
inspection (e.g. Students with wide disparity in marks in
two subjects)

V.Rajaraman

SAD/M12/LU2/V1/2004

Auditing With The Computer


(contd)
Totaling specified subset of data for check
Procedure to check sale discounts
Process with independent data file created by auditor and
verify to see if system is as per specification

V.Rajaraman

SAD/M12/LU2/V1/2004

System Testing
Objectives
To ensure the entire system will perform as per specification
Ensure system meets users requirements
Verify if controls function as intended
To make sure incorrect inputs,incorrect processing and
incorrect outputs (if any) will be detected during operation
Should include both computer based and manual processes
Remember that system testing is done before a system is released
as ready for operation
V.Rajaraman

SAD/M12/LU3/V1/2004

Classification Of System Tests


Program Tests
- Program tests with test data
- Normally individual modules tested then integration test done
- Test boundary conditions
- Test using loop counts

V.Rajaraman

SAD/M12/LU3/V1/2004

System Testing (Contd)


System Tests
- Results from a program fed as input to a succeeding
program a string of programs run one after another
- All programs in a complete system are tested
together as a
whole.Tested using unreasonable data and non key data
besides normal test data for whole system
V.Rajaraman

SAD/M12/LU3/V1/2004

System Testing (Contd)

Pilot Tests
- Use data from manual system to test system when it is
first implemented. If it is modification of earlier
computer based system use data and output from that system

V.Rajaraman

SAD/M12/LU3/V1/2004

System Testing (Contd)


Parallel Runs
- Run both manual and computer based systems with
same live data and see if both give identical results
- If it is re-engineered (i.e.,Modified) system run both
old and new systems and compare results

V.Rajaraman

SAD/M12/LU3/V1/2004

Security Of Information Systems


Security means protection of data from accidental or intentional
modification, destruction or disclosure to unauthorised persons
Potential Threats To Security
Natural disasters such as fire, floods, earthquakes
Accidents such as disk crashes, file erasure by
inexperienced operators
Theft/erasure of data by disgruntled employees
V.Rajaraman

SAD/M12/LU4/V1/2004

Security Of Information Systems


Potential Threats To Security (Contd)
Frauds by changing programs, data by employees
Industrial espionage
Viruses/Worms
Hackers who break into systems connected to the internet
Denial of service attacks by flooding with mail

V.Rajaraman

SAD/M12/LU4/V1/2004

How To Protect Data/programs


Regular back up of data bases every day/or week
depending on the time criticality and size
Incremental back up at shorter intervals
Backup copies kept in safe remote location
-particularly necessary for disaster recovery

V.Rajaraman

SAD/M12/LU4/V1/2004

How To Protect Data/programs


Duplicate systems run and all transactions mirrored if it
is a very critical system and cannot tolerate any
disruption before storing in disk.
Physical locks
Password system
Biometric authentication (Eg: Finger print)

V.Rajaraman

SAD/M12/LU4/V1/2004

How To Protect Data/programs


Encrypting sensitive data/programs
Identification of all persons who read or modify data and
logging it in a file
Training employees on data care/handling and security
Antivirus software
Firewall protection when connected to internet

V.Rajaraman

SAD/M12/LU4/V1/2004

Data Security, Privacy And Integrity


Data security is concerned with protecting data from
erasure,theft,unauthorized access and unauthorized modifications
Data privacy is concerned with protecting data regarding
individuals from being accessed and used without the
permission/knowledge of concerned individuals
Data integrity is concerned with the quality and
raw as well as processed data

V.Rajaraman

SAD/M12/LU4/V1/2004

reliability of

Data Security Privacy And Integrity


Security does not imply privacy or integrity
Privacy controls need specific law against disclosure of personal
data
Ultimately data and system integrity most important

V.Rajaraman

SAD/M12/LU4/V1/2004

System Analysis and Design/ Electronic Commerce

Learning Objectives

Learning Goals
The basics of Electronic Commerce abbreviated as e-commerce
The advantages and disadvantages of e-commerce
Architecture of e-commerce systems
Electronic Data Interchange in e-commerce
The need for security in e-commerce transactions and how to ensure it
How Electronic payment schemes work in e-commerce.

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design / Electronic Commerce

Motivation

Motivation
With the emergence of internet and the world wide web new methods of carrying
out business transactions using the world wide web began to be explored.
Electronic Commerce emerged as a very important application of the world wide
web.
Today it is difficult to find an isolated computer. Computers in an organization
are interconnected to form intranets and intranets of the cooperating organizations
are interconnected to form extranet.
It is cheaper and faster to carry out business transactions within an organization
and among organizations electronically using the network connection.
Thus it is important to understand how business transactions are carried out
electronically reliably and securely
When designing information systems it is essential to understand the emerging
web based transactions
A number of organizations are exploring how to carry out all day-to-day
operations electronically using the intranet in a so-called paperless system
It is thus important for a student to understand how to design such systems

V. Rajaraman/IISc. Bangalore

//V1/July 04/1

Electronic Commerce
13.1 What is E-Commerce?

V.Rajaraman

M13/LU1/V1/2004

What Is Electronic Commerce


Definition
Sharing Business Information, Maintaining Business relationships
and conducting business transactions using computers connected to a
Telecommunication Network is called E-Commerce
Classification
Classified As : Business To Business (B2B)
Business To Customer (B2C)
Customer To Customer (C2C)
V.Rajaraman

M13/LU1/V1/2004

E-commerce Applications-example
Retail Stores - Books, Music
Auction Sites
Cooperating Businesses Placing orders,paying invoices etc.
Electronic Banking
Booking Tickets - Trains, Cinema, Airlines
Electronic Publishing
Filling Tax Returns With Government Dept.

V.Rajaraman

M13/LU1/V1/2004

Business To Business E-commerce

LAN of buisness2

Public switched telephone network

LAN of buisness1

PSTN or
LEASED LINE

Purchase store accounts


Local computers

Vendor
Local computers

V.Rajaraman

M13/LU1/V1/2004

Business To Business E-commerce


(contd.)
Local LAN of business would normally follow TCP/IP protocol
of internet and is called corporate intranet
Purchase order entered by business1 in its PC and electronically
dispatched to vendor (by e-mail)
Vendor acknowledges electronically the order
Vendor dispatches goods(physically) and delivery note
electronically to business1

V.Rajaraman

M13/LU1/V1/2004

B2B E-commerce (Contd)


Business 1 can compare delivery note against order -both are in
computer readable form
Discrepancy note(if any) can be immediately sent to the vendor
Business 1 can carry out all local transactions using its LAN
Local transactions are inventory update by stores - advice to
accounts to pay for goods taken into stock
Accounts can make payment electronically to Vendor

V.Rajaraman

M13/LU1/V1/2004

Implementing B2B E-commercerequirements


1. Agreed on formats for Purchase order, delivery note, payment
order etc. Standard known as EDI (Electronic Data Interchange
Standard) is used to send documents electronically
2.Each Business must have corporate intranet and the two nets
are connected by PSTN or leased line
3. Transactions must be secure - particularly if PSTN is used
4.Secure electronic payment methods are required
V.Rajaraman

M13/LU1/V1/2004

Steps In B2C E-commerce


1. Customer uses a browser and locates vendor or he has
vendor's web page address
2. Sees Vendor's web page listing of items available,
prices etc
3. Customer selects item and places order. Order may
include credit card details or may be cash on delivery
4. Vendor checks with credit card company customers
credit

V.Rajaraman

M13/LU1/V1/2004

Steps In B2C E-commerce


5. Credit card company OKs transaction
6. Vendor acknowledges Customers order and gives
details of delivery date, mode of transport, cost etc
7. Vendor orders with distributor who ships item to
vendor's warehouse from where item supplied to
customer
8. Customer's credit card company debits his account,
credits vendor's account and sends bill to customer for
payment

V.Rajaraman

M13/LU1/V1/2004

Customer to Customer E-Commerce


Customer2

Internet

Customer1

Wants to buy Item 1

Wants to sell Item 1


Brokers website
Advertises - "for sale"

Brings together buyer and


seller
Transports items
Collects fee from both Seller
&Buyer
V.Rajaraman

M13/LU1/V1/2004

10

Advantages Of E-commerce
1. Buying/selling a variety of goods and services
from one's home or business
2. Anywhere, anytime transaction
3. Can look for lowest cost for specific goods or
service
4. Businesses can reach out to worldwide clients can establish business partnerships

V.Rajaraman

M13/LU1/V1/2004

11

Advantages Of E-commerce
5. Order processing cost reduced
6. Electronic funds transfer faster
7. Supply chain management is simpler, faster, and cheaper
using e-commerce
- Can order from several vendors and monitor supplies.
- Production schedule and inventory of an organization can
be inspected by cooperating supplier who can in-turn
schedule their work.

V.Rajaraman

M13/LU1/V1/2004

12

Disadvantages Of E-commerce
1. Electronic data interchange using EDI is expensive for
small businesses
2. Security of internet is not very good - viruses, hacker
attacks can paralise e-commerce
3. Privacy of e-transactions is not guaranteed
4. E-commerce de-personalises shopping.People go
shopping to meet others - window shop and bargain

V.Rajaraman

M13/LU1/V1/2004

13

E-commerce System Architectures


LOGICAL LAYERS

SERVICES IN LAYER

Application layer

B2B,B2C,C2C

Middleman services

Hosting services,value added nets


payment services,Certificates

Secure messaging

Encryption,EDI,Firewalls

World wide web services


Logical network

HTTP,HTML,XML,OLE
Software agents
Intranet,internet,extranet

Physical network

PSTN,LAN,Bridges,routers

Layered architecture
V.Rajaraman

M13/LU1/V1/2004

14

Electronic Data Interchange


Computer readable forms for business documents such
as invoices, purchase orders, delivery notes needed in
B2B e-commerce so that e-documents can be
exchanged.
Essential to eliminate manual data entry which is error
prone
Essential to agree on common formats for commonly
used forms.
V.Rajaraman

M13/LU2/V1/2004

Electronic Data Interchange (contd.)


Electronic data interchange (EDI) standard gives
specifications for commonly used standard
business forms
Currently two standards are available for EDI
forms

It is possible to adapt these standards for


documents which use XML for specification.

V.Rajaraman

M13/LU2/V1/2004

EDI Standards
ANSI X.12 standard proposed by American National
Standards Institute
EDIFACT (Electronic Data Interchange For Administration
Commerce and Trade) standardized by United Nations
Economic Commission for Europe for international trade
EDIFACT used in India for government transactions customs, central excise etc.

V.Rajaraman

M13/LU2/V1/2004

EDI Transactions in B2B


E-commerce
Cooperating businesses agree on EDI standard
Programs needed to translate data received in EDI format
to a form needed by the application program
Method of sending/receiving data between businesses to
be agreed on - is it PSTN, Extranet or VAN (value added
network) service ?
Important to ensure reliable, guaranteed and secure
receipt of electronic documents by intended receiver
V.Rajaraman

M13/LU2/V1/2004

EDI Using Value Added Network


Service
VAN provides post box for all subscribers
Guarantees delivery
Open 24 hours, 7 days a week
Provides security, acknowledgement, audit trails for transactions,
non repudiation by users
Some VANS provide conversion of EDI forms to application
format
Disadvantage high cost. Used by large businesses - may not be
cost-effective for smaller businesses
V.Rajaraman

M13/LU2/V1/2004

EDI Using Internet


Cheaper method for use by small business is to use XML for
EDI and e-mail,instead of VAN
Establish EDI form standard - XML appropriate Document
Type Definition(DTD) publicised using organizations web
page-cooperating business can use a DTD to interpret XML
documents.
Use MIME (multipurpose internet mail extension) to attach
EDI forms to e-mail messages
V.Rajaraman

M13/LU2/V1/2004

EDI Using Internet


Can use Simple Mail Transfer Protocol(SMTP) of internet
If secure transmission needed use S/MIME (Security
enhanced MIME) which uses encryption and digital signature
(We will describe encryption and digital signature later in
this module)
If very long document or many documents are to be sent
together File Transfer Protocol (FTP) may be more
appropriate.
V.Rajaraman

M13/LU2/V1/2004

EDI Standard
Defines several hundred transaction sets corresponding
to each type of business document such as invoice,
purchase order etc.
Defines data segments - corresponding to groups of data
elements such as purchase order line
Defines data elements - which are individual fields such
as price, quantity etc

V.Rajaraman

M13/LU2/V1/2004

Security In E-commerce
Transactions between organizations take place in
many e-commerce applications using the Internet
Internet is widely accessible and insecure as
eavesdropping is possible
Need to protect company confidential information
from snoopers

V.Rajaraman

M13/LU3/V1/2004

Security In E-commerce
We need to protect a company's network from
unauthorised entry - both hardware and software
techniques used
When an organization receives a message it has to be
sure from whom it came and whether the message is
authentic and not changed by an unauthorised person
We thus need a digital signature which can be used in a
court of law
V.Rajaraman

M13/LU3/V1/2004

Network Security Using


Firewall
Firewall is a security device deployed at the
boundary of an organization' s network to
protect it from unauthorised external access
It links an organization's intranet to the
internet and restricts the type of traffic that it
will pass, thus providing security

V.Rajaraman

M13/LU3/V1/2004

Network Security Using


Firewall
Simple firewalls may be implemented in some routers, called packet
filtering firewalls, they pass only some packets based on simple
specified criteria such as
-Type of access (such as email, ftp, telnet as determined by
TCP port number)
-Direction of traffic
-Source or destination IP address
-Time of day
V.Rajaraman

M13/LU3/V1/2004

Proxy Application Gateway


Primarily for allowing members of an
organization on corporate intranet to access
internet facility ensuring organizational
discipline and security
Proxy application program running on a firewall
machine is the one which acts on behalf of all
members of an organization wanting to use the
internet
V.Rajaraman

M13/LU3/V1/2004

Proxy Application Gateway


This program monitors all requests - allows access to
only designated addresses outside, limits use of
certain browsers and disallows use of some protocols
with known security holes
Proxy application program may also be allowed to
run on some user's machine who have authorization
for internet use

V.Rajaraman

M13/LU3/V1/2004

Hardened Firewalls With Proxy


Application Gateway
Any one from inside or outside an organization give their user id,
password, service required to the firewall machine which acts as
one's proxy (ie.does ones work on his behalf)
Proxy firewall is now server to the requestor's desktop PC and
also a client to some other requested service acting on requestor's
behalf
Firewall needs proxy agent for each service requested such as
FTP, HTTP, TELNET etc
V.Rajaraman

M13/LU3/V1/2004

Hardened Firewalls With Proxy


Application Gateway
Now proxy firewall is the initiator of all sessions and thus
knows every activity - thus ensuring security
Firewall with a proxy function replaces the source address of
transaction requestor with its own IP address
-this ensures that others on internet see only firewall's IP
address - all other IP addresses of organization are hidden

V.Rajaraman

M13/LU3/V1/2004

Data Encryption With Secret


Keys
Data sent via a public network may be accessed and
used by unauthorized persons
Thus necessary to scramble it so that even if one
accesses it, it cannot be understood
Similarly data stored in data bases accessible via
internet should be scrambled
Method of scrambling known as encryption
Method of unscrambling known as decryption

V.Rajaraman

M13/LU3/V1/2004

Plain Text And Ciphertext


Plain text is data in its natural form
Encryption is taking data in any form(Text,
Audio,Video etc.) and transforming it to another form
which cannot be understood
Transformed data is known as cryptogram or cipher
text

V.Rajaraman

M13/LU3/V1/2004

10

Example Text Encryption


Start plaintext

This Is A Message X

Block plaintext (5character blocks)

Thisi Sames SAGEX


41

Transpose characters with


permutation (4 1 2 5 3)

Sthii Esasm Esaxg

Substitute character by
the one 4 letters away

Wxlmm Iwewq Ixebk

(eg AE,ZD)

Cipher Text

This is an example of two transformations - permutation followed by


substitution
The keys are permutation function and substitution function
V.Rajaraman

M13/LU3/V1/2004

11

Symmetric Encryption.
PLAINTEXT

(m1,m2mn )

CIPHER TEXT (c1 c2, c3.cn )


Where ci = k( Ti (mi) ) In which Ti is permutation of ith character
and k is substitution.
Decryption by applying same transformations in reverse on cipher
text.
This method called symmetric key encryption as encryption and
decryption performed using same key.
Normally the encryption/decryption algorithm is publicised. Only
key is secret.
V.Rajaraman

M13/LU3/V1/2004

12

Symmetric Encryption
Problem is to ensure secrecy of key when it is sent to
partner.
If the key is to be sent to many partners need for separate
key for each partner.Directory of who was sent which key is
to be kept and used for each transaction.Directory should be
secure.
If large number of partners are there key distribution very
difficult.
Advantage of symmetric key is easy and fast to transform
plain text to cipher text.

V.Rajaraman

M13/LU3/V1/2004

13

Digital Encryption Standard


DES - Proposed by IBM in 1975
Standardised by US Govt in 1977
Reasonably secure
It is a combination of permutation and substitution on
blocks of 64 bits. A message is broken up into 64 bit
blocks and each block is separately encrypted.

V.Rajaraman

M13/LU3/V1/2004

14

Digital Encryption Standard


#General idea used in DES
M = PLAINTEXT 01101100

11011000

11011010

K = KEY

10101111

00101100

01011011

E= M+K

11000011

11110100

10000001 encryption

M= E + K

01101100

11011000

11011010 decryption

See simplicity of Transformation using Exclusive OR

V.Rajaraman

M13/LU3/V1/2004

15

Digital Encryption Standard


Algorithm
Before applying DES the text is split up into the
64 bit blocks.
DES applied on each 64 bit block.

V.Rajaraman

M13/LU3/V1/2004

16

Digital Encryption Standard


Algorithm

Encryption method

Step 1: Apply an initial permutation on a block.Result is


B=IP(P)
where P is the 64 bit block IP Initial Permutation
function and
B the result.
Step 2: Split B into 32 bit blocks
Li = leftmost 32 bits
Ri = rightmost 32 bits.
Step 3: Pick a 56 bit key. Permute it
V.Rajaraman

M13/LU3/V1/2004

17

Digital Encryption Standard


Algorithm
Step 4: Left circular shift it by 1 bit giving K1.
Step 5: Perform a complex sequence of operations and
obtain
X1 = F(R1,K1) (The complex set of operations
include table look up and dropping bits).

V.Rajaraman

M13/LU3/V1/2004

18

Digital Encryption Standard


Algorithm
Step 6: Find R2 = L1 + X1
Step 7: Set L2 = R1
Repeat steps 2 to 7 16 times to get B16 = L16,R16
Step 8: Apply inverse of initial permutation on B16
The result is the encrypted block

V.Rajaraman

M13/LU3/V1/2004

19

Digital Encryption Standard


Algorithm
In summary the DES encryption applies the following
transformation 16 times.The ith round transformation are
Li+1= Ri
Ri+1= Li + F(Ri,Ki)
Each round has a different key Ki
For Decryption the process of encryption is reversed.The encrypted
block is permuted using IP-1.On this transformations are applied
starting with K16 and going to K1 last.The keys and F are same as
those used in encryption process.
V.Rajaraman

M13/LU3/V1/2004

20

Digital Encryption Standard


Algorithm
The encryption process uses simple binary operations.
They can thus be realised in hardware as an integrated
circuit chip.
DES chips are inexpensive. Key externally fed.
The complex encryption algorithm is explained using two
block diagrams in the next two transparencies.

V.Rajaraman

M13/LU3/V1/2004

21

IP

R
O
U
N
D
1

L1

R
O
U
N
D
2

Initial Permutation
R1

Permute
K1

F
+
L1
L2

F(R1,K1)
Permute
K2

P2

+
L2 + F(R2,K2)
.
.
.
.
L16

Left circular
shift

P1

R2

L3

56 bit key

DES Encryption Block


Diagram

64 bit block of plain text

R3
K16

.
.
.
.
P16

.
.
.
.
.

Left circular
shift

Left circular
shift

+
R16

IP-1

Inverse of Initial permutation


(F is a complex function involving two table look ups and dropping bits of K1 to get 3
bits for bitwise Exclusive OR of L1 and F(K1,R1) )

64 bit Cipher text

V.Rajaraman

M13/LU3/V1/2004

22

Details of One Round of DES


Encryption
64 bit Plain Text

56-bit key

Permute
32 bits 32 bits
L1
R1

Permute
28 bits 28 bits
KL KB

Left Shifts

48 bits

Permute
and
Contract

L1

Round1

F(R1,K1)

K1

+
L2

R2
.
.
.
.

V.Rajaraman

KL

KB

For next key

Repeat 15 more times

M13/LU3/V1/2004

23

DES Chip

64
Input block
Key

DES
CHIP

64

Encrypted
Block

56

Observe that from initial key others are derived by circular


shifts
Decryption chip inputs encrypted block and key and the output
is decrypted block

V.Rajaraman

M13/LU3/V1/2004

24

DES - Discussion
Cryptanalysis is technique for breaking a code,
given samples of encrypted messages.
If plain text also known it is somewhat easier.
DES code can be broken if key is found.
The easiest method of breaking a code is by brute
force of trying out all possible keys to decrypt
message.

V.Rajaraman

M13/LU3/V1/2004

25

DES - Discussion
With increase in speed of computers it has now been shown
that DES key can be found in less than 12 hrs with a fast
computer (1 Million decryption per microsecond)
Thus DES is practically useless now (original DES was
invented in mid 70s)
New more secure symmetric encryption algorithm is needed
An extension of DES called triple DES is shown to be more
secure.
V.Rajaraman

M13/LU3/V1/2004

26

Triple DES
Triple DES uses three different keys and three executions of
DES algorithm.
The algorithm is
Cipher text = Ek3 [Dk2 [Ek1 [Plain Text]]]
where Ek[X] = DES Encryption of X using key K
and Dk[X] = DES Decryption of X using key K
Remember that in DES Decryption of encrypted plain text with a
different key is almost same as another encryption.
This is true as encryption and decryption use the same algorithm
V.Rajaraman

M13/LU3/V1/2004

27

Triple DES
To decrypt cipher text we reverse the operations.
Plain text = Dk1[Ek2 [Dk3[Cipher Text]]]
Block Diagrams Of Triple Des
Encryption
K1

Plain text
(64 bit block)

K2

K3

Cipher text
(64bit block)

Decryption
K3

Cipher text

V.Rajaraman

K2

M13/LU3/V1/2004

K1

Plain text

28

Triple DES(Contd)
Using DES thrice is equivalent to having a DES key length
of 168 bits.
Brute force method to break triple DES with 106 decrypts
per micro second will take 5.9 X 10 30 years!
Even at 1012 fold increase in computer speed will make
triple DES secure against brute force attacks to break code

V.Rajaraman

M13/LU3/V1/2004

29

Triple DES(Contd)
The only reason D is used as middle step in triple DES is to allow
data encrypted using single DES hardware.In this case K3=K2=K1
(Single key used) (See block diagram)
Triple DES will be quite popular for a foreseeable future as it is very
secure, can be realised by simple hardware.
Triple DES has two disadvantages
1. It is slow to implement in software
2. It uses 64 bit blocks.
Thus new standards were explored.
V.Rajaraman

M13/LU3/V1/2004

30

Requirements of Symmetric Key


Cryptography Algorithm(NIST)
Advanced Encryption System(AES)
National Institute for Standards Technology put out a call for
proposals for new crypto system with following requirements.
Must provide a high level of security (i.e. difficult to decrypt
in finite time)
Must be completely specified and easily understood
Security must reside in key Not in algorithm

V.Rajaraman

M13/LU3/V1/2004

31

Requirements of Symmetric Key


Cryptography Algorithm(NIST)
Advanced Encryption System(AES)
Must be available for all users
Adaptable for use in diverse applications e.g.credit cards
Implementable economically in electronic devices
Must be efficient to use as both software and hardware
Must allow one to validate it.

V.Rajaraman

M13/LU3/V1/2004

32

Requirements of Symmetric Key


Cryptography Algorithm(NIST)
Advanced Encryption System(AES)
Must be exportable
No trap door
Must use 128 blocks and key lengths of 128,192 or 256 bits
depending on the level of security desired.
In October 2000 it announced the selection of an algorithm
called Rijin dael(Pronounce RAIN DOLL) as new Advance
Encryption Standard (AES)
Details may be found in www.nist.gov/aes
V.Rajaraman

M13/LU3/V1/2004

33

Public Key Encryption


In Private Key Encryption transmission of key without
compromising not easy
It is necessary to assign different private key to each business
partner. When this is done a directory of keys should be kept
which should be secret.This is difficult.
Only secure way is to change the private key every time a
message is sent

V.Rajaraman

M13/LU3/V1/2004

34

Public Key Encryption


Public Key Encryption eliminates the key
distribution problem
There is a pair of keys for each organization - A
Private Key and its Public Key
If A wants to send message to B, A encrypts the
message with B's Public Key When message is
received by B he decrypts it with his Private Key

V.Rajaraman

M13/LU3/V1/2004

35

Public Key Encryption

Plain
text

ENCRYPT

DECRYPT
Cipher
text

Bs Public
Key

Bs Private
Key

RECEIVER B

SENDER A

V.Rajaraman

Plain
text

M13/LU3/V1/2004

36

RSA Code Details.R Wants To


Find His Public And Private Keys
1. Pick large primes p and q. Let n =p * q
2 Find = (p-l)*(q-l)
3 Find e relatively prime to , i.e. gcd(,e)=1; 1<e<.
{e,n} is R's Public Key

V.Rajaraman

M13/LU3/V1/2004

37

RSA Code Details.R Wants To


Find His Public And Private Keys
4 Find a number d which satisfies relation
(d * e) mod () =1
{d,n} is Rs Private key
5. Let plain text = t. Encrypt t using Rs public key.
Encryption = te (mod n) = c (cipher text)
6. Decryption

cd (mod n) =t

(Both n and e should be known to encrypt.Similarly both n and d


should be known to decrypt)

V.Rajaraman

M13/LU3/V1/2004

38

Example Of RSA Use


This example is a toy example to illustrate the method.In practice the
primes p and q will be very large each at least 300 digits long to
ensure security.
RSA Algorithm
1. Pick as prime numbers p=3,q=11
n = p * q=33
Note : The message to be encrypted should be smaller than 33.If
we do letter by letter encryption of English alphabets (A to Z 1
to 26) this is OK
2. = (p-1) x (q-1) = 2 x 10 = 20
V.Rajaraman

M13/LU3/V1/2004

39

Example Of RSA Use


RSA Algorithm (Contd)
3. Pick a number relatively prime to 20.
We pick 7. The Public key of R = {7,33}
4. To pick private key of R find d from relation (d x e)mod() = 1
(d x 7) mod (20) =1
This gives d =3
Therefore, the private key of R = {3,33}

V.Rajaraman

M13/LU3/V1/2004

40

Applying RSA Algorithm


1. Let the message be CODE
If we use code C=3, O=14,D=4,E=5
The message is 3,14,4,5
2. We will encrypt one letter at a time
Thus cipher of plain text 3 is
3e mod (n) =37 mod(33)
37 mod (33) =2187 mod (33)=9
(14)7 mod (33) = 105413504mod(33)=20
(4)7 mod (33) =16384 mod (33) =16
(5)7 mod (33) =78125 mod(33) = 14
V.Rajaraman

M13/LU3/V1/2004

41

Applying RSA Algorithm


3. Thus cipher text = 9,20,16,14
4. Decryption : cd mod (n)
d=3,n=33
93 mod (33) = 729 mod(33) = 3
203 mod(33) = 8000 mod(33)=14
163 mod(33) = 4096 mod(33) =4
143 mod(33) = 2744 mod(33) =5
We see that we get the original text 3,14,4,5

V.Rajaraman

M13/LU3/V1/2004

42

Discussion on RSA
The security RSA encryption is dependent on the fact that
factorising a large prime number to its factors is very difficult.
RSA algorithm is symmetric.In other words if a plain text is encoded
by the private key of S, the sender, it can be decrypted using the
public key of R, the receiver (We will find later that this symmetry
property is used in creating digital signature)
Example using Ss keys
Ss Private key = {3,33}
Ss Public key = {7,33}
V.Rajaraman

M13/LU3/V1/2004

43

Discussion on RSA
If we encrypt a plain text using Ss private key and send it to R,R
must be able to decrypt it with Ss public key.
Assume Plain text is encrypted with Ss private key and get cipher
text = (14)3 mod (33)=5
Decrypting with Ss Public key we get
(5)7 mod (33)
=78125 mod(33)
={(2367 x 33) + 14} mod (33)
=14
V.Rajaraman

M13/LU3/V1/2004

44

Discussion RSA Vs DES


RSA Public key has two keys a private secret key and a
public open key.
RSA implemented as a program (software) It is
computationally complex to encode plain text and decode
cipher text using RSA
DES Same key for encryption and decryption It is a single
key system - Also called symmetric key system

V.Rajaraman

M13/LU3/V1/2004

45

Discussion RSA Vs DES


DES computationally simple-implemented in hardware thus very fast
Each communication between two businesses can use a
different key provided key is securely exchanged
If key can be sent separately encrypted using RSA, then a
recipient can use this to decrypt DES encrypted message.
We look next at combining DES and RSA.

V.Rajaraman

M13/LU3/V1/2004

46

Combining RSA And DES

KEY

SENDER
PLAIN TEXT

ENCRYPT

DECRYPT

Public key Of the


receiver

Private key Of the


receiver

DES

DES

RECOVERED
KEY

RECEIVER
PLAIN
TEXT

CIPHER
TEXT

V.Rajaraman

M13/LU3/V1/2004

47

Combining RSA And DES


Advantages:
Key is sent along with the plain text. Encrypted
using RSA
Key small-fast to encrypt/decrypt
Each transaction using DES can have a different keyhigher security and also fast.Key directory not
needed.

V.Rajaraman

M13/LU3/V1/2004

48

Digital Signature
Requirements
Needed to ensure that a message received from say A is indeed
from him
Signature should be tied to the message sent by A
Sending Step
Sender sends key using RSA system
Sender sends plain text M using DES
Receiver decrypts cipher text using DES and the key received
from sender call it MR
V.Rajaraman

M13/LU3/V1/2004

49

Digital Signature
Sender hashes plain text "M' using a hashing function - let
the hashed text be "H"
Hashed text "H" encrypted by sender using his Private key
DS is his signature as H encrypted with his private key
DS decrypted by receiver using sender's Public key and
obtains "H"

V.Rajaraman

M13/LU3/V1/2004

50

Digital Signature (Contd)


Authentication step
Receiver hashes MR" using hash function and getsHR"
Receiver compares H" with HR"
If they match then it is a signed authenticated plain text
TM is signed as sender has encrypted the hashed text using his
private key which he only knows.If H=(MR)(HASHED) = HR
where MR is the received message then MR must have been sent by
sender. He cannot repudiate.
V.Rajaraman

M13/LU3/V1/2004

51

Signing A Message Using Digital


Signature
Rs Private key

Rs Public key
KE

ENCRYPT

DECRYPT
K

SENDER

ENCRYPT

Forgery

ME

DECRYPT

MR

RECEIVER

no
DS

Hash

ENCRYPT

DECRYPT

Ss Private key

Hash

Equal

Ss Public key

HR
yes

Signature OK
Accept M
V.Rajaraman

M13/LU3/V1/2004

52

Certificate Authority For


Digital Signature
As the hashed message in Digital Signature system is
decrypted using senders public key,this key must be
certified as belonging to sender by an independent
authority
Certification needed to ensure authenticity of public
keys of organizations as public key is used to verify
signature

V.Rajaraman

M13/LU3/V1/2004

53

Certificate Authority For


Digital Signature
Certification authority keeps data base of public keys of
organizations participating in e-commerce after verifying
their credentials.
Potential business partners can authenticate public keys by
sending request to certifying authority who certifies after
receiving a fee for his services

V.Rajaraman

M13/LU3/V1/2004

54

Electronic Payment Systems


In any commercial transaction payment is an integral part for
goods supplied.
Four types of payments may be made in e-commerce they are
Credit card payments
Electronic cheque payments
Micro or small payments for internet based services such as music
download.
Electronic-cash payments
Each of these requires a different system of payment. We will
examine first credit card payments.
V.Rajaraman

M13/LU4/V1/2004

Review Of Manual Credit Card


Payment
Four parties are invoked in credit card payments.
They are:
Customer having a credit card
Merchant accepting credit cards (such as VISA, MASTER
CARD etc)
Bank which issues credit cards to customers and collects
payments from customers

V.Rajaraman

M13/LU4/V1/2004

Review Of Manual Credit Card


Payment
Acquirer which is financial institution that establishes an
account with a merchant,validates credit card information sent
electronically by merchant and authorises sale based on
customers credit status.
Acquirer accepts credit cards of several card companies and
guarantees payment to merchants.
Acquirer gets reimbursed by bank issuing credit card.

V.Rajaraman

M13/LU4/V1/2004

Sequence Of Transactions In
Manual Credit Card Payment
Step 1: Customer presents credit card after purchase. Merchant
swipes it on his special phone and enters amount
Step 2: Data from merchants terminal goes to acquirer via a
private telephone line
Step 3: Acquirer checks with the issuing bank validity of card
and credit-available

V.Rajaraman

M13/LU4/V1/2004

Sequence Of Transactions In
Manual Credit Card Payment
Step 4: Acquirer authorizes sale if all OK and sends
approval slip which is printed at merchants terminal.
Step 5: Merchant takes customers signature on the slipverifies it with the signature on card and delivers the goods.
Step 6: The acquirer pays the money to merchant and
collects it from the appropriate issuing bank. The bank
sends monthly statement to customer and collects
outstanding amount.
V.Rajaraman

M13/LU4/V1/2004

Block Diagram Of Steps In Credit


Card Transaction
Step1

Customer

Merchant
Step5
Step 4

Step2 Step6

Acquirer

Step3

Issuing bank

Step3
Step6

Steps correspond to that given in previous 2 PPTs


V.Rajaraman

M13/LU4/V1/2004

Credit Card In E-commerce


Main Problems
Main Problem is: if a merchant had only a web presence, a
Customer needs to be reassured that the merchant is
genuine.
1. Customers Signature cannot be physically
verified.Customer needs electronic signature.
2. Secrecy of credit card number has to be ensured.
3. Dispute settlement mechanism must be worked out.
V.Rajaraman

M13/LU4/V1/2004

Secure Electronic Transaction


Protocol

Standardised credit card payments in e-commerce by major


card companies such as Visa, MasterCard etc.

To use SET protocol it is assumed that


1. Each party involved in e-commerce transaction has a
public and private key.A public key encryption is used.
2. All parties have their public keys certified.
3. A standard hashing algorithm is used to create message
digest for signature verification.
V.Rajaraman

M13/LU4/V1/2004

Secure Electronic Transaction


Protocol
Main Features

Customers credit card number is not revealed to a merchant.


It is revealed only to the acquirer who authorises payment.

Purchase invoice details are not revealed to the acquirer.Only


the credit card number and total amount are revealed to him

Purchase invoice + credit card number is digitally signed by


the customer.In case of a dispute an arbitrator can use this to
settle the dispute.
(Computer protocol runs to 262 pages and may be found in
www.ibm.com/redbook/SG244978)
V.Rajaraman

M13/LU4/V1/2004

Secure Electronic Transaction


Protocol
Dual Signature Scheme

Dual signature scheme is an innovation in SET protocol


Steps followed in the protocol are:
1. Customer purchase information has 3 parts
(i) Purchase Order (PO)
(ii) Credit Card Number(CCN)
(iii) Amount to be paid
2. Merchant should know (PO + Amount)=POA
3. Acquirer should know (CCN+Amount)=CCA
V.Rajaraman

M13/LU4/V1/2004

10

Secure Electronic Transaction


Protocol
4. Hash POA using standard Hash algorithm such as
RSAs MD5.Call it POD.
5. Hash CCA using MD5. Call it CCD
6. Concatenate POD and CCD.Call it (POD||CCD)
7. Hash (POD||CCD) giving PPD

V.Rajaraman

M13/LU4/V1/2004

11

Secure Electronic Transaction


Protocol
8. PPD is encrypted using Private key of customer.This is
customers digitally signed purchase order
DS = Encrypt (PPD) with CPRK
CPRK is Private key of customer. This is sent to merchant by
customer.DS is called Dual Signature as a private key is used to
sign two separate digests concatenated together.
9. POA separately encrypted by customer using merchants public
key and sent to merchant
10. Merchant decrypts it using his private key.He thus gets Purchase
order +Amount
V.Rajaraman

M13/LU4/V1/2004

12

Secure Electronic Transaction


Protocol
11. CCD and DS also sent to merchant. From CCD merchant
cannot find CCN.
12. Merchant can decrypt DS using customers public key and get
PPD. Customer must have a certified public key for verification.
13. Merchant can compute H(POD||CCD)
If H(POD||CCD)=PPD,then customers signature is OK.
14. Merchant forwards to acquirer CCA,POD,DS each separately
encrypted using acquirers public key.
V.Rajaraman

M13/LU4/V1/2004

13

Secure Electronic Transaction


Protocol
15. Acquirers forwards to bank.
16.Bank finds CCN and Amount.Verifies balance
amount.Bank also verifies customers digital signature
using CCD,POD and DS.If all OK acquirer is informed.
17. Acquirer OKs transaction to merchant
18. Merchant supplies item.Gets payment from
acquirer.Bank collects from customer.

V.Rajaraman

M13/LU4/V1/2004

14

Dual Signature System


To Merchant
C
U
S
T
O
M
E
R

P.O+Amount

POA

Hash

POD
Concatenate

C.C No +
Amount

CCA

Hash

CCD

Hash
POD||CCD

To Bank

PPD

DS

Encrypt

Private key
Of customer
CPRK

Dual
signature

POA: (Purchase Order + Amount)


POD: Purchase Order Digest
CCA: (Credit card + Amount)
CCD: (Credit card + Amount)Digest
||
: Concatenation operator which strings together POD and CCD
PPD : Purchase Payment Digest
CPRK: Private Key of Customer
V.Rajaraman

M13/LU4/V1/2004

15

Secure Electronic Transaction


Protocol
- Step1 : [(POA)EM + (CCA)EB + CCD +DS] to Merchant
- Step2 : Merchant sends [(CCA)EB + DS + POD] to Acquirer
- Step3 : Acquirer sends (CCA)EB + DS +POD to Bank.
- Bank finds (CC No. + amount) sees if OK
Computes H(CCD||POD)
Decrypts DS with customers public key
If (DS)CPK = H(CCD || POD) Signature verified
V.Rajaraman

M13/LU4/V1/2004

16

Secure Electronic Transaction


Protocol
- Step4 : OK to acquirer if credit and signature OK
- Step5 : Ok to Merchant
- Merchant finds H(H(POA) || CCD)=PPD
- Decrypts DS with public key of customer.If match signature
verified.
- Step6 : Sends delivery details
- Step7 : Bill to customer
V.Rajaraman

M13/LU4/V1/2004

17

Secure Electronic Transaction


Protocol
Merchant
Step 1

Step2

Step5

Step6

Customer

Acquirer

Step3

Bank

Step4
Step 7
V.Rajaraman

M13/LU4/V1/2004

18

Secure Electronic Transaction


Protocol

Step1: Customer fills Purchase order, amount and credit card number
in his PC. A software in PC strips it into two parts Purchase Order +
Amount (POA), Credit Card No. + Amount(CCA)
POA is encrypted using merchants.
Public key and CCA with banks public key.These are sent with
customers public key certificates, CCD and DS. Merchant verifies DS.
Step2: Merchant forwards to acquirer DS and CCD (These are encrypted
using acquirers public key)
Step3: Acquirer forwards to bank. Bank decrypts CCA with its private
key.Checks validity of credit card and balance. If OK informs acquirer
V.Rajaraman

M13/LU4/V1/2004

19

Secure Electronic Transaction


Protocol
Step4: Acquirer OKs transaction to merchant and
credits merchant's account.
Step5: Merchant accepts customers order and proceeds
to dispatch items.
Step6: At the end of the month bank sends bill to
customer.
(All these done by clicks of mouse button)
V.Rajaraman

M13/LU4/V1/2004

20

Electronic Cheque Payment


Most cheque based transactions will be between
businesses -thus special hardware attached to PCs
for signing payments
Signature encrypted by hardware
All public keys of business partners authenticated
by certifying agencies

V.Rajaraman

M13/LU4/V1/2004

21

Electronic Cheque Payment


Steps in transaction
1 Purchaser sends purchase order and payment advice signed
with his private key to vendor.He also sends his public key
certificate encrypted with vendor's public key to vendor
2 Vendor decrypts with his private key, checks certificate and
cheque, attaches deposit slip, encrypts with bank's public key
and sends it to bank. he also sends his public key certificate
3 Bank checks signatures, credits and clears cheque
4 Credit advice goes to vendor,& consolidated debit advice sent
to purchaser periodically
V.Rajaraman

M13/LU4/V1/2004

22

Clearing Cheque Payment


Electronically
Purchaser

Vendor
Order form

Signature Card

Signature Card
Order

Debit Advice

Credit
Advice

Cheque
Signature
Certificate

Deposit slip

Secure Envelope
Purchasers
Bank

Clearing
House

Vendors
Bank
Deposit
Cheque

V.Rajaraman

M13/LU4/V1/2004

Cheque
Signature
Certificates
Endorsement
Certificate
23

Payments Of Small Amounts On


Internet
Netbill's Proprietary System
Customer charged only when information delivered
Vendor guaranteed payment when information delivered
Netbill is the intermediary

V.Rajaraman

M13/LU4/V1/2004

24

Payments Of Small Amounts On


Internet
Major Steps
When customer accepts quote for information, vendor sends
encrypted information without key to customer
Payment order sent to vendor with checksum of information
obtained. It is signed by customer
Vendor sends to NET BILL copy of purchase order and the key
for decryption
NET BILL checks credit of customer. If ok it sends key to
customer. Credits vendor account and debits customer account.
Key sent to customer to decrypt information
Customer decrypts information
V.Rajaraman

M13/LU4/V1/2004

25

Paying for Small Internet


Transactions
1
2
3
4

Customer

1.
2.
3.
4.
5.
6.
7.

Request for information.


Quote
Order
Encrypted Text
Customer Bill+key
Ok to vendor
Key to customer

Customers
Bank
V.Rajaraman

Vendor
7

6
Net Bills
Server

Credit in
Account

Net Bills
Server

M13/LU4/V1/2004

Batch
Payment

Vendors
Bank

26

Electronic Cash

Cash for small payments


Cash preserves anonymity
Cash should not be traceable
We will discuss only traceable cash payments

V.Rajaraman

M13/LU4/V1/2004

27

Electronic Cash (contd.)


STEPS
1.Customer withdraws coins in various denominations signed by
bank
STRUCTURE------> serial no, denomination, signature of bank
Bank stores issued coins copy
2.Customer pays vendor using signed coins
3.Bank checks whether it is current or spent
4.If current it authorises dispatch of goods and credits vendor
account with electronic coins
V.Rajaraman

M13/LU4/V1/2004

28

Electronic Cash(contd)
Cheaper than credit card transaction
DES normally used for these transaction as it is cheap
and amounts involved is small

V.Rajaraman

M13/LU4/V1/2004

29

Electronic Cash Payment


Amt
10
5

ID
1568
6789

Signature

Customer

Vendor
2

86ABC
86ABC

4
Yes

3
OK?

Bank
1.
2.
3.
4.
5.

Spent

Withdraw
Pay
Check if OK
Replying OK
Accept order

V.Rajaraman

Amt

.
.
M13/LU4/V1/2004

Coins
ID

.
.
30

System Analysis and Design/ Systems Analysis and


Design Life Cycle

Worked Examples

Worked Examples
2.1) Who do you think should participate in determining the information
requirements of a students hostel?

Warden of hostel
Hostel Superintendent
Accountant
Student Representatives
Principal of college is consulted at the beginning

2.2) What is the difference between information requirement determination


and specification?

Information requirement determination attempts to find out what


strategic, tactical, operational information is needed to effectively
manage an organization.
Information specification defines the manner in which the information will
be presented and what analyzed data it
2.3) Why is feasibility analysis necessary before designing a system?
Feasibility analysis mean to analyze whether there is a reasonable chance of the
project succeeding given the constraints of computing equipment, human
resources, data availability i.e. before investing money and time one should
know what resources are needed for it to succeed and whether the resources are
available. If the resources are limited, then the goals to be met by the system can
be curtailed. One should have a quantitative and qualitative idea of cost of
the system and what benefits one may gain from the system.
2.4) What benefits do you expect if an information system for a hostel is
designed?
w Mess bills will be promptly generated and can give itemized details
of extras.
wCan control mess expenses by finding out consumption of various items
against an average.
w Can try to optimize daily menus based on cost of vegetables etc.
w Can find out the names of the students with large dues left and sending
the reminders.
w Can quickly find out which student stays in which room and his home
address when needed.
V. Rajaraman/IISc

M2/V1/July 2004/1

System Analysis and Design/ Systems Analysis and


Design Life Cycle

Worked Examples

2.5) What activities will you carry out during implementation of a hostel
information System?
1. PROGRAMS WRITTEN FOR

Mess accounting

Billing

Stores control
2. DATABASE CREATED

Students

Mess stores

Mess finance
3.TRAINING
Hostel office staff will be trained to input data and generate queries
4.DOCUMENTATION
Documentation of the system will be created.
5.TESTING
The computerized system will be operated in parallel with the manual
system and tested.
2.6)

When should a system be evaluated?

A rough thumb rule is to evaluate a system when the "transients die down
and it reaches a quasi "steady-state". Transients are caused by changes made due
to errors in the system and when some minor changes are introduced. Normally a
system is evaluated after being in use for 6 months, but this period may vary
according to the application.
2.7) Are excellent programmers necessarily excellent system analysts? Justify
your answer.
An Programmer is not necessarily an excellent system analyst. A
programmer is given clear specification and designs efficient programs. He need
not have good communication skills and inter-personal relations. A programmer
works with clear specifications whereas an analyst has to arrive at clear
specifications from fuzzily stated requirements.
2.8)

Why should a systems analyst be able to communicate well?

He has to understand users requirements mostly by interviewing them and


thus he has to ask the right questions, listen carefully and summarize orally the
gist of conversation. He also must be able to present and explain orally to the users
the system designed by him and clarify doubts they may have after the oral
V. Rajaraman/IISc

M2/V1/July 2004/2

System Analysis and Design/ Systems Analysis and


Design Life Cycle

Worked Examples

presentation. His main job is to interact with the management, users and the
programmers so it is obvious that he must possess good communication skills.

V. Rajaraman/IISc

M2/V1/July 2004/3

System Analysis and Design/Information gathering

Question Bank

QUESTION BANK
3.1

Describe the general strategy an analyst should use to gather information.

3.2

What are the main sources of information in an organization?

3.3

What are the methods of gathering information?

3.4

Why are interviews essential in gathering information?

3.5

How should an analyst prepare before an interview?

3.6

Are group discussions useful in information gathering? Give reasons.

3.7

Are there some guidelines for good interviewing? State them.

3.8

What is the advantage of using a questionnaire in fact gathering?

3.9

When should questionnaires be used?

3.10

When should questionnaires be not used?

3.11

State as many sources of information as you can think of.

3.12

What is the last step in information gathering?

V. Rajaraman/IISc

M3/V1/July 2004/1

System Analysis and Design/Information gathering

Question Bank

MODULE 3
CASE

STUDY -

HOSTEL INFORMATION SYSTEM Fact Gathering and

Requirements Determination
System analyst's diary: "I was called at 9 a.m. today (18 March 04) by the chief Warden
of Raman Hostel, Prof.V.Ramakrishna. He wants to examine if computers can help in
hostel administration. I made an appointment to meet him tomorrow at 10 a.m. in the
hostel office. I told him I will need 40 minutes to get an overview of his requirements".
I made the following checklist before meeting him.
Checklist

Find out what aspects of hostel operation he wants to analyze and improve.

Find out why he wants this and what benefits he foresees.

Find out his priorities

Find out how early he wants the system.

Find out about the organization of the hostel administration.

Find out who else he wants me to talk to.

Find out if any documentation on existing procedures exists.

I met Prof.V.Ramakrishna at 10 a.m. on 19 March 04 in his office in the hostel and asked
his permission to take notes. The summary of my notes which I made and sent to him on
20 March 04 for his comments are:

The total mess expenses are divided among members. Policy is set by the Chief
Warden in consultation with a student mess committee.

V. Rajaraman/IISc

M3/V1/July 2004/2

System Analysis and Design/Information gathering

Question Bank

He wants correct mess bills to be prepared and despatched within 5 days of the end
of the month to the accounts office for collection.

He wishes to know which students have large unpaid bills.

He is eager to control inventories to minimize stock.

He intents to control issue of stores to cooks to minimize wastage.

He wants to do some planning about purchase of

vegetables and fruits to

minimize cost and wastage.

He desires to have an up-to-date data base of students in hostel.

The primary objective is to minimize students' mess bills, reduce outstanding


payments, and have ready information about residents.

The priority order of the Chief Warden is: control inventory, control stores issues,
ensure speedy bill collection, student data base.

He would like a new system to be implemented within 4 months.

The organization chart of the hostel is given in Fig.3.1

The Chief Warden wants me to talk to assistant wardens, mess supervisors and
students' mess committee members.

There is no procedure manual.

Most operation are done routinely using a

commonsense approach.

Professor Ramakrishna agreed that my notes, on the whole, reflected our conversation.
He added that the number of residents in the hostel was 400, all staying in single rooms.
He further indicated that he could afford to install a Personal Computer if benefits can
justify cost. I then made an appointment to meet Dr.M.N.Swamy, the assistant warden
V. Rajaraman/IISc

M3/V1/July 2004/3

System Analysis and Design/Information gathering

Question Bank

on 23 March 04 at 4 p.m. in his office. I requested half an hour of his time for
discussions. I made the following checklist before meeting him:

Find out details of accounting and billing procedure currently used.

Ascertain his ideas about the current system and improvements

Try to know his ideas on deployment of personnel if a computer is used.

The following notes were prepared by me on 23 March 04 evening. I used the jottings in
my notebook made with Dr.Swamy's permission on 23 March 04 during the interview.

Dr.Swamy is in-charge of all hostel accounts and is assisted by Mr.R.Sampath whose


responsibilities are to collect mess dues from residents and issue receipts, prepare
cheques for vendors' payments and keep petty cash account. Besides Mr.Sampath, there
is Mr.K.S.Iyengar, an accountant, who keeps accounts of (a) daily purchases for the
mess, (b) periodical purchases for mess, and (c) employees salaries (total around 30
employees).

Presently there are three purchase payment procedures. These are:

Monthly payment.

Milk, green vegetables, meat, bread, butter, and confectionery are

delivered daily. A delivery chalan with a bill is given. Delivery is checked by mess
supervisor (Mr.Viswam) and the bill is sent to Mr.Iyengar. The rates are checked by the
mess secretary (elected by residents) against market rates and negotiated with the vendor.
The bill with the negotiated rate are filed by Mr.Iyengar and a copy given to the vendor.
V. Rajaraman/IISc

M3/V1/July 2004/4

System Analysis and Design/Information gathering

Question Bank

At the end of the month they are verified by the secretary and Dr.Swamy, and payment
by cheque made to vendors.

Cash payment. Items such as gas, coal, kerosene, dry fruits are received at random and
immediate cash payment is made. Similarly, cash payment is made for cartage of goods
and for cleaning of grains. Cash payment bill copy is kept by Mr.Iyengar as authorised
by Dr.Swamy. Cash is paid by Mr.Sampath who keeps the cash accounts.

Biweekly payment. Once in two weeks items such as sugar, grain, pulses, condiments,
etc. are purchased from the wholesale market by a group consisting of mess secretary,
Mr.Iyengar and Mr.Viswam. Rates are fixed by negotiations and bulk delivery is made
to the hostel.

Delivered quantities are checked by Mr.Viswam and bills filed by

Mr.Iyengar. Bills are approved by Dr.Swamy, and the payments are made within two
weeks by cheque.

The mess bill is calculated by Mr.Iyengar and his assistant Mr.Singh. To find the daily
rate, the total expenses are divided by the sum of the number of students who have their
food in the mess every day. If the total expenses are say Rs.5,60,000, and 400 students
eat on the first day, 395 on the second, and 406 on the third day, etc., then
Daily rate

V. Rajaraman/IISc

Rs.5,60,000 (400 + 395 + 406 + for 30 days)


=

Rs.5,60,000/12043

Rs.46.50

M3/V1/July 2004/5

System Analysis and Design/Information gathering

Question Bank

Currently, the manual calculation of bills takes over 6 days and many errors are found.
Bills do not go on time to students. This needs a better system.

Students are allowed to claim rebate if they do not eat for 2 days consecutively in the
mess, provided they give minimum 3 days notice in writing in the register kept with the
mess supervisor. Students can bring guests for meals and they have to enter the number
of guests for meals (not more than 4 at a time) in a register. They can also order "extras"
such as milk and eggs, which are entered in a register. Such entries from a daily register
are transferred to another students extras/guests/rebate register which has one page for
each student, and all entries for a student are written date-wise in this by Mr.Singh. This
register is used in calculating individual bills.

Dr.Swamy feels that this procedure complicates bill preparation. The student body wants
this facility to be continued. Dr..Swamy feels that if a proper system is designed,
Mr.Iyengar and Mr.Singh can be easily trained to use it, as both are intelligent and also
know typing.

The above notes were sent to Dr.Swamy who approved them. He added that a speedier
and accurate billing method with full details will be welcomed by students. Currently
full details of extras/guests are not provided in the bill as manual entry is too slow.
Further follow-up with students who have not paid their mess bill is currently not
methodical.

V. Rajaraman/IISc

M3/V1/July 2004/6

System Analysis and Design/Information gathering

Question Bank

I then decided to meet Dr.Prasad who is the assistant warden in charge of mess affairs. I
fixed a meeting with him on 24 March 04 at 3 p.m. Before the interview the following
points were noted in the checklist:

Find out how items are issued to cooks each day

Find out if any inventory control is exercised

Find out how wastage is reduced

Find out his ideas for an improved system and its operation.

The following notes were prepared by me after the interview and sent to Dr.Prasad on 25
March 04. (Dr.Prasad oversees the work of Mr.Viswam, the mess manager, Mr.Garg, the
store keeper, and coordinates with the student mess committee).

Dr.Prasad is very unhappy with the way the inventory is controlled. The store keeper
waits till an item is exhausted and only then he tells the mess manager about this. It leads
to many trips to the city to order items and piecemeal arrival of items, leading to high
travel/transport cost. Rs.8000 is spent in this which can be considerably reduced. Items
are issued by the mess manager to the cooks based on nominal number of students in the
hostel. Proper care is not taken to reduce issues to cooks when many students are absent.
This leads to wastage. Over 100 different items are stocked in the store and a systematic
technique of replenishing stock should be used. Mess bill could be reduced by bulk
purchase of non-perishable items when their cost is low. This is not done. Dr.Prasad
feels that use of a computer in inventory control and issue control can be very effective.

V. Rajaraman/IISc

M3/V1/July 2004/7

System Analysis and Design/Information gathering

Question Bank

The above notes were approved by Dr.Prasad who suggested that I should meet the
secretary of the student mess committee Mr.A.Pramod. I found Mr.Pramod in his room
in the hostel on 26th morning and he invited me to have a breakfast meeting. (Mr.Pramod
was elected secretary 8 months ago and has 4 more months in his current term. He wants
improvements within that period). He reiterated the points made by Dr.Prasad and
Dr.Swamy on the need to systematize issues, inventory and billing. He pointed out one
of the main difficulties he faced. Currently the bill is calculated at the end of the month.
Till then he has no idea of what the daily rate will be. Very often the daily rate goes up
sharply from say Rs.46 to Rs.54 which the students do not like. This leads to hasty
economy measures in the mess without proper knowledge of the areas in which these
measures will be effective. The student body would like to have uniform rates. This can
be ensured if estimates of daily rates are available at the end of each week. If the rate
tends to become high, some planned economy can be effected. Weekly adjustment can
lead to uniform rates. The daily menu is decided by the mess manager in consultation
with the mess secretary. Currently it is somewhat repetitive. Students joke" It is beans
curry and therefor it is Wednesday". There must be some way of randomizing menus,
keeping nutritional balance, variety of items and of effectively using seasonal low cost
vegetables, thereby reducing the mess bill. He thinks aloud whether some operations
research techniques can be used in this problem. I am somewhat intrigued by this
suggestion.

V. Rajaraman/IISc

M3/V1/July 2004/8

System Analysis and Design/Information gathering

Question Bank

I summarized the above discussion and sent it to the mess secretary and Dr.Prasad for
their comments. I next met employees of the mess to get their views. I met Mr.Viswam,
the mess manager on 27 March morning. He explained his responsibilities as :

Preparing daily menu based on advise from the mess committee.

Preparing an "issue list" of items and quantities for each meal and sending it to the
hostel store for issue to the kitchen.

Preparing a "return list" of items and quantities not used during the day by the
cooks to the store.

Stock register updating based on issue and return list.

Keeping track of rebates to students absent

from mess and extras taken by

students which are to be separately charged. Relate rebates to stores issue.

Ordering items when stock level is low. In practice, however, ordering is done
only when an item is exhausted. As delivery at door may be delayed, unnecessary
special trips are made to do cash pruchases.

Mr.Viswam felt that some help in automatically preparing issue list based on number of
persons who will eat in the mess will be very helpful. He would also appreciate assistance
in error free recording of rebates and extras.

An automatic warning mechanism when

stocks become low would be useful. Consolidation of purchases to reduce trips would be
desirable.
A summary of the above discussion was sent to Mr.Viswam for his comments.

V. Rajaraman/IISc

M3/V1/July 2004/9

System Analysis and Design/Information gathering

Next I met Mr.Mathews, the assistant mess manager.

Question Bank

His responsibilities include

supervising mess staff and day-to-day maintenance of the hostel. He also assists the
warden in room allotment by keeping a list of available rooms, preferences, applications
for change of rooms etc. He feels that mess bill preparation is time consuming as it takes
a week. Room allotment, on the other hand, is not difficult and the current system is
satisfactory.

I then met Mr.Garg, the store-keeper. He keeps the stores stock register and helps the
mess manager in preparing the issue and return lists. He prepares lists of items to be
bought and monitors quality of supplies.

I finally held a group meeting with the chief Warden, assistant wardens, mess manager,
assistant manager, mess secretary, accountant and store-keeper. I showed the data and
document flow diagrams (Figs. 3.2-3.4) prepared by me and got their approval. I then
listed the critical needs which various persons identified. These are given in Table 3.1.
Based on this a consensus was reached on what aspects needed.

Table 3.1 Critical Needs Identified by Various Persons

Mess bills to be despatched within 5 days to students.

Identify large outstanding bills from students.

Correct billing of extras and rebates to students.

Weekly calculation of daily rate.

Prompt payment to vendors.

V. Rajaraman/IISc

M3/V1/July 2004/10

System Analysis and Design/Information gathering

Question Bank

Issue of exact quantities of items to cooks based on menu and number of students.

Reducing menu repetitions.

Keeping a nutritionally balanced menu and minimizing cost.

Forecasting requirement of stores based on menu and students.

Consolidating purchases to reduce frequent trips for purchase and reducing cartage
charges.

Student data base.

Computerization, and priority among them was also determined. The following priority
list was prepared as system to be computerised.
Preparation of mess bill
Stores issue and ordering system
Menu planning
Data base of hostel residents.

They requested me to begin a feasibility study and provide a cost-benefit analysis of the
above systems.
End of Fact Gathering and Requirements Specification Phase.

V. Rajaraman/IISc

M3/V1/July 2004/11

System Analysis and Design/Information for Management

Case Study

INFORMATION PROCESSING FOR A STORE - AN OVERVIEW A Small


Case Example
In what follows we will present a broad overview of how data is processed to meet the
functional requirements of a store. The presentation below will be an overview.
The important functions of a store are:

to keep an up to date ledger containing stock positions,

cater to requisitions for issue of items from the store,

initiate reorder of items whose stock is below a specified limit,

update stock register when items are received, and

answer enquiries regarding availability of items in stores.

In a computer based system the stock ledger is organized in a suitable form for easy
updating and retrieval and recorded on a magnetic disk. Magnetic disk storage is the
primary storage medium for storing large data bases. This is due to the fact that any
record can be directly accessed. Magnetic tapes are used primarily as a back-up storage
unit for keeping copies of data on disk. Tapes are also useful for storing old files and for
interchanging files between different computers.

In order to create a stock ledger for a computer-based system it is necessary to first assign
unique codes for each item in the store. The unique code assigned to each item is known
as the key of the item record and identifies the record. After that it is necessary to find
out what data fields are needed for each item in the stock. The fields are determined by
working backwards, that is, first asking what outputs are needed and based on that

V. Rajaraman/IISc

M1/V1/July 2004/1

System Analysis and Design/Information for Management

Case Study

determining the data needed. The fields are organized as a record and stored in a data
base. This data base is the primary or master file for the store. (It is the computer
readable version of a stock ledger used in a store). Once the record format for each item
in the store is determined, one record is created for each item in the store. These records
are entered manually by a data entry operator who enters the records using a keyboard of
a terminal connected to the computer. This is called on-line data entry. Data may also
be entered on a separate computer such as Personal Computer (PC) and stored on a
floppy disk. This is called off-line data entry.

In off-line data entry the data entry machine is a low cost machine. If the volume of data
to be entered is very large, then a number of machines can be used and data prepared,
checked and corrected. As opposed to this, an on-line data entry method uses terminals
connected to the computer. In such a case the computer should be timeshared. On-line
data entry is appropriate for inserting, deleting or correcting some records in fields.

The data on floppy disk can then be transferred to the disk connected to the computer.
Off-line entry is used when the data base is very large and the computer used is a server
or a mainframe computer. If the data base is small, the PC itself may be used for data
entry and for data processing.

Before data is stored in the disk-file it must be ensured that any errors made during data
entry is detected and corrected. This is done by a program called an edit program and a

V. Rajaraman/IISc

M1/V1/July 2004/2

System Analysis and Design/Information for Management

Case Study

control total checking program. Such programs are essential to ensure the validity of data
in a master file.

A procedure similar to the one used to create the master file is also used to keep the data
in the master file up-to-date when new items are received or new stock of items already
in the ledger are received. Table 1 summarizes the operations performed for other
functions. The format of a record for entering requests uses the same item codes assigned
in creating the master file. Other fields are determined based on what outputs are needed.
In this case a reasonable format for requests is:
(item code, item name, quantity requested)
Table 1 Operations Performed in Stores Information Processing
1.

2.

3.

4.

Create stock ledger


Codify items
Determine data fields needed for each item
Create a record for each item
Organize the records as a data base
Issues/Reorder
Codify items
Determine data fields required in each request
Determine data fields required for each issue
Create record format for requests and issues
Create record format for reorder
Receipts
Codify items
Determine data fields required in each receipt
Create record format for receipts
Enquiry
Codify items
Record format for enquiry
Record format for response

The record format for a reorder request would be: item code, item name)

V. Rajaraman/IISc

M1/V1/July 2004/3

System Analysis and Design/Information for Management

Case Study

( The quantity to be reordered is normally stored in the file maintained by the Purchase
department)
The record format for issues would be : (item code, item name, quantity requested,
quantity issued)
The request record is entered through a keyboard by a requester. It is checked for
validity by a program.

A valid request is forwarded to a retrieval program which

retrieves the data on the requested item from the Master file on disk. The item code in
the request is used as the key for retrieval. If the requested number of items is available,
then an issue slip is printed; otherwise a reorder request is printed. Care must, however,
be taken to ensure that once a reorder is requested it is not requested again till the item
reordered is taken into stock.

Each request slip processed by the computer is called a

transaction. If each request is processed as and when it arrives and the terminal on which
the request is entered is connected to the computer, then the processing method is called
On-Line Transaction Processing (OLTP).
There is another method of processing requests. A number of requests arriving during a
day (for example) are collected and formed into a batch. The data in such a batch can be
keyed-in off-line and a floppy disk created. This floppy disk can then be used to enter
requests on the computer which has the Master file. The entire batch is processed and
outputs are printed.

This mode of processing is called batch processing.

Batch

processing is usually more efficient. It, however, is not as timely as on-line processing.
In operations such as payroll processing which is done periodically, batch processing is
more appropriate.

V. Rajaraman/IISc

M1/V1/July 2004/4

System Analysis and Design/Information for Management

Case Study

Enquiry system is normally an on-line transaction processing system as it is the most


natural way of answering users' queries. In an enquiry system also, a user's query is first
checked for validity of item code, etc. before it is processed.
A variety of information systems used in practice are primarily on-line transaction
processing systems.

Common examples are airlines and railway ticket reservation

systems. Designing such systems require special care to ensure that response to enquiries
are fast and that the system has a hot standby if there is a failure. High reliability is
required as failures can be catastrophic (imagine many persons getting the same berth
reserved on a train). Similarly reliability and availability is essential in on-line banking
systems.

MIS and DSS for Stores


The processing methods presented in the last para are for routine data processing. The
information they provide is operational information. The system required to obtain
tactical information require further processing. Such systems are known as Management
Information Systems (MIS). In the stores processing case study, some tactical decisions
would be:

at what stock level should reorder be initiated?

How much should be

reordered? These are determined based on data such as rate of issue of each item, time
needed for delivery from date of order, transport cost, storage cost, shelf life, and loss
incurred if an item is out-of-stock. These data have to be collected separately over a
period of time, often as a byproduct of a routine data processing system. In the stores case
daily issues of some critical items can be abstracted and the average issue can be
computed. Data on delivery times, transport cost etc. can be separately collected. Well

V. Rajaraman/IISc

M1/V1/July 2004/5

System Analysis and Design/Information for Management

Case Study

known methods of operations research can then be used to compute stock level for
initiating reorder and the optimal quantity to be reordered.
Operational data collected over a period of time is called data archives and the process
of collecting it is called data archiving. With the availability of massive disks in which
terabytes (1012 bytes) of data can be stored, it has become feasible to analyse the
archived data. Analyzing archived data to observe patterns which assist in management
decision making is called data mining. A stores manager may, based on his experience,
think that in the months of October, December and April the sale of sugar is very high
compared to other months. This conjecture maybe verified by data mining. In data
mining a rule is formulated which may say that in October sugar sale is 1.5 times the
average, in December it is 1.3 times normal and in April it is 1.4 times normal. This rule
may be verified within a specified margin of error by examing the data archive. If the
rule turns out to be correct, a manager will be able to decide how much sugar is to be
stocked in these months. This is a simple example of the use of archival data and data
mining to assist in tactical management.
As another example of tactical information requirement, let us consider the question of
fixing credit limits for customers. In order to arrive at this, the following inputs would be
useful:

Customer details such as income, occupation etc.

Customer payment history

Volume of purchase by customer

Outstanding dues (if any) from the customer.

V. Rajaraman/IISc

M1/V1/July 2004/6

System Analysis and Design/Information for Management

Case Study

Using these one may formulate some rules to arrive at the credit limits and also predict
their possible effect such as:

anticipated effect on sales caused by varying credit limits

anticipated loss/profit due to credit limits.

By analyzing the impact of credit limits as specified above, a decision may be arrived at
to fix credit limits.
The primary point to note is that one has to formulate a model and sometimes simulate a
system to obtain tactical information.

The operational information from routine

processing becomes an input to obtain tactical information.


Strategic information is obtained through what are known as Decision Support Systems
(DSS). In the stores example a strategic decision would be to reduce variety in inventory
by discontinuing some items in store, deciding what new items to introduce in the store,
and when to open a new branch. Decisions such as these require provisions for a variety
of data transformations and representations.
Strategic information is often unstructured. Strategic decisions are made after trying to
answer questions such as "What will be the profit if I take a decision and what will be the
long range loss if I don't take it?". In a complex decision many parameters will be
involved. Identifying these and predicting their impact on a decision needs judgements
coupled with analysis. For example, taking a strategic decision of whether to open a new
branch or not would require the following information:

Projected demands in the new branch

Impact on current branch

Pricing in new branch

V. Rajaraman/IISc

M1/V1/July 2004/7

System Analysis and Design/Information for Management

Competition in new location

Profitability of new branch

Case Study

These have to be provided using analytical and simulation model known as decision
support models. These models are more difficult to evolve than those needed in tactical
information development. Decision support systems should also provide aids to the
manager for conceptualization such as charts, graphs, etc. They should also provide
facilities to ask a variety of queries on the data base. A variety of summary reports
should be made available on request. The overall purpose of decision support systems
is to aid in strategic, unstructured decision making. Developing such systems is much
more

difficult than developing operational systems.

They, however, are the ones

required by the top management of organizations.

V. Rajaraman/IISc

M1/V1/July 2004/8

System Analysis and Design/Information gathering

Pointers

REFERENCE BOOKS

1. Most of the material including the case study has been adapted from Chapter
4, Analysis and Design of Information Systems by V.Rajaraman published by
Prentice Hall of India 2002 with permission from publisher.
2. Systems Analysis and Design, by K.E.Kendell and J.E.Kendell published by
Pearson Education Asia 2002 discuss in detail fact gathering in pp.117-196.
They cover interviewing, questionnaire use and observing an organization
very thoroughly.

V. Rajaraman/IISc

M3/V1/July 2004/1

System Analysis and Design/ Tools for systems analysts

Worked Examples

WORKED EXAMPLES

5.1 What is the main merit of DFD?


The main merit of DFD is that it provides an overview of what data flows in a
system, what transformations are done on the data, what files are used and where
results flow.
5.2 What is the role of DFD as a documentation aid?
It is a good documentation aid which is understood by both programmers and
non-programmers (i.e., laypersons). As DFD specifies only what processes are
performed and not how they are performed it is easily understood by a nonprogramming user.
5.3 What is a context diagram?
A diagram giving an entire systems data flows and processing with a single
Process (circle) is called a context diagram.
5.4 What do you understand by levelling of DFD?
A context diagram is expanded into a number of inter-related processes. Each
process may be further expanded into a set of inter-connected sub processes. This
procedure of expanding a DFD is known as levelling.
5.5 What is a physical DFD?
A physical DFD specifies from where data flows and who processes the data and
to whom the processed data is sent.
5.6 In what way is physical DFD useful?
It is easy to develop during fact gathering stage of systems analysis. Such a
physical DFD is easily understood by a lay user who can verify the DFD drawn
by an analyst and tell whether such a DFD corresponds to a particular operation
taking place in an organization. Physical DFD is the starting point for developing
the logical DFD.
5.7 What are the mistakes in each of the DFDs of Fig. 5.7(a)5.7(e)? Correct
these mistakes.

Employee No

V. Rajaraman/IISc. Bangalore

1
Compute
Gross pay

//V1/June 04/1

System Analysis and Design/ Tools for systems analysts

Worked Examples

Fig 5.7(a)

Gross pay

Hours worked

Leave granted

Fig 5.7(b)

1
Check if
leave
available
&update

Application returned

Employee

Leave application

Fig 5.7(c)

1
Compute
net pay

Store
amount
paid

Gross
pay

Pay
cheque

Net pay

Deductions

Employee

Net pay & deductions

Fig 5.7(d)
a
A

b
2
P2
c

d
3
P3

V. Rajaraman/IISc. Bangalore

1
P1

C
//V1/June 04/2

System Analysis and Design/ Tools for systems analysts

Worked Examples

Fig 5.7(e)

Roll No and student


Marks
Find out
if pass or
fail

Pass

Fail

(i) To compute gross pay we need hours worked and hourly wage rate. This data
flow is missing.
(ii) A data flow cannot have two arrows pointing in opposite directions. A
separate data flow line should be drawn for application returned.
(iii) A data flow connects two distinct data stores without an intermediate
processing step. (See also answer to Exercise 7.5)
(iv) Process P2 has all input data flow and no output data flow.
(v) The same data flow cannot be given two names.

V. Rajaraman/IISc. Bangalore

//V1/June 04/3

System Analysis and Design/ Feasibility analysis

Worked Examples

WORKED EXAMPLES

4.1 What is the difference between main goals and sub-goals? Illustrate with an
example.
Main goal is based on a primary objective and sub-goals are secondary or
subsidiary which are related to the main objective.
For example, the main goal and sub-goals of an inventory control system may be
as follows:
Main goal: Reduce total inventory cost by 10%
Sub-goals: (i) Find out items which are 50% above buffer level to take
appropriate action.
(ii)Find out items whose cost is 50% above average cost for closer
control.
4.2 Is it essential to use computers in all information systems?
No. Better systematization may sometimes be adequate to meet goals. However
with the reduction in the cost of computers most organizations use computers.
4.3 Distinguish between technical, operational, and economic feasibility.
A solution is technically feasible if technology is available to implement it. It is
operationally feasible if it can fit in within the existing organization with only
small changes. It is economically feasible if the investment made leads to
adequate returns. A solution which requires, say, a large mainframe computer
available in the market is technically feasible but may not be economically
feasible due to high cost of the computer relative to expected benefits. It may not
be operationally feasible due to lack of trained people to program the computer.
4.4 Give an example of a solution which is technically feasible, but not
operationally feasible.
It is technically feasible to computerize services in a bank by installing PCs with
clerks who can be trained to operate it. It is operationally not feasible in certain
banks due to agreement between management and union which do not allow use
of computers for certain customer services.

4.5 Is it essential that an operationally feasible solution should be technically


feasible? Discuss with examples.
No. A computerized enquiry system where enquiries are made using a telephone
and answers are automatically spoken out is operationally feasible. It is not

V. Rajaraman/IISc. Bangalore

//V1/June 04/1

System Analysis and Design/ Feasibility analysis

Worked Examples

technically feasible due to non-availability of speaker independent natural speech


recognition technology.

4.6 Is it essential to have tangible benefits to justify an information system? If


your answer is no, justify your answer by giving an example.
No. A ticket reservation system in railways has not much tangible benefits.
However, intangible benefits such as customer satisfaction, and ease of checking
daily cash collection are sufficient reasons to implement the system.
4.7 A project costs Rs. 2 lakhs and the net benefits are Rs. 50,000 (1st year), Rs.
80,000 (2nd year), Rs. 90,000 (3rd year), Rs. 70,000 (4th year), Rs. 50,000 (5th
year) and Rs. 30,000 (6th year). Assuming 10% interest rate, would you
proceed with your project if your criterion is cost-benefit?
Year

Cost

Benefit

Current value

Cumulative
benefit

0
1
2
3
4

200,000

50,000
80,000
90,000
70,000

45,454
66,116
67,618
47,811

45,454
111,570
179,188
226,999

As payback period is 4 years, it is decided to proceed with the project.


4.8 A manager states the following as goals of a production planning system:
1. Reduce stocks of semi-finished products.
2. Provide better information for the production planning
3. Prevent overproduction.
How would you quantify the goals? How would you obtain sub-goals and
quantify them if appropriate?
(i) Goal: Reduce stocks of semi-finished products by 10%.
Sub-goal: Classify semi-finished products as due to non-availability of part,
non-availability of machine, non-availability of tool.
(ii) Goal: Give a table giving requirement of each product.
Sub-goal: Prepare list of tools needed and when they will be needed.
Prepare maintenance schedules of machines.
(ii) Goal: Ensure that production is not more than 5% of estimated demand of
each item.
4.9 A university administrator calls a systems analyst to improve the
administration of sponsored research projects. The main problems are delay
in obtaining latest financial position to project co-ordinators, reconciliation
of advances given to co-ordinators, prompt demands not sent to sponsors to
V. Rajaraman/IISc. Bangalore

//V1/June 04/2

System Analysis and Design/ Feasibility analysis

Worked Examples

collect promised grants and lack of information to answer following


questions:
Which areas of research get maximum grants?
Which agency aids which type of projects?
What trends can be seen in the nature of grants?
Now:
1. Classify the above problems into missing functions, unsatisfactory performance and excessive cost of operation.
2. How would you set the goals to meet the deficiencies?
3. How would you quantify them?
1.

(i) Missing Function: Analysis of types of grants and grant-giving agencies.


(ii) Unsatisfactory Performance: Delay in obtaining financial statements; nonreconciliation of advances.
(iii) Excessive cost: Loss due to delay in receipt of grants (loans may have to be
taken to meet expenses).
2.
(i) Goals to improve performance
Ensure financial statements are sent each month.
Ensure reminders on advances are sent each month.
(ii) Goals to reduce cost
Bring to the attention of accounts officer grants overdue by 10 days.
Send reminder ad pre-receipt 10 days before grant is due.
(iii) Goals to incorporate missing functions
Codify research areas and granting agencies.
Introduce uniform formats to classify grants.
Create a database of all possible granting agencies and their areas of
research.
3.All goals are quantified in 2.
Sub-goals
Send list of periodicals received to interested readers within 2 days of
arrival of periodicals.
Send for binding loose periodicals within 4 weeks of arrival of last issue.
(ii) A Fully manual using cardex system.
B Using a PC and a periodicals management information system.
C Using the central computing in the university and a remote terminal system
in the library dedicated to periodicals management.

4.10

What operational, tactical and strategic information should be provided by


the mess billing system mentioned in the text (case study)?
The information that will be provided to management by the mess billing system
is:

V. Rajaraman/IISc. Bangalore

//V1/June 04/3

System Analysis and Design/ Feasibility analysis

Worked Examples

Operational
Each students bill details.
Details of inventory held.
Details of issues to stores.
Details of trips to town.
Details of expenses each day.
Tactical
Number of days taken to despatch bills after end of month.
Variation of daily rate from month to month.
Bills to students unpaid for 10 days after issue.
Bills from vendors unpaid for 5 days.
Inventory level of an item if 10% above average
Issues to cooks if 5% above normal.
Nutrition values of menus.
Strategic
Daily rate seasonal trends.
Extras/rebates and trends to enable better inventory planning.
Information on menu preferences.

V. Rajaraman/IISc. Bangalore

//V1/June 04/4

System Analysis and Design/Information gathering

Worked Examples

Worked Examples
3.1)

Describe the general strategy an analyst should use to gather information.


Strategy consists of
i)identifying information sources.
ii)evolving a method of obtaining information from the identified source.
iii)using an information flow model of the organization

3.2)

What are the main sources of information of an organization.


i) Users of systems.
ii) Forms and documents used in the organization.
iii) Procedure manuals and rule books (if any).
iv) Internal reports.
v) Any computer program of existing system.

3.3)

How should an analyst prepare before an interview?


i) Make prior appointment with the person to be interviewed and
inform the purpose of the interview, and how much time you would require.
ii) An interview should be brief and not exceed 40 minutes.
iii)read the background material and go prepared with a checklist.

3.4)

Are there some guidelines for good interviewing? Give reasons.


Yes. The guidelines for good interviewing are like
i) system analyst should state the purpose of the interview again to brush of the
problem.
ii) He should try to avoid using computer jargon because the person may not be
conversant with the technical terms.
iii) He should present good manners and introduce himself before taking
interview. If any thing is not understood it should be asked immediately to
avoid later confusion

V. Rajaraman/IISc

M3/V1/July 2004/1

System Analysis and Design/Information gathering

3.5)

Worked Examples

When should questionnaires be used?


When quantitative data from number of persons is to be collected. Short
Questionnaires elicit quick response. Follow up needed to get questionnaires
back.

3.6)

Before interviewing the chief warden, what checklist did the system analyst
make?
The checklist made by the system analyst before interviewing is
i) Find out what aspects of hostel operations he wants to analyze and improve.
ii) Find out why he wants this and what benefits he foresees.
iii) Find out his priorities.
iv) Find out how early he wants the system.
v) Find out about organization of the hostel administration.
vi) Find out with whom else he wants me to talk.
vii) Find out if any documentation on existing procedure exist.

V. Rajaraman/IISc

M3/V1/July 2004/2

System Analysis and Design/Information gathering

Case Study

CASE STUDY - HOSTEL INFORMATION SYSTEM Fact Gathering and


Requirements Determination
System analyst's diary: "I was called at 9 a.m. today (18 March 04) by the chief Warden
of Raman Hostel, Prof.V.Ramakrishna. He wants to examine if computers can help in
hostel administration. I made an appointment to meet him tomorrow at 10 a.m. in the
hostel office. I told him I will need 40 minutes to get an overview of his requirements". I
made the following checklist before meeting him.
Checklist
Find out what aspects of hostel operation he wants to analyze and improve.
Find out why he wants this and what benefits he foresees.
Find out his priorities
Find out how early he wants the system.
Find out about the organization of the hostel administration.
Find out who else he wants me to talk to.
Find out if any documentation on existing procedures exists.
I met Prof.V.Ramakrishna at 10 a.m. on 19 March 04 in his office in the hostel and asked
his permission to take notes. The summary of my notes which I made and sent to him on
20 March 04 for his comments are:
The total mess expenses are divided among members. Policy is set by the Chief Warden
in consultation with a student mess committee.
He wants correct mess bills to be prepared and despatched within 5 days of the end of
the month to the accounts office for collection.
He wishes to know which students have large unpaid bills.
He is eager to control inventories to minimize stock.
He intents to control issue of stores to cooks to minimize wastage.
He wants to do some planning about purchase of vegetables and fruits to minimize cost
and wastage.
V. Rajaraman/IISc

M3/V1/July 2004/1

System Analysis and Design/Information gathering

Case Study

He desires to have an up-to-date data base of students in hostel.


The primary objective is to minimize students' mess bills, reduce outstanding payments,
and have ready information about residents.
The priority order of the Chief Warden is: control inventory, control stores issues,
ensure speedy bill collection, student data base.
He would like a new system to be implemented within 4 months.
The organization chart of the hostel is given in Fig.3.1

The Chief Warden wants me to talk to assistant wardens, mess supervisors and students'
mess committee members.
There is no procedure manual. Most operation are done routinely using a commonsense
approach.
Professor Ramakrishna agreed that my notes, on the whole, reflected our conversation.
He added that the number of residents in the hostel was 400, all staying in single rooms.
He further indicated that he could afford to install a Personal Computer if benefits can
justify cost. I then made an appointment to meet Dr.M.N.Swamy, the assistant warden on

V. Rajaraman/IISc

M3/V1/July 2004/2

System Analysis and Design/Information gathering

Case Study

23 March 04 at 4 p.m. in his office. I requested half an hour of his time for discussions. I
made the following checklist before meeting him:
Find out details of accounting and billing procedure currently used.
Ascertain his ideas about the current system and improvements
Try to know his ideas on deployment of personnel if a computer is used.
The following notes were prepared by me on 23 March 04 evening. I used the jottings in
my notebook made with Dr.Swamy's permission on 23 March 04 during the interview.
Dr.Swamy is in-charge of all hostel accounts and is assisted by Mr.R.Sampath whose
responsibilities are to collect mess dues from residents and issue receipts, prepare
cheques for vendors' payments and keep petty cash account. Besides Mr.Sampath, there
is Mr.K.S.Iyengar, an accountant, who keeps accounts of (a) daily purchases for the
mess, (b) periodical purchases for mess, and (c) employees salaries (total around 30
employees).
Presently there are three purchase payment procedures. These are:
Monthly payment. Milk, green vegetables, meat, bread, butter, and confectionery are
delivered daily. A delivery chalan with a bill is given. Delivery is checked by mess
supervisor (Mr.Viswam) and the bill is sent to Mr.Iyengar. The rates are checked by the
mess secretary (elected by residents) against market rates and negotiated with the vendor.
The bill with the negotiated rate are filed by Mr.Iyengar and a copy given to the vendor.
At the end of the month they are verified by the secretary and Dr.Swamy, and payment
by cheque made to vendors.
Cash payment. Items such as gas, coal, kerosene, dry fruits are received at random and
immediate cash payment is made. Similarly, cash payment is made for cartage of goods
and for cleaning of grains. Cash payment bill copy is kept by Mr.Iyengar as authorised by
Dr.Swamy. Cash is paid by Mr.Sampath who keeps the cash accounts.
Biweekly payment. Once in two weeks items such as sugar, grain, pulses, condiments,
etc. are purchased from the wholesale market by a group consisting of mess secretary,
Mr.Iyengar and Mr.Viswam. Rates are fixed by negotiations and bulk delivery is made to
the hostel. Delivered quantities are checked by Mr.Viswam and bills filed by Mr.Iyengar.
V. Rajaraman/IISc

M3/V1/July 2004/3

System Analysis and Design/Information gathering

Case Study

Bills are approved by Dr.Swamy, and the payments are made within two weeks by
cheque.
The mess bill is calculated by Mr.Iyengar and his assistant Mr.Singh. To find the daily
rate, the total expenses are divided by the sum of the number of students who have their
food in the mess every day. If the total expenses are say Rs.5,60,000, and 400 students
eat on the first day, 395 on the second, and 406 on the third day, etc., then
Daily rate = Rs.5,60,000 (400 + 395 + 406 + for 30 days)
= Rs.5,60,000/12043
= Rs.46.50
Currently, the manual calculation of bills takes over 6 days and many errors are found.
Bills do not go on time to students. This needs a better system.
Students are allowed to claim rebate if they do not eat for 2 days consecutively in the
mess, provided they give minimum 3 days notice in writing in the register kept with the
mess supervisor. Students can bring guests for meals and they have to enter the number
of guests for meals (not more than 4 at a time) in a register. They can also order "extras"
such as milk and eggs, which are entered in a register. Such entries from a daily register
are transferred to another students extras/guests/rebate register which has one page for
each student, and all entries for a student are written date-wise in this by Mr.Singh. This
register is used in calculating individual bills.
Dr.Swamy feels that this procedure complicates bill preparation. The student body wants
this facility to be continued. Dr..Swamy feels that if a proper system is designed,
Mr.Iyengar and Mr.Singh can be easily trained to use it, as both are intelligent and also
know typing.
The above notes were sent to Dr.Swamy who approved them. He added that a speedier
and accurate billing method with full details will be welcomed by students. Currently full
details of extras/guests are not provided in the bill as manual entry is too slow. Further
follow-up with students who have not paid their mess bill is currently not methodical.

V. Rajaraman/IISc

M3/V1/July 2004/4

System Analysis and Design/Information gathering

Case Study

I then decided to meet Dr.Prasad who is the assistant warden in charge of mess affairs. I
fixed a meeting with him on 24 March 04 at 3 p.m. Before the interview the following
points were noted in the checklist:
Find out how items are issued to cooks each day
Find out if any inventory control is exercised
Find out how wastage is reduced
Find out his ideas for an improved system and its operation.
The following notes were prepared by me after the interview and sent to Dr.Prasad on 25
March 04. (Dr.Prasad oversees the work of Mr.Viswam, the mess manager, Mr.Garg, the
store keeper, and coordinates with the student mess committee).
Dr.Prasad is very unhappy with the way the inventory is controlled. The store keeper
waits till an item is exhausted and only then he tells the mess manager about this. It leads
to many trips to the city to order items and piecemeal arrival of items, leading to high
travel/transport cost. Rs.8000 is spent in this which can be considerably reduced. Items
are issued by the mess manager to the cooks based on nominal number of students in the
hostel. Proper care is not taken to reduce issues to cooks when many students are absent.
This leads to wastage. Over 100 different items are stocked in the store and a systematic
technique of replenishing stock should be used. Mess bill could be reduced by bulk
purchase of non-perishable items when their cost is low. This is not done. Dr.Prasad feels
that use of a computer in inventory control and issue control can be very effective.
The above notes were approved by Dr.Prasad who suggested that I should meet the
secretary of the student mess committee Mr.A.Pramod. I found Mr.Pramod in his room in
the hostel on 26th morning and he invited me to have a breakfast meeting. (Mr.Pramod
was elected secretary 8 months ago and has 4 more months in his current term. He wants
improvements within that period). He reiterated the points made by Dr.Prasad and
Dr.Swamy on the need to systematize issues, inventory and billing. He pointed out one of
the main difficulties he faced. Currently the bill is calculated at the end of the month. Till
then he has no idea of what the daily rate will be. Very often the daily rate goes up
sharply from say Rs.46 to Rs.54 which the students do not like. This leads to hasty
V. Rajaraman/IISc

M3/V1/July 2004/5

System Analysis and Design/Information gathering

Case Study

economy measures in the mess without proper knowledge of the areas in which these
measures will be effective. The student body would like to have uniform rates. This can
be ensured if estimates of daily rates are available at the end of each week. If the rate
tends to become high, some planned economy can be effected. Weekly adjustment can
lead to uniform rates. The daily menu is decided by the mess manager in consultation
with the mess secretary. Currently it is somewhat repetitive. Students joke" It is beans
curry and therefore it is Wednesday". There must be some way of randomizing menus,
keeping nutritional balance, variety of items and of effectively using seasonal low cost
vegetables, thereby reducing the mess bill. He thinks aloud whether some operations
research techniques can be used in this problem. I am somewhat intrigued by this
suggestion.
I summarized the above discussion and sent it to the mess secretary and Dr.Prasad for
their comments. I next met employees of the mess to get their views. I met Mr.Viswam,
the mess manager on 27 March morning. He explained his responsibilities as :
Preparing daily menu based on advise from the mess committee.
Preparing an "issue list" of items and quantities for each meal and sending it to the
hostel store for issue to the kitchen.
Preparing a "return list" of items and quantities not used during the day by the cooks to
the store.
Stock register updating based on issue and return list.
Keeping track of rebates to students absent from mess and extras taken by students
which are to be separately charged. Relate rebates to stores issue.
Ordering items when stock level is low. In practice, however, ordering is done only
when an item is exhausted. As delivery at door may be delayed, unnecessary special trips
are made to do cash purchases.
Mr.Viswam felt that some help in automatically preparing issue list based on number of
persons who will eat in the mess will be very helpful. He would also appreciate assistance
in error free recording of rebates and extras. An automatic warning mechanism when

V. Rajaraman/IISc

M3/V1/July 2004/6

System Analysis and Design/Information gathering

Case Study

stocks become low would be useful. Consolidation of purchases to reduce trips would be
desirable.
A summary of the above discussion was sent to Mr.Viswam for his comments.
Next I met Mr.Mathews, the assistant mess manager. His responsibilities include
supervising mess staff and day-to-day maintenance of the hostel. He also assists the
warden in room allotment by keeping a list of available rooms, preferences, applications
for change of rooms etc. He feels that mess bill preparation is time consuming as it takes
a week. Room allotment, on the other hand, is not difficult and the current system is
satisfactory.
I then met Mr.Garg, the store-keeper. He keeps the stores stock register and helps the
mess manager in preparing the issue and return lists. He prepares lists of items to be
bought and monitors quality of supplies.
I finally held a group meeting with the chief Warden, assistant wardens, mess manager,
assistant manager, mess secretary, accountant and store-keeper. I showed the data and
document flow diagrams (Fig 3.2) and (Figs 3.3 and 3.4) prepared by me and got their
approval.

V. Rajaraman/IISc

M3/V1/July 2004/7

System Analysis and Design/Information gathering

V. Rajaraman/IISc

Case Study

M3/V1/July 2004/8

System Analysis and Design/Information gathering

Case Study

I then listed the critical needs which various persons identified. These are given in Table
3.1. Based on this a consensus was reached on what aspects needed.
Table 3.1 Critical Needs Identified by Various Persons
Mess bills to be despatched within 5 days to students.
Identify large outstanding bills from students.
Correct billing of extras and rebates to students.
Weekly calculation of daily rate.
Prompt payment to vendors.
Issue of exact quantities of items to cooks based on menu and number of students.
Reducing menu repetitions.
Keeping a nutritionally balanced menu and minimizing cost.
Forecasting requirement of stores based on menu and students.
Consolidating purchases to reduce frequent trips for purchase and reducing cartage
charges.
Student data base.
Computerization, and priority among them was also determined. The following priority
list was prepared as system to be computerised.
V. Rajaraman/IISc

M3/V1/July 2004/9

System Analysis and Design/Information gathering

Case Study

Preparation of mess bill


Stores issue and ordering system
Menu planning
Data base of hostel residents.
They requested me to begin a feasibility study and provide a cost-benefit analysis of the
above systems.
End of Fact Gathering and Requirements Specification Phase.

V. Rajaraman/IISc

M3/V1/July 2004/10

System Analysis and Design

Mini Project

Mini Project Suggestion (Module 3)

1. Talk to your medical shop owner and find out what his information requirements
are. Divide it into operational, tactical, strategic and statutory components.
Describe how his operational and tactical information needs could be satisfied if
he installs a PC.
2. Go to a small hospital or nursing home in your neighbourhood and find out what
their information needs are. Classify them into operational, tactical, statutory and
strategic components.
3. Talk to your college registrar/administrative officer and staff. Find out their
information needs. How are they currently fulfilled?

V. Rajaraman/IISc

//V1/July 2004/1

You might also like