Estimating the Parameters of Software Reliability Growth Models Using the Grey Wolf Optimization Algorithm

In this age of technology, building quality software is essential to competing in the business market. One of the major principles required for any quality and business software product for value fulfillment is reliability. Estimating software reliability early during the software development life cycle saves time and money as it prevents spending larger sums fixing a defective software product after deployment. The Software Reliability Growth Model (SRGM) can be used to predict the number of failures that may be encountered during the software testing process. In this paper we explore the advantages of the Grey Wolf Optimization (GWO) algorithm in estimating the SRGM’s parameters with the objective of minimizing the difference between the estimated and the actual number of failures of the software system. We evaluated three different software reliability growth models: the Exponential Model (EXPM), the Power Model (POWM) and the Delayed S-Shaped Model (DSSM). In addition, we used three different datasets to conduct an experimental study in order to show the effectiveness of our approach.


I. INTRODUCTION
With the increasing importance of software systems in almost all aspects of our lives, there is a great need for the production of high quality software systems.The traditional model of software quality factors, suggested by McCall [1], consists of eleven different factors that should be considered in determining the quality of software.Subsequent models include Evans and Marciniak [2], which consists of twelve factors, and Deutsch and Willis [3], which consists of fifteen factors.All of these models incorporate reliability as one of the software quality factors.Software reliability is defined according to [4] as: "the probability, over a given period of time, that the system will correctly deliver services as expected by the user."A more precise definition of software reliability is given by [5], [6] as: "the probability of failure-free operation over a specified time, in a given environment, for a specific purpose."Unfortunately, the task of identifying and repairing software faults is costly.Moreover, the cost of finding the remaining faults increases as the number of faults decreases until the cost exceeds the benefit [7], [8].Therefore, there is no software system that is failure-free, which is why the reliability requirements should be included in any software development contract.Software reliability is measured based on the maximum allowable rate of failure and can represent an entire system or one or more of its parts [9]- [11].
The cost of software development is always higher for more reliable systems.Consequently, the desired reliability should be determined depending on the criticalness of failure-free operation of the system.For example, the failure rate of a life-threatening system such as heart-monitor should be very low while a company website may have a higher failure rate.
In the literature, many methods are introduced to estimate and predict software reliability [12]- [20].The proposed methods can be classified into two main categories [9].The first category is Software Reliability Prediction Models and the second category is Software Reliability Growth Models (SRGM).Software reliability prediction models consider predicting the reliability early in the development life cycle.In the requirements, design or implementation phases, the model uses historical data and some quantitative measurements like Lines of code (LOC) and depth of nesting loops to estimate the failure rate.Examples of software reliability prediction models include the orthogonal defect classification model [21] and the constructive quality model [22], [23].Some reliability models may be based on software architecture and others on modified adaptive testing [24], [25].The second category, SRGM, represents how the system reliability changes over time during the testing phase and based on test data.SRGMs collect defect data and statistically correlate this data with known mathematical functions to predict software reliability [26]- [29].
Many SRGMs are proposed to represent the relationship between software reliability and time.SRGMs can be classified as either parametric or non-parametric models.The most famous parametric models are the Non-Homogeneous Poisson Process (NHPP) models used in [30]- [32].Non-parametric models have less restricted assumptions as they can predict reliability based only on defect data [33].Other SRGMs are introduced using Neural Networks in [14], [34], [35], using Bayesian learning in [36], [37] and using particle swarm optimization in [38], [39].
In this paper, we utilize the Grey Wolf Optimization (GWO) algorithm to predict faults during the software testing process using software faults historical data.The rest of this paper is organized as follows: In Section II, we briefly introduce www.ijacsa.thesai.orgsome SRGM models that we use in our study.Section III provides an overview of the GWO algorithm.Section IV shows the evaluation criterion adopted in this study.The experimental results developed for parameter estimation of software reliability are given in Section V. Finally, we provide the conclusions and future work in Section VI.

II. RELIABILITY GROWTH MODELS (SRGM)
The inability to meet software requirements and/or deviation from the goal for which the software was developed is defined as software failure.Software reliability depends mainly on the way we handle failure.For example, detecting failure during execution and repairing it increases the reliability of the software as a function of time.This is what happens during the software testing process and before release of software to the market.Software reliability growth models (SRGMs) are the models concerned with the explanation and the description of software failures.
In the literature, many SRGMs were presented to estimate the reliability of software systems [40], [41].Each SRGM assumes a function called M (t) that measures the number of failures experienced at a given time t.The SRGM parameters are estimated based on either the failure times t 1 , t 2 , . . .or the times between failures t 1 , t 2 , . . . .For a given software project, µ(t) represents the mean value function of a SRGM reflecting the expected number of failures experienced at time t.The derivative of the mean value function with respect to time, dµ(t) dt , is defined as the failure intensity (t).In the following subsections, we briefly describe three well-known SRGM models that we use in our study.

A. Exponential Model (EXPM)
The exponential model was first provided in [5], [42].This model is also known as the Goel-Okumoto exponential model [43] shown in Equations 1.
The parameter b 0 is the expected total number of failures recovered at the end of the testing process (i.e.v 0 ).b 1 represents the rate at which the defect rate decreases (see Equation 2).
where the parameter 0 is the initial failure intensity and v 0 is the total failure at the end of the testing process.

B. Power Model (POWM)
The power model is also known as the Non-Homogeneous Poisson Process (NHPP) [44].The equations that govern µ and are given in Equations 3.
Many systems have adopted the NHPP model for analysis.For example in [45], author uses the NHPP to estimate software reliability for nuclear safety software.The Bayesian statistical inference (BSI) method was used to estimate the model parameters.

C. Delayed S-Shaped Model (DSSM)
This model is known as Yamada delayed S-shaped model [46], [47].The model is a finite failure model.Yamada et al. [27] provided this model for error detection, in which the observed growth curve of the cumulative errors has an Sshape.The system equations for µ(t; b) and (t; b) are given in Equation 4.
where b 0 is the expected total number of failures and b 1 represents the failure detection rate.

III. GREY WOLF SEARCH ALGORITHM
The Grey Wolf Optimizer (GWO) is a meta-heuristics algorithm introduced by Mirjalili et al. [48].The GWO is utilized to solve many optimization problems in different fields and successfully provides highly competitive results [49]- [52].
The GWO algorithm is based on the wild behavior of the grey wolves during hunting.According to the dominant hierarchy leadership order, the GWO divides the animals' population into four categories: alpha (↵), beta ( ), delta ( ), and omega (!).Consequently, the optimization process, the same as the hunting, is guided by the highest rank leaders: ↵, and respectively which represent the best three solutions in the search space.The ! wolves, the lowest in the hierarchical rank, represent the rest of the solutions that must adjust their positions to follow the other dominant wolves.
It is assumed that each candidate solution with dimension n is represented by the vector X such that the Grey wolf position vector is given as: During the hunting process, the grey wolves surround the prey (i.e.solution of the problem).This surrounding behavior in GWO can be represented mathematically as follows: where X(t) p is the position vector of the prey, X(t) is the position vector of the Grey wolf, t is the current iteration, Ã and C are coefficient vectors that vary to allow the wolves to adjust their positions in the space around the prey.The coefficient vectors Ã and C are computed according to Equations 8.
(IJACSA) International Journal of Advanced Computer Science and Applications, www.ijacsa.thesai.org It is given that the elements ã are linearly decreasing from the value of 2 to the value of 0 over the search process and r1 , r2 are random vectors selected in the domain of [0,1].
Then the GWO saves the best three solutions (alpha, beta and delta wolves) and allows the other solutions (omega wolves) to adjust their positions according to the positions of the best solutions.The following equations are used to calculate the distance between the current position and ↵, , and , respectively (see Equations 9): where X↵ , X and X are the positions of the ↵, and , respectively, X is the position of the current solution and C1 , C2 and C3 are random vectors.Then, the final position of the current solution can be calculated as in Equation 10.
Thus, X(t + 1) can be computed as follows: where t represents the number of iterations and Ã1 , Ã2 and Ã3 are random vectors that vary to allow the wolves to attack towards the prey.Finally, the hunting process ends when the grey wolves attack the prey after it stops moving.In the next sections we show how to utilize the GWO to estimate the parameters for number of SRGMs.

IV. MEASURE FOR MODEL PREDICTABILITY
To make a comparison between different SRGMs it is important to measure the model accuracy in terms of some meaningful measurements.In our case we adopt the Goodnessof-fit criteria.These criteria are applied to measure the quality of the solution provided and determine the proximity of the estimated failures to the measured failures.
Assume we have N measurements which represent the cumulative number of failures found at time t i where t i is the accumulated execution time.Then µ(t i , b) can be defined as the projected number of failure at time t i by a model.
According to the Goodness-of-fit criterion, a curve corresponding to a selected model is fitted to all data points t i , µ i , i = 1, . . ., n; then the difference between the actual measured failures y and the estimated failures ŷ based on the proposed model is compared and evaluated using the Variance-Accounted-For (VAF) and the Mean Magnitude of Relative Error (MMRE) [53].
Another evaluation criterion that we use in our study is the correlation coefficient R that can be calculated using the following equation.
Finally we use the mean square error as the evaluation criterion in our convergence behavior analysis as shown in the following section.

MSE
V. EXPERIMENT RESULTS To develop our new technique for solving the problem of estimating the parameters of SRGM we used GWO MATLAB toolbox.We started by setting the number of search agents (grey wolves) and the maximum number of iterations for the experiment.From our experience we found that 30 agents and 50 iterations led to highly accepted results.The objective function gets the variables as a vector ([x 1 x 2 ...x n ]) and returns the objective value.
Our experiments explore the use of the GWO method to estimate the parameters of three software projects using three SRGMs.In each case, we estimate the model parameters for EXPM, POWM and DSSM models, generate the convergence curves using the GWO method and show the scattered plot.

A. Test/Debug Data 1
A real-time control application presented in [54], [55] is adopted as the first case study with a daily collected data.The real-time control application program has a size of 870 Kilo line of code (KLOC) of FORTRAN and a middle level language code.To estimate the model parameters b 0 and b 1 based on the GWO method, we needed to set up the search space.In our case, b 0 2 [0, 500] and b 1 2 [0, 1].
In Figure 1 (a), we show the actual and estimated accumulated failures curves for the EXPM, POWM and DSSM and the convergence behavior curves of the GWO process for the three developed models.A scattered plot of the three developed models is shown in Figure 1 (b).
Table I shows the estimated parameters for the SRGMs together with the model equations.In Table IV, we summarize the results of two evaluation criterion MMRE and VAF values for the three developed models EXPM, POWN and DSSM.In this case study, the DSSM model provided the best results in terms of VAF while the EXPM model's MMRE was the minimum in comparison to other POWM and DSSM.

B. Test/Debug Data 2
In the second case study, a real-time application [56] of a software system containing 200 modules of FORTRAN language was used to test our proposed methodology.The data consists of 111 measurements [55].We ran the GWO to tune the parameters of EXPM, POWM and DSSM.www.ijacsa.thesai.orgIn our case, b 0 2 [0, 30] and b 1 2 [0, 2].In Figure 2 (a), we show the actual and estimated accumulated failures curves for the EXPM, POWM and DSSM models and the convergence curves of the GWO process for the three developed models.A scattered plot of the three developed models is shown in Figure 2 (b).
Table II shows the estimated parameters for the SRGM models together with the model equations.The computed evaluation criterion are included in Table IV.Based on the developed experiments for this case, the results show that the DSSM model provided the best performance using the GWO tuned parameters as it has the minimum MMRE and the maximum VAF compared to other proposed models.

C. Test/Debug Data 3
In our third case study, we used a Test/Debug data set including 46 measurements as presented in [56].We ran the GWO to find the best parameters to tune the EXPM, POWM and DSSM.In our case, b 0 2 [0, 1000] and b 1 2 [0, 1].In Figure 2 (a), we show the actual and estimated accumulated failures curves for the EXPM, POWM and DSSM models and the convergence curves of the GWO process for the three developed models.A scattered plot of the three developed models is shown in Figure 2 (b).
The estimated parameters for SRGMs are shown in Table III.In this case, the results show that the DSSM model was able to provide the best results in terms of MMRE while both the EXPM and the POWM models have better VAF values as shown in Table IV.

VI. CONCLUSION AND FUTURE WORK
In this paper, we proposed a GWO-based methodology to estimate the parameters of software reliability growth models (SRGMs).The estimated model parameters are used to predict the accumulated failures in a software system during the testing process.The problem is formulated for the GWO algorithm with the objective of minimizing the difference between the actual failures and the estimated accumulated failures.
Our methodology was employed to estimate the parameters of three adopted SRGMs: the exponential model, power model, and S-shaped model.Then the proposed models were applied to three real measured test/debug datasets.The results show that the proposed methodology is able to successfully estimate the parameters of SRGMs.www.ijacsa.thesai.org

Fig. 1 .
Fig. 1.(a) Actual and estimated failures and convergence curves for GWO (b) Scattered plot for the EXPM, POWM and DSSM using 109 Measurements

Fig. 2 .
Fig. 2. (a) Actual and estimated failures and convergence curves for the GWO (b) Scattered plot for the EXPM, POWM and DSSM using 111 Measurements

Fig. 3 .
Fig. 3. (a) Actual and Estimated Accumulated failures and the convergence curves for the GWO (b) Scattered plot for the EXPM, POWM and DSSM using 46 Measurements