coco mo models

44
COCOMO Models Ognian Kabranov SEG 3300A Winter .L. Probert 1

Upload: honey-nitharwal

Post on 14-Sep-2015

218 views

Category:

Documents


3 download

DESCRIPTION

detail view of cocomo model used in software project management.

TRANSCRIPT

COCOMO Models

Ognian KabranovSEG 3300A Winter 2003.L. Probert1Project Management and Mr. MurphyLogic is a systematic method of coming to the wrong conclusion with confidence. Technology is dominated by those who manage what they do not understand. Nothing ever gets built on schedule or within budget. If mathematically you end up with the incorrect answer, try multiplying by the page number. Mr. Murphy was an optimist

SEG 3300A Winter 2003.L. Probert2

SEG 3300A Winter 2003.L. Probert3MotivationThe software cost estimation provides: the vital link between the general concepts and techniques of economic analysis and the particular world of software engineering. Software cost estimation techniques also provides an essential part of the foundation for good software management. SEG 3300A Winter 2003.L. Probert4Cost of a projectThe cost in a project is due to:due the requirements for software, hardware and human resourcesthe cost of software development is due to the human resources neededmost cost estimates are measured in person-months (PM)SEG 3300A Winter 2003.L. Probert5Cost of a project (.)the cost of the project depends on the nature and characteristics of the project, at any point, the accuracy of the estimate will depend on the amount of reliable information we have about the final product.SEG 3300A Winter 2003.L. Probert6Software Cost Estimation

SEG 3300A Winter 2003.L. Probert7Introduction to COCOMO modelsThe COstructive COst Model (COCOMO) is the most widely used software estimation model in the world. It The COCOMO model predicts the effort and duration of a project based on inputs relating to the size of the resulting systems and a number of "cost drives" that affect productivity. SEG 3300A Winter 2003.L. Probert8EffortEffort Equation PM = C * (KDSI)n (person-months)where PM = number of person-month (=152 working hours), C = a constant, KDSI = thousands of "delivered source instructions" (DSI) and n = a constant. SEG 3300A Winter 2003.L. Probert9ProductivityProductivity equation (DSI) / (PM) where PM = number of person-month (=152 working hours),

DSI = "delivered source instructions"SEG 3300A Winter 2003.L. Probert10ScheduleSchedule equation TDEV = C * (PM)n (months) where TDEV = number of months estimated for software development. SEG 3300A Winter 2003.L. Probert11Average StaffingAverage Staffing Equation(PM) / (TDEV) (FSP) where FSP means Full-time-equivalent Software Personnel.

SEG 3300A Winter 2003.L. Probert12COCOMO ModelsCOCOMO is defined in terms of three different models: the Basic model, the Intermediate model, and the Detailed model. The more complex models account for more factors that influence software projects, and make more accurate estimates.SEG 3300A Winter 2003.L. Probert13The Development modethe most important factors contributing to a project's duration and cost is the Development ModeOrganic Mode: The project is developed in a familiar, stable environment, and the product is similar to previously developed products. The product is relatively small, and requires little innovation. Semidetached Mode: The project's characteristics are intermediate between Organic and Embedded.SEG 3300A Winter 2003.L. Probert14The Development modethe most important factors contributing to a project's duration and cost is the Development Mode: Embedded Mode: The project is characterized by tight, inflexible constraints and interface requirements. An embedded mode project will require a great deal of innovation.

SEG 3300A Winter 2003.L. Probert15Modes

SEG 3300A Winter 2003.L. Probert16Modes (.)

SEG 3300A Winter 2003.L. Probert17Cost Estimation ProcessCost=SizeOfTheProject x Productivity SEG 3300A Winter 2003.L. Probert18Cost Estimation ProcessErrorsEffortDevelopment Time Size Table

Lines of Code

Number of Use Case

Function PointEstimation ProcessNumber of PersonnelSEG 3300A Winter 2003.L. Probert19Project Size - MetricsNumber of functional requirementsCumulative number of functional and non-functional requirementsNumber of Customer Test CasesNumber of typical sized use casesNumber of inquiriesNumber of files accessed (external, internal, master)Total number of components (subsystems, modules, procedures, routines, classes, methods)Total number of interfacesNumber of System Integration Test CasesNumber of input and output parameters (summed over each interface)Number of Designer Unit Test CasesNumber of decisions (if, case statements) summed over each routine or methodLines of Code, summed over each routine or method SEG 3300A Winter 2003.L. Probert20Project Size Metrics(.)Availability of Size Estimation Metrics:Development PhaseAvailable MetricsaRequirements Gathering1, 2, 3bRequirements Analysis4, 5dHigh Level Design6, 7, 8, 9eDetailed Design10, 11, 12fImplementation12, 13SEG 3300A Winter 2003.L. Probert21Function PointsSTEP 1: measure size in terms of the amount of functionality in a system. Function points are computed by first calculating an unadjusted function point count (UFC). Counts are made for the following categoriesExternal inputs those items provided by the user that describe distinct application-oriented data (such as file names and menu selections) External outputs those items provided to the user that generate distinct application-oriented data (such as reports and messages, rather than the individual components of these) SEG 3300A Winter 2003.L. Probert22Function Points(.) External inquiries interactive inputs requiring a response External files machine-readable interfaces to other systems Internal files logical master files in the system SEG 3300A Winter 2003.L. Probert23Function Points(..)STEP 2: Multiply each number by a weight factor, according to complexity (simple, average or complex) of the parameter, associated with that number. The value is given by a table:

SEG 3300A Winter 2003.L. Probert24Function Points(...)STEP 3: Calculate the total UFP (Unadjusted Function Points)STEP 4: Calculate the total TCF (Technical Complexity Factor) by giving a value between 0 and 5 according to the importance of the following points:SEG 3300A Winter 2003.L. Probert25Function Points(....)Technical Complexity Factors:1. Data Communication2. Distributed Data Processing3. Performance Criteria4. Heavily Utilized Hardware5. High Transaction Rates6. Online Data Entry7. Online Updating8. End-user Efficiency9. Complex Computations10. Reusability11. Ease of Installation12. Ease of Operation13. Portability14. MaintainabilitySEG 3300A Winter 2003.L. Probert26Function Points(.....)STEP 5: Sum the resulting numbers too obtain DI (degree of influence)STEP 6: TCF (Technical Complexity Factor) by given by the formulaTCF=0.65+0.01*DISTEP 6: Function Points are by given by the formulaFP=UFP*TCFSEG 3300A Winter 2003.L. Probert27Example

SEG 3300A Winter 2003.L. Probert28Example (.)

SEG 3300A Winter 2003.L. Probert29Example (..)Technical Complexity Factors:1. Data Communication 32. Distributed Data Processing 03. Performance Criteria 44. Heavily Utilized Hardware 05. High Transaction Rates 36. Online Data Entry 37. Online Updating 38. End-user Efficiency 39. Complex Computations 010. Reusability 311. Ease of Installation 312. Ease of Operation 513. Portability 314. Maintainability 3DI =30 (Degree of Influence)SEG 3300A Winter 2003.L. Probert30Example ()Function PointsFP=UFP*(0.65+0.01*DI)= 55*(0.65+0.01*30)=52.25

That means the is FP=52.25SEG 3300A Winter 2003.L. Probert31Relation between LOC and FPRelationship:

LOC = Language Factor * FP

whereLOC (Lines of Code)FP (Function Points)

SEG 3300A Winter 2003.L. Probert32Relation between LOC and FP(.)Assuming LOCs per FP for: Java = 53, C++ = 64 aKLOC = FP * LOC_per_FP / 1000

It means for the SpellChekcer Example: (Java)

LOC=52.25*53=2769.25 LOC or 2.76 KLOCSEG 3300A Winter 2003.L. Probert33Effort ComputationThe Basic COCOMO model computes effort as a function of program size. The Basic COCOMO equation is:E = aKLOC^bEffort for three modes of Basic COCOMO.

Mode a bOrganic2.41.05Semi-detached3.01.12Embedded3.61.20SEG 3300A Winter 2003.L. Probert34Example

SEG 3300A Winter 2003.L. Probert35Effort ComputationThe intermediate COCOMO model computes effort as a function of program size and a set of cost drivers. The Intermediate COCOMO equation is:E = aKLOC^b*EAFEffort for three modes of intermediate COCOMO.

Mode a bOrganic3.21.05Semi-detached3.01.12Embedded2.81.20SEG 3300A Winter 2003.L. Probert36Effort computation(.)Effort Adjustment Factor Cost DriverVeryLowLowNominalHighVeryHighExtraHighRequired Reliability.75.881.001.151.401.40Database Size.94.941.001.081.161.16Product Complexity.70.851.001.151.301.65Execution Time Constraint1.001.001.001.111.301.66Main Storage Constraint1.001.001.001.061.211.56Virtual Machine Volatility.87.871.001.151.301.30Comp Turn Around Time.87.871.001.071.151.15Analyst Capability1.461.191.00.86.71.71Application Experience1.291.131.00.91.82.82Programmers Capability1.421.171.00.86.70.70Virtual machine Experience1.211.101.00.90.90.90Language Experience1.141.071.00.95.95.95Modern Prog Practices1.241.101.00.91.82.82SW Tools1.241.101.00.91.83.83Required Dev Schedule1.231.081.001.041.101,10SEG 3300A Winter 2003.L. Probert37Effort Computation (..)Total EAF = Product of the selected factors Adjusted value of Effort: Adjusted Person Months: APM = (Total EAF) * PMSEG 3300A Winter 2003.L. Probert38Example

SEG 3300A Winter 2003.L. Probert39Software Development TimeDevelopment Time Equation Parameter Table:

Development Time, TDEV = C * (APM **D)

Number of Personnel, NP = APM / TDEV

ParameterOrganicSemi-detachedEmbeddedC2.52.52.5D0.380.350.32SEG 3300A Winter 2003.L. Probert40Distribution of EffortA development process typically consists of the following stages:- Requirements Analysis- Design (High Level + Detailed)- Implementation & Coding- Testing (Unit + Integration)SEG 3300A Winter 2003.L. Probert41Distribution of Effort (.)The following table gives the recommended percentage distribution of Effort (APM) and TDEV for these stages:Percentage Distribution of Effort and Time Table:

Req AnalysisDesign, HLD + DDImplementationTestingEffort23%29%22%21%100%TDEV39%25%15%21%100%SEG 3300A Winter 2003.L. Probert42Error EstimationCalculate the estimated number of errors in your design, i.e.total errors found in requirements, specifications, code, user manuals, and bad fixes:Adjust the Function Point calculated in step1

AFP = FP ** 1.25Use the following table for calculating error estimatesError TypeError / AFPRequirements1Design1.25Implementation1.75Documentation0.6Due to Bug Fixes0.4SEG 3300A Winter 2003.L. Probert43All TogetherDesignUnadjusted Function Point (UFP table)ModifyFP=UFP*TCFClasses*(2Function Points)TCFKLOC=Max[aKLOC, bKLOC]LOC=13.20*Num of MethodLOC=18.25*Num of MethodAFP=FP*1.25Compute Errors = AFP*YCompute Effort: Person Month, PM=A*(KLOC**B)bKLOC= (LOCs for all Classes)/1000Adjusted PM: APM=(total EAF)*PMDevelopment Time: TDEV=C*(APM**D)Factor:1-15Number of personnel: NP=APM/TDEVDI=ratings of selected factors 14TCF=0.65+0.01*(DI)j 1Min[TCF]=0.65; Max[TCF]=1.35aKLOC=FP*LOC_per_FP/1000

Java=53; C++=64EAF=Product of selected factorNPEfforttimeReqAPMTDEVResultSEG 3300A Winter 2003.L. Probert44