You are on page 1of 53

CHAPTER 6

DETAILED PLANNING Effort and Cost (and schedule length) Estimating

What Will it Take to Build the Software?

The Big Picture for Cost Estimating
Where Is the Software? WBS How Big is the Software? Size How Much Effort is Required? Effort No: rethink assumptions or renegotiate Yes Done Is This Realistic? How Much Will it Cost? How Much Time is Required? Schedule

Cost

Cost Categories
WORK BREAKDOWN STRUCTURE SOURCE DOCUMENT NUMBER ITEM NAME PARAG RAPH 1 All Software S 4.1.6 1.01 Software Management S 4.4 1.02 C onfiguration Management S 4.4.4 1.03 Quality Assurance S 4.4.5 1.04 Documents (added cost to produce)S 4.4.3 1.05 Product (CI) # - Camera 1 S 4.1.6.1 1.06 Product (CI) # - Process Video 2 S 4.1.6.2 1.07 Product (CI) # - Display 3 S 4.1.6.3 1.08 Product (CI) # - Sound Functions 4 S 4.1.6.4 1.09 Reviews S 6.0 1.09.1 Preparation for Reviews S 6.1 1.09.2 Travel to Marketing Site S 6.1 1.10 Audits S 6.2 1.11 Workstations and Compilers for "C " S 4.4.1 C OST ESTIMATE C ATEGORY AMOUNT ALL S,P S,P S,P AL S, SA S, SA S, SA S, SA S, AD S AD AL AD

Cost Categories - Schematic

Code S SA P AL AD

Category

Estimated by

Affects

Examples

Software Cocomo & Cost & Software Design, Software Development Similar Tools Schedule Coding, Software Testing Additional SW Tasks Software Support Additional Labor Additional Dollars Add-on to Cost & Cocomo, etc. Schedule % Increment to Cocomo, etc. Increment to Labor estimate Increment to Cost estimate Cost Cost Cost Software Requirements, System Testing Software Management, SQA, Config Management Project Management, Document Generation Travel, Development Tools, Special Equipment,

The Estimating Process
Process Model S, SA Schedule Length Effort +P Generic Schedule * Effort Effort Schedule * Labor Distribution + AL Labor Schedule * Labor Cost + AD Cost Schedule

A “quick and dirty” cost estimate
• To illustrate the process • To get an initial estimate in 30 minutes • Note that this simplifies many of the steps, but shows the basic order in which things happen • Schedule length is generally determined at the end of step 2 (next slide)

The Big Picture for Cost Estimating

Where Is the Software?

WBS

How Big is the Software?

Size

How Much Effort is Required?

No: rethink assumptions or renegotiate Yes Done Is This Realistic? How Much Will it Cost?

Effort

How Much Time is Required? Schedule

Cost

The Estimating Process
Process Model S, SA Schedule Length Generic Schedule * Effort Effort Schedule * Labor Distribution + AL Labor Schedule * Labor Cost + AD Cost Schedule
W here Is the Software? How Big is the Software?

Effort
+P

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Effort Measures
• Effort represents the amount of labor that will be required to perform a task • It is usually measured in staff-hours, staffdays, or staff-months • These three are NOT necessarily related in a simple manner • Because of this, comparisons of different organizations can be very misleading staff-day = person-day = man-day = ... Different organizations use different terms
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Comparison
• 1 staff-hour = 1 person working for 1 hour • 1 staff-day = 1 person working for 1 day How many staff-hours per staff-day? 7? 7.5? 8.0? 8.5? 9.5? ??? -- How do you handle paid overtime? -- How do you handle unpaid overtime? -- How do you handle breaks, lunch hours, etc.? All of this must be resolved in order to know the answer
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

How many Hours or Days per Month?
How many staff-days per staff-month? 30? 21? 19? ??? How many staff-hours per staff-month? 152? 160? 175? 184? ??? Does it depend on which month? -- Class Discussion of issues that cause variation Underlined values are the default values assumed by Cocomo and many other models (these values allow for average number of vacation days and holidays)
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Consistency is the Most Important Factor
• If you measure effort consistently, you can understand what it costs, compare different projects, etc. • Like lines of code, there are many ways to measure effort and many arguments why each is good or bad • You cannot make meaningful evaluations if each project measures effort differently
Objects Tested per staff hour Lines of code per staff month

W here Is the Software?

How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Measure Hours if you Can
• There tend to be fewer variations in how a staff-hour is measured

• But many of the estimating models use staffmonths -- so you need to know how to convert properly between your system and the estimating model
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

But What does a staff-Month Mean?
• If it requires 12 staff-months, does this mean -- 12 people for 1 month? -- 1 person for 12 months? -- 3 people for 4 months? -- does it depend on which people you choose? • Too often, managers get caught by the assumption that all of these are equivalent • There is some flexibility, but only so much • Brooks explored this issue in considerable detail in “The Mythical Man Month”
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

You Cannot Just Allocate People Arbitrarily
COCOMO MODEL OF TIME VS EFFORT

staffdays required to do the work

Optimal Schedule

Calendar Time Allocated for the Work
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Typical Inputs to Effort Estimate
• Tasks to be Performed (WBS)
– Software Development Tasks (Design, Code, Test) – Additional Development Tasks (Requirements, System) – Support Tasks (CM, QA, Management) – Tasks requiring Additional Labor (documents, etc.) – Additional Dollar Costs (travel, equipment, etc)

• • • •

Size Estimate for Software Historical data on Effort & Productivity High Level Schedule Process and methods
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Effort Estimating Steps
1) Summarize and Document Requirements for Each Task
– Cost Content Summary – WBS Dictionary

2) Quantify Magnitude of Each Task
– Size & Complexity for Software – # of pages, # of trips, # of whatever for other things

3) Estimate Effort for Software 4) Estimate Again with an Alternative Method 5) Resolve Discrepancies (repeat from step 1, as required) [6) other tasks will be added in later]
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Notes about Effort Estimating
1) Accuracy depends on experience, historical data, availability of information, and luck -- At the start of a project, you are lucky to be within 20% unless you have very good historical data 2) There are many methods of effort estimating -- Use multiple ones to reduce risk

W here Is the Software?

How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

How do you Build an Estimating Model?
Insight

Estimating Model

Historical Data Process Model
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Some Popular Cost/Schedule Models (& Tools)
• Cocomo -- (Costar, Revic, Softcost) • Putnam’s Model -- (SLIM) • Shen and Conti -- (COPMO) • Lockheed/Martin -- (Price-S)

W here Is the Software?

How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Process, Methods, and Tools
Tools COSTAR, REVIC SLIM Methods (Models) SOFTCOST COCOMO, PUTNAM, ET. AL. Process (Purpose) EFFORT ESTIMATING
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Calibrating a Model

Estimating Model

Your Version of the Model

Your Data Your Experience
W here Is the Software? How Big is the Software?

Your Insight

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Constructive Cost Model
• There are three versions of the Cocomo model -- Basic -- Intermediate (the most popular) -- Detailed (much additional effort to use but little additional benefit) • The different versions of the model represent different levels of detail or precision

Cocomo (1)

(1) Boehm, Software Engineering Economics
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Basic Cocomo Model

Effort = a * Size

b

a and b are constants that depend on the project Size is measured in thousands of lines of code Effort is measured in staff months (19 days per month or 152 working hours per month)
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Cocomo constants -- a and b
• a and b can be determined by a curve fit procedure (regression analysis), matching project data to the equation (this is how you calibrate your data to the Cocomo model) • But most organizations do not have enough data to perform such an analysis • So Boehm has identified three levels of difficulty that seem to characterize many software projects
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Three Levels of Difficulty
• Organic -- Fairly easy software, software development team is familiar with application, language, and tools.
– Typically from 2-50 KLOC

• Semi-Detached -- Average software, average team
– Typically 50-300 KLOC

• Embedded -- Severe constraints, real time, etc.
NOTE: the origin of the names is obscure, and not considered significant, even by Boehm.
W here Is the Software? How Big is the Software?

– No stated size range, but model is known to fail under 10KLOC
How Much Effort is Required?
Is This Realistic? How Much Will it Cost? How Much Time is Required?

Done

Cocomo Modes
• Boehm found that the calibration to Cocomo was similar within each level of difficulty. • Thus there are three Cocomo “modes” or “standard values of a and b”
MODE Organic SemiDetached Embedded

a
2.4 3.0 3.6

b
1.05 1.12 1.20

W here Is the Software?

How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Basic Cocomo Equation in Graph Form
Three Cocomo Modes
400.00 300.00 200.00 100.00 0.00

embedded semidetached organic

Size (KLOC)
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Intermediate Cocomo
Motivation: Variances among programs within a given mode (level of difficulty) tend to be driven by specific cost drivers. Boehm originally identified fifteen such cost drivers. Others have since identified additional cost drivers. And specific projects often find unique situations that drive cost up or down.
W here Is the Software? How Big is the Software?

How Much Effort is Required?
How Much Time is Required?

Done

Is This Realistic?

How Much Will it Cost?

Cost Drivers - I The Nature of the Job to be Done
• Required Reliability
– Applies mainly to real time applications

• Data Base Size
– Applies mainly to data processing applications

• Product Complexity • Execution Time Constraints
– Applies when processor speed is barely sufficient

• Main Storage Constraints
– Applies when memory size is barely sufficient

• Virtual Machine Volatility
– Includes hardware and operating system of target machine

• Required Reuse
W here Is the Software? How Big is the Software? Done Is This Realistic?

How Much Effort is Required?
How Much Time is Required?

How Much Will it Cost?

The Big Picture for Cost Estimating
Where Is the Software? How Big is the Software? How Much Effort is Required? Effort

WBS

Size

Done

Yes

No: rethink assumptions or renegotiate Is This Realistic? Cost

How Much Will it Cost?

How Much Time is Required?
Schedule

The Big Picture for Cost Estimating
Where Is the Software? How Big is the Software? How Much Effort is Required?

WBS

Size

No: rethink assumptions or renegotiate Is This Realistic?

Done Yes

How Much Will it Cost?
Cost

Effort How Much Time is Required?

Schedule

The Estimating Process
Process Model S, SA Schedule Length Effort +P Generic Schedule * Effort Effort Schedule * Labor Distribution + AL

Labor Schedule
* Labor Cost

+ AD

Cost Schedule
W here Is the Software? How Big is the Software? How Much Effort is Required? Done Is This Realistic?

How Much Will it Cost?

How Much Time is Required?

Begin with a Chart of Labor % and Rates for Different Categories
Category Very Senior Senior Normal New Hire Clerical etc. % of Total 10% 10% 30% 30% 5% etc. Salary Rate# $65/hour $50/hour $40/hour $30/hour $15/hour

# use rate per hour if effort is measured in staff hours use rate per day if effort is measured in staff days etc.
W here Is the Software? How Big is the Software? How Much Effort is Required? Done Is This Realistic?

How Much Will it Cost?

How Much Time is Required?

Multiply the Effort Schedule by the Percentages to get the Labor Schedule
Labor Category V Senior Senior Avg New Hire Clerk TOTAL LABOR Add'l tasks GRAND TOTAL LABOR % Effort 10% 20% 30% 30% 10% M1 5.7 10.4 16.1 16.1 5.7 M2 5.7 10.4 16.1 16.1 5.7 57 10 67 M3 5.7 10.4 16.1 16.1 5.7 57 10 67 M4 8.4 16.8 25.2 25.2 8.4 84 20 104 M5 10.9 21.8 32.7 32.7 10.9 109 10 119 M6 10.3 20.6 30.9 30.9 9.0 103 10 113 . etc etc etc etc etc etc etc etc . etc etc etc etc etc etc etc etc Ms 5.7 10.4 16.1 16.1 5.7 57 40 97 TOT 240 480 720 720 240 2400 200 2600

100% 57 10 67

W here Is the Software?

How Big is the Software?

How Much Effort is Required?

Done

Is This Realistic?

How Much Will it Cost?

How Much Time is Required?

What the Labor Schedule Tells You
• How much labor will be expended each month, each quarter, etc. • How that labor will be distributed each month
– by category – by total people

• A graph can be very helpful here -- the data comes directly from the spreadsheet • Or you can add a “headcount” row as with the effort schedule • (The total labor or total people graphs can also be generated from the effort schedule)
W here Is the Software? How Big is the Software? How Much Effort is Required? Is This Realistic?

Done

How Much Will it Cost?

How Much Time is Required?

What the Cost Schedule Tells You
• How much the project will cost • How much money you need each month • How the money is to be spent -- by labor category -- for additional cost items (“AD”) You can add inflation factors for later years, if your project takes more than one year You can add interest charges if the money must be borrowed etc.
W here Is the Software? How Big is the Software? How Much Effort is Required? Done Is This Realistic?

How Much Will it Cost?

How Much Time is Required?

The Big Picture for Cost Estimating
Where Is the Software? WBS How Big is the Software? Size How Much Effort is Required? Effort How Much Time is Required? Schedule

No: rethink assumptions or renegotiate
Yes Done

Is This Realistic?

How Much Will it Cost? Cost

Statistical Variances and Uncertainties
Region of Likely Costs Method 1 X True Cost? X Method 2 Method 3 X

Beware of Averages

XX XX
Average is Meaningless

X X X

The Negotiation Process

We MUST have the lowest bid!!! We will, boss!!!

“Management will try to trim the budget by sending an army of low-ranking, cluless budget analysts to interview you and ask insightful questions.” Adams, The Dilbert Principle

The Estimating Process

This will never satisfy the cost goal!???!

Spreadsheet for  estimating

Identify Opportunities and Barriers

Opportunities to Cut

Barriers

Negotiate

Well, I’ll think about it

If they will cut back on the reviews and ...

Remember, Estimates are Never Perfect

The More Facts you Have, the Better Off you Are during Negotiations

• •

Get them to Review your Estimate (sometimes they don’t bother) Be WELL PREPARED to Explain it

Chapter Summary
• Effort and Schedule Length are Interdependent
– Time and effort can be traded off to some extent, but not completely - there are “infeasible” combinations

• Cost is derived through several steps • Effort can be measured in many ways, and the specific measurement can have a significant effect on the numbers computed during an estimate • Effort estimates can be made through historical experience or through models derived from historical experience

Chapter Summary (continued)
• Models are often helpful to estimate effort
– All are based on historical experience – All should be calibrated to your specific experience – Most have additional parameters that allow you to “fine tune” to specific circumstances

• Cocomo is a widely used method that is fairly successful when calibrated to your experience • Like most models, Cocomo excludes some tasks • It is best to use multiple models/methods to improve the quality of an estimate

Chapter Summary (continued)
• Division of Time is Different from Division of Labor • Beware of Averages • Cocomo 2.0 is an emerging approach that applies Cocomo and other methods to newer methods of software development • Cocomo 2.0 also recognizes that estimates must be refined and updated as a project progresses

References
Boehm, Software Engineering Economics, Prentice-Hall, 1981. Brooks, Fred, The Mythical Man-Month, 1975 / 1995. Boehm, et. al., Cost Models for Future Software Life Cycle Processes: Cocomo 2.0, Technical Report, USC Center for Software Engineering, Draft 2.0, September 6, 1994. Conte, S.D., et. al. Software Engineering Metrics and Models. Benjamin Cummings, 1986, p314.
Grady, Robert B. and Deborah L. Caswell, Software Metrics: Establishing a Company-Wide Program. Englewood Cliffs, N.J., Prentice-Hall, Inc., 1987. ISBN 0-13-821844-7.

References (continued)
Putnam, Lawrence H., “A General Empirical Solution to the Macro Software Sizing and Estimating Problem,” IEEE Transactions on Software Engineering, July, 1978, p345. Tausworthe, R.C. Software Specifications Document, DSN Software Cost Model, Jet Propulsion Laboratory, JPL Publication 81-7 (1981).

End Of Chapter 6