Measure of Complexity for Object-Oriented Programs: A Cognitive Approach

  • Amit Kumar Jakhar
  • Kumar Rajnish
Conference paper
Part of the Smart Innovation, Systems and Technologies book series (SIST, volume 44)


A new cognitive metric named “Propose Object-Oriented Cognitive Complexity” (POOCC) is proposed to measure the complexity of Object-Oriented (OO) programs. The proposed metric is based on some fundamental factors like: number of operands, operators available in a method of an OO class, cognitive weight of different basic control structures and ratio of accessing similar parameters of an OO class. Evaluation of propose cognitive metric is done with the help of 16 C++ programs and Weyuker’s property is used to validate it, seven out of nine properties are satisfied by the proposed metric. Furthermore, this work is also present the relationship between POOCC and Lines of Code (LOC) to examine the density of the code.


Lines of code Classes Object-oriented Cognitive Complexity 


  1. 1.
    IEEE CS: IEEE Standard Glossary of Software Engineering Terminology, IEEE Standard 610.12 (1990)Google Scholar
  2. 2.
    Wang, Y.: On cognitive informatics. In: Proceedings of IEEE (ICCI’2002), pp. 34–42 (2002)Google Scholar
  3. 3.
    Wang, Y.: On the informatics laws of software. In: Proceedings of 1st IEEE International Conference on Cognitive Informatics (2002)Google Scholar
  4. 4.
    Wang, Y.: On the cognitive informatics foundations of software engineering. In: Proceedings of 3rd IEEE International Conference on Cognitive Informatics (2004)Google Scholar
  5. 5.
    Mishra, S., Akman, I.K.: Weighted class complexity: a measure of complexity for object-oriented design. J. Inf. Sci. Eng. 24, 1689–1708 (2008)Google Scholar
  6. 6.
    Mishra, S., Akman, I.K., Koyuncu, M.: An inheritance complexity metric for object-oriented code: a cognitive approach. Indian Acad. Sci. 36(3), 317–337 (2011)Google Scholar
  7. 7.
    Wang, Y., Shao, J.: A new measure of software complexity based on cognitive weights. Can. J. Electr. Comput. Eng. 28(2), 69–74 (2003)CrossRefGoogle Scholar
  8. 8.
    Aloysius, A., Arockiam, L.: Coupling complexity metric: a cognitive approach. IJITCS, MECS Publisher, 9, pp. 29–35 (2012)Google Scholar
  9. 9.
    Gupta, V., Chabbra, K.J.: Object-oriented cognitive spatial complexity measures. Int. J. Electr. Electr. Eng. 3(6), 370–377 (2009)Google Scholar
  10. 10.
    Kearney, J.K., Sedlmeyer, R.L., Thompson, W.B., Gary, M.A., Adler, M.A.: Software Complexity Measurement. ACM Press, New York, vol. 28, pp. 1044–1050 (1986)Google Scholar
  11. 11.
    Weyuker, J.E.: Evaluating software complexity measures. IEEE Trans. Softw. Eng. 14, 1357–1365 (1998)MathSciNetCrossRefGoogle Scholar
  12. 12.
    Chidamber, S.R., Kemerer, C.F.: A metrics suite for object oriented design. IEEE Trans. Softw. Eng. 20(6), 476–493 (1994)CrossRefGoogle Scholar
  13. 13.
    Kamthane, A.N.: Object-Oriented Programming with ANSI & Turbo C++, 4th edn. Pearson EducationGoogle Scholar

Copyright information

© Springer India 2016

Authors and Affiliations

  1. 1.Department of Computer Science & EngineeringMesra, RanchiIndia

Personalised recommendations