2@software Reliability
2@software Reliability
Software Reliability
Basic Concepts
There are three phases in the life of any hardware component i.e.,
burn-in, useful life & wear-out.
In burn-in phase, failure rate is quite high initially, and it starts
decreasing gradually as the time progresses.
During useful life period, failure rate is approximately constant.
Failure rate increase in wear-out phase due to wearing out/aging of
components. The best period is useful life period. The shape of this
curve is like a bath tub and that is why it is known as bath tub
curve. The bath tub curve is given in Fig.1.
Software Reliability
Software Reliability
We do not have wear out phase in software. The expected curve for
software is given in fig. 2.
Software Reliability
Software may be retired only if it becomes obsolete. Some of
contributing factors are given below:
change in environment
change in infrastructure/technology
major change in requirements
increase in complexity
extremely difficult to maintain
deterioration in structure of the code
slow execution speed
poor graphical user interfaces
Software Reliability
What is Software Reliability?
Software reliability means operational reliability. Who cares how
many bugs are in the program?
As per IEEE standard: Software reliability is defined as the ability of
a system or component to perform its required functions under
stated conditions for a specified period of time.
Software Reliability
Software reliability is also defined as the probability that a software
system fulfills its assigned task in a given environment for a
predefined number of input cases, assuming that the hardware and
the inputs are free of error.
It is the probability of a failure free operation of a program for a
specified time in a specified environment.
Software Reliability
Software Reliability
There are four general ways of characterising failure occurrences in
time:
1. time of failure,
2. time interval between failures,
3. cumulative failure experienced up to a given time,
4. failures experienced in a time interval.
Software Reliability
Failure Number
18
10
25
36
11
45
57
12
71
14
86
15
104
18
10
124
20
11
143
19
12
169
26
13
197
28
14
222
25
15
250
28
10
Software Reliability
Time (sec)
Cumulative Failures
30
60
90
120
150
11
180
12
210
13
240
14
Software Reliability
Value of random
variable (failures
in time period)
Probability
Elapsed time tA = 1 hr
Elapsed time tB = 5 hr
0.10
0.01
0.18
0.02
0.22
0.03
0.16
0.04
0.11
0.05
0.08
0.07
0.05
0.09
0.04
0.12
0.03
0.16
0.02
0.13
12
Software Reliability
Value of random
variable (failures
in time period)
Probability
Elapsed time tA = 1 hr
Elapsed time tB = 5 hr
10
0.01
0.10
11
0.07
12
0.05
13
0.03
14
0.02
15
0.01
Mean failures
3.04
7.77
Software Reliability
A random process whose probability distribution varies with time to
time is called non-homogeneous. Most failure processes during test
fit this situation. Fig. 3 illustrates the mean value and the related
failure intensity functions at time tA and tB. Note that the mean
failures experienced increases from 3.04 to 7.77 between these two
points, while the failure intensity decreases.
Failure behaviour is affected by two principal factors:
Software Reliability
15
Software Reliability
Environment
The environment is described by the operational profile. The
proportion of runs of various types may vary, depending on the
functional environment. Examples of a run type might be:
Software Reliability
The run types required of the program by the environment can be
viewed as being selected randomly. Thus, we define the operational
profile as the set of run types that the program can execute along
with possibilities with which they will occur. In fig. 4, we show two of
many possible input states A and B, with their probabilities of
occurrence.
The part of the operational profile for just these two states is shown
in fig. 5. A realistic operational profile is illustrated in fig.6.
17
Software Reliability
18
Software Reliability
Software Reliability
Software Reliability
Fig.7 shows how failure intensity and reliability typically vary during
a test period, as faults are removed.
21
Software Reliability
Uses of Reliability Studies
There are at least four other ways in which software reliability
measures can be of great value to the software engineer, manager
or user.
1. you can use software reliability measures to evaluate software
engineering technology quantitatively.
2. software reliability measures offer you the possibility of
evaluating development status during the test phases of a
project.
22
Software Reliability
3. one can use software reliability measures to monitor the
operational performance of software and to control new features
added and design changes made to the software.
4. a quantitative understanding of software quality and the various
factors influencing it and affected by it enriches into the
software product and the software development process.
23
Software Reliability
Software Quality
Different people understand different meanings of quality like:
conformance to requirements
fitness for the purpose
level of satisfaction
24
Software Reliability
25
Software Reliability
26
Software Reliability
1
Reliability
Correctness
The extent to
specifications.
Consistency &
precision
Robustness
Simplicity
Traceability
Usability
which
software
meets
its
27
Software Reliability
8
Accuracy
Clarity &
Accuracy of
documentation
10
Conformity of
operational
environment
11
Completeness
12
Efficiency
13
Testability
14
Maintainability
Software Reliability
15
Modularity
16
Readability
17
Adaptability
18
Modifiability
19
Expandability
20
Portability
Software Reliability
30
Software Reliability
i.
Product Operation
Correctness
Efficiency
Integrity
Reliability
Usability
Software Reliability
ii. Product Revision
The factors which are required for testing & maintenance are
combined and are given below:
Maintainability
Flexibility
Testability
Software Reliability
iii. Product Transition
We may have to transfer a product from one platform to an other
platform or from one technology to another technology. The factors
related to such a transfer are combined and given below:
Portability
Reusability
Interoperability
33
Software Reliability
Most of the quality factors are explained in table 4. The remaining
factors are given in table 5.
Sr.No.
Quality Factors
Purpose
Integrity
Flexibility
Reusability
Interoperability
Quality criteria
35
Software Reliability
Table 5(a):
Relation
between quality
factors and
quality criteria
36
Software Reliability
1
Operability
Training
I/O volume
I/O rate
Access control
Access audit
Storage efficiency
Execution efficiency
Software Reliability
10
Traceability
The ability to
requirements.
link
software
components
to
11
Completeness
12
Accuracy
13
Error tolerance
14
Consistency
15
Simplicity
16
Conciseness
17
Instrumentation
Software Reliability
18
Expandability
19
Generability
20
Selfdescriptiveness
21
Modularity
22
Machine
independence
23
Software system
independence
24
Communication
commonality
25
39
Software Reliability
40
Software Reliability
ISO 9126
Functionality
Reliability
Usability
Efficiency
Maintainability
Portability
41
Software Reliability
Characteristic/
Attribute
Functionality
Suitability
Accuracy
Interoperability
Security
Reliability
Maturity
Software Reliability
Fault tolerance
Recoverability
Usability
Operability
Efficiency
Software Reliability
Time behaviour
Resource
behaviour
Maintainability
Analyzability
Changeability
Stability
Testability
Software Reliability
Portability
Adaptability
Installability
Conformance
Replaceability
Table 6: Software quality characteristics and attributes The ISO 9126 view
45
Software Reliability
46
Software Reliability
Software Reliability Models
( ) 0
1
V0
(7.1)
Software Reliability
d 0
d
V0
(7.2)
48
Software Reliability
For a derivation of this relationship, equation 7.1 cab be written as:
d ( )
( )
0 1
d
V0
( ) V0
0
1 exp
V0
(7.3)
49
Software Reliability
The failure intensity as a function of execution time is shown in
figure given below
0
( ) 0 exp
V0
50
Software Reliability
Derived quantities
Software Reliability
V0 P
Ln
0 F
52
Software Reliability
Example- 1
Assume that a program will experience 200 failures in infinite time. It has
now experienced 100. The initial failure intensity was 20 failures/CPU hr.
(i) Determine the current failure intensity.
(ii) Find the decrement of failure intensity per failure.
(iii) Calculate the failures experienced and failure intensity after 20 and 100
CPU hrs. of execution.
(iv)Compute addition failures and additional execution time required to
reach the failure intensity objective of 5 failures/CPU hr.
Use the basic execution time model for the above mentioned calculations.
53
Software Reliability
Solution
Here
Vo=200 failures
100 failures
0 20 failures/CPU hr.
(i) Current failure intensity:
( ) 0
1
V0
100
20 1
20(1 0.5) 10 failures/CPU hr
200
54
Software Reliability
(ii) Decrement of failure intensity per failure can be calculated as:
d 0
20
( ) V0 1 exp
V0
20 20
200 1 exp
200
55
Software Reliability
20 exp
( ) 0 exp
V0
20 20
20 exp(2) 2.71 failures / CPU hr
200
(b) Failures experienced & failure intensity after 100 CPU hr:
( ) V0
0
1 exp
V0
20 100
200 1 exp
200
200 failures(almost)
0
( ) 0 exp
V0
56
Software Reliability
20 100
20 exp
0.000908 failures / CPU hr
200
V0
200
P F
(10 5) 50 failures
20
0
57
Software Reliability
Additional execution time required to reach failure intensity objective
of 5 failures/CPU hr.
V0
P
Ln
F
0
200 10
Ln
6.93 CPU hr.
20
5
58
Software Reliability
( ) 0 exp( )
59
Software Reliability
d
0 exp( )
d
d
d
Software Reliability
1
( ) Ln(0 1)
( ) 0 /(0 1)
1 P
Ln
F
1 1
1
F P
(7.3)
61
Software Reliability
Example- 2
Assume that the initial failure intensity is 20 failures/CPU hr. The failure
intensity decay parameter is 0.02/failures. We have experienced 100
failures up to this time.
(i) Determine the current failure intensity.
(ii) Calculate the decrement of failure intensity per failure.
(iii) Find the failures experienced and failure intensity after 20 and 100 CPU
hrs. of execution.
(iv)Compute the addition failures and additional execution time required to
reach the failure intensity objective of 2 failures/CPU hr.
Use Logarithmic Poisson execution time model for the above mentioned
calculations.
62
Software Reliability
Solution
0 20 failures/CPU hr.
100 failures
0.02 / failures
(i) Current failure intensity:
( ) 0 exp( )
= 20 exp (-0.02 x 100)
= 2.7 failures/CPU hr.
63
Software Reliability
(ii) Decrement of failure intensity per failure can be calculated as:
d
d
= -.02 x 2.7 = -.054/CPU hr.
(iii) (a) Failures experienced & failure intensity after 20 CPU hr:
( )
1
Ln 0 1
Software Reliability
( ) 0 / 0 1
(20) /(20 .02 20 1) 2.22 failures / CPU hr.
(b) Failures experienced & failure intensity after 100 CPU hr:
( )
1
Ln 0 1
( ) 0 / 0 1
(20) /( 20 .02 100 1) 0.4878 failures / CPU hr.
65
Software Reliability
(iv) Additional failures required to reach the failure intensity
objective of 02 failures/CPU hr.
1
P
1
2.7
Ln
Ln
15 failures
F 0.02 2
1 1
1
1 1 1
F P 0.02 2 2.7
66
Software Reliability
Example- 3
The following parameters for basic and logarithmic Poisson models are
given:
(a) Determine the addition failures and additional execution time required to
reach the failure intensity objective of 5 failures/CPU hr. for both models.
(b) Repeat this for an objective function of 0.5 failure/CPU hr. Assume that
we start with the initial failure intensity only.
67
Software Reliability
Solution
(a) (i) Basic execution time model
V0
(P F )
0
100
(10 5) 50 failures
10
V0 P
Ln
0 F
(initial
68
Software Reliability
100 10
Ln
6.93 CPU hr.
10
5
(ii) Logarithmic execution time model
1 P
Ln
F
1
30
Ln
71.67 Failures
0.025 5
1 1
1
F P
1
1 1
69
Software Reliability
Logarithmic model has calculated more failures in almost some duration of
execution time initially.
V0
P F
0
100
V0 P
Ln
0 F
100 10
Ln
30 CPU /hr
10
0.05
70
Software Reliability
(ii) Logarithmic execution time model
1 P
Ln
F
1
30
Ln
164 failures
0.025 0.5
1 1
1
F P
1 1
1
78.66 CPU/hr
0.025 0.5 30
71
Software Reliability
Software Reliability
Resource usage
Usage parameters
requirements per
Resource
Planned parameters
CPU hr
Failure
Quantities
available
Utilisation
Failure identification
personnel
PI
Failure correction
personnel
Pf
Pf
Computer time
Pc
Pc
73
Software Reliability
Hence, to be more precise, we have
X C c c
X f f
X I I I
dxT / d r r
74
Software Reliability
Calendar time to execution time relationship
dt / d (1 / Pr pr )dxT / d
dt / d ( r r ) / Pr pr
75
Software Reliability
Software Reliability
77
Software Reliability
Example- 4
A team run test cases for 10 CPU hrs and identifies 25 failures. The effort
required per hour of execution time is 5 person hr. Each failure requires 2
hr. on an average to verify and determine its nature. Calculate the failure
identification effort required.
78
Software Reliability
Solution
As we know, resource usage is:
X r r r
Here
Hence,
r 15 person hr.
25 failures
10 CPU hrs.
r 2 hrs./failure
Xr = 5 (10) + 2 (25)
= 50 + 50 = 100 person hr.
79
Software Reliability
Example- 5
Initial failure intensity ( ) for a given software is 20 failures/CPU hr. The
0
failure intensity objective ( ) of 1 failure/CPU hr. is to be achieved.
F
Resource Usage
Failure identification effort
Failure Correction effort
Computer time
Per hour
Per failure
2 Person hr.
1 Person hr.
5 Person hr.
1 CPU hr.
80
Software Reliability
(a) What
resources
must
be
expended
to
achieve
the
reliability
81
Software Reliability
Solution
(a)
1 P
Ln
F
1
20
Ln
119 failures
0.025 1
1 1
1
F P
1 1 1
1
1 0.05 38 CPU hrs.
0.025 1 20 0.025
82
Software Reliability
Hence
X1 1 1
= 1 (119) + 2 (38) = 195 Person hrs.
X F F
= 5 (119) = 595 Person hrs.
X C c c
= 1 (119) + (1.5) (38) = 176 CPU hr.
83
Software Reliability
(b)
1
20
Ln
148 failures
0.025 0.5
1 1
1
78 CPU hr.
0.025 0.5 20
So,
Software Reliability
Hence, if we cut failure intensity objective to half, resources requirements
are not doubled but they are some what less. Note that
is
85
Software Reliability
Example- 6
A program is expected to have 500 faults. It is also assumed that one fault
may lead to one failure only. The initial failure intensity was 2 failures/CPU
hr. The program was to be released with a failure intensity objective of 5
failures/100 CPU hr. Calculated the number of failure experienced before
release.
86
Software Reliability
Solution
The number of failure experienced during testing can be calculated using
the equation mentioned below:
V0
P F
0
Here
0 2 failures/CPU hr.
Software Reliability
So
500
2 0.05
2
= 487 failures
88
Software Reliability
(t ) ( N i 1)
where
= Constant of proportionality
N = Total number of errors present
I = number of errors found by time interval ti
89
Software Reliability
Software Reliability
Example- 7
There are 100 errors estimated to be present in a program. We have
experienced 60 errors. Use Jelinski-Moranda model to calculate
failure intensity with a given value of =0.03. What will be failure
intensity after the experience of 80 errors?
91
Software Reliability
Solution
N = 100 errors
i = 60 failures
= 0.03
We know
(t ) 0.03(100 80 1)
= 0.03(100-60+1)
= 1.23 failures/CPU hr.
After 80 failures
(t ) 0.03(100 80 1)
= 0.63 failures/CPU hr.
Software Reliability
Nt
nt
N N t n nt
n
N Nt
nt
n
N Ns
ns
93
Software Reliability
94
Software Reliability
Maturity Levels:
Initial (Maturity Level 1)
Repeatable (Maturity Level 2)
Defined (Maturity Level 3)
Managed (Maturity Level 4)
Optimizing (Maturity Level 5)
95
Software Reliability
Maturity Level
Characterization
Initial
Adhoc Process
Repeatable
Defined
Process Definition
Managed
Process Measurement
Optimizing
Process Control
Software Reliability
97
Software Reliability
The key process areas at level 3 address both project and
organizational issues, as summarized below:
98
Software Reliability
99
Software Reliability
The key process areas at level 4 focus on establishing a quantitative
understanding of both the software process and the software work
products being built, as summarized below:
100
Software Reliability
The key process areas at level 5 cover the issues that both the
organization and the projects must address to implement continuous
and measurable software process improvement, as summarized
below:
101
Software Reliability
Common Features
102
Software Reliability
ISO 9000
Software Reliability
1. Management responsibility
2. Quality system
3. Contract review
4. Design control
5. Document control
6. Purchasing
7. Purchaser-supplied product
104
Software Reliability
8. Product identification and traceability
9. Process control
10. Inspection and testing
11. Inspection, measuring and test equipment
12. Inspection and test status
13. Control of nonconforming product
14. Corrective action
105
Software Reliability
15. Handling, storage, packaging and delivery
16. Quality records
17. Internal quality audits
18. Training
19. Servicing
20. Statistical techniques
106
Software Reliability
107
108
109
(a ) ( ) 0 1
V
0
(b) ( ) 0 1
V0
V
(c) ( ) 0 1 0
V
(d ) ( ) 0 1 02
V0
( P F )
0
0
(c) (F P )
V0
(a )
V0
( F P )
0
0
(d ) (P F )
V0
(b)
112
(a )
0 F
Ln
V0 P
(b)
0 P
Ln
V0 F
( c )
V0 F
Ln
0 P
(d )
V0 P
Ln
0 F
(a ) ( ) 0 LN ( )
(b) ( ) 0 exp( )
(c) ( ) 0 exp( )
(d ) ( ) 0 log( )
(c) (t ) ( N i 1)
7.26 CMM level 1 has
(a) 6 KPAs
(c) 0 KPAs
7.27 MTBF stands for
(a) Mean time between failure
(c) Minimum time between failures
7.28 CMM model is a technique to
(a) Improve the software process
(c) Test the software
(d ) (t ) ( N i 1)
(b) 2 KPAs
(d) None of the above
(b) Maximum time between failures
(d) Many time between failures
(b) Automatically develop the software
(d) All of the above
114
(b) False
(d) not fixed
119
Exercises
7.1 What is software reliability? Does it exist?
7.2 Explain the significance of bath tube curve of reliability with the help of
a diagram.
7.3 Compare hardware reliability with software reliability.
7.4 What is software failure? How is it related with a fault?
7.5 Discuss the various ways of characterising failure occurrences with
respect to time.
7.6 Describe the following terms:
(i) Operational profile
(iii) MTBF
(v) Failure intensity.
(ii)
(iv)
Input space
MTTF
120
Exercises
7.7 What are uses of reliability studies? How can one use software reliability
measures to monitor the operational performance of software?
7.8 What is software quality? Discuss software quality attributes.
7.9 What do you mean by software quality standards? Illustrate their essence
as well as benefits.
7.10 Describe the McCall software quality model. How many product quality
factors are defined and why?
7.11 Discuss the relationship between quality factors and quality criteria in
McCalls software quality model.
7.12 Explain the Boehm software quality model with the help of a block
diagram.
7.13 What is ISO9126 ? What are the quality characteristics and attributes?
121
Exercises
7.14 Compare the ISO9126 with McCall software quality model and
highlight few advantages of ISO9126.
7.15 Discuss the basic model of software reliability. How and can be
calculated/
7.16 Assume that the initial failure intensity is 6 failures/CPU hr. The failure
intensity decay parameter is 0.02/failure. We assume that 45 failures have
been experienced. Calculate the current failure intensity.
7.17 Explain the basic & logarithmic Poisson model and their significance in
reliability studies.
122
Exercises
7.18 Assume that a program will experience 150 failures in infinite time. It
has now experienced 80. The initial failure intensity was 10 failures/CPU
hr.
(i) Determine the current failure intensity
(ii) Calculate the failures experienced and failure intensity after 25 and
40 CPU hrs. of execution.
(iii) Compute additional failures and additional execution time required
to reach the failure intensity objective of 2 failures/CPU hr.
Use the basic execution time model for the above mentioned
calculations.
7.19 Write a short note on Logarithmic Poisson Execution time model. How
can we calculate & ?
7.20 Assume that the initial failure intensity is 10 failures/CPU hr. The failure
intensity decay parameter is 0.03/failure. We have experienced 75
failures upto this time. Find the failures experienced and failure intensity
after 25 and 50 CPU hrs. of execution.
123
Exercises
7.21 The following parameters for basic and logarithmic Poisson models are
given:
Exercises
7.24 A program is expected to have 250 faults. It is also assumed that one
fault may lead to one failure. The initial failure intensity is 5 failure/CPU
hr. The program is released with a failure intensity objective of 4
failures/10 CPU hr. Calculate the number of failures experienced before
release.
7.25 Explain the Jelinski-Moranda model of reliability theory. What is the
relation between t and ' ' ?
7.26 Describe the Mills bug seeding model. Discuss few advantages of this
model over other reliability models.
7.27 Explain how the CMM encourages continuous improvement of the
software process.
7.28 Discuss various key process areas of CMM at various maturity levels.
7.29 Construct a table that correlates key process areas (KPAs) in the CMM
with ISO9000.
7.30 Discuss the 20 clauses of ISO9001 and compare with the practices in
the CMM.
125
Exercises
7.31 List the difference of CMM and ISO9001. Why is it suggested that
CMM is the better choice than ISO9001?
7.32 Explain the significance of software reliability engineering. Discuss the
advantage of using any software standard for software development?
7.33 What are the various key process areas at defined level in CMM?
Describe activities associated with one key process area.
7.34 Discuss main requirements of ISO9001 and compare it with SEI
capability maturity model.
7.35 Discuss the relative merits of ISO9001 certification and the SEI CMM
based evaluation. Point out some of the shortcomings of the ISO9001
certification process as applied to the software industry.
126