19 research outputs found

    New Inheritance Complexity Metrics for Object-Oriented Software Systems: An Evaluation with Weyuker's Properties

    Get PDF
    Two inheritance complexity metrics, one at class level CCI (Class Complexity due to Inheritance) and another at program level ACI (Average Complexity of a program due to Inheritance), have been proposed for object-oriented software systems. These proposed metrics are evaluated with Weyuker's properties and compared with other well known object-oriented inheritance metrics. It has been found that the proposed metrics better represent the complexity, due to inheritance, of a class and a program. Weyuker's property 7 (Significance of Permutation) has received a negative response regarding its applicability to object-oriented software metrics. It has been observed that this property is not satisfied by any of the object-oriented inheritance metrics proposed so far. Contrary to past beliefs, the relevance of this property to object-oriented systems has been brought out in this paper. Examples with C++ code are also presented to support the applicability of this property

    Estimating Software Testing Complexity

    Get PDF
    Context: Complexity measures provide us some information about software artifacts. A measure of the difficulty of testing a piece of code could be very useful to take control about the test phase. Objective: The aim in this paper is the definition of a new measure of the difficulty for a computer to gen erate test cases, we call it Branch Coverage Expectation (BCE). We also analyze the most common com plexity measures and the most important features of a program. With this analysis we are trying to discover whether there exists a relationship between them and the code coverage of an automatically generated test suite. Method: The definition of this measure is based on a Markov model of the program. This model is used not only to compute the BCE, but also to provide an estimation of the number of test cases needed to reach a given coverage level in the program. In order to check our proposal, we perform a theoretical val idation and we carry out an empirical validation study using 2600 test programs. Results: The results show that the previously existing measures are not so useful to estimate the difficulty of testing a program, because they are not highly correlated with the code coverage. Our proposed mea sure is much more correlated with the code coverage than the existing complexity measures. Conclusion: The high correlation of our measure with the code coverage suggests that the BCE measure is a very promising way of measuring the difficulty to automatically test a program. Our proposed measure is useful for predicting the behavior of an automatic test case generator.This work has been partially funded by the Spanish Ministry of Science and Innovation and FEDER under contract TIN2011-28194 (the roadME project

    An empirical evaluation of the “cognitive complexity” measure as a predictor of code understandability

    Get PDF
    Background: Code that is difficult to understand is also difficult to inspect and maintain and ultimately causes increased costs. Therefore, it would be greatly beneficial to have source code measures that are related to code understandability. Many ‘‘traditional’’ source code measures, including for instance Lines of Code and McCabe’s Cyclomatic Complexity, have been used to identify hard-to-understand code. In addition, the ‘‘Cognitive Complexity’’ measure was introduced in 2018 with the specific goal of improving the ability to evaluate code understandability. Aims: The goals of this paper are to assess whether (1) ‘‘Cognitive Complexity’’ is better correlated with code understandability than traditional measures, and (2) the availability of the ‘‘Cognitive Complexity’’ measure improves the performance (i.e., the accuracy) of code understandability prediction models. Method: We carried out an empirical study, in which we reused code understandability measures used in several previous studies. We first built Support Vector Regression models of understandability vs. code measures, and we then compared the performance of models that use ‘‘Cognitive Complexity’’ against the performance of models that do not. Results: ‘‘Cognitive Complexity’’ appears to be correlated to code understandability approximately as much as traditional measures, and the performance of models that use ‘‘Cognitive Complexity’’ is extremely close to the performance of models that use only traditional measures. Conclusions: The ‘‘Cognitive Complexity’’ measure does not appear to fulfill the promise of being a significant improvement over previously proposed measures, as far as code understandability prediction is concerned

    Software complexity as a software quality indicator (the three doubts and the light at the end of tunnel)

    Get PDF

    Predicting Class Life Cycle Maintenance Effort Based on Class Complexity

    Get PDF
    In the software industry today many programmers spend countless hours maintaining existing Java programs. The cost of code maintenance affects a company in many ways such as the budget, time management and resources. Making management decisions regarding these issues could be assisted, if maintenance cost of Java classes could be predicted. The goal of this thesis was to create a new model predicting the maintenance effort based on the Java class complexity. It seems clear the complexity of a Java class can directly relate to the amount of time it will take to perform maintenance on the class. To develop the new maintenance effort model, a test bed of Java classes was assembled representing a sample of Java classes from the workplace. Then a variety of Java class metrics were calculated using these classes. Using the backward elimination process of regression analysis in SPSS, a new model was created predicting maintenance effort. The metrics that best predicted maintenance effort were the depth of an inheritance tree, the number of times a class has been deployed to the customer and the lines of code. Together, these metrics together were able to predict 85% of the maintenance effort on the set of Java classes tested

    Measuring the reactivity of intelligent agent programs

    Get PDF
    The booming of intelligent agent technology over past few decades brings a surging number of agent applications in various areas. There also have a large number of designs as well as programming languages been introduced in the literature in the agent oriented area. However, very little work has been dedicated to define quality measures for the development of an agent-based system. Previous efforts mostly focus on adopting classical measures such as using coupling (degree of program dependency) and cohesion (degree of function relationship in single module) to measure the quality of agent programs. I maintain that its time to work on a set of software quality measures that are specific to the distinct characteristics of agent-based systems. In this thesis, two methods are purposed to measure the reactivity of agent systems, which provide indications on how agent systems respond to changes in their environment in a timely fashion. A prototype tool is developed integrated with Jason, a well-known agent-oriented programming platform, to calculate reactivity of each agent in agent system based on their plan libraries, and conducted several experiments to demonstrate the reliability of reactivity measure. In addition, an agent behavioural profile is introduced which is an overview of relationships of actions in agent plan library. Based on agent behavioural profile, definitions of agent behavioral profile identity, entailment as well as preservation were proposed, which ensure original agent\u27s behaviours could be preserved while performing reactivity enhancement

    Variant of the Residual Complexity Metric

    Get PDF

    A quantitative charcterization of control flow context: software measures for programming environments

    Get PDF
    A review of published measures of control flow complexity in programs reveals three major deficiencies: loss of information, lack of specificity, and lack of analytical support. A new approach is used to characterize the control structure of a program, with the aim of defining properties and measures of control flow that can be of immediate use to programmers, regardless of their utility as complexity measures. Mathematical rigor and analytical evaluation techniques are used to define a set of properties of control structure and a corresponding vector of measures. Instead of defining the properties and measures for an entire flowgraph, they are defined at the node level, reflecting the control flow surrounding each node in a flowgraph. The properties and their measures reflect the following characteristics of control flow: nesting, iteration, structuredness, and predecessors. Algorithms for computing the properties and their measures are presented. An assessment of the computational complexity of the algorithms shows that they are feasible programming environment tools;A finite path set, representing all possible execution sequences, is evaluated as a characterizing property. Desired characteristics of the path set are defined and used to evaluate four published path subset criteria. Those criteria are shown to be deficient, so a fifth criterion is defined. However, the path set satisfying this fifth criterion is shown to be too large to be of practical use to a programmer
    corecore