Learning Material - System Analysis and Design
Learning Material - System Analysis and Design
Syllabus
V.Rajaraman/IISc, Bangalore
V1/1-6-04/1
Syllabus
V.Rajaraman/IISc, Bangalore
V1/1-6-04/2
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
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
6. Structured
systems analysis
and design
7. Data oriented
systems design
8. Data input
methods
9. Designing
outputs
10. Object
oriented systems
modeling
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
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
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
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
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
V.Rajaraman
SAD/M1/LU1/V1/2004
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
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
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
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
V.Rajaraman
SAD/M1/LU2/V1/2004
Management Structure
(Contd)
Middle Management
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
SAD/M1/LU3/V1/2004
V.Rajaraman
SAD/M1/LU3/V1/2004
SAD/M1/LU3/V1/2004
V.Rajaraman
SAD/M1/LU3/V1/2004
SAD/M1/LU3/V1/2004
SAD/M1/LU3/V1/2004
SAD/M1/LU3/V1/2004
SAD/M1/LU3/V1/2004
10
SAD/M1/LU3/V1/2004
11
V.Rajaraman
SAD/M1/LU3/V1/2004
12
V.Rajaraman
SAD/M1/LU3/V1/2004
13
SAD/M1/LU3/V1/2004
14
V.Rajaraman
SAD/M1/LU3/V1/2004
15
SAD/M1/LU3/V1/2004
16
Operational Information
Routine assessment.
Skills inventory.
Loan/advances and recoveries.
Leave record.
V.Rajaraman
SAD/M1/LU3/V1/2004
17
SAD/M1/LU3/V1/2004
18
SAD/M1/LU3/V1/2004
19
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
Accurate
Complete
Timely
V.Rajaraman
SAD/M1/LU4/V1/2004
Qualities of Information
Quality
Trustworthy
Relevant
Brief
Summarize relevant
information.
V.Rajaraman
SAD/M1/LU4/V1/2004
Qualities of Information
Quality
Up-to-date
Significance
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
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
V.Rajaraman
SAD/M1/LU5/V1/2004
V.Rajaraman
SAD/M1/LU5/V1/2004
SAD/M1/LU5/V1/2004
10
Learning Objectives
Learning Objectives
V. Rajaraman/IISc. Bangalore
//V1/June 04/1
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
V.Rajaraman
SAD/M2/LU1/V1/2004
V.Rajaraman
SAD/M2/LU1/V1/2004
V.Rajaraman
SAD/M2/LU1/V1/2004
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004
V.Rajaraman
V.Rajaraman
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004
V.Rajaraman
V.Rajaraman
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004
V.Rajaraman
V.Rajaraman
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004
V.Rajaraman
V.Rajaraman
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004
V.Rajaraman
V.Rajaraman
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004
V.Rajaraman
V.Rajaraman
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004
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
Improved System
SAD/M2/LU2/V1/2004
SAD/M2/LU2/V1/2004
V.Rajaraman
SAD/M2/LU3/V1/2004
V.Rajaraman
SAD/M2/LU3/V1/2004
V.Rajaraman
SAD/M2/LU3/V1/2004
V.Rajaraman
SAD/M2/LU3/V1/2004
V.Rajaraman
SAD/M2/LU3/V1/2004
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
SAD/M2/LU3/V1/2004
V.Rajaraman
SAD/M2/LU3/V1/2004
V.Rajaraman
SAD/M2/LU3/V1/2004
Learning Objectives
Learning Objectives
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
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.
V. Rajaraman
//V1/July 04/1
Information
Gathering Strategies
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
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
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
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
Vendor
Delivery note
Discrepancy
note
Inspection office
Items
Received
note
Purchase Office
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
SAD/M3/LU3/V1/2004
12
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
Vendor
Delivery
note
Receiving
Process
Items
Received
note
Orders
Inspection
Office
Purchase
Office
Discrepancy
note
V. Rajaraman
SAD/M3/LU3/V1/2004
15
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
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
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
Learning Objectives
Learning Objectives
How to prepare a system proposal for the potential users of the system
V. Rajaraman/IISc. Bangalore
//V1/June 04/1
Motivation
Motivation
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
V.Rajaraman
SAD/M4/LU1/V1/2004
V.Rajaraman
SAD/M4/LU1/V1/2004
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
SAD/M4/LU1/V1/2004
11
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.)
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
V.Rajaraman
SAD/M4/LU1/V1/2004
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
70,000
+60,000 =1,30,000
V.Rajaraman
SAD/M4/LU1/V1/2004
SAD/M4/LU1/V1/2004
V.Rajaraman
SAD/M4/LU1/V1/2004
SAD/M4/LU1/V1/2004
SAD/M4/LU1/V1/2004
Learning Objectives
Learning Objectives
V. Rajaraman/IISc. Bangalore
//V1/June 04/1
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
SAD/M5/LU1/V1/2004
1.
STORES Issue Advice
Delivery slip
SAD/M5/LU1/V1/2004
VENDOR
Invoice
Order
Customer
Bill
V.Rajaraman
SAD/M5/LU1/V1/2004
Writing
Reading
SAD/M5/LU1/V1/2004
SAD/M5/LU1/V1/2004
A Process
A Data store
DS1
Inventory
Label
Nam
e
Nam
e
Label
V.Rajaraman
SAD/M5/LU1/V1/2004
V.Rajaraman
SAD/M5/LU1/V1/2004
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
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
V.Rajaraman
V.Rajaraman
SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004
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
V.Rajaraman
SAD/M5/LU2/V1/2004
SAD/M5/LU2/V1/2004
Vendors
Order nonperishable
2
Stores issue
and
Control
system
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
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
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
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
Compare
Standard daily 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
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
SAD/M5/LU3/V1/2004
Token
Clerk
Customer
Cheque
Token
Verify A/C
Signature
Update
Balance
Cashier
Verify Token
Bad Cheque
Entry in
Day Book
Customer
Accounts
V.Rajaraman
SAD/M5/LU3/V1/2004
Retrieve
Customer
Record
Cheque
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
Learning Objectives
Learning Objectives
V. Rajaraman/IISc. Bangalore
//V1/June 04/1
Motivation
Motivation
Notation used must be appropriate for the type of the application to be modeled.
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
V.Rajaraman
SAD/M6/LU1/V1/2004
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
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
V.Rajaraman
SAD/M6/LU2/V1/2004
Easy
V.Rajaraman
SAD/M6/LU2/V1/2004
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
A1: Classify as A
A2: Classify as B
A3: Classify as C
ACTIONS
SAD/M6/LU2/V1/2004
Decision Table
Notation Explained
CONDITION
STUB
CONDITION ENTRIES
ACTION
STUB
ACTION ENTRIES
RULE
SAD/M6/LU2/V1/2004
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
SAD/M6/LU2/V1/2004
R1
R2
R3
R4
X
X
X
-
SAD/M6/LU2/V1/2004
10
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
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%
SAD/M6/LU2/V1/2004
12
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
Decision table3
Complete departmental
Course
1 yr since last increment
Advance to next salary
point
No promotion
V.Rajaraman
Y
else
Y
X
SAD/M6/LU2/V1/2004
14
14
Rl
Y
-
R2
.
Y
Al
A2 :
X
-
V.Rajaraman
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
C2
A2
Al
A1,A2
SAD/M6/LU3/V1/2004
SAD/M6/LU3/V1/2004
Use Of
Karnaugh Maps
Decision table-Grading steel
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
SAD/M6/LU3/V1/2004
11
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*
SAD/M6/LU3/V1/2004
13
Karnaugh Map
m>0
C1,C2 dependent
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
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
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.)
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
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
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
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
SAD/M6/LU4/V1/2004
SAD/M6/LU4/V1/2004
12
12
Decision Trees
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
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
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
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
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
//V1/June 04/1
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
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
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
Worked Examples
6.7
V. Rajaraman/IISc. Bangalore
//V1/June 04/5
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
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
Worked Examples
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.
Y
Y
X
//V1/June 04/7
Return amount
No stamp light on
Dispense stamp
Go to Table 2
Stop
Worked Examples
X
X
X
X
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.
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
R16
Y
Y
Y
Y
?
//V1/June 04/8
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
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
(ii)
(iii)
(iv)
(v)
(vi)
Worked Examples
N
Y
Y
N
N
Y
N
Y
N
N
Y
Y
N
N
Y
A1 A2 A3 A1 A4 A5 A1 A6 A5
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
C2
C3
V. Rajaraman/IISc. Bangalore
C4
C5
//V1/June 04/10
Worked Examples
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
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
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.
Supply requirement
//V1/June 04/12
Worked Examples
C2
Y
C1
N
Y
N
C2
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
C3
Y
N
N
C2
Y
C1
N
C3
N
C4
Y
Leave
Leave
Observe that C1 is not relevant and not clear in the Decision tree
V. Rajaraman/IISc. Bangalore
//V1/June 04/13
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
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
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
V. Rajaraman/IISc. Bangalore
//V1/June 04/16
Learning Objectives
Learning Objectives
V. Rajaraman/IISc. Bangalore
//V1/June 04/1
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
SAD/M7/LU1/V1/2004
How is Data
Dictionary Developed?
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
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
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
SAD/M7/LU1/V1/2004
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
SAD/M7/LU1/V1/2004
14
V.Rajaraman
SAD/M7/LU2/V1/2004
Error Sources
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
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
Address
Tick as applicable
Individual
Hindu undivided family
Parent/Guardian of minor
V.Rajaraman
SAD/M7/LU2/V1/2004
Enter date
(Good design)
V.Rajaraman
Enter time
Hr Min Sec
Enter time
(Good design)
(Bad design)
SAD/M7/LU2/V1/2004
Smt
1
Kum
2
Name
Only address (do not
Repeat name)
V.Rajaraman
Pin
SAD/M7/LU2/V1/2004
Hindu undivided
family
Parent or guardian
Of minor
SAD/M7/LU2/V1/2004
SAD/M7/LU2/V1/2004
10
SAD/M7/LU2/V1/2004
11
V.Rajaraman
SAD/M7/LU2/V1/2004
12
SAD/M7/LU2/V1/2004
13
V.Rajaraman
LAST NAME
SAD/M7/LU2/V1/2004
14
Dept code
CE
CS
ME EE IT
Year
Hostel code
CODES
B
C
V.Rajaraman
SAD/M7/LU2/V1/2004
15
16
SAD/M7/LU2/V1/2004
17
SAD/M7/LU3/V1/2004
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
V.Rajaraman
Cotton
SAD/M7/LU3/V1/2004
Style
Color
(Round (blue)
neck)
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
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
(Widi ) = (Widi ) + t Wk - Wk dk
i=1
i=1
V.Rajaraman
SAD/M7/LU3/V1/2004
10
SAD/M7/LU3/V1/2004
11
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
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
26 letters
10 digits
36 symbols
Therefore n=37.
V.Rajaraman
SAD/M7/LU3/V1/2004
14
SAD/M7/LU3/V1/2004
15
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
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
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
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
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
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
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
Verb
RELATIONSHIP
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
V.Rajaraman
10
V.Rajaraman
Relation Cardinality
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
V.Rajaraman
12
V.Rajaraman
Relation Cardinality
Representation
vendor
vendor
N
supplies
N
supplies
6
items
items
vendor
2
supplies
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
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
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
V.Rajaraman
SAD/M8/LU3/V1/2004
10
Functional
Dependency (Contd.)
Therefore Item code
Item name
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
V.Rajaraman
SAD/M8/LU3/V1/2004
12
Dependency Diagram
Qty.supplied
Vendor code
Date of supply
Item code
Price/unit
Composite key
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
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
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
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
V.Rajaraman
SAD/M8/LU3/V1/2004
31
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
New relations
Professor (Prof code, Dept, Percent time )
Department ( Dept, Head of Dept)
V.Rajaraman
SAD/M8/LU3/V1/2004
33
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
SAD/M8/LU3/V1/2004
34
SAD/M8/LU3/V1/2004
35
Vendor
Project
Items
Item
P
Multivalued dependency
V.Rajaraman
SAD/M8/LU3/V1/2004
36
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
SAD/M8/LU3/V1/2004
39
V.Rajaraman
SAD/M8/LU3/V1/2004
40
SAD/M8/LU3/V1/2004
41
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
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
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
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
V.Rajaraman
SAD/M8/LU6/V1/2004
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
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
V.Rajaraman
V.Rajaraman
SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004
2
2
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 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
Vendor id
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
V.Rajaraman
V.Rajaraman
SAD/M9/LU1/V1/2004
SAD/M9/LU1/V1/2004
8
8
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
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
V.Rajaraman
SAD/M9/LU2/V1/2004
V.Rajaraman
SAD/M9/LU2/V1/2004
V.Rajaraman
SAD/M9/LU2/V1/2004
V.Rajaraman
SAD/M9/LU2/V1/2004
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)
SAD/M9/LU2/V1/2004
Example 1
Identification Of Objects
ANSWERS FOR EXAMPLE 1
1.
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
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
V.Rajaraman
SAD/M9/LU2/V1/2004
14
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
SAD/M9/LU2/V1/2004
17
Is Part of
DELIVERY
NOTE
V.Rajaraman
ORDER TO
VENDOR
SAD/M9/LU2/V1/2004
18
V.Rajaraman
SAD/M9/LU2/V1/2004
19
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
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
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
SAD/M9/LU3/V1/2004
SAD/M9/LU3/V1/2004
SAD/M9/LU3/V1/2004
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
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
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
V. Rajaraman
SAD/M10/LU1/V1/2004
Laser printer
Non-Impact
V. Rajaraman
Inkjet printer
SAD/M10/LU1/V1/2004
Printer Characteristics
Line Printers
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
V. Rajaraman
SAD/M10/LU1/V1/2004
V. Rajaraman
SAD/M10/LU1/V1/2004
V. Rajaraman
SAD/M10/LU1/V1/2004
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
V. Rajaraman
SAD/M10/LU1/V1/2004
11
V. Rajaraman
SAD/M10/LU1/V1/2004
12
V.Rajaraman
SAD/M10/LU2/V1/2004
V.Rajaraman
SAD/M10/LU2/V1/2004
V.Rajaraman
SAD/M10/LU2/V1/2004
V.Rajaraman
SAD/M10/LU2/V1/2004
SAD/M10/LU2/V1/2004
V.Rajaraman
SAD/M10/LU2/V1/2004
V.Rajaraman
SAD/M10/LU3/V1/2004
V.Rajaraman
SAD/M10/LU3/V1/2004
V.Rajaraman
SAD/M10/LU3/V1/2004
Example Of Terminology
Report heading
Page heading
Control heading
Detail lines
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
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
V.Rajaraman
SAD/M10/LU3/V1/2004
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
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
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
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
Motivation
V. Rajaraman/IISc. Bangalore
//V1/July 04/1
Motivation
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
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
(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
V.Rajaraman
SAD/M11/LU1/V1/2004
V.Rajaraman
SAD/M11/LU1/V1/2004
V.Rajaraman
SAD/M11/LU1/V1/2004
10
V.Rajaraman
SAD/M11/LU1/V1/2004
11
Protocol used
Domain name
Of server
Having web page
Folder with
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
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
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
V.Rajaraman
SAD/M11/LU2/V1/2004
These are primarily for linear texts and not meant for linked text
known as hypertext
V.Rajaraman
SAD/M11/LU2/V1/2004
Each document called a web page. Each web page has a unique
path to retrieve it.
V.Rajaraman
SAD/M11/LU2/V1/2004
V.Rajaraman
SAD/M11/LU2/V1/2004
V.Rajaraman
SAD/M11/LU2/V1/2004
V.Rajaraman
SAD/M11/LU2/V1/2004
V.Rajaraman
SAD/M11/LU2/V1/2004
10
V.Rajaraman
SAD/M11/LU2/V1/2004
11
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
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
V.Rajaraman
SAD/M11/LU2/V1/2004
16
SAD/M11/LU2/V1/2004
17
SAD/M11/LU2/V1/2004
18
<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
SAD/M11/LU2/V1/2004
20
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
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
V.Rajaraman
SAD/M11/LU2/V1/2004
23
SAD/M11/LU2/V1/2004
24
SAD/M11/LU2/V1/2004
25
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
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
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
V.Rajaraman
SAD/M12/LU2/V1/2004
V.Rajaraman
SAD/M12/LU2/V1/2004
V.Rajaraman
SAD/M12/LU2/V1/2004
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
V.Rajaraman
SAD/M12/LU3/V1/2004
SAD/M12/LU3/V1/2004
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
V.Rajaraman
SAD/M12/LU3/V1/2004
SAD/M12/LU4/V1/2004
V.Rajaraman
SAD/M12/LU4/V1/2004
V.Rajaraman
SAD/M12/LU4/V1/2004
V.Rajaraman
SAD/M12/LU4/V1/2004
V.Rajaraman
SAD/M12/LU4/V1/2004
V.Rajaraman
SAD/M12/LU4/V1/2004
reliability of
V.Rajaraman
SAD/M12/LU4/V1/2004
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
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
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
LAN of buisness2
LAN of buisness1
PSTN or
LEASED LINE
Vendor
Local computers
V.Rajaraman
M13/LU1/V1/2004
V.Rajaraman
M13/LU1/V1/2004
V.Rajaraman
M13/LU1/V1/2004
M13/LU1/V1/2004
V.Rajaraman
M13/LU1/V1/2004
V.Rajaraman
M13/LU1/V1/2004
Internet
Customer1
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
SERVICES IN LAYER
Application layer
B2B,B2C,C2C
Middleman services
Secure messaging
Encryption,EDI,Firewalls
HTTP,HTML,XML,OLE
Software agents
Intranet,internet,extranet
Physical network
PSTN,LAN,Bridges,routers
Layered architecture
V.Rajaraman
M13/LU1/V1/2004
14
M13/LU2/V1/2004
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
M13/LU2/V1/2004
M13/LU2/V1/2004
M13/LU2/V1/2004
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
V.Rajaraman
M13/LU3/V1/2004
M13/LU3/V1/2004
M13/LU3/V1/2004
V.Rajaraman
M13/LU3/V1/2004
M13/LU3/V1/2004
V.Rajaraman
M13/LU3/V1/2004
V.Rajaraman
M13/LU3/V1/2004
V.Rajaraman
M13/LU3/V1/2004
10
This Is A Message X
Substitute character by
the one 4 letters away
(eg AE,ZD)
Cipher Text
M13/LU3/V1/2004
11
Symmetric Encryption.
PLAINTEXT
(m1,m2mn )
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
V.Rajaraman
M13/LU3/V1/2004
14
11011000
11011010
K = KEY
10101111
00101100
01011011
E= M+K
11000011
11110100
10000001 encryption
M= E + K
01101100
11011000
11011010 decryption
V.Rajaraman
M13/LU3/V1/2004
15
V.Rajaraman
M13/LU3/V1/2004
16
Encryption method
M13/LU3/V1/2004
17
V.Rajaraman
M13/LU3/V1/2004
18
V.Rajaraman
M13/LU3/V1/2004
19
M13/LU3/V1/2004
20
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
R3
K16
.
.
.
.
P16
.
.
.
.
.
Left circular
shift
Left circular
shift
+
R16
IP-1
V.Rajaraman
M13/LU3/V1/2004
22
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
M13/LU3/V1/2004
23
DES Chip
64
Input block
Key
DES
CHIP
64
Encrypted
Block
56
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
V.Rajaraman
M13/LU3/V1/2004
31
V.Rajaraman
M13/LU3/V1/2004
32
M13/LU3/V1/2004
33
V.Rajaraman
M13/LU3/V1/2004
34
V.Rajaraman
M13/LU3/V1/2004
35
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
V.Rajaraman
M13/LU3/V1/2004
37
cd (mod n) =t
V.Rajaraman
M13/LU3/V1/2004
38
M13/LU3/V1/2004
39
V.Rajaraman
M13/LU3/V1/2004
40
M13/LU3/V1/2004
41
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
V.Rajaraman
M13/LU3/V1/2004
45
V.Rajaraman
M13/LU3/V1/2004
46
KEY
SENDER
PLAIN TEXT
ENCRYPT
DECRYPT
DES
DES
RECOVERED
KEY
RECEIVER
PLAIN
TEXT
CIPHER
TEXT
V.Rajaraman
M13/LU3/V1/2004
47
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
M13/LU3/V1/2004
51
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
V.Rajaraman
M13/LU3/V1/2004
53
V.Rajaraman
M13/LU3/V1/2004
54
M13/LU4/V1/2004
V.Rajaraman
M13/LU4/V1/2004
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
Customer
Merchant
Step5
Step 4
Step2 Step6
Acquirer
Step3
Issuing bank
Step3
Step6
M13/LU4/V1/2004
M13/LU4/V1/2004
M13/LU4/V1/2004
M13/LU4/V1/2004
M13/LU4/V1/2004
10
V.Rajaraman
M13/LU4/V1/2004
11
M13/LU4/V1/2004
12
M13/LU4/V1/2004
13
V.Rajaraman
M13/LU4/V1/2004
14
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
M13/LU4/V1/2004
15
M13/LU4/V1/2004
16
M13/LU4/V1/2004
17
Step2
Step5
Step6
Customer
Acquirer
Step3
Bank
Step4
Step 7
V.Rajaraman
M13/LU4/V1/2004
18
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
M13/LU4/V1/2004
20
V.Rajaraman
M13/LU4/V1/2004
21
M13/LU4/V1/2004
22
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
V.Rajaraman
M13/LU4/V1/2004
24
M13/LU4/V1/2004
25
Customer
1.
2.
3.
4.
5.
6.
7.
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
V.Rajaraman
M13/LU4/V1/2004
27
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
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
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
M2/V1/July 2004/1
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)
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)
M2/V1/July 2004/2
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
Question Bank
QUESTION BANK
3.1
3.2
3.3
3.4
3.5
3.6
3.7
3.8
3.9
3.10
3.11
3.12
V. Rajaraman/IISc
M3/V1/July 2004/1
Question Bank
MODULE 3
CASE
STUDY -
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.
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
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.
The priority order of the Chief Warden is: control inventory, control stores issues,
ensure speedy bill collection, student data base.
The Chief Warden wants me to talk to assistant wardens, mess supervisors and
students' mess committee members.
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
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:
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.
Monthly payment.
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
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.
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/12043
Rs.46.50
M3/V1/July 2004/5
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
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 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
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
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 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.
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.
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
Question Bank
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.
V. Rajaraman/IISc
M3/V1/July 2004/10
Question Bank
Issue of exact quantities of items to cooks based on menu and number of students.
Consolidating purchases to reduce frequent trips for purchase and reducing cartage
charges.
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
Case Study
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
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
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.
The record format for a reorder request would be: item code, item name)
V. Rajaraman/IISc
M1/V1/July 2004/3
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.
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.
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.
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
Case Study
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.
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
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:
V. Rajaraman/IISc
M1/V1/July 2004/6
Case Study
Using these one may formulate some rules to arrive at the credit limits and also predict
their possible effect such as:
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.
V. Rajaraman/IISc
M1/V1/July 2004/7
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
V. Rajaraman/IISc
M1/V1/July 2004/8
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
Worked Examples
WORKED EXAMPLES
Employee No
V. Rajaraman/IISc. Bangalore
1
Compute
Gross pay
//V1/June 04/1
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
Fig 5.7(d)
a
A
b
2
P2
c
d
3
P3
V. Rajaraman/IISc. Bangalore
1
P1
C
//V1/June 04/2
Worked Examples
Fig 5.7(e)
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
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.
V. Rajaraman/IISc. Bangalore
//V1/June 04/1
Worked Examples
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
//V1/June 04/2
Worked Examples
4.10
V. Rajaraman/IISc. Bangalore
//V1/June 04/3
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
Worked Examples
Worked Examples
3.1)
3.2)
3.3)
3.4)
V. Rajaraman/IISc
M3/V1/July 2004/1
3.5)
Worked Examples
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
Case Study
M3/V1/July 2004/1
Case Study
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
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
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
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
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
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
V. Rajaraman/IISc
Case Study
M3/V1/July 2004/8
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
Case Study
V. Rajaraman/IISc
M3/V1/July 2004/10
Mini Project
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