Professional Documents
Culture Documents
Maintainability
Understandability
Changeability
Simplicity
Reusability
The solution to a problem should be as general as
possible
User friendliness
Efficiency
Some interesting numbers
About 25% of s/w projects fail
Failure rate increases as the size of the project
increases
Costs about $100/LOC
Ranges between $10-$600
Typical programmer produces about 30 LOCs
a day
Ranges between 10-100 LOCs
25 faults/KLOC
Ranges between 3-100 faults/KLOC
Software costs
Development costs
generally measured in hundreds to thousands of
dollars per delivered LOC
many artifacts associated with a line of code
testing and analysis is usually 50% of this cost
Maintenance costs
2-3 times as much as development
Software Costs
Development costs
testing
50%
reqts/design testing
maintenance
Models
Software code is too complex to reason
about it directly
Need a higher level representation, called
design
Captures only the most important relevant
characteristics of the problem
Needs to capture the behavior of the problem
accurately
Software code must conform to its design
Software Engineering
Projection
1000
638
475
142
113
Expansion
100 75 81
Factor
47
37.5
The ratio 30
of machine
lines of 15
code to a 10
source line
of code
3
Order of Magnitude Increase Every Twenty Years
1
1960 1965 1970 1975 1980 1985 1990 1995 2000
Machine Macro High Level Database On-line Prototyping Subsecond Object Large Scale
Instructions Assembler Language Manager Time Oriented Reuse
Sharing Programming
Regression 4GL Small
Testing Scale
Reuse
What is novel about software, compared to
other fields of engineering?
product is unprecedentedly complex
application horizons expand too fast--with
human demands/imagination
construction is human-intensive
solutions require unusual rigor
extremely malleable--can modify the product
all too easily
How to increase Software Quality
design specs
validation
coding
validation
testing
adequacy
maintenance
revalidation
Waterfall Model
requirements-- a complete,consistent
specification of what is needed
providesvisibility for customers, developers, and
managers
benchmark for testing and acceptance
reduces misunderstandings
requirements analysis
evaluate completeness and consistency
evaluate needs and constraints
evaluate feasibility and costs
design validation
traceability between requirements and design
decisions
internal consistency
Waterfall Model (continued)
testing validation
adequacy of the testcases
Waterfall Model (continued)
software houses
intenselycompetitive
often don't use own technology
keep development cost down, fix later
unsophisticated industries
lack of technical expertise
lack of administrative experience
Scientific basis
Organized discipline
R&D strategy
Trained professionals
Technology transfer strategies
Quality control
Certification and Licensing?
what is it doing?
Has a set of possible behaviors
field 1
…
field n
method 1
…
method n
Example: class Tree
UML Java
Class Tree {
private float height_;
private int noOfBranches_;
private Classification species_;
Example:
Inheritance (cont.)
Multiple levels of inheritance are possible
Subclasses inherit attributes and methods of
their superclasses
Important OO principles: polymorphism
A related but different kinds of functionality
can be implemented by several different
modules
If the interfaces to all these modules are
the same, they can be used in exactly the
same way
In the program, a module being used can be
changed dynamically, as long as the interface
remains the same
Important OO concepts: aggregation
Aggregation is a relationship where one class
is a part of another
Important OO concepts: association
Association is a general relationship among
two classes
Class diagram for a game of dice
Modeling dynamic behaviors: state and
sequence diagrams
Static behavior represents relationships
among classes
Classdiagrams
inheritance
aggregation
association
Dynamic behavior represents interactions
among objects
State diagrams
Sequence diagrams
State diagrams
Represent all possible behaviors of an object
Consist of states and transitions
At any moment of time, an object is in some state
Doing something
Having certain qualities
A transition represents the object moving from one
state to another
Transitions are triggered by events
May have guards and side-effects
Has a start state
May have a final state
Car
This class serves as a
very general type of
a car. You have to
instantiate one of its
children