Modelling
Module-2
Software Design
Software Design
• Software design is a process to transform user
requirements into some suitable form, which helps
the programmer in software coding and
implementation.
• Software design focusses on the solution
domain of the system.
• Once SRS document is created whereas for coding
and implementation, there is a need of more specific
and detailed requirements in software terms.
• The output of this process can directly be used into
implementation in programming languages
• Design is what almost every engineer wants to
do. It is the place where creativity rules
Objectives of software design
Other objectives/characteristics of
software design:
Portability
Modularity
Coupling(Coupling refers to the degree
of interdependence between software
modules)
Cohesion(Cohesion refers to the degree
to which elements within a module work
together to fulfil a single, well-defined
purpose)
Reusability
Objectives of software design
Design within The Context of Software Engineering
Software design sits at the technical
kernel of software engineering and is
applied regardless of the software
process model that is used.
Beginning once software requirements
have been analysed and modelled,
software design is the last software
engineering action within the modelling
activity and sets the stage for
construction (code generation and
testing)
Translation of requirement model into design
model
Data/class design:
The data/class design transforms class models into design class realizations and the
requisite data structures required to implement the software.
The objects and relationships defined in the CRC diagram and the detailed data content
depicted by class attributes and other notation provide the basis for the data design
action.
Architectural design:
It defines the relationship between major structural elements of the software, the
architectural styles, and design patterns.
Interface design:
The interface design describes how the software communicates with systems that
interoperate with it, and with humans who use it.
An interface implies a flow of information (e.g., data and/or control) and a specific type of
behaviour. Therefore, usage scenarios and behavioural models provide much of the
information required for interface design.
Component based design:
Information obtained from the class-based models, flow models, and behavioural models
serve as the basis for component design.
Design Process
The design phase of software development deals with transforming the customer
requirements as described in the SRS documents into a form implementable using a
programming language.
Basic elements of a software design model:
Architecture – This is the conceptual model that defines the structure, behaviour, and
views of a system.
Modules – These are components that handle one specific task in a system.
Components – This provides a particular function or group of related functions. They
are made up of modules.
Interfaces – This is the shared boundary across which the components of a system
exchange information and relate.
Data – This is the management of the information and data flow.
Design process (contd.)
Interface design:
Specification of the interaction between a
system and its environment.
this phase proceeds at a high level of
abstraction with respect to the inner workings
of the system .
Architectural design:
Architectural design is the specification of the
major components of a system, their
responsibilities, properties, interfaces, and
the relationships and interactions between
them.
Overall structure of the system is chosen.
internal details of major components are
ignored.
Detail design:
Refers to Algorithmic design of each module
in the system. Also called logical design.
Concentrates on algorithm specification, data
structures associated with it, etc.
Detail design can directly converted to source
code using programming language.
Design and quality
Throughout the design process, the quality of the evolving design is assessed
with a series of formal technical reviews.
Guidelines of design quality
Design principles
Design concepts
Abstraction
Describing the problem at higher level.
Concentrate only essential details, hiding internal details.
Architecture Word pad
Demonstrate the external behaviour of the system.
Provide a conceptual view.
Information hiding
File
Modules hide internal details to other module. saving editing
creation
Prevent unauthorized access from internal and external
environments.
Functional decomposition Save as save
System decompose in multiple functional modules
Modularity
background
Emphasize on number of modules a system could be Font style
colour
divided to produce quality product.
Modularity
Coupling
Lowest Cohesion
• Message coupling Strongest (best)
(best) • Functional cohesion
• Communicate through message passing
• Single function in module
• Data coupling • Sequential cohesion
• Data are passed as parameter/arguments
• Output of one module input to other
• Stamp coupling • Communicational cohesion
• Modules shares entire data structures • Elements operate on same input or output data
• Control coupling • Procedural cohesion
• One module controls the execution of instructions • Elements are bound to same procedural unit
of other module (flag)
• Temporal cohesion
• External coupling
• Module contain different function, but activated or
• Share external devices deactivated at same time
• Common coupling • Logical cohesion
• Global variable • Logically related sub modules are connected
• Content coupling together
• Local variables Highest • Coincidental cohesion Weakest (worst)
(worst) • Simple combination of modules with no relation
between them