Professional Documents
Culture Documents
2CEIT406
SOFTWARE ENGINEERING &
PROJECT MANAGEMENT
UNIT 2
REQUIREMENT MODELLING AND DESIGN
Prepared by: Prof. Ravi Raval (Asst. Prof in C.E Dept. , UVPCE)
Unit 2: Requirements Modeling and Design
Contents:
Requirement Engineering – Crucial Steps
Types of requirements
Requirement Documentation (SRS)
Nature of SRS
Characteristics of a good SRS
Structure of SRS Document
Use case diagrams with guidelines
Data Flow diagrams
Software Design
Modularity
Function oriented Design
Unit 2: Requirements Modeling and Design
Requirement Engineering: managers, customers, end users),
where business need is defined, user
The broad spectrum of tasks and
scenarios are described, functions
techniques that lead to an
and features are delineated, and
understanding of requirements is
project constraints are identified.
called requirements engineering.
Others might suggest that it begins
Requirements engineering builds a
with a broader system definition,
bridge to design and construction.
where software is but one
But where does the bridge originate?
component of the larger system
One could argue that it begins at the domain.
feet of the project stakeholders (e.g.,
Unit 2: Requirements Modeling and Design
Requirement Engineering: It encompasses seven distinct tasks:
Requirements engineering provides 1) inception,
the appropriate mechanism for 2) elicitation,
understanding 3) elaboration,
what the customer wants 4) negotiation,
analyzing need
5) specification,
assessing feasibility
negotiating a reasonable solution, 6) validation, and
specifying the solution unambiguously, 7) management
validating the specification,
and managing the requirements as they are
transformed into an operational system.
Unit 2: Requirements Modeling and Design
Requirement Engineering: when a business need is identified or
(1) Inception(આરંભ, શરૂઆત): How does a potential new market or service is
a software project get started? discovered.
Is there a single event that becomes Business mangers Stakeholders
- Do feasibility
the catalyst for a new computer- Marketing people analysis
based system or product, OR Product manager - Define business
Does the need evolve over time? case
- Identify depth and
In some cases, a casual conversation
breadth of the
is all that is needed to precipitate a market
major software engineering effort.
But in general, most projects begin
Unit 2: Requirements Modeling and Design
Requirement Engineering: needed, have a poor understanding of
the capabilities and limitations of their
(2) Elicitation(સ્પષ્ટતા): Ask customer computing environment, don’t have a
users and others what the objectives for full understanding of the problem
the product are: domain, have trouble communicating
What is to be done? needs to the system engineer, omit
How solution fits to business? information that is believed to be
Problems you may encounter during “obvious,” specify requirements that
elicitation: conflict with the needs of other
1) Problem of Scope: ill-defined customers / users, or specify
boundaries or unnecessary technical requirements that are ambiguous or
details specified. untestable.
2) Problems of Understanding: When 3) Problems of volatility: requirements
customers/users are not sure what is changes over time.
Unit 2: Requirements Modeling and Design
Requirement Engineering: limited business resources
(3) Elaboration: expand and refine the It’s also relatively common for
information received during inception different customers or users to
and elicitation. propose conflicting requirements,
Focuses on software function, arguing that their version is
behavior and information “essential for our special needs.”
Develop scenarios – how the user You need to negotiate the
will interact with the system. requirements in order to:
Develop class diagrams Rank requirements
Actor Use-case
System boundary
Association
Unit 2: Requirements Modeling and Design
Use Case Relationship:
INCLUDES. The includes relationship (also called uses relationship) describes the situation in which a
use case contains behavior that is common to more than one use case. In other words, the common use
case is included in the other use cases. A dotted arrow that points to the common use case indicates the
includes relationship. An example would be a use case Pay Student Fees that is included in Enroll in
Course and Arrange Housing, because in both cases students must pay their fees. This may be used by
several use cases. The arrow points toward the common use case.
EXTENDS. The extends relationship describes the situation in which one use case possesses the
behaviour that allows the new use case to handle a variation or exception from the basic use case. For
example, the extended use case Student Health Insurance extends the basic use case Pay Student Fees.
The arrow goes from the extended to the basic use case.
GENERALIZES. The generalizes relationship implies that one thing is more typical than the other
thing. This relationship may exist between two actors or two use cases. For example, a Part-Time Student
generalizes a Student. Similarly, some of the university employees are professors. The arrow points to
the general thing.
Unit 2: Requirements Modeling and Design
Example:
Unit 2: Requirements Modeling and Design
entities external to the software system which
Data Flow Diagrams interact with the system by inputting data to the
The DFD (also known as the bubble chart) is a system or by consuming the data produced by the
simple graphical formalism that can be used to system.
represent a system in terms of the input data to An external entity such as a librarian, a library
the system, various processing carried out on member, etc. is represented by a rectangle.
those data, and the output data generated by the In addition to the human users, the external entity
system. symbols can be used to represent external
A data flow diagram (DFD) maps out the flow of hardware and software such as another
information for any process or system. It uses application software that would interact with the
defined symbols like rectangles, circles and software being modelled.
arrows, plus short text labels, to show data inputs,
outputs, storage points and the routes between
each destination.
External entity
The external entities are essentially those physical
Unit 2: Requirements Modeling and Design
Primitive symbols used for constructing DFDs Data store symbol
A data store is represented using two parallel lines.
A directed arc (or an arrow) is used as a data flow symbol represents the entire data of the data store and hence
A data flow symbol represents the data flow occurring arrows connecting to a data store need not be annotated
between two processes or between an external entity and with the name of the corresponding data items.
a process in the direction of the data flow arrow. Output symbol
Data flow symbols are usually annotated with the The output symbol is used when a hard copy is produced.
0-level DFD
Unit 2: Requirements Modeling and Design
1-level DFD
Unit 2: Requirements Modeling and Design
2-level DFD
Unit 2: Requirements Modeling and Design
Unit 2: Requirements Modeling and Design
Example: (RMS Calculating Software) A software system called RMS calculating software would read three
integral numbers from the user in the range of –1000 and +1000 and would determine the root mean square (RMS) of
the three input numbers and display it.
Unit 2: Requirements Modeling and Design
Example: (Tic-Tac-Toe Computer Game): Tic-tac-toe is a computer game in which a human player and the computer
make alternate moves on a 3 × 3 square. A move consists of marking a previously unmarked square. The player who is
first to place three consecutive marks along a straight line (i.e., along a row, column, or diagonal) on the square wins.
As soon as either of the human player or the computer wins, a message congratulating the winner should be displayed.
If neither player manages to get three consecutive marks along a straight line, and all the squares on the board are filled
up, then the game is drawn. The computer always tries to win a game.
Unit 2: Requirements Modeling and Design
What is Design?
A meaningful representation of something to be
built
It’s a process by which requirements are
translated into blueprint for constructing a
software blueprint gives us the holistic view
(entire view) of a software
Software design is a mechanism to transform user
requirements into some suitable form, which helps
the programmer in software coding and
implementation. It deals with representing the
client's requirement, as described in SRS (Software
Requirement Specification) document, into a form,
i.e., easily implementable using programming
Unit 2: Requirements Modeling and Design
Software Design Process:
Unit 2: Requirements Modeling and Design
Analysis Model -> Design Model
Co m p o n e n t -
s c e na rio - ba s e d f lo w- o rie nt e d Le v e l D e s ig n
e le me nt s e le me nt s
us e-cas es - text data flow diagrams
us e-cas e diagrams control-flow diagrams
activity diagrams proces s ing narratives
s wim lane diagrams
In t e rf a c e D e s ig n
An a ly s is Mo de l
A rc h it e c t u ra l D e s ig n
c la ss- ba se d be ha v io ra l
e le me nt s e le me nt s
clas s diagrams s tate diagrams
analys is packages s equence diagrams
CRC models D a t a / Cla s s D e s ig n
collaboration diagrams
Desig n Mo d el
Unit 2: Requirements Modeling and Design
Design Model
Unit 2: Requirements Modeling and Design
Characteristics
design: of a good software should be logically partitioned
into elements or subsystems
1) The Design must be implement all 7) A design should contain distinct
explicit requirement available in representations of data, architecture,
requirements interfaces, and components.
2) The Design must accommodate all 8) A design should lead to data structures
implicit requirements given by that are appropriate for the classes to be
stakeholders implemented and are drawn from
3) The design must be readable & recognizable data patterns.
understandable 9) A design should lead to components
4) The good design should provide complete that exhibit independent functional
picture of software, addressing the data, characteristics.
functional and behavioral domains 10) A design should lead to interfaces that
reduce the complexity of connections
Quality Guidelines: between components and with the
external environment.
5) A design should exhibit an architecture
that (1) has been created using 11) A design should be derived using a
recognizable architectural styles or repeatable method that is driven by
patterns, (2) is composed of components information obtained during software
that exhibit good design characteristics requirements analysis.
and (3) can be implemented in an 12) A design should be represented using a
evolutionary fashion notation that effectively communicates
6) A design should be modular; that is, the its meaning.
Unit 2: Requirements Modeling and Design
Objectives of Software Design
Example
Unit 2: Requirements Modeling and Design
Modularity:
Advantages Disadvantages
It allows large programs to be written by several Execution time maybe, but not certainly,
or different people longer
It encourages the creation of commonly used Storage size perhaps, but is not certainly,
routines to be placed in the library and used by increased
other programs. Compilation and loading time may be longer
It simplifies the overlay procedure of loading a Inter-module communication problems may
large program into main storage. be increased
It provides more checkpoints to measure More linkage required, run-time may be
progress. longer, more source lines must be written, and
It provides a framework for complete testing, more documentation has to be done
more accessible to test
It produced the well designed and more readable
program.
Unit 2: Requirements Modeling and Design
Modularity and software cost:
Unit 2: Requirements Modeling and Design
4) Pseudo-code
Pseudo-code notations can be used in both the preliminary and detailed design phases. Using pseudo-
code, the designer describes system characteristics using short, concise, English Language phases
that are structured by keywords such as If-Then-Else, While-Do, and End.
It use keyword and indentation. Pseudo codes are used as replacement for flow charts