Professional Documents
Culture Documents
Design Engineering
Design Engineering
Design Engineering
-Amruta Patil
This courseware material are to be used in conjunction with "Software Engineering: A practioner's Appraoch" 7/e and
are provided with permission by R.S. Pressman and associates. The course material is also havind contents copied
from internet. Changes are made wrt Pune University Syllabus
Design Engineering
UNIT-III
Design Engineering
• Software design encompasses the set of principles, concepts, and practices that lead to the development of
a high-quality system or product.
• Design is pivotal to successful software engineering.
• The goal of design is to produce a model or representation that exhibits firmness, commodity, and delight.
• Software design sits at the technical kernel of software engineering and is applied regardless of the software
process model that is used.
• Software design is the last software engineering action within the modeling activity and sets the stage for
construction (code generation and testing).
• Each of the elements of the requirements provides information that is necessary to create the four design
models required for a complete specification of design.
The flow of information during software design is illustrated in Figure.
The data/class design:
• It 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.
• Part of class design may occur in conjunction with the design of software
architecture.
• More detailed class design occurs as each software component is designed.
The architectural design:
• It defines the relationship between major structural elements of the software, the
architectural styles and design patterns that can be used to achieve the
requirements defined for the system, and the constraints that affect the way in
which architecture can be implemented.
• The architectural design representation—the framework of a computer-based
system—is derived from the requirements model.
Hewlett-Packard developed a set of software quality attributes that has been given the
acronym FURPS –
1. Functionality is assessed by evaluating the feature set and capabilities of the program, the
generality of the functions that are delivered, and the security of the overall system.
2. Usability is assessed by considering human factors, overall aesthetics, consistency, and
documentation.
3. Reliability is evaluated by measuring the frequency and severity of failure, the accuracy of
output results, the mean-time-to-failure (MTTF), the ability to recover from failure, and the
predictability of the program.
4. Performance is measured by considering processing speed, response time, resource
consumption, throughput, and efficiency.
5. Supportability combines the ability to extend the program (extensibility), adaptability,
serviceability—these three attributes represent a more common term, maintainability—and
in addition, testability, compatibility, configurability.
Design Concepts
Software design concepts span both traditional and object-oriented software development
1. Abstraction:
A modular solution for any problem has many levels of abstraction.
a) Highest level - a solution is stated in broad terms
b) lower level - more detailed description of the solution is provided
c) lowest level - the solution is stated in a manner that can be directly implemented.
Two types:
a) Procedural abstraction: A sequence of instructions that have a specific and limited function.
Ex: Open the door
a) Data abstraction: A named collection of data that describes a data object.
Ex: Door is a data object
A set of attributes e.g. door type, swing direction, opening mechanism, weight, dimensions
2. Architecture:
Architecture is the structure or organization of program components or modules, the manner in
which these components interact, and the structure of data that are used by the components.
A set of properties that should be specified as part of an architectural design:
a) Structural properties – the components of a system (e.g., modules, objects, filters) and the
manner in which those components are packaged and interact with one another.
b) Extra-functional properties – how the design architecture achieves requirements for
performance, capacity, reliability, security, adaptability, and other system characteristics.
c) Families of related systems - the design should have the ability to reuse architectural building
blocks.
The architectural design can be represented using one or more of a number of different models
a) Structured Models - an organized collection of program components
b) Framework Models - by attempting to identify repeatable architectural design frameworks
c) Dynamic Models - the behavioral aspects of the program architecture
d) Process Models - focus on the design of the business or technical process
e) Functional Models - represent the functional hierarchy of a system
3) Patterns:
A design pattern describes a design structure that solves a particular design problem within a specific context.
The intent of each design pattern is to provide a description that enables a designer to determine
(1) whether the pattern is applicable to the current work
(2) whether the pattern can be reused (hence, saving design time), and
(3) whether the pattern can serve as a guide for developing a similar, but functionally or structurally
different pattern.
4) Separation of Concerns:
• A concern is a feature or behavior that is specified as part of the requirements model for the software.
• It suggests that any complex problem can be more easily handled if it is subdivided into pieces that can each
be solved and/or optimized independently.
• Divide-and-conquer strategy for software modularity
5) Modularity:
• Software is divided into separately named and addressable components i.e. modules, which are integrated
to satisfy problem requirements.
• Monolithic software cannot be easily grasped by a software engineer.
• Modularity reduce the cost required to build the software.
Fig: Modularity and
the software cost
7) Functional Independence:
• Functional independence is achieved by developing modules with “singleminded” function and an “aversion” to
excessive interaction with other modules
• One should design software so that each module addresses a specific subset of requirements.
• Independent modules are easier to maintain and test.
• Independence is assessed using two qualitative criteria
a) Cohesion - an indication of the relative functional strength of a module
b) Coupling - an indication of the relative interdependence among modules
• In software design, you should strive for the lowest possible coupling.
8) Refinement:
• Refinement is a process of elaboration.
• Elaborate on the original statement, providing more and more detail as each successive refinement occurs.
• Abstraction and refinement are complementary concepts.
• Refinement helps you to reveal low-level details as design progresses
9) Aspects:
• As requirements analysis occurs, a set of “concerns” is uncovered.
• An aspect is a representation of a crosscutting concern.
• It is important to identify aspects so that the design can properly accommodate them as refinement and
modularization occur.
10) Refactoring:
• Refactoring is a reorganization technique that simplifies the design (or code) of a component without changing its
function or behavior.
• When software is refactored, the existing design is examined for redundancy
The following design tasks are applied when a pattern-based design philosophy is used:
1. Examine the requirements model and develop a problem hierarchy. - Work from broad problems to
smaller subproblems
2. Determine if a reliable pattern language has been developed for the problem domain- ex: home
security products, digital device monitoring problems, user interface problems, digital video
management problems etc.
3. Beginning with a broad problem, determine whether one or more architectural patterns is available
for it.
4. Examine subsystem or component-level problems and search for appropriate patterns to address
them.
5. Repeat steps 2 through 5 until all broad problems have been addressed
6. If user interface design problems have been isolated, search the many user interface design pattern
repositories for appropriate patterns
7. Regardless of its level of abstraction, if a pattern language and/or patterns repository or individual
pattern shows promise, compare the problem to be solved against the existing pattern(s) presented.
8. Be certain to refine the design as it is derived from patterns using design quality criteria as a guide.
Building a Pattern-Organizing Table:
• Representations of software architecture are an enabler for communication between all parties
(stakeholders) interested in the development of a computer-based system.
• The architecture highlights early design decisions that will have a profound impact on all
software engineering work that follows and, as important, on the ultimate success of the system
as an operational entity.
• Architecture “constitutes a relatively small, intellectually graspable model of how the system is
structured and how its components work together” .
Architectural design decisions
• Architectural design is a creative process where you design a system organization that will satisfy
the functional and non-functional requirements of a system
1. Is there a generic application architecture that can act as a template for the system?
2. How will the system be distributed across a number of cores or processors?
3. What architectural patterns or styles might be used?
4. What will be the fundamental approach used to structure the system?
5. How will the structural components in the system be decomposed into subcomponents?
6. What strategy will be used to control the operation of the components in the system?
7. What architectural organization is best for delivering the non-functional requirements of the
system?
8. How will the architectural design be evaluated?
9. How should the architecture of the system be documented?
The architectural style and structure that you choose for a system is also dependent on the non-functional
requirements depending upon critical requirement.
1. Performance
2. Security
3. Safety
4. Availability
5. Maintainability
Evaluating an architectural design is difficult because the true test of an architecture is how well the system
meets its functional and non-functional requirements when it is in use.
Architectural views
• Views or perspectives are useful when designing and documenting a system’s architecture
1. A logical view
• shows the key abstractions in the system as objects or object classes.
• relate the system requirements to entities in this logical view.
2. A process view
• how, at run-time, the system is composed of interacting processes.
• useful for making judgments about nonfunctional system characteristics such as performance and availability.
3. A development view
• how the software is decomposed for development i.e. breakdown of the software
• useful for software managers and programmers.
4. A physical view
• shows the system hardware and how software components are distributed across the processors in the
system.
• useful for systems engineers planning a system deployment.
Architectural patterns
Patterns are way of presenting,
sharing, and reusing knowledge
about software systems.
Ex: Model-View-Controller
pattern
- Used as interaction
management in many web-based
systems
1. Layered architecture
• way of achieving separation and independence. Organizes the system into layers with related functionality associated with
each layer.
• A layer provides services to the layer above it, so the lowest-level layers represent core services that are likely to be used
throughout the system.
When used
• when building new facilities on top of existing systems
• when the development is spread across several teams with each team responsibility for a layer of functionality
• When there is a requirement for multi-level security.
Advantages
• Allows replacement of entire layers so long as the interface is maintained.
• Redundant facilities (e.g., authentication) can be provided in each layer to increase the dependability
Disadvantages
• providing a clean separation between layers is often difficult and a high-level layer may have to interact directly with
lower-level layers rather than through the layer immediately below it.
• Performance can be a problem because of multiple levels of interpretation of a service request as it is processed at each
layer.
Fig: A generic layered architecture
Fig: Architecture of library system
2. Repository architecture
• All data in a system is managed in a central repository that is accessible to all system components.
• Components do not interact directly, only through the repository.
When used
• when you have a system in which large volumes of information are generated that must be stored for a long
time.
• In data-driven systems where the inclusion of data in the repository triggers an action or tool.
Advantages
• Components can be independent—they do not need to know of the existence of other components.
• Changes made by one component can be propagated to all components.
• All data can be managed consistently (e.g., backups done at the same time) as it is all in one place.
Disadvantages
• The repository is a single point of failure so problems in the repository affect the whole system.
• May be inefficiencies in organizing all communication through
• Distributing the repository across several computers may be difficult.
Fig: Repository architecture for an IDE
3. Client Server architecture
• Clients are users of these services and access servers to make use of them.
When used
• When data in a shared database has to be accessed from a range of locations.
• Because servers can be replicated, may also be used when the load on a system is variable.
Advantages
• servers can be distributed across a network.
• General functionality (e.g., a printing service) can be available to all clients and does not need to be
implemented by all services.
Disadvantages
• Each service is a single point of failure so susceptible to denial of service attacks or server failure.
• Performance may be unpredictable because it depends on the network as well as the system.
• May be management problems if servers are owned by different organizations.
Fig: A client-server architecture of film library
3. Pipe and filter architecture
• run-time organization of a system where functional transformations process their inputs and produce
outputs.
• The data flows (as in a pipe) from one component to another for processing through each component(filter)
is discrete and carries out one type of data transformation.
When used
• Commonly used in data processing applications (both batch- and transaction-based) where inputs are
processed in separate stages to generate related outputs..
Advantages
• Easy to understand and supports transformation reuse.
• Workflow style matches the structure of many business processes.
• Can be implemented as either a sequential or concurrent system.
Disadvantages
• The format for data transfer has to be agreed upon between communicating transformations.
• Each transformation must parse its input and unparse its output to the agreed form. This increases system
overhead and may mean that it is impossible to reuse functional transformations.
Fig: Pipe and filter architecture.
Application architectures
• Application architectures encapsulate the principal characteristics of a class of systems
1. Transaction processing systems:
• A transaction is any coherent sequence of operations that satisfies a goal.
• Transaction processing (TP) systems are designed to process user requests for information from a database,
or requests to update a database.
• a library catalog, a flight timetable, or the records of patients in a hospital.
• For ex- find the times of flights from London to Paris
d) Streamline interaction as skill levels advance and allow the interaction to be customized.
f) Design for direct interaction with objects that appear on the screen.
Ex: an application interface that allows a user to “stretch” an object (scale it in size) is an implementation of
direct manipulation
2. Reduce the User’s Memory Load
a) Allow the user to put the current task into a meaningful context
c) If past interactive models have created user expectations, do not make changes unless there is a compelling reason to
do so.
e.g., The use of ctrl-S is to save a file, so the user expects this in every application he encounters.
Interface design models
• Four different models:
1. user model: A human engineer (or the software engineer)
2. design model: software engineer
3. mental model: end user
4. implementation model: implementers
As an interface designer, your role is to reconcile these differences and derive a consistent representation of
the interface.
• To build an effective user interface, all design should begin with an understanding of the intended users.
• Users can be categorized as
1. Novices : No syntactic knowledge of the system and little semantic knowledge
2. Knowledgeable, intermittent users: Reasonable semantic but relatively low recall of syntactic information
3. Knowledgeable, frequent users: Good semantic and syntactic knowledge
The Process
During this interface analysis step, the format and aesthetics of the content (as it is displayed by the interface)
are considered.
The work influenced by the activity around them, the physical characteristics of the workplace, the type of
equipment they are using, and the work relationships they have with other people.
Interface Design Steps
• Each user interface design step occurs a number of times, elaborating and refining information.
• Steps:
1. Applying Interface Design Steps
• Define Object and actions iteratively.
• Perform screen layout
2. User Interface Design Patterns
Ex: Entering the calendar days
3. Design Issues
• system response time
• user help facilities
• error information handling
• Menu and command labeling
4. Application accessibility
5. Internationalization
Design Evaluation
Evaluation criteria:
1. The length and complexity of the requirements model
2. Interaction time and the overall efficiency of the
system.
3. the memory load on users of the system
4. complexity of the interface and the degree to which it
will be accepted by the user.
62
63
64
65