## LOC for the C Language AFP x Locafp x LOC

As with all sizing and estimating models, adaptations and calibrations are encouraged. What is counted, how weights are applied, and what environmental factors are considered are all modifiable. For example, in the silicon chip industry, where physical units are tested via software, device components could be counted instead of inputs and outputs.

Disadvantages of Function Point Analysis

Disadvantages to the use of function point analysis include the following:

It requires subjective evaluations, with much judgment involved. Results depend on technology used to implement it.

Many effort and cost models depend on LOC, so function points must be converted. There is more research data on LOC than on function points. It is best performed after the creation of a design specification. It is not well-suited to non-MIS applications (use feature points instead).

Table 10-1 has another use in that an existing program may be examined for its function point count. For example, if you had an application consisting of 500 SLOC system in C++, the table would indicate that you have 6 x 500 = 3,000 function points. This technique, called "backfiring," can be used to build a rough size measure for a portfolio of applications. The portfolio can become the extremely useful historical database, which can be used for estimating future projects as well as calibrating sizing and estimating models.

How many function points are in a system that is considered to be very large? Some large military applications approach 400,000, the full SAP/R3 is 300,000, Wndows 98 is about 100,000, and IBM's MVS is also about 100,000. Software Productivity Research, Inc., generated this data from its database of 8,500 projects from more than 600 organizations.

### Feature Points as a Unit of Size

Feature points are an extension of the function point method designed to deal with different kinds of applications, such as embedded and/or real-time systems. In 1986, Software Productivity Research developed feature point analysis for system software. Pure function point counts applied to non-MIS software can result in a misleading metric because the applications are usually heavy in algorithmic complexity but light on external inputs and outputs. A feature point is a new category of function that represents complex algorithms and control (stimulus/response). The complexity of the algorithm is defined in terms of the number of "rules" required to express that algorithm. Feature points are generally used for:

• Real-time software such as missile defense systems;

• Systems software (e.g., operating systems, compilers);

® Embedded software such as radar navigation packages or chips in automobile air bags;

® Engineering applications such as Computer-Aided Design (CAD), Computer-Integrated Manufacturing (CIM), and mathematical software;

® Artificial intelligence (Al) software;

® Communications software (e.g., telephone switching systems);

• Process control software such as refinery drivers.

Feature points are basically function points that are sensitive to high algorithmic complexity, where an algorithm is a bounded set of rules (executable statements) required to solve a computational problem.

Guidelines for Counting Feature Points

Figure 10-5 shows the basic steps in counting feature points; each will be described later. The Feature Point Worksheet appears itTable 10-11.

Figure 10-5. Basic Steps in Feature Point Analysis

Figure 10-5. Basic Steps in Feature Point Analysis

plaxity—SfrflTaMfl) [)

7, Convert to IGC (Optional)

Step 1. Count Feature Points

This is the same as counting function points—count inputs, outputs, files (data structures), inquiries, and interfaces.

The filled-out Feature Point Worksheet in Table 10-13 serves as an example for each of the seven steps.

Step 2. Continue the Feature Point Count by Counting the Number of Algorithms

An algorithm is a bounded computational problem that is included within a specific computer program.

Significant and countable algorithms deal with a definite, solvable, bounded problem with a single entry and a single exit point.

Developers who use data flow diagrams or structure charts in design often equate an algorithm to a basic process specification or module specification.

### Step 3. Weigh Complexity

Use "average" weights instead of simple, average, or complex (note that the average for feature points is different from the average for function points) for inputs, outputs, files (data structures), inquiries, and interfaces. Weigh algorithms with a simple, average, and complex multiplier.

The average complexity factor for "files" is reduced from 10 to 7 to reflect the reduced significance of logical files in computation-intensive software.

The default weighting factor for algorithms is 3. The value can vary over a range of 1 to 10. Algorithms that require basic arithmetic operations and few decision rules are assigned a value of 1. Algorithms requiring complex equations, matrix operation, and difficult logical processing are assigned a value of 10. Algorithms that are significant and therefore should be counted have these characteristics:

• Deals with a solvable, bounded, definite problem;

• Is precise and unambiguous; ® Has an input or starting value;

• Has output or produces a result;

® Is implementable—each step is capable of executing on a computer;

• Is capable of representation via one of the standard programming constructs: sequence, if-then-else, do-case, do-while, and do-until.

Step 1. Count Feature Points | ||

Average |
Feature Points | |

Number of Inputs |
x 4 | |

Number of Outputs |
x 5 | |

Number of Files (Data Structures) |
x 7 | |

Number of Inquiries |
x 4 | |

Number of Interfaces |
x 7 | |

Step 2. Count the Number of Algorithms | ||

Average |
Feature Points | |

Number of Algorithms |
x 3 | |

Total (FP): | ||

Step 3. Weigh Complexity | ||

Step 4. Evaluate Environmental Factors | ||

Step 5. Calculate the Complexity Adjustment Factor (CAF) | ||

Logic Values (Select One) | ||

Simple Algorithms and Calculations—1 | ||

Majority of Simple Algorithms—2 | ||

Average Complexity of Algorithms—3 | ||

Some Difficult Algorithms—4 | ||

Many Difficult Algorithms—5 | ||

Data Values (Select One) | ||

Simple Data—1 | ||

Numerous Variables, but Simple Relationships—2 | ||

Multiple Fields, Files, and Interactions—3 | ||

Complex File Structures—4 | ||

Very Complex Files and Data Relationships—5 | ||

Total (CAF): |

Step 1. Count Feature Points

Average

Feature Points

Step 6. Multiply the Raw Feature Point Count by the CAF

## Project Management Made Easy

What you need to know about… Project Management Made Easy! Project management consists of more than just a large building project and can encompass small projects as well. No matter what the size of your project, you need to have some sort of project management. How you manage your project has everything to do with its outcome.

## Post a comment