A Fuzzy Approach for Component Selection amongst Different Versions of Alternatives for a Fault Tolerant Modular Software System under Recovery Block Scheme Incorporating Build-or-Buy Strategy

Software projects generally have to deal with producing and managing large and complex software products. As the functionality of computer operations become more essential and yet more critical, there is a great need for the development of modular software system. Component-Based Software Engineering concerned with composing, selecting and designing components to satisfy a set of requirements while minimizing cost and maximizing reliability of the software system. This paper discusses the fuzzy approach for component selection using “Build-or-Buy” strategy in designing a software structure. We introduce a framework that helps developers to decide whether to buy or build components. In case a commercial off-the-shelf (COTS) component is selected then different versions are available for each alternative of a module and only one version will be selected. If a component is an in-house built component, then the alternative of a module is selected. Numerical illustrations are provided to demonstrate the model developed.


Introduction
Computer software is very important in today's world.In particular, science and technology demand high quality software for making improvements and breakthroughs.The software development companies are continuously developing/modifying/updating their software according to the changing needs and requirements.The concept of "software reliability" and its measurement is receiving much attention in the software development community.Software reliability is one of the important parameters of software quality and system dependability.Software reliability engineering balances customer needs in the major quality characteristics of reliability, availability, delivery time and cost more effectively.The reliability of software can be controlled during the development life cycle through the application of reliability improvement techniques.Two of the best-known fault tolerant soft-ware design methods are N-version programming and Recovery block scheme.The basic mechanism of both the schemes is to provide redundant software to tolerate software failures.Software whose failure can have bad effects afterwards can be made fault tolerant through redundancy at module level [1].
When the design of software architecture reaches a good level of maturity, software engineers have to take a decision on the selection of software components.Non functional aspects play a significant role in determining software quality.Given the fact that lack of proper handling of non functional aspects of a software application has led to a series of software failures [2], nonfunctional attributes such as reliability security and performance should be considered during the component selection phase of software development.This paper discusses a framework that helps developers to decide whether to buy or build components of software architecture on the basis of cost and non functional factors.While developing software, components can be both bought as commercial off-the shelf (COTS) products, and probably adapted to work in the software system, or they can be developed in-house.This decision is known as "build-orbuy decision".This decision affects the overall cost and reliability of the system.Most of the current software systems include one or more COTS products.COTS are pieces of software that can be reused by software projects to build new systems.Benefits of COTS based development include significant reduction in the development cost, time and improvement in the dependability requirement.The components, which are not available in the market or cannot be purchased economically, can be developed within the organization and are known as inhouse built components.Reference [3] discussed issues related to reliability of systems, caused by integrating COTS components.The optimal selection is achieved through weighted maximization of system quality subject to budget as a constraint in which an upper limit is placed over the constraint.
This paper discusses the issues related to reliability of the software systems and cost caused by integrating COTS or in-house built components.Fault tolerance is achieved through redundancy in Recovery Block model and redundancy results in additional cost.We assume that for all the alternatives available for a module, cost increases if higher reliability is desired.Several alternatives of a software module may be available as COTS, almost equivalent from the functional viewpoint.Purchase of high quality COTS products can be justified by the frequent use of the module.Large software systems possess the modular structure to perform a set of functions.Each function is performed by different modules having different alternatives for each module.In case, a COTS component is selected then different versions are available for each alternative of a module and only one version will be selected.If a component is an in-house built component, then the alternative of a module is selected.A schematic representation of the software system is given in Figure 1.
In the existing research related to the software decision, it is assumed that all the parameters of the problem are known precisely.Various objectives and restrictions are set by the management and cost coefficients involved in the cost function are determined based on past experience and the available data base.This makes it difficult for the management to provide precise values of the various cost coefficients and objectives to be met.Moreover due to changing customer specifications, lack of experience of testing team or novelty, changing testing environment, complexity in the project involved, unknown emerging factors at the start of the project adds imprecision and ambiguity to the above-mentioned definitions.It may also be possible that the management itself does not set precise values in order to provide some tolerance on these parameters due to competitive considerations.All this leads to uncertainty (fuzziness) in the problem formulation.Crisp mathematical programming approaches provide no such mechanism to quantify these uncertainties.Fuzzy optimization is a flexible approach that permits more adequate solutions to real problems in the presence of vague information, providing well-defined mechanisms to quantify the uncertainties directly.The idea of fuzzy programming was first given by [4] and then developed by [5][6][7].A number of researchers thereafter have contributed to the development of fuzzy optimization technique [8,9].Today, similar to the developments in crisp optimization, different kinds of mathematical models have been proposed and many practical applications have been implemented by using the fuzzy set theory.Reference [10] formulated fuzzy multi objective optimization models for selecting the optimal COTS software products in the development of modular software system.Recently, Reference [11] de-velops a crisp multi-objective programming model from the fuzzy basic data.When a feasible solution to the problem exists, single and multiple objective fuzzy opti-mization procedure are used to solve the problem.How-ever, it is assumed that a crisp or a constant value of all the parameters is known.However, in practice, it is not possible for a management to obtain a precise value of reliability and cost for a software system.Or they may decide not to set precise levels due to the market considerations and are ready to have some tolerance of their objectives.When the precise values of parameter of the problem are not known, the problem becomes a fuzzy optimization problem and the solution so obtained is a fuzzy approximation.
This paper proposes two fuzzy multi-objective optimization models for selecting the best software product for each module.The first optimization model (optimiza-tion model-I) of this paper is a joint optimization problem that maximizes the system reliability with simultaneous minimization of the cost.The second optimization model (optimization model-II) considers the issue of compatibility between different alternatives of modules as it is observed that some COTS components cannot integrate with all the alternatives of another module.We apply fuzzy optimization procedure to solve the problem, when a feasible solution of the problem exists, but in case we reach the infeasibility case, then we apply fuzzy goal programming optimization technique to provide a compromised solution for the same.The rest of this paper is organized as follows.Section 2 consists of proposed notations.In Section 3, we discuss the assumptions of optimization models and we develop a crisp model for reliability and cost and in Section 4, we describe Fuzzy Multi-Objective Optimization Model for software products selection.In Section 5, Fuzzy optimization technique is discussed to solve the problem with numerical illustration.In Section 6, we furnish our concluding observations.

Notations
if the version of COTS alternative of the module is chosen otherwise

Optimization Models
The first optimization model is developed for the following situations, which also holds good for the second model, but with additional assumptions related to compatibility among alternatives of a module.The following assumptions are common for optimization models: 1) Software system consists of a finite number of modules.
2) Software system is required to perform a known number of functions.The program written for a function can call a series of modules .A failure occurs if a module fails to carry out an intended operation.

 n  
3) Codes written for integration of modules do not contain any bug.
4) Several alternatives are available for each module.Fault tolerant architecture is desired in the modules (it has to be within the specified budget).Independently developed alternatives (primarily COTS/In-House components) are attached in the modules and work similar to the recovery block scheme discussed in [12,13].
5) The cost of an alternative is the development cost, if developed in house; otherwise it is the buying price for the COTS product.

6) Different
In-house alternatives with respect to unitary development cost, estimated development time, average time and testability of a module are available.
7) Cost and reliability of an in-house component can be specified by using basic parameters of the development process, e.g., a component cost may depend on a measure of developer skills, or the component reliability depends on the amount of testing.
8) Different versions with respect to cost, reliability and delivery time of a module are available.9) Other than available cost-reliability versions of an alternative, we assume the existence of virtual versions, which has a negligible reliability of 0.001, zero cost and zero delivery time.These components are denoted by index one in the third subscript of ijk x , and ijk .for example 1 denotes the reliability of first version of alternatives for module .
C ijk r ij r j i

Model Formulation
Let be a software architecture made of modules, with a maximum number of i alternatives available for each module and each COTS alternatives has different versions.

Build versus Buy Decision
For each module , if an alternative is bought (i.e.some ) then there is no in-house development (i.e. ) and vice versa.

Redundancy Constraint
The equation stated below guarantees that redundancy is allowed for the components. ;

Probability of Failure Free In-House Developed Components
The possibility of reducing the probability that the alternative of module fails by means of a certain amount of test cases (represented by the variable ).Reference [14] define the probability of failure on demand of an in-house developed alternative of module, under the assumption that the on-field users' operational profile is the same as the one adopted for testing [15].  Let A be the event " suc ij N failure-free test cases have been performed " and B be the event " the alternative is failure free during a single run".If ij  is the probability that the in-house developed alternative is failure free during a single run given that suc ij N test cases have been successfully performed, from the Bayes theorem we get the following.
The following equalities come straightforwardly:

Reliability Equation of Both In-House and COTS Components
The reliability ( ij s ) of alternative of module of the software. where

Delivery Time Constraint
The maximum threshold has been given on the delivery time of the whole system.In case of a COTS components the delivery time is simply given by ijk , whereas for an in-house developed alternative the delivery time shall be expressed as .

Reliability Objective Function
Reliability objective function maximizes the system quality (in terms of reliability) through a weighted function of module reliabilities.Reliability of modules that are invoked more frequently during use is given higher weights.Analytic Hierarchy Process (AHP) can be effectively used to calculate these weights.
  where i is the reliability of module of the system under Recovery Block stated as follows.

Cost Objective Function
Cost objective function minimizes the overall cost of the system.The sum of the cost of all the modules is selected from "build-or -buy" strategy.The in-house development cost of the alternative of module can be expressed as

Optimization Model I
In the optimization model it is assumed that the alternatives of a module are in Recovery Block.In a Recovery block, more than one alternative of a program exist.For COTS based software, multiple alternatives of a module can be purchased from different vendors.Each module works under a recovery block.Upon invocation of a module the first alternative is executed and the result is submitted for acceptance test.If it is rejected, the second alternative is executed with the original inputs.The same process continues through attached alternative until a result is accepted or the whole recovery block (module) fails.Fault tolerance in a recovery block is achieved by increasing the number of redundancies.
subject to

 
and are binary variable  where X is a vector of component ijk x and ;

Optimization Model II
As explained in the introduction, it is observed that some alternatives of a module may not be compatible with alternatives of another module [16].The next optimization model II addresses this problem.It is done, incorporating additional constraints in the optimization models.This constraint can be represented as , which means that if alternative s for module g is chosen, then alternative , have to be chosen for module .We also assume that if two alternatives are compatible, then their versions are also compatible.
  Constraint ( 12) and ( 13) make use subject to of binary variable t y fer to choose one pair of alternatives from among difent alternative pairs of modules.Finally, model can be re-written as If more than one alternative comp mponent is to be c  

Fuzzy Multi-Objective Optimization
Model for Software Products inciple to multi-objective optimization P of an "efficient solution", where any improvement of one objective can only be achieved at the expense of another.The fuzzy approach can be used as an effective tool for quickly obtaining a good compromise solution.Conventional optimization methods assume that all parameters and goals of an optimization model are precisely known.However, for many practical problems there are incompleteness and unreliability of input information.This has resulted in use of fuzzy multi-objective optimization method with fuzzy parameters.For instance, a designer is required to minimize the system cost while simultaneously maximizing the system reliability.Therefore multiple objective functions become an important aspect in the reliability design of the engineering systems.
In general reliability optimization problem is solved with the assumption that the coefficients or cost of components is specified in a precise way.In real life, there are many diverse situations due to uncertainty in judgments, lack of evidence, etc.Sometimes it is not possible to get relevant precise data for the reliability system.This type of imprecise data is not always well represented by random variable selected from a probability distribution.Fuzzy number may represent this data, so fuzzy optimization method with fuzzy parameters is needed for a fuzzy reliability optimization model.
Therefore, we formulate fuzzy multi-objective optimization model for software products selection ba gue aspiration levels, the decision maker may decide his aspiration levels on the basis of past experience and knowledge possessed by him.To express vague aspiration levels of the decision, various membership functions have been proposed [6,7].A fuzzy mathematical programming problem with non linear membership function results in a non linear programming problem.Usually, a linear membership function is employed to avoid nonlinearrity.Further, if membership function is interpreted as the fuzzy utility of the decision maker, which describes the behavior of indifference, preference or aversion towards uncertainty, a non linear membership function is a better representation than a linear membership function.

Problem Formulation
Fuzzy multi-objective optimiza p reliability function and minimizing the fuzzifier cost function subject to crisp constraints are stated as follows.
Problem (P3)  Here, we have defined the two objective functions, the and cost that are considered to be vague and un tion sed to solve the fuzzy matheatical programming problem.function.Same defuzzific reliability certain (i.e.fuzzy in nature) and the constraints are of crisp nature.Cut-throat competition in the existing market, system complexity, and intended flexibility makes it difficult for the management to precisely define their goals and constraints.Moreover a slight shift on bounds can provide a more efficient solution.Hence, we have used fuzzy optimization technique (fuzzy mathematical programming) to solve the fuzzy multi-objective optimization problem.

Problem Solu
The following steps are u m Step 1. Compute the crisp equivalent of the fuzzy parameters using a defuzzification ation function is to be used for each of the parameters.
Here we use the defuzzification function of the type where are the triangular fuzzy numbers.
Step I e the objective function of the fuzzin (max n (a 1 a , 2. ) as a fuzzy constraint with a restrictio spiration) level.The above problem (P3) can be rewritten as Problem (P4) Step 3. Define appropriate membership functions for each fuzzy inequalities as well constraint correspondin as g to the objective function.The membership function for the fuzzy less than or equal to and greater than or equal to type are given as where is the aspiration level and is the tolerfuzzy reliability obj function con- where is the restriction level and is the tolerhe fuzzy budget constraint.

4.
to mathematical pr

C
Step Extension principle is used identify the fuzzy decision, which results in a crisp ogramming problem given by Problem (P5) can be solved by the standard crisp mathem gramming algorithms.

onstraint. Each constraint is co atical pro-
Step 5.While solving the problem, the objective of the problem is also treated as a c nsidered to be an objective for the decision maker and the problem can be looked as a fuzzy multiple objective mathematical programming problem.Further each objec-tive can have a different level of importance and can be assigned weights according to their relative importance.The resulting problem can be solved by the weighted minmax approach.The crisp formulation of the weighted problem is given as Problem (P6) where,  represents the gree up to which the aspiration of the decision maker is met.If th nstraints are de e co fuzzy as well as crisp, then in the equivalent crisp mathematical programming problem, there will be no change in the original crisp constraints since their tolerances are zero except for those constraints which are fuzzy in nature.The problem (P6) can be solved using standard mathematical programming approach.
Step 6.On substituting the values for Step 7. If a feasible solution is not o tainable for the problem (P7) then we can use fuzzy go ogramming ap aving two modules with ore than one alternative for each module.The data sets b al pr proach to obtain a compromised solution [9].The method is discussed in detail in the numerical illustration.

Illustrative Examples
Consider a software system h m for COTS and in-house developed components are given in Table 1 and Table 2

First
liability and cost values are omputed using fuzzied values of these parameters and signed for reliability and cost are 0.7 and 0.3 respectively.

Mi
ly, the triangular fuzzy re c

Fuzzy Goal Program Approach
On solving the problem, we found that the problem is achieved for a feasible value of   0,1   .Now we use fuzzy goal programming technique to obtain a compromised solution.The approach is the goal programming technique for solving crisp goal programming problem (Mohamed, 1997).The maximum value of any membership function can be 1; maximization of based on is equivalent to making it as close to 1 as best as possible.This can be achieved by minimizi deviational variables of goal programming (i.e. ) from 1.The fuzzy goal programming formulation for the given problem (P7) introducing the negative and positive deviational variables ng the negative j  and j  is given as

Optimization Model I
for optimization model I. he problem is solved using software package LINGO l for compatibility, we se previous results.ond alternative of first module is co econd m Table 3 presents the solution T [17].The solution to the model gives the optimal component selection for the software system along with the corresponding cost and reliability of the overall system.The sensitivity analysis to the delivery time constraint has been performed.It is clearly seen from the table that in case 1, when the delivery time was 15 units then one in-house and other COTS components were selected while in all other cases when the delivery time increases along with in-house components there will be a corresponding change in reliability and cost.In case 2, when the delivery time was 18 units, our system reliability and cost also increases and in case 3 as compared to case 2, when delivery time was 20 units, system reliability increases and cost decreases.Therefore, if the customer is ready to wait then case 3 is an optimal solution.Redundancy is also present in all the three cases.

Optimization Model II
To illustrate optimization mode u Case 1. Delivery time is assumed to be 15 units.We assume that sec mpatible with second and third alternative of s odule.Following solution was obtained using LINGO.It is observed that due to the compatibility condition, third alternative of first module is chosen as it is compatible with second alternative of second module.The system reliability for the above solution is 0.93 and cost is 77 units.The achievement level of the membership function is 0.90   .
. Conclusions ptimization models that supports the and cost.This developed approach can effectively deal efully acknowledges nt of Maharaja Agrasen Inir permission to publish this adrzejowicz, "An Approach to Reliability oftware with Redundancy," IEEE Transacre Engineering, Vol.17, No. 3, 1991, pp.310-312.

6
e have presented o W decision whether to buy software components for software architecture or to build them in-house.We have formulated bi-criteria optimization models based on decision variables indicating the set of structural components "to buy" and "to build" in order to minimize the software cost with simultaneous maximization of system reliability.The problem is formulated for Recovery Block fault-tolerant software system.It may be appreciated that when different alternatives of the same module are available with variations in the attributes of reliability and cost, then it involves multi-objective decision making environment that befits more of fuzzy approximation than deterministic formulation.Therefore, we have drawn on fuzzy methodology for the estimation of reliability with the vagueness and subjectivity of expert's information.Fuzzy predictions of the triangular fuzzy statistical data have been defuzzified using Heipern's defuzzifier and a crisp multi-objective model has been developed using the defuzzified values.The component selection problem is formulated as a multi-objective programming problem and fuzzy goal programming technique is used to provide a feasible solution.

Figure 1 .
Figure 1.Structure of the software.
Basing on the testability definition, we can assume that the number suc ij N th j of successful (i.e.failure free) tests performed on alternative of same module.
software roducts selection based on maximizing the fuzzifier x subject hosen for redundancy, constraint (13) can be relaxed as follows.
not feasible; hence the management goal cannot be r reliability and cost is * 0 0.85 R  and

Table 3 . Solution for optimization model I.
second module is chosen as it is compatible with second alternative of first module.The system reliability for the above solution is 0.86 and cost is 85 units.The achievement level of the membership We assume that second alternative of second m compatible with second and third alternative of first module.Following solution was obtained using LINGO.