Introduction To Software Design
Introduction To Software Design
Design
• One of the most distinctive of human characteristics is the making of, and
the use of, tools.
• A second distinguishing characteristic of human beings that provides an
underpinning for any form of design activity is that of communication.
Translating a ‘design’ into a ‘product’.
• Communication also plays another, rather different, role in design
activities. This is to act as the vehicle by which experience and expertise
are transferred from ‘expert’ to ‘novice’, as well as shared amongst a
community of experts.
• Our perception of the importance of the roles that design may play in
producing these different artifacts will vary, although it may not always be
correct.
• Communication plays an important role for good design. However, an
equally important channel of communication is with the source of the
‘requirements’ specification that a designer is being asked to address.
• Software designer may need to acquire some degree of ‘domain
knowledge’ as a routine part of the input needed for undertaking any
particular design task.
• The static structure of the system, including any subprograms to be
used and their hierarchy.
• Any data objects to be used in the system.
• The algorithms to be used.
• The packaging of the system, in terms of how components are
grouped in compilation units.
• Interactions between components, including the form these should
take, and the nature of any causal links.
• These are all concerned with specifying the form of the design
product itself. But as was observed above, the overall design task may
also involve producing process oriented plans too.
• Software designers produce plans that specify how the final product
is to be assembled in terms of the items listed earlier.
• For designing software consists of designing a process; and so it
becomes necessary to model and describe its behaviour as well as its
structure, and also the functions that it will perform.
Design as a problem-solving process
• The purpose of design is simply to produce a solution to a problem.
• The problem will typically be summarized by means of some form of
requirements specification, and it is the designer’s task to provide a
description of how that requirement is to be met.
• Design methods and patterns can provide strategies that will help to
determine which choice may be most appropriate in a given situation.
• Representations can also help with the process of building models of the
intended system and with evaluating its behaviour.
• Abstraction enables the designer to concentrate effort on building a logical
model of a system, which is translated into a physical model at a relatively
late stage in the design process.
Design as a ‘wicked’ problem
• There is no definitive formulation of a wicked problem.
• Wicked problems have no stopping rule.
• Solutions to wicked problems are not true or false, but good or bad.
• There is no immediate and no ultimate test of a solution to a wicked
problem.
• Every solution to a wicked problem is a ‘one-shot operation’, because
there is no opportunity to learn by trial-and-error, every attempt
counts significantly.
• Wicked problems do not have an enumerable set of potential
solutions.
• Every wicked problem is essentially unique.
• Every wicked problem can be considered to be a symptom of another
problem.
Building models
• The difficulties involved in creating software-based systems have long
been recognized. While apparently related technology such as
hardware design and production has raced along gaining orders of
magnitude in performance, and similarly reducing price and size,
software development techniques seem to have inched along in a
series of relatively small steps.
• Brooks cites the following properties of software as major factors
affecting its development.
• Complexity
• Conformity
• Changeability
• Invisibility
• The use of abstract ‘mental models’ by the designer to simulate the
dynamic behaviour of the eventual system that will be derived from
the design.
• Expanding the detail of a model in a systematic manner by keeping all
elements of the design at the same level of detail as they are
developed. This then aids the task of simulation.
• The need to make any constraints affecting the design as explicit as
possible when handling an unfamiliar problem.
• Reuse of previous design plans.
• Making notes about future (detailed) intentions
Transferring design knowledge
Exceptional designers were observed to possess three significant
characteristics:
• Familiarity with the application domain
• Skill in communicating technical vision to other project members
• Identification with project performance
When we look at how successful designers work, there are other
factors to consider:
• to postpone a decision, if the information required is not yet available
at this design level;
or
• to process information that is readily to hand, and which can be used
for defining modules in anticipation of further developments in the
design.
opportunistic
• Software design method can be considered as providing a supportive
framework that consists of two major components:
• The representation part provides a set of descriptive forms that the designer
can use for building both black box and white box models of the problem and
their ideas for its solution, and for describing the structural features of the
solution to the eventual implementors.
• The process part is concerned with describing how the necessary
transformations between the representation forms are to be organized, as
well as with any elaboration of their detail that might be required.
A set of heuristics that can be used to provide guidelines for specific classes of
problem.
Design Qualities
• In order to achieve high standards of quality in products, one needs
to seek high standards of quality in the design process.
• Unfortunately, quality is a concept that can rarely be related to any
absolutes, and even for manufactured items ideas about quality
usually cannot be usefully measured on any absolute scale. The best
that we can usually do is to rank items on an ordinal scale.
• Since software is such an abstract product that the concept of quality
is equally difficult to define for software. Few quality attributes can be
quantified in any way, and those measures that we do possess are of
uneven value.
• We also encounter once again the dual nature of software in thinking
about how we can identify its quality. Software has both static and
dynamic attributes, and so any set of measures that we can develop
should seek to assess both of these, and should recognize the
potential for conflict between them.
Assessing design quality
“When you can measure what you are speaking about, and express it in
numbers, you know something about it, but when you cannot measure
it, when you cannot express it in numbers, your knowledge is of a
meagre and unsatisfactory kind.”
• Quality concepts
• Design attributes
• Counts
The ‘ilities’
• The ‘ilities’ form a group of quality factors that need to be considered
when making any attempt to assess design quality:
• Reliability: concerned with the dynamic characteristics of the eventual system
• Complete
• Consistent
• Robust
• Efficiency
• Maintainability
• Usability
Cognitive dimensions
• Premature commitment
• Hidden dependencies
• Secondary notation
• Viscosity
Quality attributes of the design product
• Simplicity
• Modularity
• Information-hiding
Assessing design quality
• well structured: consistent with chosen properties such as information-
hiding
• simple: to the extent of being ‘as simple as possible, but no simpler’
• efficient: providing functions that can be computed using the available
resources
• adequate: meeting the stated requirements
• practical: module interfaces should provide the required facilities, neither
more nor less
• implementable: using current and available software and hardware
technology
• standardized: using well-defined and familiar notation for any
documentation
Assessing the design process
• There are three widely adopted ways of providing these inputs to the
design process
• Technical reviews
• Management reviews
• Prototyping
Representing abstract ideas
• A representation is used to provide a particular abstraction of the
characteristics of a system, and is typically needed for such purposes
as:
• capturing the designer’s ideas for a solution
• explaining the designer’s ideas to others
• checking for consistency and completeness in a solution
Design viewpoints for software
• Software is not only an abstraction, it is also the description of a
process.
• In order to describe system-oriented properties, the designer usually
needs forms that describe the dynamic behaviour of the system.
• For more detailed solution-oriented design needs, which are often
concerned with describing ‘constructional’ issues such as packaging,
procedure hierarchy, and data organization, the chosen forms will
generally focus on static design attributes.
• constructional forms, in which the viewpoint is concerned with
essentially static aspects of the system
• behavioural forms, a set of viewpoints that seek to describe the
causal links between events and system responses during execution
• functional forms, viewpoints that seek to describe what the system
does in terms of its tasks
• data-modelling forms, concerned with the data objects used within
the system, and the relationships between these
• Constructional forms
• data specification
• threads of execution
• packaging constructs
• Behavioural forms
• sequencing aspects can be described fairly well
• fixed-interval descriptions are also fairly tractable, although their use is
mainly restricted to particular features of real-time systems
• constraint
• Functional forms
• One of the hardest tasks for the designer is to describe exactly what it is that
a system does. This is essentially a problem-driven issue and hence is difficult
to describe in any general form.
• Data-modelling forms
• While the description of data structures need not be a very significant issue in
architectural design terms, it is often a critical aspect of a detailed design.
Again, there are a number of relationships that may need to be captured.
• These include: type and sequence
Forms of notation
• Text
• Diagrams
• Mathematical expressions
The DFD viewpoint
The Entity–Relationship Diagram
The Jackson Structure Diagram
• It is basically concerned with describing sequential structure, in terms
of the three ‘classical’ structuring forms:
• Sequence
• Selection
• Iteration
• A white box notation can be viewed as one that is largely concerned
with describing some aspect of the detailed realization of a design
element. It tends to be associated with the constructional and
functional viewpoints.
The Structure Chart
Class and object diagrams
Sequence Diagrams
• We need to consider design processes and strategies in rather more
detail. This is because each of the procedural steps of any design
method, regardless of the strategy employed, can usually be classified
as being one of those two forms.
• transformation step: the designer modifies the structuring for their model of
the ‘system’ in some way.
• elaboration step: does not usually involve any change of viewpoint, but is
more concerned with restructuring or reorganizing the design model within
the current viewpoint.
D-Matrix
• The D-Matrix (short for ‘Design Matrix’) notation, is intended to
provide an abstract description of the state of the ‘design model’ at
any point in its evolution.
• The D-Matrix is totally independent of any specific methods; indeed it
can be used to describe not only method processes but also to record
quite opportunistic sequences of design activities.
• The basic assumption for this notation is that any design (or
requirements) specification can be composed from the specifications
for a set of ‘design elements’ (or ‘requirements elements’), where
each element can itself be described in terms of a set of attributes
that describe the properties associated with the four major
viewpoints.
• function
• behaviour
• data model
• construction
• Example: