1. Introduction
The Internet of Things (IoT) has gained global attention in recent years and has developed rapidly. However, with the advancement of technology and society, an increasing amount of IoT devices and data are appearing, presenting a series of severe challenges in relation to data storage and transmission. These challenges have also ushered in a series of emerging technological revolutions. As the core of the IoT, cloud computing provides services such as storage capacity, high processing power, and computing resources. In addition, cloud servers support the visualization of computing resources [1]. However, cloud servers are usually located far away from the end devices. Thus, cloud servers sometimes cause long WAN delays and a poor quality of service in latency-sensitive applications [2,3]. Moreover, with the increasing demand for connected devices and IoT applications, cloud computing has various problems that need to be optimized, such as those that are related to bandwidth, privacy, delay, storage, response time, security, and the excessive concentration of computing resources [4,5,6]. Therefore, Cisco proposed a new computing concept in 2012 known as fog computing (FC) [7]. FC complements cloud computing in application servers with high latency sensitivity [8,9,10]. FC can integrate storage, networking, and cloud computing services for the end users [11]. As a result of these advantages, FC is widely used in electronic health [12,13,14,15,16], smart home [17], manufacturing [18], smart grid [19], and smart city applications [20,21].
FC can meet the requirements of many IoT devices; however, it still faces numerous challenges and urgent optimization problems [22]. Indicators such as delay optimization, bandwidth optimization, and energy consumption optimization play an important role in FC [4] because the tasks that are performed on devices are usually heterogeneous, and resources are provided by different individuals, making such systems highly volatile [23]. When assigning resources to each task in FC, the performance difference between the different devices should be taken into account. A reasonable resource-scheduling strategy for FC will not only improve the execution efficiency of an FC system, but also considerably reduce resource consumption.
In distributed FC scenarios with a large number of nodes, such as those that are used in large factories with multiple production lines, hospital health assessments [13,15], and emergency response, the nodes are difficult to schedule and resource utilization is low. In order to improve user service quality for FC technology in Internet of Things environments, to reduce the delay in FC systems, and to improve resource utilization rates, a resource-scheduling scheme for distributed FC is presented in this paper. This scheme considers the load balancing between different fog nodes in the same fog cluster and the performance difference between the different fog clusters, avoids the limitation of a single fog cluster, and, thus, processes the task more efficiently.
The main contributions are as follows:
(1) A two-level model for task scheduling and resource allocation is proposed. This model combines task scheduling between different fog clusters and load-balancing resource allocation between fog nodes within the same fog cluster, combining the integrity of the entire distributed fog layer with the advantages of the individual fog cluster;
(2) An effective task-scheduling algorithm, i.e., an artificial bee colony (ABC) based on particle swarm optimization (PSO) and the genetic algorithm (GA), is proposed. We use PGABC to represent the proposed algorithm. This algorithm is suitable for task-scheduling problems and it reduces the total execution time and the total energy consumption of the system;
(3) We propose a resource-scheduling scheme consisting of two parts: PSO to optimize the resource allocation of the fog nodes in the same fog cluster, and PGABC to address the task-scheduling problem between the fog clusters. We use PGABC–PSO to represent the proposed resource-scheduling strategy. This scheme effectively reduces service latency and improves resource utilization, thus improving the overall task execution stability.
The rest of this paper is organized as follows: Section 2 discusses related work, Section 3 describes the FC architecture, Section 4 describes resource scheduling in FC, Section 5 proposes the resource-scheduling algorithm, Section 6 analyzes the experimental results, and Section 7 summarizes this study.
2. Related Work
With the rapid development of FC in recent years, research on resource-scheduling strategies for FC has progressed. The study of novel optimization methods to address delays or energy consumption issues in resource scheduling has become widespread. Rafique et al. [24] proposed a new bio-inspired hybrid algorithm, which combines improved PSO and improved cat swarm optimization. In this method, a modified PSO is used to perform task scheduling among fog devices, and a bio-inspired hybrid algorithm is used to perform resource management at the fog device level. This scheme improves the resource utilization and reduces the average response time by managing the available fog resources. Ghobaei et al. [25] proposed a task-scheduling algorithm that was based on moth–flame optimization (MFO), which reduces the total execution time of tasks by allocating optimal task sets to meet the service quality requirements of the network physical system applications. This algorithm achieves optimal results by considering the minimization of task execution and the transmission time as the objective function. However, the energy consumption that is associated with the system is not taken into account. Narayana et al. [26] developed an extended PSO and an additional gradient method to optimize the task-scheduling problem in the cloud–fog environment. This approach takes the time and cost of task execution as the optimization objective, compares it with other PSO methods, and obtains preferable optimization results. However, the number of fog nodes used in the cloud and fog environments is small and the limitations are considerable. Saroja et al. [27] proposed a resource-allocation algorithm that was based on a hybrid multi-objective crow search considering heterogeneity. The success rate and the safe hit rate are the objective functions. The simulation results were compared with the GA and the modified crow search algorithm based on the pivot rule in order to demonstrate the method’s effectiveness. Li et al. [28] standardized and normalized resource properties and combined fuzzy clustering and PSO to partition the resources, thus reducing the size of the resource search. Finally, according to weight matching, the resources and tasks were matched, and the final resource scheduling results were obtained in order to improve user satisfaction. The simulation results were satisfactory in terms of their user satisfaction but lacked the necessary latency and energy consumption metrics. On the basis of the classical Apriori algorithm, Liu et al. [29] proposed a classification I-Apriori algorithm for tasks in the FC environment, which improves the efficiency and the performance of classification mining. For the task-scheduling problem in the FC environment, the I-Apriori algorithm is used to construct an FC task-scheduling model with the execution time and average waiting time as the optimization objectives; thus, a modified task priority-scheduling algorithm was proposed. Experiments show that the proposed method has a superior performance; however, this study only considered time as the optimization objective and did not consider the energy consumption of the system. For FC, both latency and energy consumption are extremely important. Strategies that only target latency or energy consumption are not conducive to the sustainable utility of FC systems. The special environment of FC requires not only low latency to improve the execution efficiency of the system, but also sufficient energy to process the tasks. Therefore, in this study, we constructed a multi-objective optimization model by considering delay and energy consumption as the optimization objectives.
The ABC was proposed by Karaboga in 2005. It has the advantages of a simple structure, an excellent search performance, a strong stability, and few control parameters, and it has been successfully used to solve function optimization problems [30,31].
In recent years, the ABC has been frequently used in resource-scheduling problems. Li et al. [32] introduced Gaussian mutation and the adaptive factor to improve the ABC, taking into account the global search ability in the early stage and the local detailed search in the later stage. The adaptive crossover probability was introduced to improve the differential evolution algorithm, which takes into account the genetic diversity and the convergence speed. The two modified algorithms are used to find the optimal solution in parallel; the optimal solution and the location information are exchanged in time so that the two algorithms can quickly approach the optimal solution, therefore reducing the number of algorithm iterations and improving the convergence rate and accuracy of the algorithm. Li et al. [14] were the first to discuss the flexible task-scheduling problem in cloud computing and modeled the problem as a hybrid flow store scheduling problem. First, an improved adaptive disturbance structure was embedded into the ABC to balance the development and exploration capabilities. An effective selection and update method was used to enhance the development process. Second, in order to further improve the development capability, a deep development operator was designed. Then, a modified version of the scout bee was designed. Finally, the convergence of this algorithm was improved by designing an improved scout bee with different local search methods to find the best food source or discarded solution. The performance of the proposed algorithm was also verified. Meshkati et al. [33] proposed a hybrid scheduling framework that was based on the combination of the ABC and the PSO(HSF.ABC&PSO), which combines the global search ability of the ABC with the preferable local development ability of the PSO. When applied to the energy-aware framework of cloud computing, it reduces the energy consumption and the execution time of cloud computing.
Nevertheless, the application of the ABC in FC resource-scheduling suffers from a low optimization efficiency and a low computational accuracy. To address these issues, in this study, we make the following improvements to the ABC: we introduce the discrete search capability of the GA algorithm into the artificial bee colony algorithm in order to increase the search efficiency of the algorithm, and the PSO algorithm is introduced to increase the local search capability of the algorithm and to improve the search accuracy. In this paper, the modified ABC is called PGABC, which is proposed to solve the multi-objective problem of delay and energy consumption in task scheduling.
On the basis of existing studies, we consider the efficiency of a single fog cluster and the integrity of the entire distributed FC system. A resource-scheduling scheme based on the PSO and the PGABC algorithm (PGABC–PSO) is proposed. The PSO is used to solve the problem of optimal load balancing for each task in a single fog cluster. Then, according to the obtained load balancing results, and taking into account the transmission time, tasks are assigned to each fog cluster in a reasonable manner. The resource-scheduling problem is solved by the PGABC algorithm, with delay and energy consumption as the optimization metrics.
3. Improved Resource-Scheduling Architecture for FC
FC is usually used in cooperation with edge servers and cloud computing. Therefore, the existing FC architecture consists of the following three layers: cloud, fog, and terminal nodes [34,35]. On the basis of the three-layer cloud architecture that was proposed by Ramirez [36] and Ren et al. [37], we propose an improved FC architecture by referring to a two-level resource-scheduling model that was proposed by Sun et al. [38] and a hierarchical cloud network workload allocation scheme designed by Fan et al. [39]. The FC architecture was split into two layers, and a resource-scheduling strategy based on the two fog networks was designed, as shown in Figure 1.
In the improved three-layer FC resource-scheduling architecture, the fog layer is composed of a fog cluster layer and a fog node layer from a data processing perspective, the fog clusters are composed of fog nodes based on the principle of the geographic location, and the variance of the number of nodes between each fog cluster is as small as possible. At the fog node layer, when a service request arrives, the task is split into subtasks according to the number of fog nodes in the fog cluster. This phase focuses on how to rationally distribute the upload tasks to the nodes in the fog cluster in order to minimize the data processing load at each fog node.
At the cluster layer, each fog cluster has a manager node, which is a resource scheduler for the tasks that are submitted by the resource requesters from the terminal layer. Task scheduling between fog clusters means that when there is a task from a fog cluster, the manager nodes communicate with each other and allocate tasks. Task scheduling follows two principles: the proximity of fog clusters and resource utilization.
Although a short communication distance reduces the communication delay, the user may not tolerate the waiting time if the resource utilization of the fog cluster that is closest to the user has already reached the upper-bound threshold. Therefore, the waiting time is introduced into the model to improve the resource utilization of the entire FC layer.
4. FC Resource-Scheduling Model
The proposed resource-scheduling strategy for FC consists of two parts. The first part is represented as resource allocation in the fog cluster. According to the computational resources and bandwidth of each fog node in the cluster, it optimally allocates tasks under the load-balancing condition. The second part is formulated as task scheduling between the fog clusters, in which input tasks are rationally assigned to different fog clusters. In this paper, the n tasks with a large delay sensitivity that cannot be handled independently by the edge server are fed into the fog layer and are processed by M fog clusters that are composed of m fog nodes in the fog layer. First, the minimum delay and the minimum energy consumption of each task after optimal load balancing in different fog clusters are calculated in this part. Then, on the basis of the first part, the minimum delay and the minimum energy consumption of the system when all of the tasks have been completed are calculated. Table 1 shows the problem notation.
4.1. Load Balancing between Nodes in the Same Fog Cluster
In order to balance the task load of the fog nodes in the fog cluster and to ensure a reasonable resource allocation, the delay and the energy consumption of the fog cluster processing tasks are minimized. In this study, a set of random values was preset as the initial load allocation, and then a preferable load allocation method was obtained through the load-balancing model. Finally, a set of optimal workloads was trained. The load-balancing model process is shown in Figure 2.
In a fog cluster, it is assumed that the q FC node devices (z1, z2, …, zq) constitute the fog cluster computing framework, and these devices have different computing capabilities. When a task from the scheduler is sent to the fog cluster, each task is denoted as X. As shown in Figure 3, it is assumed that the FC node device that is connected to the submitted task is z1 each time (z1 is the selected task manager node that is responsible for receiving the tasks and allocating the resources). Then, task X is divided into multiple subtasks, and the relationship between its subtasks is satisfied with xpg = δgX. All of the FC nodes, including z1 itself, can perform the corresponding processing computations on the subtasks.
Thus, in the fog cluster, the total processing time t of the input task in the fog layer consists of two parts: the computation delay and the communication transmission delay. This can be expressed as Equation (1).
(1)
where represents the computing power of the FC node device; represents the time that is required for the FC device zg to process the subtask xg, i.e., the computing delay of the FC device; represents the time that it takes for the subtask xg to be transferred to the FC device zg; and represents the communication transmission speed from fog node g to fog node h (1 ≤ h ≤ m).(2)
where bh represents the channel bandwidth of the data transmission from fog node g to fog node h, S represents the channel power, and N represents the noise power.In order to ensure that Equation (1) obtains an optimal solution, i.e., a set of values of δ so that t(δ) is minimized, Equation (3) is used.
(3)
The processing capacity of the subtask of each fog node is xg = δgX. Thus, the subtask vector that is processed by the m fog nodes is xp = [xp1, xp2, …, xpq]. The modeling of task X and time t in the fog layer is shown in Equation (4).
(4)
As with the time delay composition, the energy consumption of the entire fog cluster also mainly consists of the transmission energy consumption and the execution energy consumption. The total energy consumption of a fog cluster performing a task can be expressed as follows:
(5)
where Ptran is the energy consumption of the data transmission from one node to another in the system and Pcomp is the energy consumption of the fog node processing the data in the system.In the same fog cluster, the joint optimization objective function of the delay and the energy consumption of the resource allocation is as follows:
f(xp) = min(μt(xp) + (1 − μ)e(xp))(6)
where μ is .4.2. Task Scheduling between Different Fog Clusters
There are also performance differences between the different fog clusters. In order to fully utilize all of the fog clusters, the time and energy consumption of the FC system for processing tasks are reduced. This section introduces the waiting time into the task-scheduling model and constructs the task-scheduling model between the fog clusters by combining the processing time and the waiting time in order to represent the total completion time of a task. The task-scheduling process between the different fog clusters is shown in Figure 4.
Suppose that there are m fog nodes in the system and each fog node is represented by a quaternion. Suppose that fi(axi, oyi, bi, λi) represents the ith fog node, axi represents the abscissa of the fog node, oyi represents the ordinate of the fog node, bi represents the bandwidth of the fog node, λi represents the computing resources of the fog node, and m fog nodes are represented as follows:
f = {f1, f2, f3, …, fm}(7)
M clusters consist of m fog nodes according to their geographical location, each represented by a binary group. FI(BI, CI) represents the Ith fog cluster, BI represents the average bandwidth of the Ith fog cluster, and CI represents the total computing resources of the fog cluster. The M fog clusters are represented as follows:
F = {F1, F2, F3, …, FM}(8)
When n tasks are uploaded to the fog layer, each input task is represented by a binary group. Suppose that rk(k, Xk) specifies the kth task, k represents the number of the task, and Xk represents the data size of the task k. Then, n tasks are shown in Equation (9).
r = {r1, r2, r3, …, rn}(9)
Suppose that SkI represents the kth task processed by the Ith fog cluster and there is a mapping matrix S between the task and the fog cluster, as shown in the following formula:
(10)
The execution time and the energy consumption of the n tasks in each fog cluster are calculated as in Section 4.1. tkI represents the time spent by task k in fog cluster I, without the waiting time, and ekI represents the energy consumption of task k in fog cluster I, without the energy consumption spent by the waiting time. Thus, the following delay matrix and energy consumption matrix can be obtained:
(11)
(12)
The tasks assigned to the M clusters can be obtained from Equation (10) as the set Mn.
(13)
If we assume that the nI tasks need to be processed in fog cluster I, the representation of nI tasks is RI:
(14)
Moreover, n tasks can be expressed in another way:
R = {R1, R2, R3, …, RM}(15)
where RI represents the Ith scheduling list and n tasks are assigned to the M fog clusters according to the M task scheduling lists. Each fog cluster processes the assigned tasks according to the corresponding task scheduling list.The time to complete the assigned task in the Ith fog cluster can be obtained from Equations (10) and (12), without the waiting time.
(16)
(1 ≤ j ≤ nI) represents the waiting time for task j in fog cluster I. Then, can be expressed as follows:
(17)
The completion time of a task consists of the task waiting time and the task execution time , which can be expressed as the total time spent on the jth task in fog cluster I.
(18)
The total delay in fog cluster k is equal to the service delay time TInI of the nIth task.
(19)
The total service delay spent by the entire fog layer processing n tasks is T:
(20)
From the perspective of the fog cluster, the energy consumption of the entire fog layer consists mainly of the waiting energy consumption and the execution energy consumption. The total energy consumption of the fog layer can be expressed as follows:
(21)
where Qwait represents the task waiting energy consumption per second in the Ith fog cluster.The objective function value is an important metric by which to evaluate the pros and cons of an individual source. In the artificial bee colony algorithm, the quality of each honey source is determined by the objective function value. The nectar source with a preferred objective function value is preferentially retained. However, as a result of the large difference in the time delay and energy consumption, the direct processing procedure produces large errors. Therefore, it is necessary to numerically standardize the two objectives.
Ft(S) = ln(T(S))(22)
Fe(S) = ln(E(S))(23)
According to the normalization of the above objectives, the task-scheduling objective function value F between the different fog clusters is finally obtained by summation. The final objective function can be calculated using Equation (24).
F(S) = min{ψFt(S) + γFe(S)}(24)
where ψ and γ represent the weights of the delay and the energy consumption, respectively. The center of gravity of the optimization objectives is represented by their values, where ψ = Fe(S)/(Ft(S) + Fe(S)) and ψ + γ = 1.5. Design of Resource-Scheduling Strategy Based on PGABC–PSO
5.1. Load Balancing between Nodes
When a task is uploaded to the FC system, the optimal load balancing is computed to minimize the computation time and the energy consumption when each task is processed by each fog cluster.
The initial load allocation of a task is represented for N q-dimensional random arrays, where q represents the number of fog nodes in the fog cluster. The traditional PSO is used to find the best load-balancing scheme. The particle search formula is as follows:
(25)
yp(I,:) = xp(i,:) + vp(i,:)(26)
where xp(i,:) represents the position of the current ith particle, yp(i,:) represents the position of the ith particle after searching, pp(i,:) represents the current extremum position of the ith particle, and gbestp represents the optimal value position of all of the current particles.The mass of the particles is represented by Equation (6), and the particles with preferable quality are selected according to the greedy criterion. The above operation is repeated until the maximum period is reached, and the desired allocation result is output.
The pseudocode for the load-balancing Algorithm 1 in this article is as follows:
Algorithm 1: Load balancing based on PSO |
Input: resource set {z1, z2, …, zq}, task set X, N, MP |
Output: Processing time (t), energy consumption (e), load balancing solutions |
1: initialize particle position, particle velocity |
2: calculate the fitness value of the particle and record it as the best fitness value for each particle |
3: obtain the current global best fitness value and global best particle position |
4: for tm = 1→MP do |
5: for i = 1→N do |
6: update particle velocity and position |
7: calculate the fitness value of the new particle |
8: if (new particle fitness value < particle best fit value s) then |
9: The new particle position becomes the best position for the particle |
10: end |
11: if (particle best fit value < global best fit value) then |
12: The best position of this particle becomes the current global best particle position |
13: end |
14: end |
15: obtain the global best particle position |
16: end |
17: calculate processing time (t) and energy consumption (e) |
18: return Load Balancing Solutions |
5.2. Task-Scheduling Optimization Based on PGABC
In order to address the shortcomings of the traditional ABC, such as its poor convergence and optimization ability, and the way in which it falls into the local optimum in task-scheduling problems, we introduced the concept of chromosome coding from the genetic algorithm into the initial stage of the traditional ABC. Thus, the initialization of the bee colony is represented by chromosome coding. The chromosome crossover of the genetic algorithm was introduced into the employed bee phase. The global optimal value was introduced into each generation of the observation bee iteration stage of the ABC. The concept of variation was introduced into the scout bee phase. On the basis of the ABC, the PSO was introduced for deep optimization. Thus, an ABC optimized with PSO and the genetic algorithm (PGABC) is proposed.
The modified artificial bee colony algorithm consists of five main phases: bee colony initialization, the improved employed bee stage, the observation bee stage, the improved reconnaissance peak stage, and the particle swarm optimization stage.
(1) The bee colony initialization stage
The initial solution set is composed of D-dimensional numbers. Each number is represented by the value r (0 ≤ r ≤ 1). Each r represents a gene, and several genes form a chromosome. The chromosome represents the location information of the nectar source in the ABC. Each nectar source represents a solution, task represents the quantity of tasks input, and gene represents the quantity of genes per chromosome. The dimension of the particle is equal to the quantity of tasks multiplied by the quantity of genes in each chromosome.
D = task × gene(27)
The quantity of nectar sources is set to nPop, i.e., the quantity of employed bees and scout bees is also nPop, the number of observer bees is n0nlooker, the maximum number of searches for nectar sources is Limit, and the maximum quantity of iterations is Maxcycle. In the initial stage, all of the bees are scout bees, and random searching produces nPop nectar sources. The solution groups are represented by nPop D-dimensional vectors. The nectar source generation formula is as follows:
xij = xminj + α(xmaxj − xminj) (28)
where xij represents the jth dimension value of the ith nectar source, ,, xmaxj and xminj represent the maximum 1 and the minimum 0 in the jth dimension space, respectively, and denotes random numbers between 0 and 1;(2) The improved employed bee stage
The employed bees search for new nectar sources in the vicinity of the initial nectar sources and update them according to the greedy rule. If the fitness value of the new nectar source is higher than that of the original nectar source, then the original nectar source is replaced by a new one. As a result of the large quantity of variables that is used in the destination algorithm, in order to increase the effort that is put into the search for the solution, the chromosome crossover in the genetic algorithm is combined with the neighborhood search in the traditional ABC in order to obtain the latest solution. The specific operation scheme is shown in Figure 5.
(3) The observation bee phase
When the nectar source is discovered by the bee colony, the quality of the honey source is measured by its fitness. The fitness calculation formula is as follows:
fiti = 1/Fi(29)
where Fi represents the objective function value of xi, Fi is obtained by transforming xi into the mapping matrix that is shown in Equation (10) using Equation (24), and fiti represents the fitness value of xi.In the observation bee stage, the observing bees select the honey source by observing the quality of the honey source. In this paper, the smaller the objective function value, the better the quality of the honey source, and the more observation bees will convene. The observing bee selects a source of honey via roulette probability. The selection probability formula is as follows:
(30)
where pi represents the probability that xi is selected. Then, because of the slow convergence of the algorithm, the global optimal honey source position is introduced to accelerate the convergence of the algorithm. The location update formula is as follows:(31)
where yij is the new nectar source that is identified by the employed bees; xij is the current nectar source; xkj is the other nectar source that is selected, which is different from the current nectar source; ; k ≠ I; xbest is the best nectar source position among all of the current nectar sources; and is a random number between −1 and 1;(4) The improved scout bee stage
Because the number of genes is too large and the traditional ABC reconnaissance peak phase is not suitable, the mutation rate was introduced by referring to the variation in the genetic algorithm. Given a value Var (Var < 1) as the mutation rate, all of the nectar sources are traversed during the reconnaissance peak phase, and each nectar source randomly generates a random value rand (0,1). When Var < rand (0,1), the nectar source is mutated to obtain a new nectar source in order to avoid the algorithm solution falling into the local optimum;
(5) The particle swarm optimization stage
The current optimal solution is introduced into the PSO, and each nectar source position is used as the initial position of the particles. With the particle swarm velocity update formula and the position update formula, a new nectar source is identified near to the original nectar source. The particle velocity update formula and the position update formula are as follows:
(32)
x(i,:) = x(i,:) + v(i,:)(33)
where x(i,:) represents the location information of the current ith particle (the honey source), p(i,:) represents the individual extremum position of the ith particle (the honey source), and gbest represents the optimal value position of all of the current particles.The pseudocode for Algorithm 2 task scheduling is as follows:
Algorithm 2: Task scheduling based on PGABC |
Input: resource set {F1, F2, …, FM}, task set {r1, r2, …, rn}, nPop, n0nlooker, MaxIt, em, tm, Var |
Output: Total time delay, total energy consumption, scheduling results |
1: initialize the nectar source location, calculate the fitness value of each nectar source |
2: obtain the nectar source with the best fitness value at present |
3: for it = 1→MaxIt do |
4: for i = 1→nPop do |
5: generation of new nectar positions according to chromosome crossover |
6: calculate the fitness value for the new nectar source location |
7: if (new nectar source adaptation value < old nectar source adaptation value) then |
8: new nectar source replaces old one |
9: end |
10: end |
11: calculate the probability of fitness for each nectar source |
12: for i = 1→n0nlooker do |
13: honey source selection by roulette with the following bees |
14: search for new honey sources near the selected honey source |
15: calculate the fitness value for the new nectar source location |
16: if (new nectar source adaptation value < old nectar source adaptation value) then |
17: new nectar source replaces old one |
18: end |
19: end |
20: for i = 1→nPop do |
21: generate a random number between 0 and 1 represented by rand |
22: if (rand < Var) then |
23: local variation of location information in nectar sources |
24: the new nectar source obtained replaces the original one |
25: end |
26: update the global best honey source |
27: for i = 1→nPop do |
28: search for new nectar source locations using the particle swarm algorithm search method |
29: calculate the fitness value for the new nectar source location |
30: if (new nectar source adaptation value < old nectar source adaptation value) then |
31: new nectar source replaces old one |
32: end |
33: end |
34: obtain the location of the nectar source with the best fitness value |
35: end |
36: calculate the total time delay and energy consumption |
37: return task scheduling solutions |
5.3. Resource Scheduling Based on PGABC–PSO
Firstly, the PSO is used to determine the load balancing in the same fog cluster, and then PGABC is used to determine the resource-scheduling scheme (PGABC–PSO) of the task-scheduling problem between the fog clusters, as shown in Figure 6.
The overall algorithm steps are as follows:
(1) Input the fog node parameters and the task parameters;
(2) The fog nodes are simply clustered according to the geographical location, and the parameters of each cluster are output;
(3) Use the classical PSO to calculate the time and the energy consumption that are required for processing all of the input fog layer tasks in each fog cluster, which are then saved in a matrix;
(4) Input the matrix that was calculated in step (1); initialize the nectar sources, the employed bees, the observed bees, and the iterations; and input the values of c, w, etc.;
(5) Calculate the objective function value of each nectar source individual, identify the current optimal nectar source position and the optimal function value, and record them;
(6) Use the employed bees after the genetic optimization to generate a new solution and calculate the fitness value;
(7) The employed bees update the nectar source according to the greedy strategy;
(8) Use Equation (29) to calculate the fitness value of the honey source according to the objective function value of the honey source and calculate the selection probability of the honey source by using Equation (30);
(9) Use the genetic optimized reconnaissance peak stage to locally mutate and update the honey source;
(10) Update the optimal nectar source position and the optimal function value;
(11) Perform further optimizations in the PSO stage to improve the computational accuracy of the proposed algorithm. Take the optimal position of the nectar source obtained in step (10) as the global optimal particle of the particle swarm, and take the latest position of all of the nectar sources obtained in step (9) as the initial particle position and the local optimal position of the particle swarm. Update the positions according to the particle swarm algorithm;
(12) Calculate the objective function value of each individual nectar source again, and update and identify the current optimal nectar source position and optimal function value;
(13) If the iteration end condition is reached, stop the iteration to output the optimal honey source position and fitness value; if not, return to step (6).
5.4. Time and Resource Complexities
In Table 2, q represents the number of fog nodes in the fog cluster, Np represents the number of particles in the particle swarm, Mp represents the total number of cycles of the particle swarm, m represents the total number of fog nodes, n represents the number of tasks, M represents the number of fog clusters in the system, nPop represents the number of employed bees, n0nlooker represents the amount of following bees, gene represents the number of genes per chromosome in the PGABC, and Maxcycle represents the total number of cycle iterations in the PGABC.
In the FC system, the number of fog nodes m and the number of fog clusters M are generally fixed, and only the number of input tasks n is variable. The other parameters in the above table are all inherent parameters of the algorithm itself. It can be seen that the data variation in the method is only related to the number of tasks n, and the other parameters can be neglected; therefore, the final time complexity is O(n) and the resource complexity is O(n). The performance of the method that was proposed in this section is good, and it does not become computationally intractable as the amount of data increases.
6. Simulation and Analysis
6.1. Simulation Parameter Design
The experimental parameters were limited in order to make the proposed PGABC–PSO strategy suitable for FC scenarios. In the simulation experiment, the experimental parameters were set as follows: The task number range was [20, 200] and the task data range was [1, 10] GB. The fog node number range was [50, 300], the fog node calculation rate range was [10, 60] MB/s, and the fog node bandwidth range was [50, 200] Hz. The fog node abscissa range was [0–1000] m, and the ordinate range was [0–1000] m. The fog cluster was divided by fog nodes according to the geographical location, and the number of fog clusters was [6, 14]. With 100 tasks and 10 fog clusters from 100 fog nodes in the experimental environment, i.e., Intel (R) Core (TM) i5-4210H CPU @ 2.90 GHz and Windows 10, 64-bit operating system, the average time to train the proposed policy was 33 s, which varied with the number of tasks and fog clusters. The remaining parameters are listed in Table 3.
In the proposed PGABC–PSO strategy, the appropriate number of fog clusters has a large impact on resource utilization; if a small number of fog clusters is set, not all of the fog nodes are fully utilized, which increases the total latency of the system. A larger number of fog clusters increases the total energy consumption of the whole system. The results that are given in Figure 7 and Figure 8 show how we established the appropriate number of fog clusters via extensive experimentation.
It can be seen from Figure 7 and Figure 8 that, for 100, 150, and 200 fog nodes, fewer fog clusters resulted in a lower energy consumption, but larger latency. The energy consumption increased significantly with the quantity of fog clusters, and the delay decreased with the quantity of fog clusters until the delay curve plateaued after the number of fog clusters reached 10. Thus, the optimal value of the quantity of fog clusters was 10 when the quantity of fog nodes was around 100, 150, and 200. At this point, the system was most stable in terms of the processing task.
6.2. Strategy Comparison
In order to verify the effectiveness and the superiority of the proposed resource-scheduling strategy for the resource-scheduling problem in FC, the proposed strategy was tested against two performance metrics: completion time and energy consumption. The PGABC–PSO resource-scheduling strategy was compared with PGABC inter-cluster task scheduling based on random resource allocation (PGABC-R), shortest job first (SJF) inter-cluster task scheduling based on PSO for load-balancing resource allocation (SJF–PSO), the hybrid scheduling framework based on the combination of the ABC and the PSO (HSF.ABC&PSO) scheduling strategy proposed by Meshkati [35], and an efficient task-scheduling approach using the moth–flame optimization algorithm (MFO) proposed by Ghobaei [26].
First, we validated the optimization effect of the proposed scheme based on the completion time and the energy consumption for different numbers of tasks. We compared the completion time and the energy consumption of the five resource-scheduling schemes when the amount of fog nodes was fixed, and the quantity of processed tasks was different. We took the average of 30 experiments, and the quantity of tasks was set to 20, 60, 100, 140, and 200. The results are shown in Figure 9 and Figure 10.
According to Figure 9 and Figure 10, as the number of tasks increases, the total energy consumption and the total delay of the system also increase. Compared with the remaining four strategies, the proposed PGABC–PSO has an obvious optimization effect on the delay and energy consumption. The optimization effect of delay is very large. Compared with the other four strategies, the optimization effect is significantly improved. The optimization of energy consumption increases gradually with the increase in the number of tasks. It can be concluded from Table 4 that, when the quantity of tasks is 20, i.e., the minimum quantity of tasks, compared with SJF–PSO, PGABC-R, HSF.ABC&PSO, and MFO, the delay of PGABC–PSO is reduced by 31.25%, 27.8%, 27.8%, and 25.4%, respectively, and the energy consumption is reduced by 9.7%, 33.3%, 32%, and 29.6%, respectively. When the quantity of tasks is 200, i.e., the maximum quantity of tasks, compared with SJF–PSO, PGABC-R, HSF.ABC&PSO, and MFO, the delay of PGABC–PSO is reduced by 28.3%, 29.3%, 27.2%, and 21.9%, respectively, and the energy consumption is reduced by 5%, 27.9%, 26.5%, and 26.3%, respectively. Therefore, compared to the remaining four resource-scheduling strategies, the proposed strategy has a preferable optimization effect on time delay and energy consumption when the number of tasks increases, and is more suitable for resource-scheduling problems in FC. Therefore, the strategy that has been proposed in this paper is preferable to the remaining four strategies.
We validated the optimization effect of the proposed scheme on the completion time and energy consumption in environments with different numbers of fog nodes. The completion time and the energy consumption of the five task-scheduling schemes were compared when the total quantity of input tasks was fixed, and the quantity of fog node devices owned by the system was different. The quantity of fog nodes was set to 50, 100, 150, 200, and 250. The results are shown in Figure 11 and Figure 12.
According to Figure 11 and Figure 12, the total energy consumption and the total delay of the system decreased as the number of fog nodes increased. For delay optimization, the proposed strategy was far superior. Compared with PGABC-R, HSF.ABC&PSO, and MFO, concerning energy consumption optimization, PGABC–PSO was also excellent. However, when compared to SJF–PSO, there was no obvious improvement in optimization after reaching 200 fog nodes. It can be concluded from Table 5 that, when the quantity of fog nodes was 50, i.e., the quantity of fog nodes was the minimum, compared to SJF–PSO, PGABC-R, HSF.ABC&PSO, and MFO, the delay of PGABC–PSO was reduced by 25.4%, 23%, 15.4%, and 15.2%, respectively, and the energy consumption was reduced by 6.8%, 22.6%, 20.7%, and 21.2%, respectively. When the number of fog nodes was 250, i.e., the maximum number of tasks, PGABC–PSO reduced the delay by 18.5% and improved the energy consumption by only 1.1%, compared to SJF–PSO. As compared to PGABC-R, HSF.ABC&PSO, and MFO, the latency was reduced by 40.5%, 38.2%, and 34.5%, respectively, and the energy consumption was reduced by 36.5%, 36.6%, and 36.4%, respectively. Therefore, the proposed strategy exhibited a superior optimization effect for time delay and energy consumption compared to the other four strategies, but the optimization effect for energy consumption decreased as the quantity of nodes increased. Overall, the proposed strategy is superior to the other four strategies for the resource-scheduling problem.
6.3. Algorithm Performance Comparison
In order to validate the improved optimization capability and search accuracy of the proposed algorithm, it was compared with GABC, ABC, and PSO for a fixed number of fog nodes and tasks, and different numbers of fog clusters. The number of fog clusters was set to 6, 7, 8, 9, 10, 11, 12, and 13. The results are shown in Figure 13 and Figure 14.
According to Figure 13 and Figure 14, with the increase in fog cluster number, the time delay curves for the PGABC and GABC algorithms decreased and tended to be stable. Moreover, the time delay curves and the energy consumption curves for the ABC and the PSO exhibited a rising trend. However, as the number of fog clusters increased, the proposed PGABC outperformed GABC, ABC, and PSO in terms of both the optimum delay and the energy consumption, and the optimization trend also increased. According to Table 6, when the number of fog clusters was 13, the time delay of PGABC improved by 1.04%, 15.9%, and 28.5%, and the energy consumption improved by 3.9%, 6.6%, and 12.6%, as compared to GABC, ABC, and PSO, respectively. It can be seen that the improvement metrics of the traditional ABC algorithm are impressive, and the optimization effect and accuracy are better than those of the GABC, ABC, and PSO algorithms.
In summary, the proposed PGABC task-scheduling algorithm and the PGABC–PSO resource-scheduling strategy based on the proposed PGABC algorithm are suitable for addressing FC resource-scheduling problems. In addition, they produced promising results in terms of time delay and energy consumption optimization in resource-scheduling problems. The resource-scheduling policy proposed in this paper is very effective in applications with a large number of fog nodes with a wide distribution, such as those used in large factories with multiple production lines, health detection applications, emergency responses in hospitals, etc. It should be noted, however, that in this paper, we mainly focused on task scheduling in the resource-scheduling problem; thus, a more in-depth study of load balancing will be conducted in the future.
7. Conclusions
Resource scheduling in FC is crucial to improve the processing rate, the sustainable development, and the stability of FC. With the aim of addressing the difficulty of scheduling FC nodes in IoT applications, low resource utilization, and the poor application effect of the artificial bee colony algorithm in the FC resource-scheduling problem, we first optimized and improved the ABC algorithm. We then effectively applied the optimized algorithm to FC resource-scheduling to achieve optimal optimization results. Thus, we improved the scheduling scheme for FC resources in the IoT. The combination of load balancing and task scheduling reduces the latency and the energy consumption of FC network processing tasks in the context of the entire IoT network, which improves the efficiency of FC task processing in IoT applications, as well as the energy efficiency. Finally, the improved PGABC algorithm was compared with three other algorithms through simulation experiments, and the proposed PGABC–PSO strategy was compared with four other strategies. We reached the following conclusions:
(1) Genetic algorithms were introduced into the PGABC algorithm in order to prevent the traditional artificial bee colony algorithm from becoming stuck in local optima. The introduction of the PSO further improved the search accuracy based on the optimization of the genetic algorithm for the artificial bee colony algorithm. The experimental results show that the time delay that was calculated using the proposed PGABC algorithm in the given model was reduced by 1.04%, 15.9%, and 28.5%, compared to GABC, ABC, and PSO, respectively, and the energy consumption was reduced by 3.9%, 6.6%, and 12.6%, respectively. We showed that the developed algorithms produced preferable optimization results and higher accuracy. Thus, they were shown to be more suitable for the resource-scheduling scheme for FC.
(2) In the PGABC–PSO resource-scheduling strategy, the input tasks were allocated in the resource-allocation layer using the PSO algorithm for load balancing. According to the allocation results, the PGABC algorithm was used for task scheduling in the task-scheduling layer. The proposed PGABC–PSO resource-scheduling strategy reduced the delay by approximately 31.25%, 27.8%, 27.8%, and 25.4%, and the energy consumption by approximately 9.7%, 33.3%, 32%, and 29.6%, compared with SJF–PSO, PGABC-R, HSF.ABC&PSO, and MFO, respectively. It was demonstrated that the proposed strategy leads to a significant improvement in delay optimization and energy consumption optimization compared to PGABC-R, SJF–PSO, HSF.ABC&PSO, and MFO.
In this study, we optimized and improved the artificial swarm algorithm, and, combined with the PSO, it was applied to FC resource scheduling. In doing so, we achieved excellent optimization results. We also improved the resource-scheduling scheme for FC in the IoT. The combination of load balancing and task scheduling reduces the latency and the energy consumption of FC network procedures in the context of the entire IoT network and contributes to the further development of the IoT network.
However, in our study, the training data samples that were used in the scheme were small, and the application of load balancing was not sufficiently deep. Therefore, in the future, we aim to conduct a more in-depth study of load balancing and hope to produce additional optimizations based on the current work.
Conceptualization, C.L. and W.L.; methodology, C.L., W.L. and A.Z.; software, C.L., Y.X. and Z.Z. (Zhen Zhang); validation, C..L, Y.X. and Z.Z. (Zhen Zhang); formal analysis, C.L. and A.Z.; investigation, C.L.; resources, C.L. and A.Z.; data curation, C.L. and Z.Z. (Zhi Zheng); writing—original draft preparation, C.L.; writing—review and editing, C.L., W.L. and Z.Z. (Zhi Zheng); supervision, C.L. and A.Z.; project administration, A.Z.; funding acquisition, W.L. and Z.Z. (Zhi Zheng) All authors have read and agreed to the published version of the manuscript.
The data presented in this study are available upon request from the corresponding author. The data are not publicly available due to the need for our follow-up research.
To the authors and organizations mentioned in this article, we would like to offer thanks for their support in writing this article.
The authors declare no conflict of interest.
Footnotes
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.
Figure 1. Two-layer fog computing resource-scheduling architecture based on load balancing and task scheduling.
Figure 5. Chromosome crossover was performed between the original nectar source and a nearby nectar source.
Figure 8. Total energy consumption versus fog cluster number in three environments.
Figure 10. Total system energy consumption for the five schemes varying with task number.
Figure 12. Total system energy consumption of five schemes varying with fog node number.
Figure 14. Total energy consumption for the four algorithms varying with fog cluster number.
Mathematical notation.
Notation | Description |
---|---|
n | Number of tasks |
m | Total number of fog nodes |
M | Number of fog clusters |
q | Number of fog nodes in a single fog cluster |
X | Data for a task |
xp | The number of subtasks that each fog node needs to handle in the fog cluster |
t | Time required for fog cluster to process a single task |
λ | Fog node calculation rate |
b | Fog node bandwidth |
τ | Transmission speed between fog nodes |
e | Total energy consumption of a fog cluster processing a single task |
Ptran | Transmission energy consumption per second between fog nodes |
Pcomp | Unit calculation energy consumption of fog node processing data |
fi | Quad representation of the ith fog node |
FI | Binary representation of the Ith fog cluster |
rk | Triple representation of the kth task |
axi | Abscissa of the ith fog node |
oyi | Ordinate of the ith fog node |
BI | Average bandwidth of the Ith fog cluster |
CI | The total computing resources of the Ith fog cluster |
S | Mapping matrix between a task and a fog cluster |
em | Fog cluster and task energy consumption matrix |
tm | Fog cluster and task delay matrix |
Mn | Set of tasks assigned by M fog clusters |
|
Computation time of the set of tasks assigned on the Ith cluster |
|
Waiting time of the jth task in fog cluster I |
TIj | Total time from uploading to completion of task j in fog cluster I |
TnI | The time it takes fog cluster I to process the assigned task |
T | Total time for the entire fog system to complete all tasks |
E | Energy consumption of the entire fog system for all tasks |
Qwait | Unit waiting energy consumption of tasks |
Time and resource complexities of methods.
Algorithm | Time Complexity | Resource Complexity |
---|---|---|
PSO | O(Max(q Np, Np, MP NP)) | O(q Np) |
PGABC | O(Max(nPop, Maxcycle nPop n, Maxcycle n0nlooker n)) | O(n gene nPop + 2M + n) |
PGABC–PSO | O(Max(q Np m n, Np m n, MP NP m n, nPop, Maxcycle nPop n, Maxcycle n0nlooker n)) | O(2n + 4m + 2M)+ O(m n q Np) + O(n gene nPop + 2M + n) + O(n) |
Resource-scheduling algorithm simulation parameter settings.
Parameter Symbol | Value Range | Definition |
---|---|---|
n | [20, 200] | Number of tasks |
m | [50, 250] | Number of fog nodes |
b | [50, 200] MHz | Fog node bandwidth |
λ | [10, 60] MB/s | Fog node calculation rate |
M | [6, 14] | Number of fog clusters |
wp | 0.65 | Inertial weight |
c1p | 0.8 | Individual learning factor |
c2p | 1.7 | Social learning factor |
N | 40 | Number of particles in PSO |
MP | 40 | Iterations of PSO |
nPop | 40 | Employed bee/scout bee |
n0nlooker | 20 | Observation bee |
c 1 | 1 | Individual learning factor |
c 2 | 2 | Social learning factor |
w | 0.2 | Inertial weight |
a | 0.95 | Acceleration factor |
Var | 0.01 | Mutation probability |
Maxcycle | 500 | Iteration times |
Ptran | 0.2 J/s | Unit transmission energy consumption |
Pcomp | 0.05 J/s | Unit calculated energy consumption |
Qwait | 0.01 J/(s·MB) | Unit waiting energy consumption |
The delay and energy consumption of the five strategies when the number of tasks was 20 or 200 and the fog node was 100.
Algorithm | Number of Tasks | Time Delay/s | Energy Consumption/J |
---|---|---|---|
PGABC–PSO | 20 | 44 | 140 |
200 | 367 | 3057 | |
SJF–PSO | 20 | 64 | 155 |
200 | 512 | 3217 | |
PGABC-R | 20 | 61 | 210 |
200 | 519 | 4240 | |
HSF.ABC&PSO | 20 | 61 | 206 |
200 | 504 | 4161 | |
MFO | 20 | 59 | 199 |
200 | 470 | 4148 |
The delay and energy consumption calculated using the five strategies when the number of fog nodes was 50 and 250.
Algorithm | Number of Fog Nodes | Time Delay/s | Energy Consumption/J |
---|---|---|---|
PGABC–PSO | 50 | 378 | 2290 |
250 | 97 | 531 | |
SJF–PSO | 50 | 507 | 2457 |
250 | 119 | 525 | |
PGABC-R | 50 | 491 | 2959 |
250 | 163 | 836 | |
HSF.ABC&PSO | 50 | 447 | 2888 |
250 | 157 | 837 | |
MFO | 50 | 446 | 2906 |
250 | 148 | 835 |
The optimization results of each algorithm for the delay and energy consumption when the quantity of fog clusters was 13.
Algorithm | Time Delay/s | Energy Consumption/J |
---|---|---|
PGABC | 191 | 1205 |
GABC | 193 | 1254 |
ABC | 227 | 1290 |
PSO | 267 | 1378 |
References
1. Mubeen, S.; Nikolaidis, P.; Didic, A.; Pei-Breivold, H.; Sandstrom, K.; Behnam, M. Delay Mitigation in Offloaded Cloud Controllers in Industrial IoT. IEEE Access; 2017; 5, pp. 4418-4430. [DOI: https://dx.doi.org/10.1109/ACCESS.2017.2682499]
2. Anna, K.; Carson, L.; Ching-Hsien, H.; Raghavendra, S.; Chang, V. Emerging trends, issues and challenges in Internet of Things, Big Data and cloud computing. Future Gener. Comput. Syst.; 2018; 87, pp. 416-419.
3. Moura, J.; Hutchison, D. Review and analysis of networking challenges in cloud computing. J. Netw. Comput. Appl.; 2016; 60, pp. 113-129. [DOI: https://dx.doi.org/10.1016/j.jnca.2015.11.015]
4. Bellendorf, J.; Mann, Z.Á. Classification of optimization problems in fog computing. Future Gener. Comput. Syst.; 2020; 107, pp. 158-176. [DOI: https://dx.doi.org/10.1016/j.future.2020.01.036]
5. Singh, J.; Singh, P.; Gill, S.S. Fog computing: A taxonomy, systematic review, current trends and research challenges. J. Parallel Distrib. Comput.; 2021; 157, pp. 56-85. [DOI: https://dx.doi.org/10.1016/j.jpdc.2021.06.005]
6. Ni, J.; Zhang, K.; Lin, X.; Shen, X.S. Securing Fog Computing for Internet of Things Applications: Challenges and Solutions. IEEE Commun. Surv. Tutor.; 2018; 20, pp. 601-628. [DOI: https://dx.doi.org/10.1109/COMST.2017.2762345]
7. Singh, S.P.; Nayyar, A.; Kumar, R.; Sharma, A. Fog computing: From architecture to edge computing and big data processing. J. Supercomput.; 2019; 75, pp. 2070-2105. [DOI: https://dx.doi.org/10.1007/s11227-018-2701-2]
8. Jamil, B.; Shojafar, M.; Ahmed, I.; Ullah, A.; Munir, K.; Ljaz, H. A job scheduling algorithm for delay and performance optimization in fog computing. Concurr. Comput. Pract. Exp.; 2019; 32, e5581. [DOI: https://dx.doi.org/10.1002/cpe.5581]
9. Mutlag, A.A.; Abd, G.M.K.; Arunkumar, N.; Mohamed, M.A.; Mohd, O. Enabling technologies for fog computing in healthcare IoT systems. Future Gener. Comput. Syst.; 2019; 90, pp. 62-78. [DOI: https://dx.doi.org/10.1016/j.future.2018.07.049]
10. Nayeri, Z.M.; Ghafarian, T.; Javadi, B. Application placement in Fog computing with AI approach: Taxonomy and a state of the art survey. J. Netw. Comput. Appl.; 2021; 185, 103078. [DOI: https://dx.doi.org/10.1016/j.jnca.2021.103078]
11. Mondragón-ruiz, G.; Tenorio-trigoso, A.; CAstillo-cara, M.; Caminero, B.; Carrión, C. An experimental study of fog and cloud computing in CEP-based Real-Time IoT applications. J. Cloud Comput.; 2021; 10, 32. [DOI: https://dx.doi.org/10.1186/s13677-021-00245-7]
12. Hameed Abdulkareem, K.; Awad Mutlag, A.; Musa Dinar, A.; Frnda, J.; Abed Mohammed, M.; Hasan Zayr, F.; Lakhan, A.; Kadry, S.; Ali Khattak, H.; Nedoma, J. Smart Healthcare System for Severity Prediction and Critical Tasks Management of COVID-19 Patients in IoT-Fog Computing Environments. Comput. Intell. Neurosci.; 2022; 2022, 5012962. [DOI: https://dx.doi.org/10.1155/2022/5012962]
13. Alatoun, K.; Matrouk, K.; Mohammed, M.A.; Nedoma, J.; Martinek, R.; Zmij, P. A Novel Low-Latency and Energy-Efficient Task Scheduling Framework for Internet of Medical Things in an Edge Fog Cloud System. Sensors; 2022; 22, 5327. [DOI: https://dx.doi.org/10.3390/s22145327]
14. Li, Z.M.; Zhang, W. Cloud computing resource scheduling based on differential evolutionary artificial bee colony algorithm. Comput. Eng. Des.; 2018; 39, pp. 3451-3455.
15. Mutlag, A.A.; Abd Ghani, M.K.; Mohammed, M.A.; Lakhan, A.; Mohd, O.; Abdulkareem, K.H.; Garcia Zapirain, B. Multi-Agent Systems in Fog–Cloud Computing for Critical Healthcare Task Management Model (CHTM) Used for ECG Monitoring. Sensors; 2021; 21, 6923. [DOI: https://dx.doi.org/10.3390/s21206923]
16. Lakhan, A.; Mohammed, M.A.; Rashid, A.N.; Kadry, S.; Abdulkareem, K.H. Deadline aware and energy-efficient scheduling algorithm for fine-grained tasks in mobile edge computing. Int. J. Web Grid Serv.; 2022; 18, pp. 168-193. [DOI: https://dx.doi.org/10.1504/IJWGS.2022.121935]
17. Rahimi, M.; Songhorabadi, M.; Kashani, M.H. Fog-based smart homes: A systematic review. J. Netw. Comput. Appl.; 2020; 153, 102531. [DOI: https://dx.doi.org/10.1016/j.jnca.2020.102531]
18. Yin, L.; Luo, J.; Luo, H. Tasks Scheduling and Resource Allocation in Fog Computing Based on Containers for Smart Manufacturing. IEEE Trans. Ind. Inform.; 2018; 14, pp. 4712-4721. [DOI: https://dx.doi.org/10.1109/TII.2018.2851241]
19. Liu, J.; Weng, J.; Yang, A.; Chen, Y.; Lin, X. Enabling Efficient and Privacy-Preserving Aggregation Communication and Function Query for Fog Computing-Based Smart Grid. IEEE Trans. Smart Grid; 2020; 11, pp. 247-257. [DOI: https://dx.doi.org/10.1109/TSG.2019.2920836]
20. Li, Y. Construction of U2S communications system based on edge fog computing. Comput. Commun.; 2020; 153, pp. 569-579. [DOI: https://dx.doi.org/10.1016/j.comcom.2020.02.038]
21. Hui, N.; Wu, J.Z.; Yi, Q.; Liu, L.; Zhou, Z.G. Future vehicular fog computing networks. Telecommun. Sci.; 2020; 36, pp. 14-27.
22. Dastjerdi, A.V.; Buyya, R. Fog Computing: Helping the Internet of Things Realize Its Potential. Computer; 2016; 49, pp. 112-116. [DOI: https://dx.doi.org/10.1109/MC.2016.245]
23. Li, X.; Xu, L.D. A Review of Internet of Things—Resource Allocation. IEEE Internet Things J.; 2021; 8, pp. 8657-8666. [DOI: https://dx.doi.org/10.1109/JIOT.2020.3035542]
24. Rafique, H.; Shah, M.A.; Islam, S.U.; Maqsood, T.; Maple, C. A Novel Bio-Inspired Hybrid Algorithm (NBIHA) for Efficient Resource Management in Fog Computing. IEEE Access; 2019; 7, pp. 115760-115773. [DOI: https://dx.doi.org/10.1109/ACCESS.2019.2924958]
25. Ghobaei, M.; Souri, A.; Safara, F.; Norouzi, M. An efficient task scheduling approach using moth-flame optimization algorithm for cyber-physical system applications in fog computing. Trans. Emerg. Telecommun. Technol.; 2019; 31, e3770. [DOI: https://dx.doi.org/10.1002/ett.3770]
26. Potu, N.; Jatoth, C.; Parvataneni, P. Optimizing resource scheduling based on extended particle swarm optimization in fog computing environments. Concurr. Comput. Pract. Exp.; 2021; 33, e6163. [DOI: https://dx.doi.org/10.1002/cpe.6163]
27. SUbbaraj, S.; Thiyagarajan, R.; Rengaraj, M. A smart fog computing based real-time secure resource allocation and scheduling strategy using multi-objective crow search algorithm. J. Ambient Intell. Humaniz. Comput.; 2023; 14, pp. 1003-1015. [DOI: https://dx.doi.org/10.1007/s12652-021-03354-y]
28. Li, G.; Liu, Y.; Wu, J.; Lin, D.; Zhao, S. Methods of Resource Scheduling Based on Optimized Fuzzy Clustering in Fog Computing. Sensors; 2019; 19, 2122. [DOI: https://dx.doi.org/10.3390/s19092122]
29. Liu, L.; Wu, Y. A task scheduling algorithm for fog computing. J. Zhongshan Univ. (Nat. Sci. Ed.); 2021; 60, pp. 166-174.
30. Karaboga, D.; Basturk, B. A powerful and efficient algorithm for numerical function optimization: Artificial bee colony (ABC) algorithm. J. Glob. Optim.; 2007; 39, pp. 459-471.
31. Karaboga, D. An Idea Based on Honey Bee Swarm for Numerical Optimization; Technical Report-tr06 Erciyes University, Engineering Faculty, Computer Engineering Department: Kayseri, Turkey, 2005; Volume 200, pp. 1-10.
32. Li, J.; Han, Y. A hybrid multi-objective artificial bee colony algorithm for flexible task scheduling problems in cloud computing system. Clust. Comput.; 2020; 23, pp. 2483-2499. [DOI: https://dx.doi.org/10.1007/s10586-019-03022-z]
33. Meshkati, J.; Safi-esfahani, F. Energy-aware resource utilization based on particle swarm optimization and artificial bee colony algorithms in cloud computing. J. Supercomput.; 2019; 75, pp. 2455-2496. [DOI: https://dx.doi.org/10.1007/s11227-018-2626-9]
34. Hu, P.; Ning, H.; Qiu, T.; Zhang, Y.; Luo, X. Fog Computing Based Face Identification and Resolution Scheme in Internet of Things. IEEE Trans. Ind. Inform.; 2017; 13, pp. 1910-1920. [DOI: https://dx.doi.org/10.1109/TII.2016.2607178]
35. Stojmenovic, I.; Wen, S.; Huang, X.Y.; Luan, H. An overview of Fog computing and its security issues. Concurr. Comput. Pract. Exp.; 2016; 28, pp. 2991-3005. [DOI: https://dx.doi.org/10.1002/cpe.3485]
36. Deng, R.; Lu, R.; Lai, C.; Tom, H.L.; Liang, H. Optimal Workload Allocation in Fog-Cloud Computing Towards Balanced Delay and Power Consumption. IEEE Internet Things J.; 2016; 3, pp. 1171-1181. [DOI: https://dx.doi.org/10.1109/JIOT.2016.2565516]
37. Ren, Z.; Lu, T.; Wang, X.; Guo, W.; Chang, S. Resource scheduling for delay-sensitive application in three-layer fog-to-cloud architecture. Peer Peer Netw. Appl.; 2020; 13, pp. 1474-1485. [DOI: https://dx.doi.org/10.1007/s12083-020-00900-x]
38. Sun, Y.; Lin, F.; Xu, H. Multi-objective Optimization of Resource Scheduling in Fog Computing Using an Improved NSGA-II. Wirel. Pers. Commun.; 2018; 102, pp. 1369-1385. [DOI: https://dx.doi.org/10.1007/s11277-017-5200-5]
39. Fan, Q.; Ansari, N. Workload Allocation in Hierarchical Cloudlet Networks. IEEE Commun. Lett.; 2018; 22, pp. 820-823. [DOI: https://dx.doi.org/10.1109/LCOMM.2018.2801866]
You have requested "on-the-fly" machine translation of selected content from our databases. This functionality is provided solely for your convenience and is in no way intended to replace human translation. Show full disclaimer
Neither ProQuest nor its licensors make any representations or warranties with respect to the translations. The translations are automatically generated "AS IS" and "AS AVAILABLE" and are not retained in our systems. PROQUEST AND ITS LICENSORS SPECIFICALLY DISCLAIM ANY AND ALL EXPRESS OR IMPLIED WARRANTIES, INCLUDING WITHOUT LIMITATION, ANY WARRANTIES FOR AVAILABILITY, ACCURACY, TIMELINESS, COMPLETENESS, NON-INFRINGMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Your use of the translations is subject to all use restrictions contained in your Electronic Products License Agreement and by using the translation functionality you agree to forgo any and all claims against ProQuest or its licensors for your use of the translation functionality and any output derived there from. Hide full disclaimer
© 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/). Notwithstanding the ProQuest Terms and Conditions, you may use this content in accordance with the terms of the License.
Abstract
As the amount of data input increases, fog devices on IoT edge networks become increasingly inefficient. However, a well-designed fog computing resource-scheduling strategy can help to reduce excessive time delays and energy consumption. Therefore, in this paper, we propose an efficient fog computing resource-scheduling strategy. First, we used particle swarm optimization (PSO) to determine the optimal load balance among fog nodes and to obtain the optimal computation time and energy consumption in a single fog cluster. Second, we designed a particle swarm genetic joint optimization artificial bee colony algorithm (PGABC) to optimize the task scheduling among fog clusters based on the time and energy consumption obtained from load balancing. In addition, PGABC was used to optimize the task-scheduling model, which further reduced the delay and energy consumption of fog computing. The experimental results show that the time delay that was calculated using the proposed PGABC algorithm in the given model was reduced by 1.04%, 15.9%, and 28.5%, compared to GABC, ABC, and PSO, respectively, and the energy consumption was reduced by 3.9%, 6.6%, and 12.6%, respectively. The proposed resource-scheduling strategy reduced the delay by approximately 31.25%, 27.8%, 27.8%, and 25.4%, and the energy consumption by approximately 9.7%, 33.3%, 32%, and 29.6%, compared to SJF–PSO, PGABC-R, HSF.ABC&PSO, and MFO, respectively.
You have requested "on-the-fly" machine translation of selected content from our databases. This functionality is provided solely for your convenience and is in no way intended to replace human translation. Show full disclaimer
Neither ProQuest nor its licensors make any representations or warranties with respect to the translations. The translations are automatically generated "AS IS" and "AS AVAILABLE" and are not retained in our systems. PROQUEST AND ITS LICENSORS SPECIFICALLY DISCLAIM ANY AND ALL EXPRESS OR IMPLIED WARRANTIES, INCLUDING WITHOUT LIMITATION, ANY WARRANTIES FOR AVAILABILITY, ACCURACY, TIMELINESS, COMPLETENESS, NON-INFRINGMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Your use of the translations is subject to all use restrictions contained in your Electronic Products License Agreement and by using the translation functionality you agree to forgo any and all claims against ProQuest or its licensors for your use of the translation functionality and any output derived there from. Hide full disclaimer
Details

1 College of Mechanical Engineering, North China University of Science and Technology, Tangshan 063210, China
2 College of Mechanical Engineering, North China University of Science and Technology, Tangshan 063210, China; HUIDA Sanitary Ware Co., Ltd., Tangshan 063000, China