Software Engineering Unit 2
Software Engineering Unit 2
Software Requirement
Specification
Topics to be covered
• What are Software Requirements? Types of S/W Requirements.
• Requirement Engineering Process: Elicitation, Analysis, Documentation,
Review and Management of User Needs, Feasibility Study
• Information Modelling,
• Data Flow Diagrams,
• Entity Relationship Diagrams,
• Decision Tables,
• SRS Document,
• IEEE Standards for SRS.
• Software Quality Assurance (SQA): Verification and Validation, SQA Plans,
Software Quality Frameworks, ISO 9000 Models, SEI-CMM Model.
Classification of Software
Requirements
• According to IEEE standard 729, a requirement is defined as follows:
• A condition or capability needed by a user to solve a problem or achieve an
objective
• A condition or capability that must be met or possessed by a system or
system component to satisfy a contract, standard, specification or other
formally imposed documents
• A documented representation of a condition or capability as in 1 and 2.
• A software requirement can be of :
• Functional requirements
• Non-functional requirements
• Interface Requirements
• Inverse Requirements
• Design and Constraints Requirements
Functional Requirements
• These are the requirements that the end user specifically demands as
basic facilities that the system should offer.
• All these functionalities need to be necessarily incorporated into the
system as a part of the contract.
• These are represented or stated in the form of input to be given to the
system, the operation performed, and the output expected.
• They are basically the requirements stated by the user which one can
see directly in the final product, unlike the non-functional requirements.
• Each high-level functional requirement may involve several interactions
or dialogues between the system and the outside world. In order to
accurately describe the functional requirements, all scenarios must be
enumerated.
• There are many ways of expressing functional requirements e.g., natural
language, a structured or formatted language with no rigorous syntax
and formal specification language with proper syntax.
Non-Functional Requirements
• These are basically the quality constraints that the system must satisfy
according to the project contract. The priority or extent to which these
factors are implemented varies from one project to other. They are also
called non-behavioral requirements.
They basically deal with issues like:
• Portability
• Security
• Maintainability
• Reliability
• Scalability
• Performance
• Reusability
• Flexibility
Non-Functional Requirements
• NFR’s are classified into following types:
• Interface constraints
• Performance constraints: response time, security, storage space, etc.
• Operating constraints
• Life cycle constraints: maintainability,
Click to add text portability, etc.
• Economic constraints
• The process of specifying non-functional requirements requires the knowledge
of the functionality of the system, as well as the knowledge of the context
within which the system will operate.
Difference between Functional Requirement
and Non-functional Requirement
Interface Requirements
•Systems must operate with other systems and the operating interfaces must be specified as
part of requirements. It includes:
1. User Interface
2. Communication Interface
3. Software Interface
4. Hardware Interface
1. User Interface: Describe the logical characteristics of each user interface that the system
needs. Example includes GUI, CLI (Command line Interface), API (Application Program
Interface) etc.
2. Communication Interface: State the requirements for any communication functions the
product will use, including e-mail, Web browser, network communications protocols, and
electronic forms. Define any pertinent message formatting. Specify communication security
or encryption issues, data transfer rates, and synchronization mechanisms.
Interface Requirements
3. Software Interface: Describe the connections between this product and other software components
(identified by name and version), including databases, operating systems, tools, libraries, and
integrated commercial components. State the purpose of the messages, data, and control items
exchanged between the software components. Describe the services needed by external software
components and the nature of the inter-component communications. Identify data that will be shared
across software components. If the data-sharing mechanism must be implemented in a specific way,
such as a global data area, specify this as a constraint.
4. Hardware Interface: Describe the characteristics of each interface between the software and
hardware components of the system. This description might include the supported device types, the
data and control interactions between the software and the hardware, and the communication
protocols to be used.
Interface Requirements
5. Inverse Requirements
•Inverse requirements specify the constraints on allowable behavior. Software safety and security
requirements are usually stated in this manner. Inverse requirements can be functional and
nonfunctional. For example: When a customer specifies that something must not be done. For
example, User ID should only contain digits.
Design and Implementation
Requirements
6. Design and Implementation Requirements
Design constraints and implementation constraints are boundary conditions on how the required
software is to be constructed and implemented. Examples of design constraints include the fact that
the software must run using a certain database system or that the software must fit into the
memory of a 512 Kbyte machine.
WORST NIGHTMARE:A Customer walks into your office , sits
down, looks you straight in the eye, and says, “I know you
think you understand what I said, but what you don’t
understand is what I said is not what I mean”
Finding Actors
• Entity
• Entity Type
• Entity Set
• An Entity may be an object with a physical existence – a particular person, car,
house, or employee – or it may be an object with a conceptual existence – a
company, a job, or a university course.
• An Entity is an object of Entity Type and set of all entities is called as entity
set. e.g.; E1 is an entity having Entity Type Student and set of all students is
called Entity Set. In ER diagram, Entity Type is represented as:
E-R Model
• Attributes are the properties which define the entity type. For
example, Roll_No, Name, DOB, Age, Address, Mobile_No are the
attributes which defines entity type Student. In ER diagram, attribute is
represented by an oval.
• The multi-valued attribute consisting more than one value for a given
entity. For example, Phone_No (can be more than one for a given
student). In ER diagram, multivalued attribute is represented by double
oval.
E-R Model
• An attribute composed of many other attribute is called as composite
attribute. For example, Address attribute of student Entity type consists of
Street, City, State, and Country. In ER diagram, composite attribute is
represented by an oval comprising of ovals.
E-R Model
• An attribute which can be derived from other attributes of the entity type
is known as derived attribute. e.g.; Age (can be derived from DOB). In ER
diagram, derived attribute is represented by dashed oval.
• The complete entity type Student with its attributes can be represented as:
Relationships in E-R Model
• The number of participating entities in a relationship describes the degree of the
relationship. The three most common relationships in E-R models are:
1. Unary (degree1)
2. Binary (degree2)
3. Ternary (degree3)
Condition
Stub Rules
Stub
Action Entries
Stub Stub
Developing Decision Tables
Loyality N N Y Y N N
Card (10%)
Coupon Y N Y N Y N
(20%)
ACTIONS
NO X
DISCOUN
T
20% X
15% X
30% X
10% X
20% X
Another Example
• In this example a company is trying to maintain a meaningful mailing
list of customers. The objective is to send out only the catalogs from
which customers will buy merchandise.
• The managers realize that certain loyal customers order from every
catalog and that some people on the mailing list never order. These
ordering patterns are easy to observe, but deciding which catalogs to
send customers who order only from selected catalogs is more difficult.
Once these decisions are made, a decision table is constructed for
three conditions (C1: customer ordered from Fall catalog; C2: customer
ordered from Christmas catalog; and C3: customer ordered from
specialty catalog), each having two alternatives (Y or N).
Solution
Decision Table
For example: A bookstore get a trade discount of
25% for order more then 6 books; for order from
libraries and individuals, 5% allowed on orders
of 6-19 copies per book title; 10% on orders for
20-49 copies per book title; 15% on orders for 50
copies or more per book title.
Cleaning Things Up
• Check the table for any impossible situations, contradictions, and
redundancies and eliminate such rules
• Rewrite the decision table with the most reduced set of rules;
rearranging the rule order is permissible if it improves user
understanding
Decision Table example:
combine and reduce
Y N Y Y Y N N N
Y Y Y N N N Y N
Y Y N N Y Y N N
1 5 1&5 2 4 2&4 3 7 3&7 6 8 6&8
Y N - Y Y Y Y N - N N N
Y Y Y Y N - N N N Y N -
Y Y Y N N N Y Y Y N N N
2&4 6&8 2,4,6 & 8
Y N -
- - -
N N N
X X X
Conditions and Actions 1& 5 3 & 7 2,4 6,8
• Auditing: Auditing involves inspection of the work products and its related information to determine if the set
of standard processes were followed or not.
• Reviewing: A meeting in which the software product is examined by both the internal and external
stakeholders to seek their comments and approval.
• Code Inspection: It is the most formal kind of review that does static testing to find bugs and avoid defect
growth in the later stages. It is done by a trained mediator/peer and is based on rules, checklist, entry and
exit criteria. The reviewer should not be the author of the code.
• Design Inspection: Design inspection is done using a checklist that inspects the below areas of software
design:
• General requirements and design
• Functional and Interface specifications
• Conventions
• Requirement traceability
• Structures and interfaces
• Logic
• Performance
• Error handling and recovery
• Testability, extensibility
• Coupling and cohesion
SQA Techniques
• Simulation: Simulation is a tool that models the real-life situation in order to virtually examine
the behavior of the system under study.
• Functional Testing: It is a QA technique which verifies what the system does without
considering how it does. This type of black box testing mainly focuses on testing the system
specifications or features.
• Standardization: Standardization plays a crucial role in quality assurance. It decreases the
ambiguity and guesswork, thus ensuring quality.
• Static Analysis: It is a software analysis that is done by an automated tool without actually
executing the program. This technique is highly used for quality assurance in medical, nuclear
and aviation software. Software metrics and reverse engineering are some popular forms of
static analysis.
SQA Techniques
• Walkthroughs: Software walkthrough or code walkthrough is a kind of peer review where the
developer guides the members of the development team to go through the product and raise
queries, suggest alternatives, make comments regarding possible errors, standard violations or
any other issues.
• Path Testing: It is a white box testing techniques where the complete branch coverage is ensured
by executing each independent path at least once.
• Stress Testing: This type of testing is done to check how robust a system is by testing it under
heavy load i.e. beyond normal conditions.
• Six Sigma: Six Sigma is a quality assurance approach that aims at nearly perfect products or
services. It is widely applied in many fields including software. The main objective of six sigma is
process improvement so that the produced software is 99.76 % defect free.
(define,measure,analyse,improve,control
ISO
• ISO 9000 is defined as a set of international standards on quality management
and quality assurance developed to help companies effectively document the
quality system elements needed to maintain an efficient quality system.
• Refer this link: ISO .
• They are not specific to any one industry and can be applied to organizations of
any size.
• ISO 9000 can help a company satisfy its customers, meet regulatory
requirements, and achieve continual improvement.
• It should be considered as first step or the base level of a quality system.
The ISO Approach to Quality
Assurance Systems
• ISO 9000 describes the elements of a quality assurance system in general terms.
• These elements include the organizational structure, procedures, processes, and resources
needed to implement quality planning, quality control, quality assurance, and quality
improvement.
• However, ISO 9000 does not describe how an organization should implement these quality system
elements.
• Consequently, the challenge lies in designing and implementing a quality assurance system that
meets the standard and fits the company’s products, services, and culture.
The ISO 9001 Standard
• ISO 9001 is the quality assurance standard that applies to software engineering.
• The standard contains 20 requirements that must be present for an effective quality assurance system.
• Because the ISO 9001 standard is applicable to all engineering disciplines, a special set of ISO guidelines have
been developed to help interpret the standard for use in the software process.
• The requirements defined by ISO 9001 address topics such as
• management responsibility,
• quality system,
• contract review,
• design control,
• document and data control,
• product identification and
• traceability,
• process control,
• inspection and testing,
• corrective and preventive action,
• control of quality records,
• internal quality audits,
• training, servicing, and
• statistical techniques.
The ISO 9001 Standard
• The software organization registered to ISO 9001, it must establish policies and procedures to
address each of the requirements just noted (and others) and then be able to demonstrate that
these policies and procedures are being followed.
• ISO/IEC (International Electrotechnical Commission) 9126 Software engineering — Product quality was an
international standard for the evaluation of software quality. It has been replaced by
ISO/IEC 25010:2011.
Capability Maturity Model
• CMM was developed by the Software Engineering Institute (SEI) at Carnegie Mellon University in
1987.
• It is not a software process model. It is a framework which is used to analyze the approach
and techniques followed by any organization to develop a software product.
• It also provides guidelines to further enhance the maturity of those software products.
• It is based on profound feedback and development practices adopted by the most successful
organizations worldwide.
• This model describes a strategy that should be followed by moving through 5 different levels.
• Each level of maturity shows a process capability level. All the levels except level-1 are
further described by Key Process Areas (KPA’s).
Key Process Area
• Each of these KPA’s defines the basic requirements that should be met by a software process in
order to satisfy the KPA and achieve that level of maturity.
• Conceptually, key process areas form the basis for management control of the software project
and establish a context in which technical methods are applied, work products like models,
documents, data, reports, etc. are produced, milestones are established, quality is ensured, and
change is properly managed.
• The 5 levels of CMM are as follows:
• Initial
• Repeatable
• Defined
• Managed
• Optimized
Level-1: Initial
• No KPA’s defined.
• Processes followed are ad hoc and immature and are
not well defined.
• Unstable environment for software development.
• No basis for predicting product quality, time for
completion, etc.
Level-2: Repeatable
• Focuses on establishing basic project management policies.
• Experience with earlier projects is used for managing new similar natured projects.
• KPA’s:
• Project Planning- It includes defining resources required, goals, constraints, etc. for the
project. It presents a detailed plan to be followed systematically for successful completion of
a good quality software.
• Configuration Management- The focus is on maintaining the performance of the software
product, including all its components, for the entire lifecycle.
• Requirements Management- It includes the management of customer reviews and feedback
which result in some changes in the requirement set. It also consists of accommodation of
those modified requirements.
• Subcontract Management- It focuses on the effective management of qualified software
contractors i.e. it manages the parts of the software which are developed by third parties.
• Software Quality Assurance- It guarantees a good quality software product by following
certain rules and quality standard guidelines while development.
Level-3: Defined
• At this level, documentation of the standard guidelines and procedures takes place.
• It is a well-defined integrated set of project specific software engineering and management
processes.
• KPA’s:
• Peer Reviews- In this method, defects are removed by using several review methods like
walkthroughs, inspections, buddy checks, etc.
• Intergroup Coordination- It consists of planned interactions between different development
teams to ensure efficient and proper fulfilment of customer needs.
• Organization Process Definition- It’s key focus is on the development and maintenance of the
standard development processes.
• Organization Process Focus- It includes activities and practices that should be followed to
improve the process capabilities of an organization.
• Training Programs- It focuses on the enhancement of knowledge and skills of the team
members including the developers and ensuring an increase in work efficiency.
Level-4: Managed
• At this stage, quantitative quality goals are set for the organization for software products as well
as software processes.
• The measurements made help the organization to predict the product and process quality within
some limits defined quantitatively.
• KPA’s:
• Software Quality Management- It includes the establishment of plans and strategies to
develop a quantitative analysis and understanding of the product’s quality.
• Quantitative Management- It focuses on controlling the project performance in a quantitative
manner.
Level-5: Optimizing
• This is the highest level of process maturity in CMM and focuses on continuous process
improvement in the organization using quantitative feedback.
• Use of new tools, techniques and evaluation of software processes is done to prevent recurrence
of known defects.
• KPA’s:
• Process Change Management- Its focus is on the continuous improvement of organization’s
software processes to improve productivity, quality and cycle time for the software product.
• Technology Change Management- It consists of identification and use of new technologies to
improve product quality and decrease the product development time.
• Defect Prevention- It focuses on identification of causes of defects and to prevent them from
recurring in future projects by improving project defined process.
ISO CMM