Abstract
Scheduling is a fundamental factor in managing the network resource of the Internet of things. For IoT systems such as production lines, to operate effectively, it is necessary to find an intelligent management scheme, i.e., schedule, for network resources. In this study, we focus on multiskill resourceconstrained project scheduling problem (MSRCPSP), a combinational optimization problem that has received extensive attention from the research community due to its advantages in network resource management. In recent years, many approaches have been utilized for solving this problem such as genetic algorithm and ant colony optimization. Although these approaches introduce various optimization techniques, premature convergence issue also occurs. Moreover, previous studies have only been verified on simulation data but not on real data of factories. This paper formulated the MSRCPSP and then proposed a novel algorithm called DEM to solve it. The proposed algorithm was developed based on the differential evolution metaheuristic. Besides, we build the reallocate function to improve the solution quality so that the proposed algorithm converges rapidly to global extremum while also avoiding getting trapped in a local extremum. To evaluate the performance of the proposed algorithm, we conduct the experiment on iMOPSE, the simulated dataset used by previous authors in their research studies. In addition, DEM was verified on real dataset supported by a famous textile industry factory. Experimental results on both simulated data and real data show that the proposed algorithm not only finds a better schedule compared with related works but also can reduce the processing time of the production line currently used at the textile industry factory.
1. Introduction
Internet of things systems include not only sensors and automated machines like robots but also intelligent control and management algorithms [1]. Intelligent algorithms for managing network resource play a key role in controlling the operation of automated machines such as robots, enabling them to devote their full capacity to serve users.
Multiskill resourceconstrained project scheduling problem (MSRCPSP), a combinational optimization problem, has received extensive attention from the research community in recent years due to its advantages in network resources management and scheduling for Internet of things system. The main purpose of the MSRCPSP is to find the way for assigning tasks to resources so that the execution time is minimal.
In recent years, MSRCPSP is widely used, and this problem is found not only in critical civilian fields but also in the military setting. MSRCPSP appears on a broad scale of military operations such as planning an onboard mission or routing an unmanned aerial vehicle (UAV) [2, 3].
The rest of the paper is organized as follows. In Section 2, we present some related works such as previous approaches to solving the MSRCPSP. Specifically, the summary of the differential evolution method is included in this section. Differential evolution is a wellknown evolutionary algorithm that has been applied effectively to solve NPhard problems. In this paper, the proposed algorithm is inspired by the differential evolution method. In Section 3, we present the system model and the statement of MSRCPSP. The formulation of MSRCPSP is introduced in this section. Section 4 describes the proposed algorithm, which is built on differential evolution strategy [4]. In this section, we focus on presenting the reallocate function, which is the key component that creates the strength of the proposed algorithm. Besides, this section introduces our design for schedule representation and a new measurement model for measuring the difference between two schedules. The proposed algorithm (DEM) is also introduced in this section. Simulation results examining the proposed algorithms along with computational and comparative results are given and analyzed in Section 5. Simulations conducted by using the iMOPSE dataset [5] are presented in this section. In addition, this section describes experiments conducted on the factory’s dataset collected from TNG, a wellknown national textile company. Finally, Section 6 concludes the paper and outlines some directions for future work.
2. Related Works
2.1. Approximation Algorithms for MSRCPSP
Scheduling problem arises in many practical situations [6–11]. In the general case, the scheduling is proved to be NPhard. The authors of [5, 12, 13] show that MSRCPSP, the problem we mentioned in this paper, is an NPhard scheduling problem. In addition, MSRCPSP is multimodal or discontinuous and very challenging to solve with traditional optimization methods. In the past few years, various approaches have been proposed to solve MSRCPSP, thereby finding out intelligent algorithms to allocate and manage network resources in the Internet of things systems [14–17]. Some popular metaheuristic algorithms are the genetic algorithm (GA), ant colony optimization (ACO), and particle swarm optimization [18–22].
Su et al. [23] used a mixedinteger model and discrete constraints to solve the problems. Maghsoudlou et al. [24] and Bibiks et al. [25] applied the cuckoo Search algorithm to plan for the multirisk project with three distinct evaluation objectives. Lin et al. [26] proposed a new solution based on GA and some other heuristic algorithms.
Myszkowski et al. [5, 13] proposed the hybrid algorithm which is the combination of the differential evolution strategy and the greedy approach for arranging the human resources in product manufacturing projects and calculating timeofuse electricity tariffs and shift differential payments. The authors aimed to achieve the shortest makespan and low cost and gave a new benchmark dataset called iMOPSE [5], an artiﬁcially created dataset based on realworld instances for the MSRCPSP.
The MSRCPSP is studied and applied in the planning of many practical areas of the Internet of things. Some authors also study new variants of the MSRCPSP and apply them in different fields. Mejia [3] developed a new variant of the MSRCPSP to coordinate research activities in the nuclear laboratory. Hosseinian [27] proposed two new algorithms, PGWO and MOFA, to solve the MSRCPSP with the deterioration effect and financial constraints (a case study of a gas treating company). In another study, Hosseinian et al. introduced a new mixedinteger formulation for the timedependent MSRCPSP considering the learning effect [28].
NematiLafmejani et al. [29] developed an integrated biobjective optimization model to deal with multimode RCPSP. The objective of the proposed model is to minimize both the costs and the makespan of the project. Tahrir and Yang [30] proposed a hybrid metaheuristic algorithm that combined ant colony optimization and variable neighbourhood search approaches for job scheduling in grid computing.
Several prior research has also been conducted to solve other subproblems of RCPSP, the general problem of MSRCPSP, to improve the efficiency of network resource management in specific fields of the Internet of things. Ballestin and Leus [31] and Javanmard [32] and their colleagues studied specific cases of RCPSPs such as multiskill stochastic and preemptive problem to calculate project implementation time, i.e., makespan, and build mathematical models for the project resource investment.
2.2. Differential Evolution Method
Differential evolution (DE) is a populationbased stochastic optimization algorithm introduced by Storn and Price [4]. The advantages of DE lies in its simplicity, efficiency, and speed thanks to the local search method. DE deals with the old generation of the original population by using the mutation operator to create better solutions in the new generation. Until now, DE is clearly recognized to be the approach that has the potential to solve NPhard [4, 33] problems.
Tanabe et al. and Ghosh and Das [34, 35] proposed a DEbased method for scheduling problems in grid computing environment whose purpose is to minimize the execution time and add more parameter adjustment to get high effects.
Like other evolutionary approaches, DE performs the evolution of a population by using three kinds of the operator: crossover (recombination), mutation, and selection. The major difference between DE and genetic algorithm, a classical evolutionary algorithm, is due to the mutation operator. DE’s mutation operator uses orientation information to change solutions of the current population as follows.
Given the population that is composed of solutions, each of them consists of D components, and thus a particular solution is represented by a vector x_{i} = (x_{i,2}, x_{i,2},…, x_{i,D}) where x_{i,j} ∈ R, i = 1, 2, …, N; j = 1, 2, …, D.
To create the mutated solution of a given solution x_{i}, DE picks out three random different solutions from the current population: x_{r1} ≠ x_{r2} ≠ x_{r3} ≠ x_{i}, and then the mutation solution is determined as follows:where the value of the constant F, which plays the role of the mutant factor, is in the range [0, 1]. Because the mutant factor F is used to adjust the size of the directional vector, it is also called the directional hop length.
After executing the mutation step, the crossover operation is carried out by combining the parent solution x_{i} and the mutation solution . The crossover operator is performed by selecting a random number CR (CR ∈ [0, 1]) as the probability of crossover. The result of the crossover step is represented by the vector (u_{1,1}, u_{1,2}, ... u_{N,D}) where(i)i = 1, 2, …, N; j = 1, 2,…, D.(ii)rand_{i,j}: mutant factor.(iii)I_{rand}: a random number varies within the range [1,D]. Thanks to I_{rand}, the mutation solution is always different from the parent solution x_{i}.
Finally, the next generation is created from the x_{i} and the u_{i} as follows:
Since 1997, various versions of DE have been developed by researchers. This paper proposes a variant of the DE algorithm which uses the following terminologies and conventions:(i)A solution represents a schedule, that is, a plan for performing given tasks(ii)The number of search space’s dimensions is equal to the number of tasks
3. System Model and Definitions
3.1. RCPSP
MSRCPSP is just a special case of RCPSP. Before the outline of the multiskill RCPSP, the description of the classical RCPSP would be introduced as follows.(i)Assume a given project represented by a directed noncyclical graph G (V, E), where each node depicts a task and the arc represents finishtostart precedence relationship between two tasks. The arc (u, ) ∈ E shows that the task u must be completed before task begins (Figure 1).(ii)Without any difference, two empty tasks were added to the project. The first one is placed at the beginning of the project as the predecessor of every other task, whereas the second empty task is placed at the end of the process as the successor of other tasks.(iii)The duration (also called execution time) of a certain task is calculated from the beginning time to the ending time of that task.(iv)The execution progress of every task cannot be stopped until it is done.(v)Each task needs an amount of resources for its execution.
The goal of the RCPSP is to find out a schedule of the task such that the precedence and resource constraints are satisfied and the makespan is minimized. RCPSP has been proved to be NPhard [12]. Throughout the paper, we use the term “makespan” to refer to the execution time of the project, also called project duration. In the process of looking for the optimal schedule, both priority constraint between operations and resource constraint have to be met.
3.2. MSRCPSP Formulation
In this paper, MSRCPSP [5, 13, 36] was chosen because it is more practical than its general problem, RCPSP. MSRCPSP uses the additional attribute, skill, in the problem formulation. Each task requires particular skills at the given levels to be executed, whereas each resource has some skills with given levels. Thus, the resource A is capable of performing the task B if A has skills required by B at the identical or higher level.
Before deepening the study of MSRCPSP, we take a look at some notations as follows:(i)d_{j}: the duration of task j; P_{j}: subset of the predecessors of task j(ii)q_{j}: subset of skills required by task j(iii)Q_{k}: the subset of skills owned by the resource k(iv)Q: the set of skills, Q_{k} ⊆ Q(v)RS: the set of resources(vi)T: the set of tasks(vii)T_{k}: the set of tasks that resource k can perform, T_{k} ⊆ T(viii)RS_{k}: the set of resources that can perform task k, RS_{k} ⊆ RS(ix)S_{j}, F_{j}: start time and ﬁnish time of task j(x)U_{j,k}^{t}: U_{j,k}^{t} = 1 in case of resource k is assigned to task j at given time t; U_{j,k}^{t} = 0 in other cases(xi)l_{q}: the level of the given skill q; h_{q}: type of the skill q(xii)q_{j}: the skill required by task j(xiii)τ: duration of a schedule(xiv)PS: a feasible schedule(xv)PS_{all}: the set of all feasible schedules(xvi)f(PS): makespan of schedule PS
Each schedule (PS) is responsible for coordinating n tasks and m resources.
Formally, MSRCPSP could be stated as follows:where
4. Proposed Algorithm
4.1. Schedule Representation
In this study, every schedule or solution is represented by a vector that consists of elements; the number of elements (size of the vector) and the number of tasks are the same. The value of a certain element depicts the resource that can execute the corresponding task.
Example 1. Given a set of task T = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10} and a set of resource RS = {1, 2, 3}. The MSRCPSP’s goal is to find out a schedule in which the makespan can be minimized while meeting priority constraints between tasks (Figure 1).
Consider a set of task T = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10} and set of resource RS = {1, 2, 3}. Priority constraints between tasks are depicted in Figure 1, whereby task 1 is the predecessor of task 2, and thus task 2 cannot be performed until task 1 is finished: S_{2} ≥ F_{1}. There is no relation between task 3 and task 4; therefore, they are executed concurrently or sequentially.
Besides, in this example, we assume that(i)s_{k} = s_{i} ∀k, i ∈ RS(ii)Q_{k} = Q ∀k ∈ RS(iii)RS_{k} = RS ∀k ∈ RSThe duration of the tasks is given in Table 1.
A feasible schedule for the project is demonstrated in Figure 2, where it can be seen that the makespan is 15.
The above schedule is demonstrated in Table 2, where resource 1 performed tasks number 1, 2, 6, 8, and 9; resource 2 is assigned to execute tasks number 3 and 7; resource 3 deals with the remaining tasks.
4.2. Measurement Model
The differential evolution algorithm was primarily designed for realvalued data. However, like most of the other scheduling problems, MSRCPSP deals with discrete values, and thus there is a need for the discrete variant of DE. In addition, this discrete DE algorithm needs a model for representing the MSRCPSP’s factors such as the difference between two schedules. In this paper, we build a new measurement model for measuring the difference between the two schedules as follows:(i)Unit vector P = (p_{1}, p_{2}, ..., p_{n}); p_{i} = 100/(k _{i} − 1), where k_{i} is the number of resources that can execute task i(ii)The difference between schedule X = (x_{1}, x_{2}, ..., x_{n}) and schedule Y = (y_{1}, y_{2}, ..., y_{n}) is denoted by the differential vector D = X – Y = (d_{1}, d_{2}, ..., d_{n}) where order (x_{i}): the position of the resource (x_{i}) in the RS_{i}(iii)The sum of the schedule Y and differential vector D is the schedule X = (x_{1}, x_{2}, ..., x_{n}) where position (i): the resource corresponding to the position i
Example 2. Assume that there are 6 resources that could handle task 1: RS_{1} = {R_{1}, R_{3}, R_{4}, R_{5}, R_{9}, R_{10}}. Thus, k_{1} = 6; p_{1} = 100/(6–1) = 20. Assume that there are 5 resources that could handle task 2: RS_{2} = {R_{3}, R_{5}, R_{7}, R_{8}, R_{10} }. Thus, k_{2} = 5; p_{2} = 100/(5–1) = 25. The resource order in measurement model is presented in Table 3.
Consider 2 schedules: X = (3, 5); Y = (5, 10). The task assignment is shown in Table 4.
D = X–Y = (d_{1}, d_{2}), where d_{1} = p_{1}. Abs (order (x_{1}) − order (y_{1})) = 20. Abs (1–3) = 40.
d_{2} = p_{2}. Abs (order (x_{2}) − order (y_{2})) = 25. Abs (1–4) = 75. Thus, D = (40, 75). Consider D’ = (35.71, 5.23). As shown in Table 5, we have Z = X + D’ = (5, 8).
4.3. Proposed DEM Algorithm
The proposed algorithm (differential evolution multiskill, or DEM) is described in Algorithm 1:(i)Stop criterion: the loop whileend while would be stopped if the difference between makespan of some continuous generations is smaller than a threshold(ii)Size: number of solutions in the population(iii)F: parameter of the mutation operator(iv)CR: crossover probability(v)n: number of tasks

As shown in line 25, after classical DE steps such as mutation and selection are executed, function Reallocate() is called to reduce the makespan of the candidate schedule bestnest. Procedures of this function will be dealt with in more detail in the next section (Algorithm 2):
currentBest: the best schedule among the population of the current generation. R_{b} : According to the arrangement of schedule newbest (line 3), R_{b} is the last resource that finishes its job. In Figure 3, before the reallocate function was called, R_{b} is resource 1. maxResource(): the function which returns the last resource to finish (line 3). size(): the function which returns the number of elements of the given set or array (line 5). newmakespan: makespan of the new schedule (line 11), which is obtained from the old schedule by reassigning task i. The task i is moved from resource R_{b} (line 9) to resource R_{i}[j] (line 10).

4.4. Function Reallocate
Line 12 and 13 demonstrate that the new schedule (newbest) is better than the old schedule (currentBest) in terms of makespan, which means that the function Reallocate certainly returns a better schedule. Moreover, the function Reallocate guides DEM algorithm in the right direction by finding a new schedule (newbest) based on the best solution (currentBest); therefore, it inherits the advanced genomes of the population as well as the old schedule.
Example 3. Given set of task T = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, set of resource RS = {1, 2, 3}. Resource 1 can execute tasks 1, 2, 3, 4, 6, 8, 9, and 10; resource 2 can perform tasks 1, 3, 7, and 9; resource 3 can handle tasks 1, 4, 5, 8, 9, and 10. The relationship between tasks is depicted in Figure 1, and the duration of the tasks is given in Table 1.
Consider a schedule (PS) as shown in Table 6. From observation, Figure 4 shows that makespan f(PS) = 17.
New schedule, the result of the function Reallocate, is described in Table 7.
Figure 4 illustrates that function Reallocate converts the schedule PS into the new schedule by assigning task 9 to resource 2 instead of resource 1 as before. Thanks to this allocation, the new schedule achieves better makespan (15) compared to the old schedule (17).
5. Experiment
Experiments were conducted on the simulated dataset and the real dataset to evaluate the performance of proposed algorithms in comparison with previous algorithms such as GreedyDO and GA. We first utilize the simulated iMOPSE dataset, a collection of project instances that are artificially created based on a database obtained from the international company, to evaluate the performance of the proposed algorithm.
5.1. Simulation on Simulated Dataset
5.1.1. iMOPSE Dataset
The simulated dataset iMOPSE [5] has been used to investigate existing algorithms GreedyDO and GA [13, 36]; therefore, we conduct simulations on iMOPSE dataset to fairly compare between DEM and those algorithms.
As shown in Table 8, iMOPSE’s instances are classified into 15 categories according to the following attributes:(i)The number of tasks and resources(ii)The number of precedence relations between tasks(iii)The number of skills
All simulations were run on a PC with Intel Core i5CPU 2.2 GHz, 6 GB RAM, and operating system Windows 10. All of iMOPSE instances used by our simulations are listed in Table 8.
5.1.2. Parameters and System Settings
The simulation is conducted by using the following:(i)Simulation environment: Matlab ver. 2014(ii)Simulation tool: the performance of previous algorithms such as GA is fairly evaluated by using GARunner [13]; the simulation tool was provided by the author of those algorithms(iii)Input data: 15 iMOPSE instances that are described in Table 8(iv)Number of solution in the population N_{p}: 100(v)Number of generations : 50,000(vi)Since all of the considered algorithms are approximate, we run on each instance 35 times to get average value, the standard deviation value, and the best value
5.1.3. Simulation Results
Simulation results are shown in Tables 9 and 10, where the makespan of the best solutions found by GreedyDO, GA, and the proposed algorithm (DEM) is illustrated (in hours). Table 9 shows that the makespans acquired by GA are always better than those acquired by GreedyDO.
Table 10 illustrates the average value, the best value, and the standard deviation of the makespan found by GA and the proposed DEM algorithm.
From the observation, the result in Tables 9 and 10 shows that(i)The solutions found by DEM are better than Greedy from 16% to 78% and GA from 0% to 21%.(ii)Regarding the average value (Table 9): DEM is better than Greedy from 15% to 77.5% and GA from 0.7% to 20.8%.(iii)Inspired by the differential evolution strategy, the proposed algorithm uses two parameters to guide the generation of the solution generated in the next generation: (i) the experience vector of both the population and (ii) the experience vector of the solution across different generations. DEM not only inherits those advantages of differential evolution approach but also utilizes the function reallocate, which improves its performance. Therefore, DEM has faster convergence and greater stability, which is shown by the standard deviation in Table 9 (column Std). The total standard deviation of DEM is 19.5 while the value of GA is 55.7; this result proves that the stability of DEM algorithm is better than GA.(iv)In addition, the use of a scale to represent solutions helps DEM calculate the deviations between solutions more accurately and create better solutions in the next generations.
5.2. Simulation on Real Dataset
5.2.1. TNG Dataset
Experiments conducted on the simulated dataset are sometimes inaccurate and unsatisfactory. To overcome this drawback, we collected the dataset of TNG Investment and Trading Joint Stock Company [37], a wellknown national textile company. TNG dataset instances have the following characteristics and parameters:(i)The company has product sewing contracts under the business partners' contracts; each order places a sample of a product in large quantities(ii)Each product has a certain number of stages, each of which requires a certain time to complete(iii)Each order will be assigned to a group of workers(iv)Each group consists of many workers(v)Each worker's skills are rated based on his rank
The above parameters of the dataset have been converted to a suitable format as shown in Table 11.
Table 11 demonstrates that the TNG dataset parameters will be represented as follows:(i)The order from the business partners’ is represented by a project(ii)The stage of the product is represented by a task(iii)A worker in the factory is represented by a resource in the problem formulation(iv)The worker grade is represented by the skill level of the resource(v)The order in which the tasks are executed is represented by the priority of the tasks(vi)Order execution time is represented by the total time of project implementation, i.e., the makespan
After the conversion, the dataset is shown in Table 12
5.2.2. Parameters and System Settings
Experiment setting:(i)Input data: 8 instances that are listed in Table 12(ii)Number of the solution in the population N_{p}: 100(iii)Number of generations : 50,000(iv)Like simulation on the simulated dataset, we run on each TNG dataset instance 35 times to get the best value
5.2.3. Simulation Results
To prove the effectiveness of the proposed algorithm (DEM), we carry out experiments by using the realworld dataset collected from the TNG company. DEM will be compared with other algorithms from previous research studies, GreedyDO and GA. The performance of these algorithms is recorded and observed by using GARunner, the tool created by Myszkowski et al. [13].
Table 13 contains the makespan (measured in hours) of the best solution achieved by GreedyDO, GA, and DEM. In addition, the performing intervals of the actual projects at the TNG factory are shown in column TNG.
Table 13 proves that schedules found by DEM are better than those acquired by GA and GreedyDO. Table 13 and Figure 5 also highlight that the schedules found by evolutionary algorithms are always shorter than the execution time of the actual projects at the TNG factory.
Compared to the execution time at the TNG factory, the GreedyDO and GA algorithms reduce the makespan by 4%–42% and 7%–51%, respectively, while DEM has the best results of 16%–61%. This result is understandable because so far all projects have been manually scheduled based on the scheduler's experience.
This statistical analysis of the experimental result proves that DEM achieved better solutions than the previous algorithms. Thanks to the directed nature, DEM not only ensures fast convergence but also averts getting trapped in local extrema. In experiments conducted on the TNG dataset, DEM reduces the makespan from 16% to 61% compared to the current factory schedule.
6. Conclusion and Future Work
This paper proposes to investigate the MSRCPSP, one of the combinatorial optimization problems that have a wide range of practical applications in science, technology, and life. The MSRCPSP is formulated and presented as a mathematical model, and then a novel algorithm called DEM which is based on differential evolution strategy is proposed.
The MSRCPSP, which is the subject of the investigation in this paper, has significant meaning for network resource management in the Internet of things. The MSRCPSP we study takes into account the resource’s skill level, an important factor of the practical projects. Inspired by differential evolution metaheuristic, we have devised a new evolutionary algorithm that has the ability to outperform all the previous approaches. We build a function called reallocate, which is the key component that creates the strength of the proposed algorithm. This function avoids the idle time intervals in a given schedule, improving the solution quality.
To analyze the efficiency of the proposed algorithm, various simulations are conducted and compared with the previous algorithms. Besides the simulated dataset, the real dataset supported by the TNG company has also been utilized for the assessment. The simulation result shows that our developed algorithm is more effective than existing algorithms. DEM achieves not only better quality solution but also faster convergence to global extremum in comparison with the prior algorithms.
In the next steps, we are planning to improve DEM algorithm by using a blended random walk and the Gauss statistical function. We will implement local search operations to further improve the quality of the solutions. At the same time, we will integrate the Gaussian probability distribution to improve the search direction modification in the solution space. Thanks to that improvement, we expect that the proposed algorithm will not fall into the local extreme trap.
In the future, we will utilize the DE metaheuristic with the integration of the Gauss distribution and Gauss statistical function [38, 39] to improve the effectiveness of the searching for the optimum solution and avoid the local extreme trap.
Data Availability
The paper uses the standard iMOPSE dataset to test the efficiency of the algorithm. This dataset is publicly available at http://imopse.ii.pwr.wroc.pl/ and is free of charge. In addition, we also tested the algorithm with TNG's garment manufacturing dataset. We have obtained permission from TNG to use these data.
Conflicts of Interest
The authors declare that there are no conflicts of interest regarding the publication of this paper.
Acknowledgments
We are grateful to the TNG Investment and Trading Joint Stock Company for giving us the information regarding their projects as well as providing us with their factory dataset.