Unit-1 Software Effort Estimation
Unit-1 Software Effort Estimation
INTRODUCTION
A successful is one delivered ‘on time , within budget and with the required quality’. This implies
that targets are set which the project manager then tries to meet. This assumes that the targets are
reasonable- no account is taken of the possibility of project managers achieving record levels of
productivity from their teams, but still not meeting a deadline because of the incorrect initial
estimates. Realistic estimates are therefore crucial.
A project manager like Amanda has to produce estimates of effort, which affect costs, and of
activity durations, which affect the delivery time. Theses could be different, as in the case where
two testers work on the same task for the same five days.
Some of difficulties of estimating arise from the complexity and invisibility of software. Also, the
intensely human activities which make up system development cannot be treated in a purely
mechanistic way. Other difficulties include:
Changing technology
Where technologies change rapidly, it is difficult to use the experience of previous projects on
new ones.
Lack of homogeneity of project experience
Even where technologies have not changed, knowledge about typical task durations may not
be easily transferred from one project to another because of other differences between projects.
ESTIMATIONS
Estimations are carried out at various stages of a software project for a variety of reasons
Where an Estimates Done?
Strategic Planning
Feasibility Study
System Specification
Evaluation of suppliers proposals
Project Planning
Strategic Planning:
Project portfolio management involves estimating the costs and benefits of new applications in order
to allocate priorities. Such estimates may also influence the scale of development staff recruitment.
Feasibility Study:
This confirms that the benefits of the potential system will justify the costs.
System Specification
Most system development methodologies usefully distinguish between the definition of the users
requirement and the design which shows how those requirements are to be fulfilled. The effort needed
to implement different design proposals will need to be estimated. Estimates at the design stage will
also confirm that the feasibility study is still valid .
Evaluation of suppliers proposals
In the case of IOE annual maintenance contracts subsystem. For example, IOE might consider putting
development out to tender. Potential contractors would scrutinizer the system specification and
produce estimates as the basis of their bids. Amanda might still produce own estimates so that IOE
could question a proposal which seems too low in order to ensure that the proposer has properly
understood the requirements. The cost of bids could also be compared to in-house development.
Project Planning
As the planning and implementation of the project becomes more detailed, more estimates of smaller
work components will be made. These will confirm earlier broad-brush estimates, and will support
more detailed planning, especially staff allocations.
Parkinson’s law
Brooks Law
Parkinson’s Law:
‘ Work expands to fill the time available ‘ , that is, given an easy target staff will work less hard.
Brooks Law:
The effort of implementing a project will go up disproportionately with the number of staff assigned
to the project. As the project team grows in size, so will the effort that has to go into management,
coordination and communication. This has given rise, in extreme cases, to the notion of Brooks’ Law:
‘Putting more people on a late job makes it later’. If there is an over estimate of the effort required,
this could lead to more staff being allocated than needed and managerial overheads being increased.
Some have suggested that while the under-estimated project might not be completed on time or to
cost, it might be implemented in a shorter time than a project with a more generous estimate.
An estimation is not really a prediction, it is a management goal. Barry Boehm has suggested that if a
software development cost is within 20% of the estimated cost for the job then a good manager can
turn into a self-fulfilling prophecy. A project leader like Amanda will work hard to make the actual
performance conform to the estimate.
Measure of work:
Measure of work involved in completing a project is also called the size of the
project.
Work itself can be characterized by cost in accomplishing the project and the time
over which is to be completed.
Direct calculations of cost or time is difficult at the early stages of planning.
The time taken to write the software may vary according to the competence or
experience of the software developers might not even have been identified.
Implementation time may also vary depending on the extent to which
CASE(computer aided software engineering) tools are used during development.
It is therefore a standard practice to first estimate the project size; and by using it,
the effort and the time taken to develop the software can be computed.
Thus, we can consider project size as an independent variable and the effort or time
required to develop the software as dependent variable.
Two metrics are popularly being used to measure size
I. Source Lines of Code(SLOC)
II. Function Point(FP)
The SLOC measure suffers from various types of disadvantages, Which are to a
great extent corrected in the FP measure.
However, the SLOC measure is intuitively simpler, so it is still being widely used.
It is important , however, to be aware of the major shortcomings of the SLOC
measure
I. No precise Definition
II. Difficult to estimate at start of a project
III. Only a Code measure
IV. Programmer-dependent
V. Does not consider code complexity
No precise Definition: SLOC is very imprecise measure. Unfortunately , researchers have not been
consistent on points like does it include comment lines or are data declarations to be included?
Difficult to estimate at start of a project: From the project manager’s perspective , the biggest
shortcoming of the SLOC metric is that it is very difficult to estimate it during project planning stage,
and can be accurately computed only after the development of the software is complete. The SLOC
count can only be guessed at the beginning of a project , often leading to grossly inaccurate
estimations.
Only a Code Measure: SLOC is a measure of coding activity alone. A good problem size measure
should consider the effort required for carrying out of all the life cycle activities and not just coding.
Programmer-Dependent: SLOC gives a numerical value to the problem size that can vary widely
with the coding style of individual programmers. This aspect alone readers any LOC-based size and
effort estimations inaccurate.
Does not consider code complexity: Two software components with the same KLOC will not
necessarily take the same time to write, even if done by the same programmer in the same
environment. One component might be more complex. Because of this, the effort estimate based on
SLOC might have been made to find objective measures of complexity, but it depends to a large
extent on the subjective judgement of the estimator.
SOFTWARE EFFORT ESTIMATION TECHNIQUES:
Barry Boehm, in his classic work on software effort models, identified the main ways of deriving
estimates of software development effort as:
Clearly, the ‘Parkinson’ method is not really an effort prediction method, but a method of setting the
scope of a project.
Similarly, ‘price to win’ is a way of identifying a price and not a prediction.
Although Boehm rejects them as prediction techniques, they have value as management techniques.
For example, a perfectly acceptable engineering practice of ‘design to cost’.
BOTTOM-UP ESTIMATING
While the bottom-up approach the estimator breaks the project into its component tasks. With a
large project, the process of breaking it down into tasks is iterative: each task is decomposed into
its component sub tasks and theses in turn could be further analysed. It is suggested that this is
repeated until getting the tasks as an individual could do in a week or two. Although this top-
down analysis is an essential precursor to bottom-up estimating, it is really a separate process that
of producing a work breakdown schedule(WBS).
The bottom-up part comes in adding up the calculated effort for each activity to get an overall
estimate. The bottom-up approach is the best at the later. More detailed, stages of project
planning. Whenever a project is completely novel or there is no historical data available , the
estimator would be forced to use the bottom-up approach.
A Procedural Code-Oriented Approach:
The bottom-up approach described above works at a level of activities. In software development a
major activity is writing code. Describing how bottom-up approach can be used at the level of
software components.
1. Envisage the number and type of software modules in the final system
2. Estimate the SLOC of each identified module
3. Estimate the work content, taking into account complexity and technical difficulty
4. Calculate the work-days effort
Envisage the number and type of software modules in the final system:
Most information systems, for example, are built from a small set of system operations, e.g.,
Insert, Amend, Update, Display, Delete, Print.
The same principle should equally apply to embedded systems, Albeit with a different set of
primitive functions.
Estimate the SLOC of each identified module:
One way to judge the number of instructions likely to be in a program is to draw up a program
structure diagram and visualize how many instructions would be needed to implement
procedure. The estimator may look at existing programs which have a similar functional
description.
Estimate the work content, taking into account complexity and technical difficulty:
The practice is to multiply the SLOC estimate by a factor for complexity and technical
difficulty.
This factor will depend largely on the subjective judgement of the estimator.
For example, the requirement to meet particular highly constrained performance targets can
greatly increase programming effort.
Calculate the work-days effort:
Historical data can be used to provide ratios to convert weighted SLOC effort.
Project effort relates mainly to variables associated with characteristics of the final system. A
parametric model will normally have one or more formulae in the form
Productivity= effort/size
A more sophisticated way of doing this would be by suing the statistical technique least squares
regression to derive an equation in the form:
Effort=constant1+ (size * constant2)
Some parametric models . such as that implied by function points, are focused on system or task size,
while others, such are COCOMO , are more concerned with productivity factors. Having calculated
the overall effort required , the problem is then to allocate proportions of that effort to the various
activities within the project.
The top-down and bottom-up approaches are not mutually exclusive. Project managers will probably
try to get a number of different estimates from different people using different methods. Some parts of
an overall estimate could be derived using a top-down approach while other parts could be calculated
using a bottom-up method.
EXPERT JUDGEMENT
This is asking for an estimate of task effort from someone who is knowledgeable about either
the application or the development environment.
This method is often used when estimating the effort needed to change an existing piece of
software,
The estimator would have to examine the existing code in order to judge the proportion of
code affected and from that derive an estimate.
Someone already familiar with the software would be in the best position.
Some have suggested that expert judgement is simply a matter of guessing , but our own
research ahs shown that experts tend to use a combination of an informal analogy approach
where similar projects from the past are identified , supplemented by bottom-up estimating.
There are many cases where the opinions of more than one expert may need to be combined.
ESTIMATING BY ANALOGY
This is also called case-based reasoning. The estimator identifies completed projects (source
cases) with similar characteristics to the new project(the target cases). The effort recorded for the
matching source case is then used as a base estimate for the target. The estimator then identifies
differences between the target and the source and adjust the base estimate to produce an estimate
for the new project.
This can be a good approach where you have information about some previous projects nut not
enough to draw generalized conclusions about what might be useful drivers or typical
productivity rates.
A problem is identifying the similarities and differences between applications where you have a
large number of past projects to analyse. One attempt to automate this selection process is the
ANGEL software tool. This identifies the source case that is nearest the target by measuring the
Euclidean distance between cases. The Euclidean distance is calculated as:
Distance=square-root((target_parameter1-source_parameter1)2 +…
(target_parametern-source_parametern)2)
The above explanation is simply to give an idea of how Euclidean distance may be calculated.
The ANGEL package uses rather more sophisticated algorithms based on this principle.
Data Store
The overall FFP count is derived by simply adding up the counts for each of the four
types of data movement. The resulting units are Cfsu(COSMIC functional size units).
COCOMO II : A PARAMETRIC PRODUCTIVITY MODEL
Boehm’s COCOMO (Constructive Cost Model) is often referred to in the literature on software
project management, particularly in connection with software estimating. The term COCOMO
really refers to a group of models.
Boehm originally based his models in the late 1970s on a study of 63 projects. Of these only 7
were business systems and so the models could be used with applications other than information
systems. The basic model was built around the equation.
(effort)=c(size)k
Where effort was measured in pm or the number of ‘person-months’ consisting of units of 152
working hours, size was measured in kdsi, thousands of delivered source code instructions, and c
and k were constants.
Organic mode:
This would typically be the case when relatively small teams developed software in a
highly familiar in-house environment and when the system being developed was
small and the interface requirements were flexible.
Embedded mode:
This meant that the product being developed had to operate within very tight
constraints and changes to the system were very costly.
Semi-detached mode:
This combined elements of the organic and the embedded modes or had
characteristics that came between the two.
COCOMO II has been designed to accommodate by having models at three different stages:
Application composition:
The external features of the system that the user will experience are designed.
Prototyping will typically be employed to do this. With small applications that can be
built using high-productivity application-building tools, development can stop at this
point.
Early design:
The fundamental software structures are designed. With larger, more demanding
systems, where, for example, there will be large volumes of transactions and
performance is important, careful attention will need to be paid to the architecture to
be adopted.
Post Architecture:
The software structures undergo final construction, modification and tuning to create
a system that will perform as required.
To estimate the effort for application composition, the counting of object points is recommended by
the developers of COCOMO II.
At the early design stage, FPs are recommended as the way of gauging a basic system size. An FP
count may be converted to an LOC equivalent by multiplying the FPs by a factor for the programming
language that is to be used.
The following model can then be used to calculate an estimate of person-months.
Pm=A(size)(sf) X (em1) X (em2) X ……X (emn)
Where pm is the effort in ‘person-month’, A is a constant , size is measured in kdsi and sf is exponent
scale factor.
The scale factor is derived thus:
The fact that these factors are used to calculate an exponent implies that tha lack of these qualities
increase the effort required disproportionately more on larger projects.
Precedentedness(PREC):
This quality is the degree to which there are precedents or similar past cases for the
current project. The greater the novelty of the new system , the more uncertainty there
is and the higher the value given to the exponent driver.
Development Flexibility(FLEX):
This reflects the number of different ways there are of meeting the requirements. The
less flexibility there is, the higher the value of the exponent driver.
Architecture/Risk Resolution:
This reflects the degree of uncertainty about the requirements. If they are liable to
change then a high value would be given to this exponent driver.
Team Cohesion(TEAM):
This reflects the degree to which there is a large dispersed team as opposed to there
being a small tightly knit team
Process Maturity(PMAT):
On software quality explains the process maturity model. The more structured and
organized the way the software is produced , the lower the uncertainty and the lower
the rating will be for this exponent driver.
In the COCOMO II model the effort multipliers(em) adjust the estimate to take account of
productivity factors, but do not involve economies or diseconomies of scale. The multipliers
relevant to early design are in the above table and those used at the post architecture stage in
the below table .
At a later stage of the project , detailed design of the application will have been completed.
There will be a clearer idea of application size in terms of lines of code, and the factor
influencing productivity will be better known. A revised estimate of effort can be produced
based on the broader range of effort modifiers seen in above table. The method of calculation
is the same as for early design.