# The importance of measuring software complexity Software complexity

The

importance of measuring software complexity

Software

complexity (Programming

complexity) refers to number of pieces of properties in software, altogether

which will affect internal interactions. Complexity describes about the

interactions between many entities. When the number of entities increases

drastically, the number of interactions between them would increase altogether

and it would lead to a point where it would be impossible to know and understand

all of them. Similarly higher the complexity in ongoing software it also

increases the danger of unintentional interfering with interactions and so

increases the chances of errors when making modifications. As a result various

matrices were implemented over the years to overcome complexity issues.

Complexity

software metrics are implemented to introduce objective measurements that are

used for management, performance, quality assurance, and debugging, estimating

costs, predicting project success, defects in codes, predicting defective code,

and predicting project risks.

The various metrics proposed over the

years and the problems of them.

Cyclomatic complexity: this is a software

metrics used to show the complexity of an application program. Through a

program’s source code a quantitative measurement of numbers in linearly

independent paths.

Halstead complexity measures are software

metrics introduced by Maurice Howard Halstead in 1977 as part

of his treatise on establishing an empirical science of software development. Halstead

made the observation that metrics of the software should reflect the

implementation or expression of algorithms in different languages, but be

independent of their execution on a specific platform. These metrics are

therefore computed statically from the code.

·

However these older complexity measuring matrices have

fallbacks and disadvantages comparing to the matric we are implementing.

·

The time to conclude a systems complexity will be high

with the above mentioned matrices.

·

Duplicate and unwanted comments will be added to the

comments repeatedly.

·

High coloration within the size of the program

·

The percentage used as comments, number of inputs and

outputs and number of functions are not measured with the Halstead complexity and Cyclomatic complexity matrices.

·

Very difficult to understand and implement these matrices

How the new metric overcome the problems that exist in previously

proposed metrics.

·

The time to

conclude the system complexity is reduced within out matrix as we have excluded

all unwanted measurements like in older systems.

·

Easier to

understand and easier to maintain.

·

Duplicate and unwanted comments will be added to the

comments repeatedly.

·

The percentage used as comments, number of inputs and

outputs and number of functions complexity measurements are included in our

metrics rather than the Halstead

complexity and Cyclomatic complexity matrices

Previously we conceded about the various metrics. There were

many complexity factors used.

·

Direct measurement.

·

Efficiency

·

Portability.

·

Indirect / derived measurement.

·

Ratio.

·

Predication.

·

Interval.

·

Nominal

Using these complexity factors we can make a good

metric. We did a survey using a google form and get information from the IT

professionals. The factors we categorized into five parts and we want to know

the weight for the each factor. Using all the results implement the new metric.

The factors are given below.

·

Commented percentage.

·

Cohesions & couplings.

·

Fan in & Fan out.

·

Number of functions.

·

Number of inputs & outputs.