Requirement Engineering Unit 2
Requirement Engineering Unit 2
Requirements engineering (RE) refers to the process of defining, documenting, and maintaining
requirements in the engineering design process. Requirement engineering provides the appropriate
mechanism to understand what the customer desires, analyzing the need, and assessing feasibility,
negotiating a reasonable solution, specifying the solution clearly, validating the specifications and
managing the requirements as they are transformed into a working system. Thus, requirement
engineering is the disciplined application of proven principles, methods, tools, and notation to describe a
proposed system's intended behavior and its associated constraints.
1. Feasibility Study
2. Requirement Elicitation and Analysis
3. Software Requirement Specification
4. Software Requirement Validation
5. Software Requirement Management
1. Feasibility Study:
The objective behind the feasibility study is to create the reasons for developing the software that is
acceptable to users, flexible to change and conformable to established standards.
Types of Feasibility:
1. Technical Feasibility - Technical feasibility evaluates the current technologies, which are needed to
accomplish customer requirements within the time and budget.
2. Operational Feasibility - Operational feasibility assesses the range in which the required software performs
a series of levels to solve business problems and customer requirements.
3. Economic Feasibility - Economic feasibility decides whether the necessary software can generate financial
profits for an organization.
2. Requirement Elicitation and Analysis:
This is also known as the gathering of requirements. Here, requirements are identified with the help of
customers and existing systems processes, if available.
Analysis of requirements starts with requirement elicitation. The requirements are analyzed to identify
inconsistencies, defects, omission, etc. We describe requirements in terms of relationships and also
resolve conflicts if any.
o Data Flow Diagrams: Data Flow Diagrams (DFDs) are used widely for modeling the requirements. DFD
shows the flow of data through a system. The system may be a company, an organization, a set of
procedures, a computer hardware system, a software system, or any combination of the preceding. The DFD
is also known as a data flow graph or bubble chart.
o Data Dictionaries: Data Dictionaries are simply repositories to store information about all data items
defined in DFDs. At the requirements stage, the data dictionary should at least define customer data items, to
ensure that the customer and developers use the same definition and terminologies.
o Entity-Relationship Diagrams: Another tool for requirement specification is the entity-relationship
diagram, often called an "E-R diagram." It is a detailed logical representation of the data for the organization
and uses three main constructs i.e. data entities, relationships, and their associated attributes.
New requirements emerge during the process as business needs a change, and a better understanding of
the system is developed.
The priority of requirements from different viewpoints changes during development process.
The business and technical environment of the system changes during the development.
o Clear
o Correct
o Consistent
o Coherent
o Comprehensible
o Modifiable
o Verifiable
o Prioritized
o Unambiguous
o Traceable
o Credible source
Software Requirements: Largely software requirements must be categorized into two categories:
1. Functional Requirements: Functional requirements define a function that a system or system element
must be qualified to perform and must be documented in different forms. The functional requirements are
describing the behavior of the system as it correlates to the system's functionality.
2. Non-functional Requirements: This can be the necessities that specify the criteria that can be used to
decide the operation instead of specific behaviors of the system.
Non-functional requirements are divided into two main categories:
o Execution qualities like security and usability, which are observable at run time.
o Evolution qualities like testability, maintainability, extensibility, and scalability that embodied in the
static structure of the software system.
Requirements Elicitation – Software Engineering
Requirement elicitation can be done by communicating with stakeholders directly or by doing some research,
experiments. The activities can be planned, unplanned, or both.
#2) Brainstorming
This technique is used to generate new ideas and find a solution for a specific issue. The members included for
brainstorming can be domain experts, subject matter experts. Multiple ideas and information give you a repository of
knowledge and you can choose from different ideas.
This session is generally conducted around the table discussion. All participants should be given an equal amount of
time to express their ideas.
Brainstorming technique is used to answer the below questions:
What is the expectation of a system?
What are the risk factors that affect the proposed system development and what to do to avoid that?
What are the business and organization rules required to follow?
What are the options available to resolve the current issues?
What should we do so that this particular issue does not happen in the future?
Brainstorming can be described in the following phases:
There are some basic rules for this technique which should be followed to make it a success:
The time limit for the session should be predefined.
Identify the participants in advance. One should include 6-8 members for the session.
The agenda should be clear enough for all the participants.
Clear expectations should be set with the participants.
Once you get all the information, combine the ideas, and remove the duplicate ideas.
Once the final list is ready, distribute it among other parties.
Benefits:
Creative thinking is the result of the brainstorming session.
Plenty of ideas in a short time.
Promotes equal participation.
Drawbacks:
Participants can be involved in debating ideas.
There can be multiple duplicate ideas.
#3) Interview
This is the most common technique used for requirement elicitation. Interview techniques should be used for building
strong relationships between business analysts and stakeholders. In this technique, the interviewer directs the question
to stakeholders to obtain information. One to one interview is the most commonly used technique.
If the interviewer has a predefined set of questions then it’s called a structured interview.
If the interviewer is not having any particular format or any specific questions then it’s called an unstructured
interview.
For an effective interview, you can consider the 5 Why technique. When you get an answer to all your Whys then you
are done with your interview process. Open-ended questions are used to provide detailed information. In this
interviewee cannot say Yes or No only.
Closed questions can be answered in Yes or No form and also for areas used to get confirmation on answers.
Basic Rules:
The overall purpose of performing the interviews should be clear.
Identify the interviewees in advance.
Interview goals should be communicated to the interviewee.
Interview questions should be prepared before the interview.
The location of the interview should be predefined.
The time limit should be described.
The interviewer should organize the information and confirm the results with the interviewees as soon as
possible after the interview.
Benefits:
Interactive discussion with stakeholders.
The immediate follow-up to ensure the interviewer’s understanding.
Encourage participation and build relationships by establishing rapport with the stakeholder.
Drawbacks:
Time is required to plan and conduct interviews.
Commitment is required from all the participants.
Sometimes training is required to conduct effective interviews.
#4) Document Analysis/Review
This technique is used to gather business information by reviewing/examining the available materials that describe the
business environment. This analysis is helpful to validate the implementation of current solutions and is also helpful in
understanding the business need.
Document analysis includes reviewing the business plans, technical documents, problem reports, existing requirement
documents, etc. This is useful when the plan is to update an existing system. This technique is useful for migration
projects.
This technique is important in identifying the gaps in the system i.e. to compare the AS-IS process with the TO-BE
process. This analysis also helps when the person who has prepared the existing documentation is no longer present in
the system.
Benefits:
Existing documents can be used to compare current and future processes.
Existing documents can be used as a base for future analysis.
Drawbacks:
Existing documents might not be updated.
Existing documents might be completely outdated.
Resources worked on the existing documents might not be available to provide information.
This process is time-consuming.
#5) Focus Group
By using a focus group, you can get information about a product, service from a group. The Focus group includes
subject matter experts. The objective of this group is to discuss the topic and provide information. A moderator
manages this session.
The moderator should work with business analysts to analyze the results and provide findings to the stakeholders.
If a product is under development and the discussion is required on that product then the result will be to update the
existing requirement or you might get new requirements. If a product is ready to ship then the discussion will be on
releasing the product.
Benefits:
You can get information in a single session rather than conducting one to one interview.
Active discussion with the participants creates a healthy environment.
One can learn from other’s experiences.
Drawbacks:
It might be difficult to gather the group on the same date and time.
If you are doing this using the online method then the participant’s interaction will be limited.
A Skilled Moderator is required to manage focus group discussions.
#6) Interface Analysis
Interface analysis is used to review the system, people, and processes. This analysis is used to identify how the
information is exchanged between the components. An Interface can be described as a connection between two
components. This is described in the below image:
The interface analysis focus on the below questions:
1. Who will be using the interface?
2. What kind of data will be exchanged?
3. When will the data be exchanged?
4. How to implement the interface?
5. Why we need the interface? Can’t the task be completed without using the interface?
Benefits:
Provide missed requirements.
Determine regulations or interface standards.
Uncover areas where it could be a risk for the project.
Drawbacks:
The analysis is difficult if internal components are not available.
It cannot be used as a standalone elicitation activity.
#7) Observation
The main objective of the observation session is to understand the activity, task, tools used, and events performed by
others.
The plan for observation ensures that all stakeholders are aware of the purpose of the observation session, they agree on
the expected outcomes, and that the session meets their expectations. You need to inform the participants that their
performance is not judged.
During the session, the observer should record all the activities and the time taken to perform the work by others so that
he/she can simulate the same. After the session, the BA will review the results and will follow up with the participants.
Observation can be either active or passive.
Active observation is to ask questions and try to attempt the work that other persons are doing.
Passive observation is silent observation i.e. you sit with others and just observe how they are doing their work
without interpreting them.
Benefits:
The observer will get a practical insight into the work.
Improvement areas can be easily identified.
Drawbacks:
Participants might get disturbed.
Participants might change their way of working during observation and the observer might not get a clear
picture.
Knowledge-based activities cannot be observed.
#8) Prototyping
Prototyping is used to identify missing or unspecified requirements. In this technique, frequent demos are given to the
client by creating the prototypes so that client can get an idea of how the product will look like. Prototypes can be used
to create a mock-up of sites, and describe the process using diagrams.
Benefits:
Gives a visual representation of the product.
Stakeholders can provide feedback early.
Drawbacks:
If the system or process is highly complex, the prototyping process may become time-consuming.
Stakeholders may focus on the design specifications of the solution rather than the requirements that any
solution must address.
#9) Joint Application Development (JAD)/ Requirement Workshops
This technique is more process-oriented and formal as compared to other techniques. These are structured meetings
involving end-users, PMs, SMEs. This is used to define, clarify, and complete requirements.
Questions should be based on high priority risks. Questions should be direct and unambiguous. Once the survey is
ready, notify the participants and remind them to participate.
FAQs
1. What is the need for requirement analysis?
Determining the needs or conditions to meet for a new or altered product or project, taking account of the possibility.
Conflicting requirements of the stakeholders, analyzing, documenting, validating, and managing software or system
requirements.
We need the requirement analysis for all the activities that have been mentioned before.
(i) Draw the context diagram: The context diagram is a simple model that defines the boundaries and
interfaces of the proposed systems with the external world. It identifies the entities outside the proposed
system that interact with the system. The context diagram of student result management system is given
below:
(ii) Development of a Prototype (optional): One effective way to find out what the customer wants is
to construct a prototype, something that looks and preferably acts as part of the system they say they
want.
We can use their feedback to modify the prototype until the customer is satisfied continuously. Hence, the
prototype helps the client to visualize the proposed system and increase the understanding of the
requirements. When developers and users are not sure about some of the elements, a prototype may help
both the parties to take a final decision.
Some projects are developed for the general market. In such cases, the prototype should be shown to
some representative sample of the population of potential purchasers. Even though a person who tries out
a prototype may not buy the final system, but their feedback may allow us to make the product more
attractive to others.
The prototype should be built quickly and at a relatively low cost. Hence it will always have limitations and
would not be acceptable in the final system. This is an optional activity.
(iii) Model the requirements: This process usually consists of various graphical representations of the
functions, data entities, external entities, and the relationships between them. The graphical view may
help to find incorrect, inconsistent, missing, and superfluous requirements. Such models include the Data
Flow diagram, Entity-Relationship diagram, Data Dictionaries, State-transition diagrams, etc.
(iv) Finalise the requirements: After modeling the requirements, we will have a better understanding of
the system behavior. The inconsistencies and ambiguities have been identified and corrected. The flow of
data amongst various modules has been analyzed. Elicitation and analyze activities have provided better
insight into the system. Now we finalize the analyzed requirements, and the next step is to document
these requirements in a prescribed format.
Data Flow Diagrams
A Data Flow Diagram (DFD) is a traditional visual representation of the information flows
within a system. A neat and clear DFD can depict the right amount of the system
requirement graphically. It can be manual, automated, or a combination of both.
It shows how data enters and leaves the system, what changes the information, and where
data is stored.
The objective of a DFD is to show the scope and boundaries of a system as a whole. It may
be used as a communication tool between a system analyst and any person who plays a
part in the order that acts as a starting point for redesigning a system. The DFD is also
called as a data flow graph or bubble chart.
1. All names should be unique. This makes it easier to refer to elements in the DFD.
2. Remember that DFD is not a flow chart. Arrows is a flow chart that represents the order of
events; arrows in DFD represents flowing data. A DFD does not involve any order of events.
3. Suppress logical decisions. If we ever have the urge to draw a diamond-shaped box in a DFD,
suppress that urge! A diamond-shaped box is used in flow charts to represents decision
points with multiple exists paths of which the only one is taken. This implies an ordering of
events, which makes no sense in a DFD.
4. Do not become bogged down with details. Defer error conditions and error handling until the
end of the analysis.
Standard symbols for DFDs are derived from the electric circuit diagram analysis and are
shown in fig:
Circle: A circle (bubble) shows a process that transforms data inputs into data outputs.
Data Flow: A curved line shows the flow of data into or out of a process or data store.
Data Store: A set of parallel lines shows a place for the collection of data items. A data
store indicates that the data is stored which can be used at a later stage or by the other
processes in a different order. The data store can have an element or group of elements.
Source or Sink: Source or Sink is an external entity and acts as a source of system inputs
or sink of system outputs.
0-level DFDM
It is also known as fundamental system model, or context diagram represents the entire
software requirement as a single bubble with input and output data denoted by incoming
and outgoing arrows. Then the system is decomposed and described as a DFD with
multiple bubbles. Parts of the system represented by each of these bubbles are then
decomposed and documented as more and more detailed DFDs. This process may be
repeated at as many levels as necessary until the program at hand is well understood. It is
essential to preserve the number of inputs and outputs between levels, this concept is
called leveling by DeMacro. Thus, if bubble "A" has two inputs x 1 and x2 and one output y,
then the expanded DFD, that represents "A" should have exactly two external inputs and
one external output as shown in fig:
The Level-0 DFD, also called context diagram of the result management system is shown in
fig. As the bubbles are decomposed into less and less abstract bubbles, the corresponding
data flow may also be needed to be decomposed.
1-level DFD
2-Level DFD
2-level DFD goes one process deeper into parts of 1-level DFD. It can be used to project or
record the specific/necessary detail about the system's functioning.
What is requirements analysis (requirements engineering)?
Requirements analysis (requirements engineering) is the process of determining user expectations for a new or
modified product. It is usually a team effort and demands a variety of human soft skills, such as critical thinking,
communication and judgment.
Requirements analysis is a common and essential concept in software development and software project management.
At the start of every software project, the project team must understand, finalize and document the features and
functionalities required of the end product. These required features and functionalities are often called functional
specifications, and the process of determining and understanding them is called requirements gathering and analysis.
Requirements must be quantifiable, as detailed as possible and relevant to the end product. In addition, they should be
clearly documented so the development team has clear expectations and understands required specifications from the
beginning.
Ensures that the final product conforms to requirements, i.e., prevents scope creep.
Requirements analysis is an important concept in
software development.
The importance of communication during requirements analysis
During requirements analysis, project team members come together to understand the project goals, clarify expectations
and document the product's required specifications and features. All of this requires clear and unambiguous
communication between team members.
When gathering requirements, the project team should also communicate with other stakeholders, such as the project
owner and end users, to determine their expectations regarding specific features. Early and frequent discussions
between these parties help to prevent ambiguity. It ensures that the final product conforms to the end user's or client's
needs and avoids forcing users to adjust their expectations.
Requirements analysis and feature creep
Requirements analysis and clear communication help to prevent feature creep in software projects. Also known
as scope creep, feature creep refers to the addition of excessive features to a product, which often makes it overly
complex and difficult to use.
Feature creep is usually the result of poor planning, insufficient communication, inadequate requirements analysis and
poor understanding of requirements by the team. It complicates product design, undermines its value and can
eventually make it unusable for end users. To avoid such problems, project teams must gather, understand and analyze
the product's requirements before development begins.
In any project, the key stakeholders, including end users, generally have final say on the project scope. Project teams
should identify them early and involve them in the requirements gathering process from the beginning.
To capture all necessary requirements, project teams must first understand the project's objective. What business need
drives the project? What problem is the product meant to solve? By understanding the desired end, the project team can
define the problem statement and have more productive discussions when gathering requirements.
3. Capture requirements
At this stage, all relevant stakeholders provide requirements. This can be done through one-on-one interviews, focus
groups or consideration of use cases. Project teams gather stakeholder feedback and incorporate it into requirements.
4. Categorize requirements
Categorization of requirements can help with prioritization, impact analysis, feasibility analysis and conflict resolution.
Four common requirements categories are the following:
1. Functional requirements.
2. Technical requirements.
3. Transitional requirements.
4. Operational requirements.
Post-categorization, the project team should analyze its set of requirements to determine which ones are feasible.
Interpretation and analysis are easier when requirements are well defined and clearly worded. Each requirement should
have a clear and understood impact on the end product and the project plan. After all the requirements have been
identified, prioritized and analyzed, project teams should document them in the software requirements specification
(SRS).
6. Finalize SRS and get sign-off on requirements
The SRS should be shared with key stakeholders for sign-off to ensure that they agree with the requirements. This helps
prevent conflicts or disagreements later. Feedback, if any, should be incorporated. The SRS can then be finalized and
made available to the entire development team. This document provides the foundation for the project's scope and
guides other steps during the software development lifecycle (SDLC), including development and testing.
The software development lifecycle (SDLC)
A prototype can help teams to convert intangible requirements into a tangible form. By developing a prototype and
showing it to end users -- or, more practically, a selection of end users -- the team can gather user feedback and
understand what requirements it lacks. Then, it can incorporate feedback to improve the prototype and use it to create
an end product that appropriately reflects user requirements and expectations.
Business Process Model and Notation (BPMN). BPMN enables project teams to create a standardized graphical
representation of processes and coordinate communications between participants in that process.
Flowcharts. Whether simple or complex, flowcharts can show the relationships between activities in an intuitive
way, which can provide clarity of understanding and simplify communication as the project progresses.
Gantt charts. Gantt charts help with project planning and -- to some extent -- with requirements analysis. A Gannt
chart visually represents various tasks and scheduled timelines, complete with start and end dates.
Gap analysis. Gap analysis helps project managers and teams to evaluate a product's performance and compare it
against its requirements.
What is Requirements Analysis?
Requirements analysis or requirements engineering is a process used to determine the needs and expectations of a new product. It
involves frequent communication with the stakeholders and end-users of the product to define expectations, resolve conflicts, and
document all the key requirements.
One of the greatest challenges faced by any organization is to share the vision of the final product with the customers. Hence,
a business requirements analysis involves a team effort of all the key stakeholders, software developers, end-users, and customer
managers to achieve a shared understanding of what the product should do. This is always done in the early phase of any project to
ensure that the final product conforms to all the requirements.
The first step of the requirements analysis process is to identify key stakeholders who are the main sponsors of the project. They will
have the final say on what should be included in the scope of the project.
Next, identify the end-users of the product. Since the product is intended to satisfy their needs, their inputs are equally important.
Step 2: Capture Requirements
Ask each of the stakeholders and end-users their requirements for the new product. Here are some requirements analysis techniques
that you can use to capture requirements:
Interview each stakeholder and end-user individually. This technique will help you gather specific requirements.
Conduct group interviews or group workshops to understand the flow of information between different stakeholders and end-users.
This technique will ensure that there will be no conflict of interest later on during the project.
Use cases provide a walkthrough of the entire product through the eyes of the end-user. This technique will help visualize how the
product will actually work.
4. Build Prototypes
A prototype provides users a sample look and feel of the final product. This technique will help address feasibility issues and identify
problems ahead of time.
Since requirements can be of various types, they should be grouped to avoid confusion. Requirements are usually divided into four
categories:
Operational Requirements: Operations to be carried out in the backend for proper functioning of the product.
Once the requirements are categorized, determine which requirements are actually achievable and document each one of them. Here
are some techniques to analyze and interpret requirements:
Ensure that the requirements are clearly worded, sufficiently detailed, and related to business needs.
Prioritize Requirements
Prioritize requirements and list them out based on which ones are the “most critical” and which ones are just “nice-to-have”.
Carry out an impact analysis to make sure that you fully understand the consequences of the requirements.
Resolve Conflicts
Arrange a meeting with key stakeholders and resolve conflicting requirements. You can also perform a scenario analysis to explore
how the requirements would work for different possible scenarios.
Analyze Feasibility
Perform a detailed analysis of the product based on the requirements gathered to determine its reliability and to identify any major
problems.
Once all the requirements are analyzed, create a detailed written document and circulate it among the key stakeholders, end-users and
development teams.
Once a final decision is made on the requirements, ensure that you get a signed agreement from the key stakeholders. This is done to
ensure that there are no changes or uncontrolled growth in the scope of the project.
The purpose of drawing a context diagram is to find out how to design a new system within an organization or how to modify it.
Context diagram defines how external elements impact the internal system of an organization. They are complex diagrams that draw
the system analysis simply yet crisply. The arrows indicate the date-flow between the external elements and the internal system. For
example, the following diagram shows how different elements move within the hotel reservation system.
Prototype development is an important part of a product launch as this helps the organization find out the specific requirements of
customers. Based on the customers' response, the prototype is modified until it achieves maximum customer satisfaction. The
prototype allows the client to imagine the system to be built and to understand the customer's requirements. If the developers and end
users still need to catch up on some aspects of the system, the prototype or the replica of the product helps them to finalize those
elements.
Those products that are developed for the general masses should get a glimpse of the prototype. Then, it should be shown to a selected
section of potential buyers. This will help to create a product more attractive than before.
The prototype is usually created faster and at an affordable cost. However, it always comes with some limitations and is not accepted
in the final analysis.
This stage involves creating requirement models that ultimately allow customers and stakeholders to imagine the product in the
making. Various functions, data tables, external elements, and their relation to each other are represented in graphical forms. A
graphical viewing of these things assists in finding flaws in the requirements. It allows the developers to see if there are any
inconsistencies, missing, wrong, or unnecessary elements added to the system. Such requirement models can be divided into the
following categories.
Data Flow Diagram: A graphical preparation using symbols and notations to show how a business operates through data movement.
Entity-Relationship diagram: A flowchart describing how things like people, a concept, or an object are related within a system.
Data Dictionaries: These contain different definitions, names, and other forms of data elements utilized within the project.
State-transition diagrams: They represent the changes that take place within the system
Requirement models will add to the understanding of the system. All the necessary corrections are done at this stage. All ambiguities
are removed, and the data flow is examined across various models. The elicitation process and subsequent analysis lead to a greater
understanding of the system. So finally, the requirements are approved, and the documentation begins.
Data Dictionaries in Software Engineering
Data Dictionary is the major component in the structured analysis model of the system. It lists all
the data items appearing in DFD. A data dictionary in Software Engineering means a file or a set of
files that includes a database’s metadata (hold records about other objects in the database), like
data ownership, relationships of the data to another object, and some other data.
Example a data dictionary entry: GrossPay = regular pay + overtime pay
Case Tools is used to maintain data dictionary as it captures the data items appearing in a DFD
automatically to generate the data dictionary.
Here, we will discuss some use cases of the data dictionary as follows.
Used for creating the ordered list of data items
Used for creating the ordered list of a subset of the data items
Used for Designing and testing software in Software Engineering
Used for finding data items from a description in Software Engineering
Entity-Relationship Diagrams
ER-modeling is a data modeling method used in software engineering to produce a conceptual data model
of an information system. Diagrams created using this ER-modeling method are called Entity-Relationship
Diagrams or ER diagrams or ERDs.
Purpose of ERD
o The database analyst gains a better understanding of the data to be contained in the database through the
step of constructing the ERD.
o The ERD serves as a documentation tool.
o Finally, the ERD is used to connect the logical structure of the database to users. In particular, the ERD
effectively communicates the logic of the database to users.
Components of an ER Diagrams
1. Entity
An entity can be a real-world object, either animate or inanimate, that can be merely identifiable. An entity
is denoted as a rectangle in an ER diagram. For example, in a school database, students, teachers, classes,
and courses offered can be treated as entities. All these entities have some attributes or properties that
give them their identity.
Entity Set
An entity set is a collection of related types of entities. An entity set may include entities with attribute
sharing similar values. For example, a Student set may contain all the students of a school; likewise, a
Teacher set may include all the teachers of a school from all faculties. Entity set need not be disjoint.
2. Attributes
Entities are denoted utilizing their properties, known as attributes. All attributes have values. For example,
a student entity may have name, class, and age as attributes.
There exists a domain or range of values that can be assigned to attributes. For example, a student's
name cannot be a numeric value. It has to be alphabetic. A student's age cannot be negative, etc.
1. Key attribute
2. Composite attribute
3. Single-valued attribute
4. Multi-valued attribute
5. Derived attribute
1. Key attribute: Key is an attribute or collection of attributes that uniquely identifies an entity among
the entity set. For example, the roll_number of a student makes him identifiable among students.
1. Super key: A set of attributes that collectively identifies an entity in the entity set.
2. Candidate key: A minimal super key is known as a candidate key. An entity set may have more than one
candidate key.
3. Primary key: A primary key is one of the candidate keys chosen by the database designer to uniquely
identify the entity set.
5. Derived attribute: Derived attributes are the attribute that does not exist in the physical database,
but their values are derived from other attributes present in the database. For example, age can be
derived from date_of_birth. In the ER diagram, Derived attributes are depicted by the dashed ellipse.
3. Relationships
The association among entities is known as relationship. Relationships are represented by the diamond-
shaped box. For example, an employee works_at a department, a student enrolls in a course. Here,
Works_at and Enrolls are called relationships.
Relationship set
A set of relationships of a similar type is known as a relationship set. Like entities, a relationship too can
have attributes. These attributes are called descriptive attributes.
1. Unary (degree1)
2. Binary (degree2)
3. Ternary (degree3)
1. Unary relationship: This is also called recursive relationships. It is a relationship between the
instances of one entity type. For example, one person is married to only one person.
2. Binary relationship: It is a relationship between the instances of two entity types. For example, the
Teacher teaches the subject.
3. Ternary relationship: It is a relationship amongst instances of three entity types. In fig, the
relationships "may have" provide the association of three entities, i.e., TEACHER, STUDENT, and SUBJECT.
All three entities are many-to-many participants. There may be one or many participants in a ternary
relationship.
In general, "n" entities can be related by the same relationship and is known as n-ary relationship.
Cardinality
Cardinality describes the number of entities in one entity set, which can be associated with the number of
entities of other sets via relationship set.
Types of Cardinalities
1. One to One: One entity from entity set A can be contained with at most one entity of entity set B and
vice versa. Let us assume that each student has only one student ID, and each student ID is assigned to
only one person. So, the relationship will be one to one.
Using Sets, it can be represented as:
2. One to many: When a single instance of an entity is associated with more than one instances of
another entity then it is called one to many relationships. For example, a client can place many orders; a
order cannot be placed by many customers.
Using Sets, it can be represented as:
3. Many to One: More than one entity from entity set A can be associated with at most one entity of
entity set B, however an entity from entity set B can be associated with more than one entity from entity
set A. For example - many students can study in a single college, but a student cannot study in many
colleges at the same time.
Unified Modeling Language (UML) is a general-purpose modeling language. The main aim of
UML is to define a standard way to visualize the way a system has been designed. It is quite
similar to blueprints used in other fields of engineering. UML is not a programming language, it
is rather a visual language.
We use UML diagrams to portray the behavior and structure of a system.
UML helps software engineers, businessmen, and system architects with modeling, design, and
analysis.
The Object Management Group (OMG) adopted Unified Modelling Language as a standard in
1997. It’s been managed by OMG ever since.
The International Organization for Standardization (ISO) published UML as an approved
standard in 2005. UML has been revised over the years and is reviewed periodically.
Creating Unified Modeling Language (UML) diagrams involves a systematic process that typically
includes the following steps:
1. Identify the Purpose:
Determine the purpose of creating the UML diagram. Different types of UML diagrams serve
various purposes, such as capturing requirements, designing system architecture, or
documenting class relationships.
2. Identify Elements and Relationships:
Identify the key elements (classes, objects, use cases, etc.) and their relationships that need
to be represented in the diagram. This step involves understanding the structure and
behavior of the system you are modeling.
3. Select the Appropriate UML Diagram Type:
Choose the UML diagram type that best fits your modeling needs. Common types include
Class Diagrams, Use Case Diagrams, Sequence Diagrams, Activity Diagrams, and more.
4. Create a Rough Sketch:
Before using a UML modeling tool, it can be helpful to create a rough sketch on paper or a
whiteboard. This can help you visualize the layout and connections between elements.
5. Choose a UML Modeling Tool:
Select a UML modeling tool that suits your preferences and requirements. There are various
tools available, both online and offline, that offer features for creating and editing UML
diagrams.
6. Create the Diagram:
Open the selected UML modeling tool and create a new project or diagram. Begin adding
elements (e.g., classes, use cases, actors) to the diagram and connect them with appropriate
relationships (e.g., associations, dependencies).
7. Define Element Properties:
For each element in the diagram, specify relevant properties and attributes. This might
include class attributes and methods, use case details, or any other information specific to
the diagram type.
8. Add Annotations and Comments:
Enhance the clarity of your diagram by adding annotations, comments, and explanatory
notes. This helps anyone reviewing the diagram to understand the design decisions and logic
behind it.
9. Validate and Review:
Review the diagram for accuracy and completeness. Ensure that the relationships,
constraints, and elements accurately represent the intended system or process. Validate
your diagram against the requirements and make necessary adjustments.
10. Refine and Iterate:
Refine the diagram based on feedback and additional insights. UML diagrams are often
created iteratively as the understanding of the system evolves.
11. Generate Documentation:
Some UML tools allow you to generate documentation directly from your diagrams. This can
include class documentation, use case descriptions, and other relevant information.
You can think of an SRS as a blueprint or roadmap for the software you're going to build. The elements that comprise an
SRS can be simply summarized into four Ds:
We want to DEFINE the purpose of our product, DESCRIBE what we are building, DETAIL the individual requirements,
and DELIVER it for approval. A good SRS document will define everything from how software will interact when
embedded in hardware to the expectations when connected to other software. An even better SRS document also
accounts for the needs of real-life users and human interaction.
An SRS gives you a complete picture of your entire project. It provides a single source of truth that every team involved in
development will follow. It is your plan of action and keeps all your teams — from development and testing to
maintenance — on the same page.
An SRS not only keeps your teams aligned and working toward a common vision of the product, it also helps ensure that
each requirement is met. It can ultimately help you make vital decisions on your product’s lifecycle, such as when to retire
an obsolete feature.
It takes time and careful consideration to create a proper SRS. But the effort it takes to write an SRS is gained back in the
development phase. It helps your team better understand your product, the business needs it serves, its users, and the
time it will take to complete.
Software Requirements Specification vs. System Requirements Specification
What is the difference between a software requirements specification document and a system requirements specification
document?
“Software” and “system” are sometimes used interchangeably as SRS. But, a software requirements specification
provides greater detail than a system requirements specification.
A system requirements specification (abbreviated as SyRS to differentiate from SRS) presents general information
on the requirements of a system, which may include both hardware and software, based on an analysis of business
needs.
A software requirements specification (SRS) details the specific requirements of the software that is to be developed.
Here are five steps you can follow to write an effective SRS document.
Your first step is to create an outline for your software requirements specification. This may be something you create
yourself, or you can use an existing SRS template.
If you’re creating the outline yourself, here’s what it might look like:
1. Introduction
1.1 Purpose
1.2 Intended Audience
2. Overall Description
This introduction is very important as it sets expectations that we will come back to throughout the SRS.
Define who in your organization will have access to the SRS and how they should use it. This may include developers,
testers, and project managers. It could also include stakeholders in other departments, including leadership teams, sales,
and marketing. Defining this now will lead to less work in the future.
Product Scope
What are the benefits, objectives, and goals we intend to have for this product? This should relate to overall business
goals, especially if teams outside of development will have access to the SRS.
Clearly define all key terms, acronyms, and abbreviations used in the SRS. This will help eliminate any ambiguity and
ensure that all parties can easily understand the document.
If your project contains a large quantity of industry-specific or ambiguous terminology or acronyms, you may want to
consider including a reference to a project glossary, to be appended to the SRS, in this section.
Your next step is to give a description of what you’re going to build. Why is this product needed? Who is it for? Is it a new
product? Is it an add-on to a product you’ve already created? Is this going to integrate with another product?
Understanding and getting your team aligned on the answers to these questions on the front end makes creating the
product much easier and more efficient for everyone involved.
User Needs
Describe who will use the product and how. Understanding the various users of the product and their needs is a critical
part of the SRS writing process.
Who will be using the product? Are they a primary or secondary user? What is their role within their organization? What
need does the product need to fulfill for them?
Do you need to know about the purchaser of the product as well as the end user? For the development of medical devices
and med device software, you may also need to know the needs of the patient.
What are we assuming will be true? Understating and laying out these assumptions ahead of time will help with
headaches later. Are we assuming current technology? Are we basing this on a Windows framework? We need to take
stock of these technical assumptions to better understand where our product might fail or not operate perfectly.
Finally, you should note if your project is dependent on any external factors. Are we reusing a bit of software from a
previous project? This new project would then depend on that operating correctly and should be included.
In order for your development team to meet the requirements properly, we must include as much detail as possible. This
can feel overwhelming but becomes easier as you break down your requirements into categories. Some common
categories are functional requirements, interface requirements, system features, and various types of nonfunctional
requirements:
Functional Requirements
Functional requirements are essential to your product because, as the name implies, they provide some sort of
functionality.
Asking yourself questions such as “does this add to my tool’s functionality?” or “what function does this provide?” can help
with this process. Within medical devices especially, these functional requirements may have a subset of domain-specific
requirements.
You may also have requirements that outline how your software will interact with other tools, which brings us to external
interface requirements.
External interface requirements are specific types of functional requirements. These are especially important when
working with embedded systems. They outline how your product will interface with other components.
There are several types of interfaces you may have requirements for, including:
User
Hardware
Software
Communications
System Features
System features are a type of functional requirements. These are features that are required in order for a system to
function.
Nonfunctional Requirements
Nonfunctional requirements, which help ensure that a product will work the way users and other stakeholders expect it to,
can be just as important as functional ones.
Performance requirements
Safety requirements
Security requirements
Usability requirements
Scalability requirements
The importance of each of these types of nonfunctional requirements may vary depending on your industry. In industries
such as medical device, life sciences, and automotive, there are often regulations that require the tracking and accounting
of safety.
We made it! After completing the SRS, you’ll need to get it approved by key stakeholders. This will require everyone to
review the latest version of the document.
1. Correctness: User review is used to provide the accuracy of requirements stated in the SRS. SRS is
said to be perfect if it covers all the needs that are truly expected from the system.
2. Completeness: The SRS is complete if, and only if, it includes the following elements:
(1). All essential requirements, whether relating to functionality, performance, design, constraints,
attributes, or external interfaces.
(2). Definition of their responses of the software to all realizable classes of input data in all available
categories of situations.
Note: It is essential to specify the responses to both valid and invalid values.
(3). Full labels and references to all figures, tables, and diagrams in the SRS and definitions of all terms
and units of measure.
3. Consistency: The SRS is consistent if, and only if, no subset of individual requirements described in its
conflict. There are three types of possible conflict in the SRS:
(1). The specified characteristics of real-world objects may conflicts. For example,
(a) The format of an output report may be described in one requirement as tabular but in another as
textual.
(b) One condition may state that all lights shall be green while another states that all lights shall be blue.
(2). There may be a reasonable or temporal conflict between the two specified actions. For example,
(a) One requirement may determine that the program will add two inputs, and another may determine that
the program will multiply them.
(b) One condition may state that "A" must always follow "B," while other requires that "A and B" co-occurs.
(3). Two or more requirements may define the same real-world object but use different terms for that
object. For example, a program's request for user input may be called a "prompt" in one requirement's and
a "cue" in another. The use of standard terminology and descriptions promotes consistency.
4. Unambiguousness: SRS is unambiguous when every fixed requirement has only one interpretation.
This suggests that each element is uniquely interpreted. In case there is a method used with multiple
definitions, the requirements report should determine the implications in the SRS so that it is clear and
simple to understand.
5. Ranking for importance and stability: The SRS is ranked for importance and stability if each
requirement in it has an identifier to indicate either the significance or stability of that particular
requirement.
Typically, all requirements are not equally important. Some prerequisites may be essential, especially for
life-critical applications, while others may be desirable. Each element should be identified to make these
differences clear and explicit. Another way to rank requirements is to distinguish classes of items as
essential, conditional, and optional.
6. Modifiability: SRS should be made as modifiable as likely and should be capable of quickly obtain
changes to the system to some extent. Modifications should be perfectly indexed and cross-referenced.
7. Verifiability: SRS is correct when the specified requirements can be verified with a cost-effective
system to check whether the final software meets those requirements. The requirements are verified with
the help of reviews.
8. Traceability: The SRS is traceable if the origin of each of the requirements is clear and if it facilitates
the referencing of each condition in future development or enhancement documentation.
1. Backward Traceability: This depends upon each requirement explicitly referencing its source in
earlier documents.
2. Forward Traceability: This depends upon each element in the SRS having a unique name or reference
number.
The forward traceability of the SRS is especially crucial when the software product enters the operation
and maintenance phase. As code and design document is modified, it is necessary to be able to ascertain
the complete set of requirements that may be concerned by those modifications.
9. Design Independence: There should be an option to select from multiple design alternatives for the
final system. More specifically, the SRS should not contain any implementation details.
10. Testability: An SRS should be written in such a method that it is simple to generate test cases and
test plans from the report.
11. Understandable by the customer: An end user may be an expert in his/her explicit domain but
might not be trained in computer science. Hence, the purpose of formal notations and symbols should be
avoided too as much extent as possible. The language should be kept simple and clear.
12. The right level of abstraction: If the SRS is written for the requirements stage, the details should
be explained explicitly. Whereas,for a feasibility study, fewer analysis can be used. Hence, the level of
abstraction modifies according to the objective of the SRS.
Concise: The SRS report should be concise and at the same time, unambiguous, consistent, and
complete. Verbose and irrelevant descriptions decrease readability and also increase error possibilities.
Black-box view: It should only define what the system should do and refrain from stating how to do
these. This means that the SRS document should define the external behavior of the system and not
discuss the implementation issues. The SRS report should view the system to be developed as a black box
and should define the externally visible behavior of the system. For this reason, the SRS report is also
known as the black-box specification of a system.
Conceptual integrity: It should show conceptual integrity so that the reader can merely understand it.
Response to undesired events: It should characterize acceptable responses to unwanted events. These are
called system response to exceptional conditions.
Verifiable: All requirements of the system, as documented in the SRS document, should be correct. This
means that it should be possible to decide whether or not requirements have been met in an
implementation.
1. Improved communication and understanding between stakeholders and developers, as the SRS clearly
defines the requirements for the software system
2. Increased efficiency in the software development process, as a well-written SRS can help to reduce the
need for rework and change requests
3. Improved quality of the final software system, as a well-written SRS helps to ensure that all requirements
are met
4. Increased stakeholder satisfaction, as a well-written SRS helps to ensure that the software system meets
the needs of the business and its users
5. Improved traceability and verifiability, as a well-written SRS can be traced to other documents and artifacts
and its requirements can be tested and validated.
6. Clarity and Completeness: A good SRS document provides clear and complete specifications for the
software project, which ensures that all stakeholders have a common understanding of the requirements
and objectives.
7. Traceability: A good SRS document includes detailed requirements and specifications, which enables
traceability throughout the software development process.
8. Testability: A good SRS document can serve as a basis for test cases and verification, which can ensure
that the software meets the requirements and specifications.
9. Improved Communication: A good SRS document can serve as a communication tool between different
stakeholders, such as project managers, developers, testers, and customers.
10. Reduced Rework: A good SRS document can help to identify and resolve issues early in the
development process, which can reduce the need for rework and improve the overall quality of the
software.
1. Confusion and misunderstandings between stakeholders and developers, as the requirements are not
clearly defined or are vague
Increased rework and change requests, as the SRS does not accurately capture the requirements of the
software system
2. Reduced quality of the final software system, as a poorly written SRS can result in requirements being
missed or not fully met
3. Reduced stakeholder satisfaction, as a poorly written SRS does not accurately capture the needs of the
business and its users
4. Reduced traceability and verifiability, as a poorly written SRS can’t be traced to other documents and
artifacts and its requirements can’t be tested and validated.
5. It is important to note that, regardless of the quality of the SRS, gathering and validating requirements is an
iterative process, that should be continuously reviewed and updated throughout the software development
process.
6. Time-consuming: Creating a good SRS document can be a time-consuming process, especially for complex
software projects, which can delay the development process.
7. Changes and Updates: Changes or updates to the SRS document can cause delays in the software
development process and can be difficult to manage.
8. Lack of Flexibility: A detailed SRS document can restrict the flexibility of the development process, which
can be challenging for projects that require agile development methodologies.
9. Limited Stakeholder Involvement: The process of creating an SRS document can limit the involvement of
stakeholders in the software development process, which can lead to a lack of collaboration and input from
different perspectives.
10. Ambiguity: A poorly written SRS document can lead to ambiguity and misunderstandings, which can
cause issues throughout the software development process.