• No results found

Ants Can Schedule Software Projects

N/A
N/A
Protected

Academic year: 2021

Share "Ants Can Schedule Software Projects"

Copied!
5
0
0

Loading.... (view fulltext now)

Full text

(1)

Broderick Crawford1,2, Ricardo Soto1,3, Franklin Johnson4, and Eric Monfroy5 1 Pontificia Universidad Cat´olica de Valpara´ıso, Chile

[email protected]

2 Universidad Finis Terrae, Chile 3 Universidad Aut´onoma de Chile, Chile

4 Universidad de Playa Ancha, Chile

[email protected]

5 LINA, Universit´e de Nantes, France

[email protected]

Abstract. This paper presents the design of an algorithm based on Ant Colony Optimization paradigm to solve the Software Project Scheduling Problem. This problem consists in deciding who does what during the software project development, finding an optimal schedule for a project so that the precedence and resource constraints are satisfied and the final project cost and its duration are minimized. We present the design of an general ant algorithm to solve it.

Keywords: Software Engineering, Software Project Scheduling Prob-lem, Project Management, Ant Colony Optimization.

1

Introduction

We present the design of an algorithm based on Ant Colony Optimization (ACO) paradigm to solve the Software Project Scheduling Problem (SPSP). The SPSP is related to the Resource-Constrained Project Scheduling (RCPS), an existing problem very popular in the literature. It is a problem of finding an optimal schedule for a project so that the precedence and resource constraints are satis-fied and the final project cost consisting of personal salaries and project duration is minimized. The RCPS is known to be a NP-hard optimization problem. That means that is not possible to find an efficient algorithm to optimally solve large-size instances in reasonable computational time. Most of the methods used for solving the problem belong to the class of priority-rule-based-methods or to the class of metaheuristic. The first kind of methods starts with none of the jobs being scheduled. Subsequently, a single schedule is constructed by selecting a subset of jobs in each step and assigning starting times to these jobs until all jobs have been considered. By other side, metaheuristics improve an initial solu-tion executing operasolu-tions which transform one or several solusolu-tions into others. ACO has demonstrated to solve several NP-hard combinatorial problems effec-tively [5]. We believe that the constructive nature of ACO is effective attacking this problem.

C. Stephanidis (Ed.): Posters, Part I, HCII 2013, CCIS 373, pp. 635–639, 2013. c

(2)

Table 1.SPSP Model

Item Description

S={s1, ..., ssk} set of skills associated with software projects

T ={t1, ..., tT} set of tasks necessary for the project

G(V, A) precedence graph defined in the project’s Gantt

V ={t1, t2, ..., tT} is a vertex set consisted of all tasks

A={(ti, tj), ...,(tn, tT)}is an arc set, the tasktimust be done beforetj

tskillsj is a set of skills for the taskj. It is a subset ofS

tef f orsj is a effort person-months to complete the tasktj

EM ={e1, ..., eE} is a set of employees

eskillsi is the set of skills ofei. It is a subset ofS

emaxdedi is the maximum degree of dedication ofei,ei∈(0,1)

esalaryi is the monthly salary ofei

2

The Software Project Scheduling Problem

SPSP is one of the most common problems in managing software engineering projects [12]. It consists in deciding who does what during the software project lifetime. SPSP should consider salaries and employee skills which must be as-signed to project tasks according to the requirements of these tasks [14,2]. We describe the model in Table 1:

The SPSP solution can be represented as a matrix M = [E×T] and mij [0,1] which represents the degree of dedication of employee ei to task tj. If mij = 0 the employeeei is not assigned to task tj, if mij = 1 the employeeei work all day in tasktj. We define some constraints to be feasible solutions from the matrixM, first, all tasks are assigned at least one employee:

E i=1

mij >0 j∈ {1, ..., T} (1) Second, the employees assigned have all the necessary skills to carry out the task. for this allmij>0,tskillsj is a subset of the unioneskillsi∈{1,...,E} forj∈ {1, ..., T}. It follows that the skills needed for the tasktj are a subset of the union of the skills the employees assigned to the task. To evaluate the quality of the solutions should be evaluated the feasibility of the solution, the whole project cost and duration of the project. We calculate the duration tdurj , j ∈ {1, ..., T} for each task according to the solution matrix as the following formula:

tdurj =

tef f ortj E

i=1mij

(2)

Now we can calculate the start timetstartj and the end timetendj for taskj. We must consider tasks without precedence, in this case the start timetstartj = 0, and the end time is tendj = tstartj +tdurj . To calculate the start time of tasks

(3)

with precedence, must be calculated first the end time for all previous tasks. In this casetstart

j is defined as tstartj =max{tendi |(ti, tj)∈A} else 0. For the total duration of a projectpdur just need the end time of task that ends later. We can calculate aspdur =max{tendj |∀k=j(tj, tk)/ A}. For the total cost of the software project we need to calculate the cost of each task and then the total cost is the sum of costs according to the following formulas:

tcostj = E i=1

esalaryi mijtdurj (3) pcost = T j=1

tcostj (4)

The target is minimize the project duration pdur and the total cost pcost of project. Therefore a fitness function is used, where wcost and wdur are values weighting the relative importance of the total cost and duration of the whole project. Then, the fitness fuction to minimize is given by:

f(x) = (wcostpcost+wdurpdur) (5)

3

ACO for Schedule Software Project

Ant Colony Optimization (ACO) is a Swarm Intelligence technique which in-spired from the foraging behavior of real ant colonies. The artificial ants seek the solutions according to a constructive procedure as described in [9,6]. This ACO exploits an optimization mechanism for solving discrete optimization problems in various engineering domain [7,11]. To adapt SPSP to ACO using a Hyper-Cube Framework (ACO-HC) [10] must establish an appropriate construction graph and define the use of pheromone and heuristic information associated with the specified problem [4,1].

The construction graph structure and pheromone matrix, with the respective ACO-HC algorithm is presented in the following subsections. This algorithm makes the association of employees to tasks according to the needs of the tasks, evaluating the quality of the solution [13].

3.1 Construction Graph

The ants travel through the construction graph starting from an initial point and select the nodes which travel according to a probability function that is given by the pheromone and heuristic information of the problem, their relative influence is given byα and β respectively[3,8]. The proposed construction graph makes the association of employees for each task. The construction graph consists of each employee and the ratio of dedication contributions of employees for the task defined asded[0,1] This structure is presented in Fig 1.

The ants travel through the construction graph selecting ways of probabilis-tically way. Using the following function:

ptij= [τij]α[ηij]β ded l=0[τil] α[ ηil]β, j∈ { 1, ..., ded} (6)

(4)

start end e1 e2 eE 0.0 1.0 ... ... ... ... ... ... 0.25

Fig. 1.Construction Graph,CG= [ded×E]

Whereτij is the pheromone andηij is the heuristic information of the problem on the path between node ito j in the graph CG for det task. The heuristic information can be defined according to the importance of the task.

3.2 Pheromone

In the hyper-cube framework the pheromone trails are forced to stay in the interval [0,1].We represent computationally the evaporation of pheromone and in addition the amount of pheromone in the ant path through the graph, once is completed a tour using the following formula:

τij = (1ρ)τij+ρΔτk (7) Whereρis a rate of evaporationρ ]0,1]. AndΔτ it is associated with quality of the current solution of ant k. We can use a updating pheromone strategy considering the cost and duration of the whole project as follows [10]:

Δτk = ((wcostpcost+wdurpdur)

1)k m

h=1((wcostpcost+wdurpdur)1)h

(8)

3.3 Algorithm Description

ACO-HC algorithm to solve the software project scheduling problem can be briefly described as follow:

Step 1: to initialize the pheromone values and splitting tasks. Step 2: to allocate first ant in the initial node.

Step 3: each ant travels on the graph choosing nodes (it is to fix the dedication degree of one employee in the task).

Step 4: when the tours are finished, a solution matrix is determined per each ant. Step 5: to evaluate the quality of the solutions.

Step 6: to calculate the duration and cost of the whole software project and to evaluate its feasibility.

Step 7: to select the best solution and update the pheromone values.

Step 8: to repeat the steps (3-7) until the termination condition is satisfied (iterations). Step 9: to obtain the best solution according to the fitness.

(5)

4

Conclusion

We presented an overview to the resolution of the SPSP using an ACO-HC frame-work. We design a representation of the problem in order to ACO algorithm can solve it, proposing a construction graph and a pertinent heuristic information. Furthermore, we defined a fitness function able to allow optimization of the generated solutions.

References

1. Abdallah, H., Emara, H.M., Dorrah, H.T., Bahgat, A.: Using ant colony optimiza-tion algorithm for solving project management problems. Expert Systems with Applications 36(6), 10004–10015 (2009)

2. Barreto, A., de Oliveira Barros, M., Werner, C.M.L.: Staffing a software project: A constraint satisfaction and optimization-based approach. Comput. Oper. Res. 35(10), 3073–3089 (2008)

3. Berrichi, A., Yalaoui, F., Amodeo, L., Mezghiche, M.: Bi-objective ant colony opti-mization approach to optimize production and maintenance scheduling. Computers and Operations Research 37(9), 1584–1596 (2010)

4. Chen, W., Zhang, J.: Ant colony optimization for software project scheduling and staffing with an event-based scheduler. IEEE Transactions on Software Engineer-ing 39(1), 1–17 (2013)

5. Crawford, B., Castro, C.: Integrating lookahead and post processing procedures with ACO for solving set partitioning and covering problems. In: Rutkowski, L., Tadeusiewicz, R., Zadeh, L.A., ˙Zurada, J.M. (eds.) ICAISC 2006. LNCS (LNAI), vol. 4029, pp. 1082–1090. Springer, Heidelberg (2006)

6. Dorigo, M., Di Caro, G.: Ant colony optimization: a new meta-heuristic. In: Pro-ceedings of the 1999 Congress on Evolutionary Computation, CEC 1999, vol. 2, p. 1477 (1999)

7. Dorigo, M., Gambardella, L.M.: Ant colony system: A cooperative learning ap-proach to the traveling salesman problem. IEEE Transactions on Evolutionary Computation (1997)

8. Dorigo, M., Maniezzo, V., Colorni, A.: The ant System: Optimization by a colony of cooperating agents. IEEE Transactions on Systems, Man, and Cybernetics Part B: Cybernetics 26(1), 29–41 (1996)

9. Dorigo, M., Stutzle, T.: Ant Colony Optimization. MIT Press, USA (2004) 10. Johnson, F., Crawford, B., Palma, W.: Hypercube framework for aco applied to

timetabling. In: Bramer, M. (ed.) Artiticial Intelligence in Theory and Practice. IFIP, vol. 217, pp. 237–246. Springer, Boston (2006)

11. Liao, T.W., Egbelu, P., Sarker, B., Leu, S.: Metaheuristics for project and con-struction management a state-of-the-art review. Automation in Concon-struction 20(5), 491–505 (2011)

12. Ozdamar, L., Ulusoy, G.: A survey on the resource-constrained project scheduling problem. IIE Transactions 27(5), 574–586 (1995)

13. Rubio, J.M., Crawford, B., Johnson, F.: Solving the university course timetabling problem by hypercube framework for aco. In: Cordeiro, J., Filipe, J. (eds.) ICEIS (2), pp. 531–534 (2008)

14. Xiao, J., Ao, X.-T., Tang, Y.: Solving software project scheduling problems with ant colony optimization. Computers and Operations Research 40(1), 33–46 (2013)

References

Related documents

In a study on native, HL, and L2 learner experiences within mixed learner classrooms, Edstrom (2007) reports that L2 learners experienced an overall positive impact on their listen-

Given the broad range of infrared thermographic equipment on the market today, the intent of inspection and assessment specifications is to ensure that suitable equipment is used

• Check for understanding throughout the class period by asking questions and observing students’ work. • Ticket-to-Leave at the end of class. • Further assessment given on

Subject matter jurisdiction of tribal, state or federal courts depends largely on (1) whether the defendant is an Indian or non-Indian person or entity 52 and (2) whether the

We calculated the odds of early retirement for four forms of juridical relationship to one’s housing (private owner; part owner in a cooperative; private rental; rental from a

The model can help doctors operating under the traditional appointment policy to decide about a maximal panel size in order to achieve a service level with respect to their

(Counsel for Genworth Life Insurance Company and Genworth Life and Annuity Insurance Company (formerly General Electric Capital Assurance Company, First Colony Life Insurance