Requirements Engineering in Software Development
Requirements Engineering in Software Development
Module - II
REQUIREMENTS ENGINEERING
The broad spectrum of tasks and techniques that lead to an understanding of
requirements is called requirements engineering. From a software process
perspective, requirements engineering is a major software engineering action that
begins during the communication activity and continues into the modeling activity.
It must be adapted to the needs of the process, the project, the product, and the
people doing the work.
Requirements engineering builds a bridge to design and construction.
Requirements engineering provides the appropriate mechanism for understanding
what the customer wants, analyzing need, assessing feasibility, negotiating a
reasonable solution, specifying the solution unambiguously, validating the
specification, and managing the requirements as they are transformed into an
operational system. It encompasses seven distinct tasks: inception, elicitation,
elaboration, negotiation, speci𝑓ication, validation, and management.
a) Inception. In general, most projects begin when a business need is identified or a potential
new market or service is discovered. Stakeholders from the business community define a
business case for the idea, try to identify the breadth and depth of the market, do a rough
feasibility analysis, and identify a working description of the project’s scope.
At project inception, you establish a basic understanding of the problem, the people who
want a solution, the nature of the solution that is desired, and the effectiveness of
preliminary communication and collaboration between the other stakeholders and the
software team.
b) Elicitation.
Ask the customer, what the objectives for the system or product are, what is to be
accomplished, how the system or product fits into the needs of the business, and finally,
how the system or product is to be used on a day-to-day basis. A number of problems that
are encountered as elicitation occurs.
Problems of scope. The boundary of the system is ill-defined or the customers/users
specify unnecessary technical detail that may confuse, rather than clarify, overall system
objectives.
Problems of understanding. The customers/users are not completely sure of what is
needed, have a poor understanding of the capabilities and limitations of their computing
environment, don’t have a full understanding of the problem domain, have trouble
communicating needs to the system engineer, omit information that is believed to be
“obvious,” specify requirements that conflict with the needs of other customers/users, or
specify requirements that are ambiguous or un testable.
Problems of volatility. The requirements change over time. To help overcome these
problems, you must approach requirements gathering in an organized manner.
c) Elaboration.
The information obtained from the customer during inception and elicitation is expanded
and refined during elaboration. This task focuses on developing a refined requirements
1
23ISI53- Software Engineering Principles and Testing Practices
model that identifies various aspects of software function, behavior, and information.
Elaboration is driven by the creation and refinement of user scenarios that describe how
the end user (and other actors) will interact with the system. Each user scenario is parsed
to extract analysis classes business domain entities that are visible to the end user.
The attributes of each analysis class are defined, and the services that are required by each
class are identified. The relationships and collaboration between classes are identified,
and a variety of supplementary diagrams are produced.
d) Negotiation.
It usual for customers, to given limited business resources. It’s also relatively common for
different customers or users to propose conflicting requirements, arguing that their
version is “essential for our special needs.”
o You have to reconcile these conflicts through a process of negotiation. Customers,
users, and other stakeholders are asked to rank requirements and then discuss
conflicts
o in priority. Using an iterative approach that prioritizes requirements, assesses their
cost and risk, and addresses internal conflicts, requirements are eliminated,
combined, and/or modified so that each party achieves some measure of
satisfaction.
e) Specification.
Specification means different things to different people. A specification can be a written
document, a set of graphical models, a formal mathematical model, a collection of usage
scenarios, a prototype, or any combination of these.
Some suggest that a “standard template” should be developed and used for a specifcation,
arguing that this leads to requirements that are presented in a consistent and therefore
more understandable manner. However, it is sometimes necessary to remain flexible
when a specification is to be developed.
For large systems, a written document, combining natural language descriptions and
graphical models may be the best approach.
In an ideal setting, stakeholders and software engineers work together on the same
team. In such cases, requirements engineering is simply a matter of conducting
meaningful conversations with colleagues who are well-known members of the
team.
2
23ISI53- Software Engineering Principles and Testing Practices
Identifying Stakeholders:
Stakeholder is “anyone who benefits in a direct or indirect way from the system which is
being developed.”
The usual stakeholders are: business operations managers, product managers, marketing
people, internal and external customers, end users, consultants, product engineers,
software engineers, support and maintenance engineers.
Each stakeholder has a different view of the system, achieves different benefits when the
system is successfully developed, and is open to different risks if the development effort
should fail.
3
23ISI53- Software Engineering Principles and Testing Practices
How would you characterize “good” output that would be generated by a successful
solution?
What problem(s) will this solution address?
Can you show me (or describe) the business environment in which the solution will be
used?
Will special performance issues or constraints affect the way the solution is approached?
o The final set of questions focuses on the effectiveness of the communication activity
itself.
Are you the right person to answer these questions? Are your answers “official”?
Are my questions relevant to the problem that you have?
Am I asking too many questions?
Can anyone else provide additional information?
Should I be asking you anything else?
These questions will help to “break the ice” and initiate the communication that is
essential to successful elicitation.
ELICITING REQUIREMENTS
Requirements elicitation combines elements of problem solving, elaboration, negotiation,
and specification.
4
23ISI53- Software Engineering Principles and Testing Practices
5
23ISI53- Software Engineering Principles and Testing Practices
6
23ISI53- Software Engineering Principles and Testing Practices
Scenario-based elements. The system is described from the user’s point of view using a
scenario-based approach. For example, basic use cases and their corresponding use-case
diagrams evolve into more elaborate template-based use cases. Scenario-based elements
of the requirements model are often the first part of the model that is developed. Three
levels of elaboration are shown, culminating in a scenario-based representation.
7
23ISI53- Software Engineering Principles and Testing Practices
Flow-oriented elements.
Information is transformed as it flows through a computer-based system. The system
accepts input in a variety of forms, applies functions to transform it, and produces
output in a variety of forms. Input may be a control signal transmitted by a transducer,
a series of numbers typed by a human operator, a packet of information transmitted
on a network link, or a voluminous data file retrieved from secondary storage. The
transform(s) may comprise a single logical comparison, a complex numerical
algorithm, or a rule-inference approach of an expert system.
Analysis Patterns:
Anyone who has done requirements engineering on more than a few software projects
begins to notice that certain problems reoccur across all projects within a specific
application domain. These analysis patterns suggest solutions (e.g., a class, a function,
a behavior) within the application domain that can be reused when modeling many
applications. Analysis patterns are integrated into the analysis model by reference to
the pattern name. They are also stored in a repository so that requirements engineers
can use search facilities to find and apply them. Information about an analysis pattern
(and other types of patterns) is presented in a standard template.
8
23ISI53- Software Engineering Principles and Testing Practices
NEGOTIATING REQUIREMENTS
In an ideal requirements engineering context, the inception, elicitation, and
elaboration tasks determine customer requirements in sufficient detail to proceed to
subsequent software engineering activities. You may have to enter into a negotiation
with one or more stakeholders. In most cases, stakeholders are asked to balance
functionality, performance, and other product or system characteristics against cost
and time-to-market. The intent of this negotiation is to develop a project plan that
meets stakeholder needs while at the same time reflecting the real- world constraints
(e.g., time, people, budget) that have been placed on the software team.
The best negotiations strive for a “win-win” result. That is, stakeholders win by getting
the system or product that satisfies the majority of their needs and you win by
working to realistic and achievable budgets and deadlines.
Boehm [Boe98] defines a set of negotiation activities at the beginning of each software
process iteration. Rather than a single customer communication activity, the following
activities are defined:
1. Identification of the system or subsystem’s key stakeholders.
2. Determination of the stakeholders’ “win conditions.”
3. Negotiation of the stakeholders’ win conditions to reconcile them into a set of win-win
conditions for all concerned.
VALIDATING REQUIREMENTS
As each element of the requirements model is created, it is examined for inconsistency,
omissions, and ambiguity. The requirements represented by the model are prioritized by
the stakeholders and grouped within requirements packages that will be implemented as
software increments. A review of the requirements model addresses the following
questions:
Is each requirement consistent with the overall objectives for the system/product?
Have all requirements been specified at the proper level of abstraction? That is, do
some requirements provide a level of technical detail that is inappropriate at this stage?
Is the requirement really necessary or does it represent an add-on feature that may
not be essential to the objective of the system?
Is each requirement bounded and unambiguous?
Does each requirement have attribution? That is, is a source noted for each
requirement?
Do any requirements conflict with other requirements?
Is each requirement achievable in the technical environment that will house the
system or product?
Is each requirement testable, once implemented?
Does the requirements model properly reflect the information, function, and
behavior of the system to be built?
Has the requirements model been “partitioned” in a way that exposes progressively
9
23ISI53- Software Engineering Principles and Testing Practices
REQUIREMENTS ANALYSIS
Requirements analysis results in the specification of software’s operational
characteristics, indicates software’s interface with other system elements, and
establishes constraints that software must meet. Requirements analysis allows you
to elaborate on basic requirements established during the inception, elicitation, and
negotiation tasks that are part of requirements engineering. The requirements
modeling action results in one or more of the following types of models:
Scenario-based models of requirements from the point of view of various
system “actors”
10
23ISI53- Software Engineering Principles and Testing Practices
Data models that depict the information domain for the problem
Class-oriented models that represent object-oriented classes (attributes
and operations) andthe manner in which classes collaborate to achieve system
requirements
Flow-oriented models that represent the functional elements of the
system and how theytransform data as it moves through the system
Behavioural models that depict how the software behaves because of
external “events”
These models provide a software designer with information that can be translated
to architectural, interface, and component-level designs. Finally, the requirements
model provides the developer and the customer with the means to assess quality
once software is built.
11
23ISI53- Software Engineering Principles and Testing Practices
Domain Analysis:
The analysis patterns often reoccur across many applications within a specific
business domain. If these patterns are defined and categorized in a manner that
allows you to recognize and apply them to solve common problems.
12
23ISI53- Software Engineering Principles and Testing Practices
SCENARIO-BASED MODELING
Requirements modeling with UML begins with the creation of scenarios in the form of
use cases,activity diagrams, and swimlane diagrams.
13
23ISI53- Software Engineering Principles and Testing Practices
14
23ISI53- Software Engineering Principles and Testing Practices
15
23ISI53- Software Engineering Principles and Testing Practices
16
23ISI53- Software Engineering Principles and Testing Practices
17
23ISI53- Software Engineering Principles and Testing Practices
data object, but dimensions (incorporating height, width, and depth) could be
defined as an object.
A data object can be an external entity (e.g., anything that produces or consumes
information), a thing (e.g., a report or a display), an occurrence (e.g., a telephone
call) or event (e.g., an alarm), a role (e.g., salesperson), an organizational unit (e.g.,
accounting department), a place (e.g., a warehouse), or a structure (e.g., a file).
The description of the data object incorporates the data object and all of its
attributes.
Data Attributes:
Data attributes define the properties of a data object and take on one ofthree
different characteristics. They can be used to (1) name an instance of the data
object, (2) describe the instance, or (3) make reference to another instance in
another table. In addition,one or more of the attributes must be defined as an
identifier—that is, the identifier attribute becomes a “key” when we want to find
an instance of the data object. In some cases, values for the identifier(s) are
unique, although this is not a requirement.
Relationships:
Data objects are connected to one another in different ways. Consider the two
data objects, person and car. These objects can be represented using the simple
notation illustrated in Figure 6.8a. A connection is established between person
and car because the two objects are related. But what are the relationships? To
determine the answer, you shouldunderstand the role of people (owners, in this
case) and cars within the context of the softwareto be built. You can establish a
set of object/relationship pairs that define the relevant relationships. For
example,
A person owns a car.
A person is insured to drive a car.
18
23ISI53- Software Engineering Principles and Testing Practices
The relationships owns and insured to drive define the relevant connections
between person and car. Figure 6.8b illustrates these object-relationship pairs
graphically. The arrows noted in Figure 6.8b provide important information about
the directionality of the relationship and often reduce ambiguity or
misinterpretations.
CLASS-BASED MODELING
Class-based modeling represents the objects that the system will manipulate, the
operations that will be applied to the objects to effect the manipulation,
relationships between the objects, and the collaborations that occur between
the classes that are defined. The elements of a class-based model include
classes and objects, attributes, operations, class responsibility, collaborator(CRC)
models, collaboration diagrams, and packages.
Specifying Attributes:
Attributes are the set of data objects that fully define the class within the context
of the problem. Attributes describe a class that has been selected for inclusionin
the requirements model. In essence, it is the attributes that define the class—
that clarify whatis meant by the class in the context of the problem space.
To develop a meaningful set of attributes for an analysis class, you should study
each use case and select those “things” that reasonably “belong” to the class.
19
23ISI53- Software Engineering Principles and Testing Practices
Defining Operations:
Operations define the behavior of an object. Although many different types of
operations exist, they can generally be divided into four broad categories: (1)
operations that manipulate data in some way. (2) operations that perform a
computation, (3) operations that inquire about the state of an object, and (4)
operations that monitor an object for the occurrence of a controlling event. These
functions are accomplished by operating on attributes and/or associations.
Therefore, an operation must have “knowledge” of the nature of the class’
attributes and associations.
As a first iteration at deriving a set of operations for an analysis class, you can
again study a processing narrative (or use case) and select those operations that
reasonably belong to the class. To accomplish this, the grammatical parse is again
studied and verbs are isolated. Some of these verbs will be legitimate operations
and can be easily connected to a specific class.
One purpose of CRC cards is to fail early, to fail often, and to fail inexpensively. It is
a lot cheaper to tear up a bunch of cards than it would be to reorganize a large
amount of source code.
20
23ISI53- Software Engineering Principles and Testing Practices
In reality, the CRC model may make use of actual or virtual index cards. The intent is
to developan organized representation of classes. Responsibilities are the attributes
and operations that are relevant for the class. Stated simply, a responsibility is
“anything the class knows or does”. Collaborators are those classes that are required
to provide a class with the information needed to complete a responsibility.
In general, a collaboration implies either a request for information or a request for
some action.
A simple CRC index card for the FloorPlan class is illustrated in Figure 6.11. The list
of responsibilities shown on the CRC card is preliminary and subject to additions or
modification. The classes Wall and Camera are noted next to the responsibility that
will require their collaboration.
Classes. Basic guidelines for identifying classes and objects were presented earlier in
this chapter. The taxonomy of class types presented in Section 6.5.1 can be extended by
considering the following categories:
• Entity classes, also called model or business classes, are extracted directly from the
statement of the problem These classes typically represent things that are to be stored
in a database and persist throughout the duration of the application.
• Boundary classes are used to create the interface (e.g., interactive screen or printed
reports)that the user sees and interacts with as the software is used. Entity objects
contain information that is important to users, but they do not display themselves.
Boundary classes are designedwith the responsibility of managing the way entity
objects are represented to users.
21
21CS61- Software Engineering and Project Management
Controller classes manage a “unit of work” from start to finish. That is, controller classes
can bedesigned to manage
Responsibilities.
The five guidelines for allocating responsibilities to classes:
1. System intelligence should be distributed across classes to best address the
needs ofthe problem.
Every application encompasses a certain degree of intelligence; that is, what the
system knows and what it can do. This intelligence can be distributed acrosss
classes in a umber of different ways. “Dumb” classes can be modeled to act as
servants to a few “smart” classes.
To determine whether system intelligence is properly distributed, the
responsibilities noted on each CRC model index card should be evaluated to
determine if any class has an extraordinarilylong list of responsibilities. Example is
aggregation of classes.
2. Each responsibility should be stated as generally as possible.
This guideline implies thatgeneral responsibilities (both attributes and
operations) should reside high in the class hierarchy
3. Information and the behavior related to it should reside within the same class.
This achieves the object-oriented principle called encapsulation. Data and the
processes that manipulate the data should be packaged as a cohesive unit.
4. Information about one thing should be localized with a single class, not
distributed across multiple classes.
A single class should take on the responsibility for storing and manipulating a
specific type of information. This responsibility should not, in general, be shared
21CS61- Software Engineering and Project Management
Collaborations.
fulfill their responsibilities in one of two ways:
1. A class can use its own operations to manipulate its own attributes, thereby
fulfilling a particular responsibility, or
2. a class can collaborate with other classes.
To help in the identification of collaborators, you can examine three different generic
relationships between classes
When a complete CRC model has been developed, stakeholders can review the model
usingthe following approach
1. All participants in the review are given a subset of the CRC model index cards. Cards
thatcollaborate should be separated
2. All use-case scenarios (corresponding use-case diagrams) should be organized into
categories.
3. The review leader reads the use case deliberately.
4. When the token is passed, the holder of the Sensor card is asked to describe the
responsibilities noted on the card.
5. If the responsibilities and collaborations noted on the index cards cannot accommodate
theuse case, modifications are made to the cards.
This continues until the use case is finished. When all use cases have been reviewed,
requirements modeling continue.
21CS61- Software Engineering and Project Management
the analysis model are categorized in a manner that packages them as a grouping—
called an analysis package—that is given a representative name.
For example, Classes such as Tree, Landscape, Road, Wall, Bridge, Building, and Visual
21CS61- Software Engineering and Project Management
Effectmight fall within this category. Others focus on the characters within the game,
describing their physical features, actions, and constraints. These classes can be grouped
in analysis packages as shown in Figure 6.15. The plus signpreceding the analysis class
name in each package indicates that the classes have public visibility and are therefore
accessible from other packages.
Although they are not shown in the figure, other symbols can precede an element within
a package. A minus sign indicates that an element is hidden from all other packages and a
#symbol indicates that an element is accessible only to packages contained within a given
package.
MODULE-2
1. List and explain the seven distinct tasks of requirements engineering?
2. Explain the process of Eliciting requirements of a project.
3. Explain the elements of building requirements model?
4. Develop Software Requirement Specification with requirement understanding for online result
analysis system for college.
5. Develop UML model for digital Library System with Structural and behavioral modeling
diagrams. 6. Describe the process of Scenario based modeling.
6. State the challenges involved in software requirements of a project.
7. Explain data modeling concepts with an example.
8. What is use case diagram? Draw a use case diagram for an ATM system?
9. Explain activity diagrams? Draw an activity diagram for an ATM system?
10. Explain swim lane diagrams? Draw a swim lane diagram for an ATM system?
11. What is class diagram? Draw class diagram for an ATM system?
12. What is sequence diagram? Draw a sequence diagram for library management system?
13. Illustrate state chart diagrams? Draw a state chart diagram for library management system pin
verification?
14. Illustrate data flow diagrams with the help of examples?
15. What is ER diagram? Explain with the help of examples?
16. What is SRS? How will you develop requirements model to finalize specifications for college
admission system