SlideShare una empresa de Scribd logo
1 de 19
Descargar para leer sin conexión
Software Quality Management 
          Unit – IV 

                      G. Roy Antony Arnold 
                           Asst. Prof. / CSE
• The li
   h lines of code ( OC) count i usually f
              f d (LOC)             is  ll for
  executable statements.
• LOC count represents the program size and
  complexity, it is not a surprise that

                            .
• More recent studies point to a curvilinear
  relationship between lines of code and defect
  rate:
Maximum Source     Average Defect per
Lines of Modules   1,000 Source Lines
       63                 1.5
      100                 1.4
      158                 0.9
      251                 0.5
      398                 1.1
      630                 1.9
      1000                1.3
     >1000                1.4
• Wh
  When module size b
             d l     i    becomes very l    large, the
                                                    h
  complexity increases to a level beyond a
  programmer s
  programmer's immediate span of control and total
  comprehension.
• The curvilinear model between size and defect
  density sheds new light on software quality
  engineering. It implies that there may be an
    g        g         p                      y
  optimal program size that can lead to the lowest
  defect rate.
• Such an optimum may depend on language,
  project, product, and environment; apparently
  many more empirical i
                  i i l investigations are needed.
                             ti ti              d d
• Halstead (1977) distinguishes software
  science from computer science.
• The premise of software science is that any
  programming task consists of selecting and
  arranging a finite number of program
  “tokens”, which are
   tokens
                              .
• A computer program, according to software
                             di        f
  science,
                                         .
• Th primitive measures of H l t d' software science
  The i iti              f Halstead's ft       i
  are




• Based on these primitive measures, Halstead
  developed a system of equations expressing

                                             and other
  features such as development effort and the projected
  number of faults in the software.
Vocabulary, 
Length, 
Length,
Volume, 
Level, 
Difficulty, 
Difficulty
Effort, 
Faults, 
• The measurement of cyclomatic complexity b
   h               f    l    i      l i by
  McCabe (1976) was designed

  (maintainability).
• It is the classical graph theory cyclomatic
  number,
          .
• To determine the paths, the program
  procedure is represented

       .
• The general formula to compute cyclomatic
      p    y
  complexity is:

• Wh
  Where,
 V(G) – Cyclomatic Number of G
  ( ) y
 e – Number of edges
 n – Number of nodes
 n Number of nodes
 p – Number of unconnected parts of the graph
• If we count the edges, nodes, and 
  disconnected parts of the graph, 


• The iteration test in a looping statement is
  The iteration test in a looping statement is 
  counted as one binary decision. In the 
  preceding simple example, since there are 
  two binary decisions, M = 2 + 1 = 3
• The cyclomatic complexity metric is 
  additive. The complexity of several graphs 
  additive The complexity of several graphs
  considered as a group is equal to the sum 
                    g p          p
  of the individual graphs' complexities.
needing detailed inspections.
      g             p
                                   likely to 
have a low defect rate and therefore 
have a low defect rate and therefore
candidates for development without 
detailed inspections.
     l

     , identify troublesome code, and 
estimate testing effort.
estimate testing effort
• McCabe's cyclomatic complexity index is a
                                      .
• It does not distinguish different kinds of control
  flow complexity such as
            p    y
                                        .
• In studying the quality and syntactic indicators
  among a sample of twenty modules of a COBOL
  compiler product
             product,             found that
          at the module level can be estimated
  through the following equations:
• Lo found that most developers were having difficulty 
                             p             g          y
  mastering the DO WHILE construct.
• As a result, minimizing the use of DO WHILE was one of 
  the actions the team took to reduce defects in the 
  compiler product.
• St t
  Structure metrics try to take into account the 
              ti t t t k i t               t th
                                        .
• The most common design structure metrics 
  are the 
  are the                        , which are 
                                   which are
  based on the                proposed by 
                         (1979) and 
  (1978):
             A count of the modules that call a given 
    module
           : A count of modules that are called by a 
    given module
    given module
• I        l    d l    ith l       f i
  In general, modules with a large fan‐in are 
                                                     . 
• In contrast, modules that are large and complex are 
  likely to have a small fan‐in.
                        structure complexity is 
  defined as:

• Henry and Selig's work (1990) defines a hybrid form 
  of their information‐flow metric as
  of their information flow metric as

  where, C internal complexity of procedure p
  where, Cip – internal complexity of procedure p
• C d d Gl (1990) d l
  Card and Glass (1990) developed a system complexity model
                                d      t       l it     d l

  Ct – System Complexity St – Structural (intermodule)
       System Complexity, S Structural (intermodule) 
   complexity, Dt – Data (intermodule) complexity
• They defined relative system complexity as

  n – no. Of modules in the system
• S
  Structure complexity is further defined as
                 l i i f h d fi d

              S=
                   ∑   f 2 (i )
                       n

  Where S – Structural Complexity, f(i) – Fan‐out of Module i,      
  n – no. Of modules in the system
• D t C
  Data Complexity is further defined as
           l it i f th d fi d



  Di  Data Complexity of Module i, V(i)  I/O 
  Di – Data Complexity of Module i, V(i) – I/O
  Variables in module i, f(i) – fan‐out of module i



  D – Data (intramodule) Complexity, D(i) – Data 
  Complexity of module i, n = Number of new 
  modules in the system

Más contenido relacionado

La actualidad más candente

Software myths | Software Engineering Notes
Software myths | Software Engineering NotesSoftware myths | Software Engineering Notes
Software myths | Software Engineering NotesNavjyotsinh Jadeja
 
Software Metrics - Software Engineering
Software Metrics - Software EngineeringSoftware Metrics - Software Engineering
Software Metrics - Software EngineeringDrishti Bhalla
 
Unit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptUnit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptDrTThendralCompSci
 
Integration testing
Integration testingIntegration testing
Integration testingqueen jemila
 
The Software Engineering Discipline and Evolution of S/W Engineering Methodol...
The Software Engineering Discipline and Evolution of S/W Engineering Methodol...The Software Engineering Discipline and Evolution of S/W Engineering Methodol...
The Software Engineering Discipline and Evolution of S/W Engineering Methodol...Santhia RK
 
Software Testing Basics
Software Testing BasicsSoftware Testing Basics
Software Testing BasicsBelal Raslan
 
Software Engineering Layered Technology Software Process Framework
Software Engineering  Layered Technology Software Process FrameworkSoftware Engineering  Layered Technology Software Process Framework
Software Engineering Layered Technology Software Process FrameworkJAINAM KAPADIYA
 
verification and validation
verification and validationverification and validation
verification and validationDinesh Pasi
 
Analysis concepts and principles
Analysis concepts and principlesAnalysis concepts and principles
Analysis concepts and principlessaurabhshertukde
 
Hardware/Software Integration Testing
Hardware/Software Integration TestingHardware/Software Integration Testing
Hardware/Software Integration TestingJohan Hoberg
 
Software Cost Estimation in Software Engineering SE23
Software Cost Estimation in Software Engineering SE23Software Cost Estimation in Software Engineering SE23
Software Cost Estimation in Software Engineering SE23koolkampus
 

La actualidad más candente (20)

Software myths | Software Engineering Notes
Software myths | Software Engineering NotesSoftware myths | Software Engineering Notes
Software myths | Software Engineering Notes
 
Staffing level estimation
Staffing level estimation Staffing level estimation
Staffing level estimation
 
Software Reliability
Software ReliabilitySoftware Reliability
Software Reliability
 
Software Metrics
Software MetricsSoftware Metrics
Software Metrics
 
System testing
System testingSystem testing
System testing
 
System testing
System testingSystem testing
System testing
 
Software Testing
Software TestingSoftware Testing
Software Testing
 
Software Metrics - Software Engineering
Software Metrics - Software EngineeringSoftware Metrics - Software Engineering
Software Metrics - Software Engineering
 
Unit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.pptUnit 1 - Introduction to Software Engineering.ppt
Unit 1 - Introduction to Software Engineering.ppt
 
Integration testing
Integration testingIntegration testing
Integration testing
 
Analysis modeling
Analysis modelingAnalysis modeling
Analysis modeling
 
Ch02 process a generic view
Ch02 process a generic viewCh02 process a generic view
Ch02 process a generic view
 
Complexity metrics and models
Complexity metrics and modelsComplexity metrics and models
Complexity metrics and models
 
The Software Engineering Discipline and Evolution of S/W Engineering Methodol...
The Software Engineering Discipline and Evolution of S/W Engineering Methodol...The Software Engineering Discipline and Evolution of S/W Engineering Methodol...
The Software Engineering Discipline and Evolution of S/W Engineering Methodol...
 
Software Testing Basics
Software Testing BasicsSoftware Testing Basics
Software Testing Basics
 
Software Engineering Layered Technology Software Process Framework
Software Engineering  Layered Technology Software Process FrameworkSoftware Engineering  Layered Technology Software Process Framework
Software Engineering Layered Technology Software Process Framework
 
verification and validation
verification and validationverification and validation
verification and validation
 
Analysis concepts and principles
Analysis concepts and principlesAnalysis concepts and principles
Analysis concepts and principles
 
Hardware/Software Integration Testing
Hardware/Software Integration TestingHardware/Software Integration Testing
Hardware/Software Integration Testing
 
Software Cost Estimation in Software Engineering SE23
Software Cost Estimation in Software Engineering SE23Software Cost Estimation in Software Engineering SE23
Software Cost Estimation in Software Engineering SE23
 

Destacado (14)

Rayleigh model
Rayleigh modelRayleigh model
Rayleigh model
 
Relations diagram
Relations diagramRelations diagram
Relations diagram
 
6 sigma
6 sigma6 sigma
6 sigma
 
6 sigma
6 sigma6 sigma
6 sigma
 
Seven basic tools of quality
Seven basic tools of qualitySeven basic tools of quality
Seven basic tools of quality
 
Case tools
Case toolsCase tools
Case tools
 
Reliability growth models for quality management
Reliability growth models for quality managementReliability growth models for quality management
Reliability growth models for quality management
 
customer satisfaction
customer satisfactioncustomer satisfaction
customer satisfaction
 
Elements Of An Effective Quality Management System
Elements Of An Effective Quality Management SystemElements Of An Effective Quality Management System
Elements Of An Effective Quality Management System
 
Six Sigma
Six SigmaSix Sigma
Six Sigma
 
Customer satisfaction
Customer satisfactionCustomer satisfaction
Customer satisfaction
 
Basic Six Sigma Presentation
Basic Six Sigma PresentationBasic Six Sigma Presentation
Basic Six Sigma Presentation
 
Customer Satisfaction
Customer SatisfactionCustomer Satisfaction
Customer Satisfaction
 
Customer Satisfaction Presentation
Customer Satisfaction PresentationCustomer Satisfaction Presentation
Customer Satisfaction Presentation
 

Similar a Complexity metrics and models

Software engineering
Software engineeringSoftware engineering
Software engineeringRohan Bhatkar
 
Vulnerability Detection Based on Git History
Vulnerability Detection Based on Git HistoryVulnerability Detection Based on Git History
Vulnerability Detection Based on Git HistoryKenta Yamamoto
 
Introduction to OpenSees by Frank McKenna
Introduction to OpenSees by Frank McKennaIntroduction to OpenSees by Frank McKenna
Introduction to OpenSees by Frank McKennaopenseesdays
 
naveed-kamran-software-architecture-agile
naveed-kamran-software-architecture-agilenaveed-kamran-software-architecture-agile
naveed-kamran-software-architecture-agileNaveed Kamran
 
Software Architectures, Week 2 - Decomposition techniques
Software Architectures, Week 2 - Decomposition techniquesSoftware Architectures, Week 2 - Decomposition techniques
Software Architectures, Week 2 - Decomposition techniquesAngelos Kapsimanis
 
INTRODUCTION TO C PROGRAMMING in basic c language
INTRODUCTION TO C PROGRAMMING in basic c languageINTRODUCTION TO C PROGRAMMING in basic c language
INTRODUCTION TO C PROGRAMMING in basic c languageGOKULKANNANMMECLECTC
 
Keynote at IWLS 2017
Keynote at IWLS 2017Keynote at IWLS 2017
Keynote at IWLS 2017Manish Pandey
 
Scalable constrained spectral clustering
Scalable constrained spectral clusteringScalable constrained spectral clustering
Scalable constrained spectral clusteringNishanth Harapanahalli
 
Software architacture recovery
Software architacture recoverySoftware architacture recovery
Software architacture recoveryImdad Ul Haq
 
Putnam Resource allocation model.ppt
Putnam Resource allocation model.pptPutnam Resource allocation model.ppt
Putnam Resource allocation model.pptAnupamaSharma80
 
IncQuery-D: Incremental Queries in the Cloud
IncQuery-D: Incremental Queries in the CloudIncQuery-D: Incremental Queries in the Cloud
IncQuery-D: Incremental Queries in the CloudGábor Szárnyas
 
Software_effort_estimation for Software engineering.pdf
Software_effort_estimation for Software engineering.pdfSoftware_effort_estimation for Software engineering.pdf
Software_effort_estimation for Software engineering.pdfsnehan789
 
Generating test cases using UML Communication Diagram
Generating test cases using UML Communication Diagram Generating test cases using UML Communication Diagram
Generating test cases using UML Communication Diagram Praveen Penumathsa
 
Software Product Measurement and Analysis in a Continuous Integration Environ...
Software Product Measurement and Analysis in a Continuous Integration Environ...Software Product Measurement and Analysis in a Continuous Integration Environ...
Software Product Measurement and Analysis in a Continuous Integration Environ...Gabriel Moreira
 

Similar a Complexity metrics and models (20)

Digital_system_design_A (1).ppt
Digital_system_design_A (1).pptDigital_system_design_A (1).ppt
Digital_system_design_A (1).ppt
 
Software engineering
Software engineeringSoftware engineering
Software engineering
 
Vulnerability Detection Based on Git History
Vulnerability Detection Based on Git HistoryVulnerability Detection Based on Git History
Vulnerability Detection Based on Git History
 
Introduction to OpenSees by Frank McKenna
Introduction to OpenSees by Frank McKennaIntroduction to OpenSees by Frank McKenna
Introduction to OpenSees by Frank McKenna
 
Cost effort.ppt
Cost effort.pptCost effort.ppt
Cost effort.ppt
 
naveed-kamran-software-architecture-agile
naveed-kamran-software-architecture-agilenaveed-kamran-software-architecture-agile
naveed-kamran-software-architecture-agile
 
Software metrics
Software metricsSoftware metrics
Software metrics
 
Software Architectures, Week 2 - Decomposition techniques
Software Architectures, Week 2 - Decomposition techniquesSoftware Architectures, Week 2 - Decomposition techniques
Software Architectures, Week 2 - Decomposition techniques
 
computer architecture.
computer architecture.computer architecture.
computer architecture.
 
INTRODUCTION TO C PROGRAMMING in basic c language
INTRODUCTION TO C PROGRAMMING in basic c languageINTRODUCTION TO C PROGRAMMING in basic c language
INTRODUCTION TO C PROGRAMMING in basic c language
 
Keynote at IWLS 2017
Keynote at IWLS 2017Keynote at IWLS 2017
Keynote at IWLS 2017
 
Scalable constrained spectral clustering
Scalable constrained spectral clusteringScalable constrained spectral clustering
Scalable constrained spectral clustering
 
Software architacture recovery
Software architacture recoverySoftware architacture recovery
Software architacture recovery
 
Putnam Resource allocation model.ppt
Putnam Resource allocation model.pptPutnam Resource allocation model.ppt
Putnam Resource allocation model.ppt
 
IncQuery-D: Incremental Queries in the Cloud
IncQuery-D: Incremental Queries in the CloudIncQuery-D: Incremental Queries in the Cloud
IncQuery-D: Incremental Queries in the Cloud
 
Ch01lect1 et
Ch01lect1 etCh01lect1 et
Ch01lect1 et
 
Chapter 12
Chapter 12Chapter 12
Chapter 12
 
Software_effort_estimation for Software engineering.pdf
Software_effort_estimation for Software engineering.pdfSoftware_effort_estimation for Software engineering.pdf
Software_effort_estimation for Software engineering.pdf
 
Generating test cases using UML Communication Diagram
Generating test cases using UML Communication Diagram Generating test cases using UML Communication Diagram
Generating test cases using UML Communication Diagram
 
Software Product Measurement and Analysis in a Continuous Integration Environ...
Software Product Measurement and Analysis in a Continuous Integration Environ...Software Product Measurement and Analysis in a Continuous Integration Environ...
Software Product Measurement and Analysis in a Continuous Integration Environ...
 

Más de Roy Antony Arnold G (20)

Run chart
Run chartRun chart
Run chart
 
Quality management models
Quality management modelsQuality management models
Quality management models
 
Pareto diagram
Pareto diagramPareto diagram
Pareto diagram
 
Ishikawa diagram
Ishikawa diagramIshikawa diagram
Ishikawa diagram
 
Histogram
HistogramHistogram
Histogram
 
Customer satisfaction
Customer satisfactionCustomer satisfaction
Customer satisfaction
 
Control chart
Control chartControl chart
Control chart
 
Check lists
Check listsCheck lists
Check lists
 
Capability maturity model
Capability maturity modelCapability maturity model
Capability maturity model
 
Structure chart
Structure chartStructure chart
Structure chart
 
Seven new tools
Seven new toolsSeven new tools
Seven new tools
 
Scatter diagram
Scatter diagramScatter diagram
Scatter diagram
 
Qms
QmsQms
Qms
 
Defect removal effectiveness
Defect removal effectivenessDefect removal effectiveness
Defect removal effectiveness
 
Customer satisfaction
Customer satisfactionCustomer satisfaction
Customer satisfaction
 
Reliability growth models
Reliability growth modelsReliability growth models
Reliability growth models
 
Customer oriented planning of case-tools using quality function deployment (qfd)
Customer oriented planning of case-tools using quality function deployment (qfd)Customer oriented planning of case-tools using quality function deployment (qfd)
Customer oriented planning of case-tools using quality function deployment (qfd)
 
Case Tools
Case ToolsCase Tools
Case Tools
 
10 rules of e-business
10 rules of e-business10 rules of e-business
10 rules of e-business
 
CRM
CRMCRM
CRM
 

Último

Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptxMan or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptxDhatriParmar
 
Concurrency Control in Database Management system
Concurrency Control in Database Management systemConcurrency Control in Database Management system
Concurrency Control in Database Management systemChristalin Nelson
 
Congestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationCongestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationdeepaannamalai16
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfJemuel Francisco
 
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxBIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxSayali Powar
 
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Association for Project Management
 
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...DhatriParmar
 
Multi Domain Alias In the Odoo 17 ERP Module
Multi Domain Alias In the Odoo 17 ERP ModuleMulti Domain Alias In the Odoo 17 ERP Module
Multi Domain Alias In the Odoo 17 ERP ModuleCeline George
 
Reading and Writing Skills 11 quarter 4 melc 1
Reading and Writing Skills 11 quarter 4 melc 1Reading and Writing Skills 11 quarter 4 melc 1
Reading and Writing Skills 11 quarter 4 melc 1GloryAnnCastre1
 
Expanded definition: technical and operational
Expanded definition: technical and operationalExpanded definition: technical and operational
Expanded definition: technical and operationalssuser3e220a
 
4.11.24 Mass Incarceration and the New Jim Crow.pptx
4.11.24 Mass Incarceration and the New Jim Crow.pptx4.11.24 Mass Incarceration and the New Jim Crow.pptx
4.11.24 Mass Incarceration and the New Jim Crow.pptxmary850239
 
Transaction Management in Database Management System
Transaction Management in Database Management SystemTransaction Management in Database Management System
Transaction Management in Database Management SystemChristalin Nelson
 
ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfVanessa Camilleri
 
ROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxVanesaIglesias10
 
Measures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataMeasures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataBabyAnnMotar
 
Active Learning Strategies (in short ALS).pdf
Active Learning Strategies (in short ALS).pdfActive Learning Strategies (in short ALS).pdf
Active Learning Strategies (in short ALS).pdfPatidar M
 
Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Seán Kennedy
 
Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4JOYLYNSAMANIEGO
 

Último (20)

Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptxMan or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
 
Concurrency Control in Database Management system
Concurrency Control in Database Management systemConcurrency Control in Database Management system
Concurrency Control in Database Management system
 
Congestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationCongestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentation
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
 
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxBIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
 
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptxINCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
 
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
 
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
 
Multi Domain Alias In the Odoo 17 ERP Module
Multi Domain Alias In the Odoo 17 ERP ModuleMulti Domain Alias In the Odoo 17 ERP Module
Multi Domain Alias In the Odoo 17 ERP Module
 
Reading and Writing Skills 11 quarter 4 melc 1
Reading and Writing Skills 11 quarter 4 melc 1Reading and Writing Skills 11 quarter 4 melc 1
Reading and Writing Skills 11 quarter 4 melc 1
 
Expanded definition: technical and operational
Expanded definition: technical and operationalExpanded definition: technical and operational
Expanded definition: technical and operational
 
4.11.24 Mass Incarceration and the New Jim Crow.pptx
4.11.24 Mass Incarceration and the New Jim Crow.pptx4.11.24 Mass Incarceration and the New Jim Crow.pptx
4.11.24 Mass Incarceration and the New Jim Crow.pptx
 
Transaction Management in Database Management System
Transaction Management in Database Management SystemTransaction Management in Database Management System
Transaction Management in Database Management System
 
ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdf
 
ROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptx
 
Measures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataMeasures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped data
 
Paradigm shift in nursing research by RS MEHTA
Paradigm shift in nursing research by RS MEHTAParadigm shift in nursing research by RS MEHTA
Paradigm shift in nursing research by RS MEHTA
 
Active Learning Strategies (in short ALS).pdf
Active Learning Strategies (in short ALS).pdfActive Learning Strategies (in short ALS).pdf
Active Learning Strategies (in short ALS).pdf
 
Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...
 
Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4
 

Complexity metrics and models

  • 1. Software Quality Management  Unit – IV  G. Roy Antony Arnold  Asst. Prof. / CSE
  • 2. • The li h lines of code ( OC) count i usually f f d (LOC) is ll for executable statements. • LOC count represents the program size and complexity, it is not a surprise that . • More recent studies point to a curvilinear relationship between lines of code and defect rate:
  • 3.
  • 4. Maximum Source  Average Defect per Lines of Modules 1,000 Source Lines 63 1.5 100 1.4 158 0.9 251 0.5 398 1.1 630 1.9 1000 1.3 >1000 1.4
  • 5. • Wh When module size b d l i becomes very l large, the h complexity increases to a level beyond a programmer s programmer's immediate span of control and total comprehension. • The curvilinear model between size and defect density sheds new light on software quality engineering. It implies that there may be an g g p y optimal program size that can lead to the lowest defect rate. • Such an optimum may depend on language, project, product, and environment; apparently many more empirical i i i l investigations are needed. ti ti d d
  • 6. • Halstead (1977) distinguishes software science from computer science. • The premise of software science is that any programming task consists of selecting and arranging a finite number of program “tokens”, which are tokens . • A computer program, according to software di f science, .
  • 7. • Th primitive measures of H l t d' software science The i iti f Halstead's ft i are • Based on these primitive measures, Halstead developed a system of equations expressing and other features such as development effort and the projected number of faults in the software.
  • 9. • The measurement of cyclomatic complexity b h f l i l i by McCabe (1976) was designed (maintainability). • It is the classical graph theory cyclomatic number, . • To determine the paths, the program procedure is represented .
  • 10. • The general formula to compute cyclomatic p y complexity is: • Wh Where, V(G) – Cyclomatic Number of G ( ) y e – Number of edges n – Number of nodes n Number of nodes p – Number of unconnected parts of the graph
  • 11. • If we count the edges, nodes, and  disconnected parts of the graph,  • The iteration test in a looping statement is The iteration test in a looping statement is  counted as one binary decision. In the  preceding simple example, since there are  two binary decisions, M = 2 + 1 = 3 • The cyclomatic complexity metric is  additive. The complexity of several graphs  additive The complexity of several graphs considered as a group is equal to the sum  g p p of the individual graphs' complexities.
  • 12.
  • 13. needing detailed inspections. g p likely to  have a low defect rate and therefore  have a low defect rate and therefore candidates for development without  detailed inspections. l , identify troublesome code, and  estimate testing effort. estimate testing effort
  • 14. • McCabe's cyclomatic complexity index is a . • It does not distinguish different kinds of control flow complexity such as p y . • In studying the quality and syntactic indicators among a sample of twenty modules of a COBOL compiler product product, found that at the module level can be estimated through the following equations:
  • 15. • Lo found that most developers were having difficulty  p g y mastering the DO WHILE construct. • As a result, minimizing the use of DO WHILE was one of  the actions the team took to reduce defects in the  compiler product.
  • 16. • St t Structure metrics try to take into account the  ti t t t k i t t th . • The most common design structure metrics  are the  are the , which are  which are based on the  proposed by  (1979) and  (1978): A count of the modules that call a given  module : A count of modules that are called by a  given module given module
  • 17. • I l d l ith l f i In general, modules with a large fan‐in are  .  • In contrast, modules that are large and complex are  likely to have a small fan‐in. structure complexity is  defined as: • Henry and Selig's work (1990) defines a hybrid form  of their information‐flow metric as of their information flow metric as where, C internal complexity of procedure p where, Cip – internal complexity of procedure p
  • 18. • C d d Gl (1990) d l Card and Glass (1990) developed a system complexity model d t l it d l Ct – System Complexity St – Structural (intermodule) System Complexity, S Structural (intermodule)  complexity, Dt – Data (intermodule) complexity • They defined relative system complexity as n – no. Of modules in the system • S Structure complexity is further defined as l i i f h d fi d S= ∑ f 2 (i ) n Where S – Structural Complexity, f(i) – Fan‐out of Module i,       n – no. Of modules in the system
  • 19. • D t C Data Complexity is further defined as l it i f th d fi d Di  Data Complexity of Module i, V(i)  I/O  Di – Data Complexity of Module i, V(i) – I/O Variables in module i, f(i) – fan‐out of module i D – Data (intramodule) Complexity, D(i) – Data  Complexity of module i, n = Number of new  modules in the system