Intelligent Workload Scheduling in Distributed Computing Environment for Balance between Energy Efficiency and Performance

*Larysa Globa, Oleksandr Stryzhak, Nataliia Gvozdetska and Volodymyr Prokopets*

#### **Abstract**

Global digital transformation requires more productive large-scale distributed systems. Such systems should meet lots of requirements, such as high availability, low latency and reliability. However, new challenges become more and more important nowadays. One of them is energy efficiency of large-scale computing systems. Many service providers prefer to use cheap commodity servers in their distributed infrastructure, which makes the problem of energy efficiency even harder because of hardware inhomogeneity. In this chapter an approach to finding balance between performance and energy efficiency requirements within inhomogeneous distributed computing environment is proposed. The main idea of the proposed approach is to use each node's individual energy consumption models in order to generate distributed system scaling patterns based on the statistical daily workload and then adjust these patterns to match the current workload while using energy-aware Power Consumption and Performance Balance (PCPB) scheduling algorithm. An approach is tested using Matlab modeling. As a result of applying the proposed approach, large-scale distributed computing systems save energy while maintaining a fairly high level of performance and meeting the requirements of the service-level agreement (SLA).

**Keywords:** energy efficiency, performance, SLA, distributed computing system, scheduling, horizontal scaling

#### **1. Introduction**

Nowadays information technologies penetrate all spheres of human life. According to the Gartner Top 10 Strategic Technology Trends for 2019 [1], the new world-driving trends are going to include augmented analytics, immersive technologies, edge computing and blockchain in the nearest future. These technologies require extremely highly efficient distributed computing systems that could process large amounts of data, consuming as little resources as possible.

the paper [3], these approaches can be divided into static and dynamic in terms of decision-making process. Both static and dynamic approaches can be applied either at the hardware level or at the software level. At the same time, these approaches are also classified according to the scope (cloud environment, single server, etc.). The overall structure of approach classification proposed in [3] is depicted in

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

Since the load on computing systems usually changes dynamically (in particular, in the cloud environment), it is worth to pay attention to the dynamic approaches to power management, respectively. Thus, within this study we mainly focus on

Considering hardware-based approaches, one of the most common approaches is dynamic voltage and frequency scaling (DVFS). DVFS is a power management technique that is effective in reducing power dissipation by lowering the supply voltage [4]. DVFS is widely used to manage the energy and power consumption in modern processors; however, for DVFS to be effective, there is a need to accurately predict the performance impact of scaling a processor's voltage and frequency [5, 6]. Moreover, the implementation of hardware-based approaches may be challenging, especially when it comes to inhomogeneous systems consisting of commodity hardware. Such approaches usually require additional expenses in order to adapt the system to their use. However, hardware-based approaches are very efficient. And they might bring even more energy efficiency when used in conjunction

Among the software approaches, the most commonly used are scheduling and consolidation [7]. Scheduling approaches are aimed at distributing the workload among the servers in a way that no servers are underutilized, jobs' processing performance is high enough and, in the case of energy-aware scheduling, the power

The authors of [8] proposed the performance and energy-based cost prediction framework that dynamically supports VMs auto-scaling decision and demonstrates the trade-off between cost, power consumption and performance. This framework allows to estimate auto-scaling total cost, which is essential when using consolidation and horizontal auto-scaling approaches. Dynamic auto-scaling can be a big gain in energy efficiency, but estimating the cost of automatic scaling should not lead to excessive overhead. Thus, in some cases, it may be worthwhile to avoid constant dynamic auto-scaling and basically rely on statistics instead, while adjusting the

*Classification of power management approaches to increasing energy efficiency of computing systems [3].*

consumption of the whole computing system is minimized. Consolidation approaches concern virtualized environments and are designed to balance virtual machines (VMs) so that they can run on as few servers as possible. Idling servers are then shut down or switched to a standby mode. It means that the consolidation is

tightly coupled with horizontal scaling approaches.

scale of the system when it is really needed.

**Figure 2.**

**49**

**Figure 2**.

dynamic energy-efficient approaches.

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

with software-based techniques.

**Figure 1.** *Electricity usage of data centres 2010–2030 estimation [2].*

Electrical power is one of the most demanded resources for the large-scale distributed computing systems. Both science and industry have made tremendous efforts to reduce the power consumption of large-scale computing systems over the past 10 years. According to the Huawei Technologies Sweden estimation, presented in [2], power consumption of data centres all over the world is still going to grow in the nearest future. However, due to the newly developed techniques, we can expect much lower growth up to 2967 TWh. On the contrary, in the worst case, data centres could consume up to 7933 TWh of energy without the use of any energysaving approaches (**Figure 1**).

Although the fruitful cooperation between science and industry has already brought very good results in terms of reducing data centre power consumption, there is still a very high demand for approaches that would allow to cope with new challenges associated with the rapid development of distributed computing.

Within this study we propose an intelligent workload scheduling approach, which is aimed at improving energy efficiency of distributed computing systems through the application of energy-aware scheduling combined with scaling, taking into account data processing performance as well. An approach considers first of all inhomogeneous distributed systems designed to use cheap commodity hardware as much as possible.

The chapter is structured as follows: Section 2 contains state-of-the-art analysis of distributed computing system energy efficiency problem. Section 3 explains the problem to be solved by proposed approach. Section 4 introduces proposed intelligent workload scheduling approach efficiently combined with dynamic scaling approaches. Section 4.1 presents a model of proposed approach implementation, and Section 5 concludes the work with a summary and outlook on future work.

#### **2. State of the art and background**

Many approaches to increasing energy efficiency of the large-scale distributed computing systems (power management approaches) already exist. According to

#### *Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*

the paper [3], these approaches can be divided into static and dynamic in terms of decision-making process. Both static and dynamic approaches can be applied either at the hardware level or at the software level. At the same time, these approaches are also classified according to the scope (cloud environment, single server, etc.). The overall structure of approach classification proposed in [3] is depicted in **Figure 2**.

Since the load on computing systems usually changes dynamically (in particular, in the cloud environment), it is worth to pay attention to the dynamic approaches to power management, respectively. Thus, within this study we mainly focus on dynamic energy-efficient approaches.

Considering hardware-based approaches, one of the most common approaches is dynamic voltage and frequency scaling (DVFS). DVFS is a power management technique that is effective in reducing power dissipation by lowering the supply voltage [4]. DVFS is widely used to manage the energy and power consumption in modern processors; however, for DVFS to be effective, there is a need to accurately predict the performance impact of scaling a processor's voltage and frequency [5, 6]. Moreover, the implementation of hardware-based approaches may be challenging, especially when it comes to inhomogeneous systems consisting of commodity hardware. Such approaches usually require additional expenses in order to adapt the system to their use. However, hardware-based approaches are very efficient. And they might bring even more energy efficiency when used in conjunction with software-based techniques.

Among the software approaches, the most commonly used are scheduling and consolidation [7]. Scheduling approaches are aimed at distributing the workload among the servers in a way that no servers are underutilized, jobs' processing performance is high enough and, in the case of energy-aware scheduling, the power consumption of the whole computing system is minimized. Consolidation approaches concern virtualized environments and are designed to balance virtual machines (VMs) so that they can run on as few servers as possible. Idling servers are then shut down or switched to a standby mode. It means that the consolidation is tightly coupled with horizontal scaling approaches.

The authors of [8] proposed the performance and energy-based cost prediction framework that dynamically supports VMs auto-scaling decision and demonstrates the trade-off between cost, power consumption and performance. This framework allows to estimate auto-scaling total cost, which is essential when using consolidation and horizontal auto-scaling approaches. Dynamic auto-scaling can be a big gain in energy efficiency, but estimating the cost of automatic scaling should not lead to excessive overhead. Thus, in some cases, it may be worthwhile to avoid constant dynamic auto-scaling and basically rely on statistics instead, while adjusting the scale of the system when it is really needed.

#### **Figure 2.**

*Classification of power management approaches to increasing energy efficiency of computing systems [3].*

Electrical power is one of the most demanded resources for the large-scale distributed computing systems. Both science and industry have made tremendous efforts to reduce the power consumption of large-scale computing systems over the past 10 years. According to the Huawei Technologies Sweden estimation, presented in [2], power consumption of data centres all over the world is still going to grow in the nearest future. However, due to the newly developed techniques, we can expect much lower growth up to 2967 TWh. On the contrary, in the worst case, data centres could consume up to 7933 TWh of energy without the use of any energy-

Although the fruitful cooperation between science and industry has already brought very good results in terms of reducing data centre power consumption, there is still a very high demand for approaches that would allow to cope with new challenges associated with the rapid development of distributed computing. Within this study we propose an intelligent workload scheduling approach, which is aimed at improving energy efficiency of distributed computing systems through the application of energy-aware scheduling combined with scaling, taking into account data processing performance as well. An approach considers first of all inhomogeneous distributed systems designed to use cheap commodity hardware as

The chapter is structured as follows: Section 2 contains state-of-the-art analysis of distributed computing system energy efficiency problem. Section 3 explains the problem to be solved by proposed approach. Section 4 introduces proposed intelligent workload scheduling approach efficiently combined with dynamic scaling approaches. Section 4.1 presents a model of proposed approach implementation, and Section 5 concludes the work with a summary and outlook on future work.

Many approaches to increasing energy efficiency of the large-scale distributed computing systems (power management approaches) already exist. According to

saving approaches (**Figure 1**).

*Electricity usage of data centres 2010–2030 estimation [2].*

*Scheduling Problems - New Applications and Trends*

**2. State of the art and background**

much as possible.

**48**

**Figure 1.**

In this chapter we use this idea, and we are mainly focused on the efficient combination of horizontal scaling and energy-aware scheduling approaches. In the field of energy-aware scheduling, there are many approaches developed so far. Some of them are also aimed to combine different fundamental ideas of energy-efficient computing.

Job is the unit of computing. The component of job is called a task. Physically, one job is represented as a single computing process of a computer. Subprocesses or

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

We will use the term "job" to determine the atomic computational problem that can be located and executed on one of the computing nodes of the system (i.e. "job"

2. Jobs come to the queue at random moments of time *τ*. If the length of the queue is 0 < *l* < *Q*, the job is placed on a free space in the queue. Otherwise, the job is

4.The job may have one of the five possible states: "preparation for execution", "readiness for execution", "in process of execution", "execution successfully

• The volume of job—the number of floating-point operations that must be performed by the machine within this job (the number of floating-point operations is not natively used to measure the jobs' volume; however, we use this artificial unit to express the amount of work that is required by job to be

is the time period from the moment the job arrives at the processing, after which it must be completed. If the job has not been transferred to the state of "execution successfully completed" after the time *Δtmaxi*, it is transferred to the state of "exe-

An optimal parallelization for the task is not considered within this study. Let us

consider that the tasks are parallelized beforehand and just declared how many cores they require to be processed, as an input data for processing system.

• Minimal amount of resources required to complete the job:

◦ Minimal required number of processing cores:

◦ Minimal required volume of persistent storage:

*th* job is characterized by the following parameters:

is the unit of load distribution). The income jobs form the queue.

3. All jobs in the queue are independent to each other.

completed", and "execution interrupted".

• The maximum execution time (or timeout):

cution interrupted" and is output from the system.

◦ Minimal amount of RAM needed:

child processes in turn appear to be tasks.

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

Let us introduce the assumptions:

1. The queue consists of *Q* positions.

rejected.

5. Each *i*

performed):

*Vi* ¼ *const operations* ½ �

*Δtmaxi* ¼ *const* ½ � sec

*RAM*\_min\_*i Gb* ½ �

*k*\_*cores*\_min\_*i cores* ½ �

**51**

The authors of the paper [9] proposed adaptive energy-efficient scheduling (AES) approach which combines scheduling with the dynamic voltage scaling (DVS) technique. This approach is proposed to be used in homogeneous computing systems. It consists of two phases—in the first phase, an adaptive threshold-based task duplication strategy is used, which can adjust the optimal threshold according to the specified schedule length, network power, processor power and application; in the second phase, DVS-enabled processors that can scale down their voltages are used for processing. A proposed approach gives a gain of 31.7% in terms of energy efficiency without performance loss that is quite a good result. Within this study we also use an idea of combining scheduling approaches with other methodologies; however, the authors of [9] use DVS and are limited by using DVS-enabled hardware. Their approach is designed for homogeneous computer environments, while we are focused on inhomogeneous environments, since it makes sense for service providers to use cheap commodity hardware with different physical parameters in order to reduce capital expenses.

Another example of energy-aware scheduling approach is Min\_c [10]. This strategy takes into account the variety of tasks that comes to the computing system and the fact that the resources required by these tasks are different. The main drawback of this approach is that the model of energy consumption is the same for each node. It has nonlinear character that is close to reality, but the characteristics of different machines can differ. Therefore, we propose defining *P* ¼ *f CPU* ð Þ dependencies for each machine individually.

Within our previous research [11–13], energy-aware scheduling approach called power consumption and performance balance (PCPB) was proposed and experimentally tested. In [13] two possible modifications to the PCPB were described one of them uses tasks classification; another one applies scaling in addition to energy-aware scheduling in order to further increase energy efficiency. It was determined that developed energy-aware scheduling approach PCPB gives the best results in terms of energy efficiency (energy savings up to 33.59%) while being used in conjunction with horizontal scaling (scale-in and scale-out). Thus, in this chapter we elaborate on this basic idea and propose to enhance PCPB with scaling techniques and smartly power off and on idling servers while distributing the workload between them using PCPB.

#### **3. Problem definition**

Consider a distributed computing system consisting of *N* nodes. Each node *Nj* is described by the following:


*Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*

Job is the unit of computing. The component of job is called a task. Physically, one job is represented as a single computing process of a computer. Subprocesses or child processes in turn appear to be tasks.

We will use the term "job" to determine the atomic computational problem that can be located and executed on one of the computing nodes of the system (i.e. "job" is the unit of load distribution). The income jobs form the queue.

Let us introduce the assumptions:

In this chapter we use this idea, and we are mainly focused on the efficient combination of horizontal scaling and energy-aware scheduling approaches. In the field of energy-aware scheduling, there are many approaches developed so far. Some of them are also aimed to combine different fundamental ideas of

The authors of the paper [9] proposed adaptive energy-efficient scheduling (AES) approach which combines scheduling with the dynamic voltage scaling (DVS) technique. This approach is proposed to be used in homogeneous computing systems. It consists of two phases—in the first phase, an adaptive threshold-based task duplication strategy is used, which can adjust the optimal threshold according to the specified schedule length, network power, processor power and application; in the second phase, DVS-enabled processors that can scale down their voltages are used for processing. A proposed approach gives a gain of 31.7% in terms of energy efficiency without performance loss that is quite a good result. Within this study we also use an idea of combining scheduling approaches with other methodologies; however, the authors of [9] use DVS and are limited by using DVS-enabled hardware. Their approach is designed for homogeneous computer environments, while we are focused on inhomogeneous environments, since it makes sense for service providers to use cheap commodity hardware with different physical parameters in

Another example of energy-aware scheduling approach is Min\_c [10]. This strategy takes into account the variety of tasks that comes to the computing system and the fact that the resources required by these tasks are different. The main drawback of this approach is that the model of energy consumption is the same for each node. It has nonlinear character that is close to reality, but the characteristics

Within our previous research [11–13], energy-aware scheduling approach called power consumption and performance balance (PCPB) was proposed and experimentally tested. In [13] two possible modifications to the PCPB were described one of them uses tasks classification; another one applies scaling in addition to energy-aware scheduling in order to further increase energy efficiency. It was determined that developed energy-aware scheduling approach PCPB gives the best results in terms of energy efficiency (energy savings up to 33.59%) while being used in conjunction with horizontal scaling (scale-in and scale-out). Thus, in this chapter we elaborate on this basic idea and propose to enhance PCPB with scaling techniques and smartly power off and on idling servers while distributing the workload

Consider a distributed computing system consisting of *N* nodes. Each node *Nj* is

—the productivity of the node *Nj*, which has *k*\_*coresj* of the computing

—the power consumption function of the node, which is

of different machines can differ. Therefore, we propose defining

*P* ¼ *f CPU* ð Þ dependencies for each machine individually.

energy-efficient computing.

*Scheduling Problems - New Applications and Trends*

order to reduce capital expenses.

between them using PCPB.

**3. Problem definition**

described by the following:

• *flopsj*

**50**

cores

• *Pj* ¼ *f CPUj*

• *Vj*—the amount of available RAM

experimentally determined for each *Nj*

	- The volume of job—the number of floating-point operations that must be performed by the machine within this job (the number of floating-point operations is not natively used to measure the jobs' volume; however, we use this artificial unit to express the amount of work that is required by job to be performed):

*Vi* ¼ *const operations* ½ �

• The maximum execution time (or timeout):

*Δtmaxi* ¼ *const* ½ � sec

is the time period from the moment the job arrives at the processing, after which it must be completed. If the job has not been transferred to the state of "execution successfully completed" after the time *Δtmaxi*, it is transferred to the state of "execution interrupted" and is output from the system.

	- Minimal amount of RAM needed:

*RAM*\_min\_*i Gb* ½ �

◦ Minimal required number of processing cores:

### *k*\_*cores*\_min\_*i cores* ½ �

An optimal parallelization for the task is not considered within this study. Let us consider that the tasks are parallelized beforehand and just declared how many cores they require to be processed, as an input data for processing system.

◦ Minimal required volume of persistent storage:

1. To define experimentally individual dependencies *Pj* ¼ *f CPUj*

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

criteria from the best one to the worst one.

of active nodes of the system) such that:

consumption of the system.

the workload in the system.

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

by SLA.

above.

100%.

(Eq. (1)).

**53**

*Pj CPUj*

**4.1 Individual** *Pj* ¼ *f CPUj*

interpolation [15].

As a result, *Pj* ¼ *f CPUj*

<sup>¼</sup> *<sup>a</sup>* <sup>∗</sup>*CPU*<sup>4</sup>

consumption functions *Pj* ¼ *f CPUj*

computing nodes of the system as power consumption functions. Having power consumption functions and performance value of each node, to range all nodes according to their integrated performance and power consumption

2. To use energy-aware PCPB scheduling approach proposed in [11] to distribute

patterns describing the state of the computer system (in particular the number

• The probability of job loss is minimized and is less than what is required

• Total energy consumption of the system is minimized. Individual functions of power consumption are used to define the total energy

Scale the system horizontally with the respect of defined patterns. Patterns should

4.To detect the deviation of the current workload from the statistical one and adjust scaling patterns dynamically for the fulfillment of the conditions listed

**dependencies definition**

As the first step of the approach, it is proposed to define individual power

• An appropriate stress test is chosen in order to load each node's CPU from 0 to

• A power consumption of each node is measured for a set of CPU utilization levels (this can be done using special hardware (multimeter/wattmeter) or software that also evaluates power consumption according to computer hardware models. It is recommended to use hardware measurement tools as

functions are obtained in a form of polynomials

*<sup>j</sup>* <sup>þ</sup> *<sup>d</sup>* <sup>∗</sup>*CPU*<sup>1</sup>

*<sup>j</sup>* <sup>þ</sup> *<sup>e</sup>* <sup>∗</sup>*CPU*<sup>0</sup>

*<sup>j</sup>* (1)

*<sup>j</sup>* <sup>þ</sup> *<sup>c</sup>* <sup>∗</sup>*CPU*<sup>2</sup>

• An analytical function is obtained from the experimental data using

for each node of the system. This process is

3. On the basis of the daily workload statistics, to determine a set of scaling

• Workload is processed with sufficient performance.

be formed only once on the basis of long-term workload statistics.

described in details in [12]. In a nutshell, it is done as follows:

they provide higher measurement accuracy).

*<sup>j</sup>* <sup>þ</sup> *<sup>b</sup>* <sup>∗</sup>*CPU*<sup>3</sup>

for all

**Figure 3.** *Workload statistic for the Google web search service (11 March 2019) [14].*

*storage*\_min\_*i Gb* ½ �

• Job's priority is an optional numeric parameter that can be set for a job and

determine the priority of its execution in comparison with other jobs. Let the priority *priorityi* be determined by an integer from 1 to 10. In this case, priority processing requires tasks with priority 1. Let the default value of the priority of the job be 10 units.

Consider the daily workload curve to be a part of an input data for the problem. Every service provider is able to gather the daily statistics of the workload in his computing system. As a result, the pattern of the day workload can be generated. For example, Google provides such statistics of using its web search service in the Transparency Report [14] (**Figure 3**).

Under the certain circumstances (holidays, festivals, special events, etc.), this pattern can be changed. It means that it is possible to create certain system configuration patterns for the stable workload, respectively, but there is a need to adapt the system in the case of changes being foreseen.

Given an input data, the problem is formulated as follows: to reduce total power consumption of considered computing system while increasing the performance of data processing and meeting service-level agreement (SLA) requirements.

#### **4. Proposed approach**

Within the previous studies [11–13], it was determined that the use of energyaware scheduling is most effective when used in conjunction with consolidation approaches and further scaling the whole system in and out. In [13] it was shown that powering off idle servers could save up to 33.59% of the energy in the considered computing cluster.

Within the current study, the system model and main idea of proposed approach were modified and can be described as follows:

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*

	- The probability of job loss is minimized and is less than what is required by SLA.
	- Workload is processed with sufficient performance.
	- Total energy consumption of the system is minimized. Individual functions of power consumption are used to define the total energy consumption of the system.

Scale the system horizontally with the respect of defined patterns. Patterns should be formed only once on the basis of long-term workload statistics.

4.To detect the deviation of the current workload from the statistical one and adjust scaling patterns dynamically for the fulfillment of the conditions listed above.

#### **4.1 Individual** *Pj* ¼ *f CPUj* **dependencies definition**

As the first step of the approach, it is proposed to define individual power consumption functions *Pj* ¼ *f CPUj* for each node of the system. This process is described in details in [12]. In a nutshell, it is done as follows:


As a result, *Pj* ¼ *f CPUj* functions are obtained in a form of polynomials (Eq. (1)).

$$P\_j(\text{CPU}\_j) = a \ast \text{CPU}\_j^4 + b \ast \text{CPU}\_j^3 + c \ast \text{CPU}\_j^2 + d \ast \text{CPU}\_j^1 + e \ast \text{CPU}\_j^0 \tag{1}$$

*storage*\_min\_*i Gb* ½ �

**Figure 3.**

the priority of the job be 10 units.

*Scheduling Problems - New Applications and Trends*

*Workload statistic for the Google web search service (11 March 2019) [14].*

the system in the case of changes being foreseen.

were modified and can be described as follows:

Transparency Report [14] (**Figure 3**).

requirements.

**52**

**4. Proposed approach**

considered computing cluster.

• Job's priority is an optional numeric parameter that can be set for a job and

Consider the daily workload curve to be a part of an input data for the problem. Every service provider is able to gather the daily statistics of the workload in his computing system. As a result, the pattern of the day workload can be generated. For example, Google provides such statistics of using its web search service in the

Under the certain circumstances (holidays, festivals, special events, etc.), this pattern can be changed. It means that it is possible to create certain system configuration patterns for the stable workload, respectively, but there is a need to adapt

Given an input data, the problem is formulated as follows: to reduce total power consumption of considered computing system while increasing the performance of data processing and meeting service-level agreement (SLA)

Within the previous studies [11–13], it was determined that the use of energyaware scheduling is most effective when used in conjunction with consolidation approaches and further scaling the whole system in and out. In [13] it was shown that powering off idle servers could save up to 33.59% of the energy in the

Within the current study, the system model and main idea of proposed approach

determine the priority of its execution in comparison with other jobs. Let the priority *priorityi* be determined by an integer from 1 to 10. In this case, priority processing requires tasks with priority 1. Let the default value of

where *a, b, c, d* and *e* are fourth degree polynomial coefficients, defined within interpolation process. An example of the *Pj* ¼ *f CPUj* � � curves obtained for five computing nodes is presented in **Figure 4**.

Having *Pj* ¼ *f CPUj* � � functions and performance values *flopsj* (in FLOPS) for all nodes in the system, we can range them from the worst one to the best one as follows:

1. For each node calculate the area under power consumption curve using Eq. (2).

$$\mathcal{S}\_{\dot{j}} = \bigcap\_{0}^{100} P\_{\dot{j}}(\mathcal{C}PU\_{\dot{j}})d\mathcal{C}PU\_{\dot{j}},\tag{2}$$

scheduler is to use individual power consumption functions *Pj* ¼ *f CPUj*

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

flatter when the load changes from 75 to 100%).

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

processing to the node *Nj* in the moment *τ<sup>k</sup>* (Eq. (3)):

scheduling the next job in a queue.

moment τ*<sup>k</sup>*�<sup>1</sup> and Δ*Pij*∣τ*<sup>k</sup>* ¼ *f CPUj*j*τ<sup>k</sup>*

according to their performance value *flopsj*

the execution (Step 2).

**Figure 5.**

**55**

*PCPB scheduling algorithm.*

The PCPB scheduling algorithm is described by **Figure 5**.

*P*Σ*<sup>i</sup>* τ*k*&*Nj* ¼ *P<sup>Σ</sup>* 

case of *jobi* being allocated to the node *Nj* at the moment *τk*. After that the nodes are sorted according to the current *P*Σ*<sup>i</sup>*

detailed description of PCPB approach is presented in [11]).

the scheduling process in order to determine dynamically, on which node the task is going to consume less power. This approach considers performance criteria as well. The main idea of approach is similar to that one described for the nodes' ranging; however, in PCPB the current state of computing nodes is considered. As it possible to see in **Figure 4**, the increase in energy consumption at different levels of CPU load is different (the curves grow steeper when the load changes from 0 to 25% and

Scheduler gathers the data regarding current load of the nodes in a system. In Step 1 it evaluates the CPU utilization of each node at the time moment *τk*�1, before

Having the knowledge on how many resources the *jobi* requires, scheduler excludes those nodes that currently do not have enough RAM or cores available for

In Step 3 scheduler calculates the theoretical total power that is going to be consumed by the whole computing system supposing that *jobi* is given for the

where PΣ∣τ*<sup>k</sup>*�<sup>1</sup> is the total power consumption of the whole system at the

tion in both sorted lists. The job is allocated to the node with the maximal mark (the

within

τ*<sup>k</sup>*�<sup>1</sup> þ Δ*Pij*∣τ*k,* (3)

. The nodes get the mark for their posi-

∣τk&*Nj* values and

is the increase of power consumption, in the

In Eq. (2) CPU load is expressed as a percentage from 0 to 100%.

2. Sort all nodes by their *Sj* value in descending order.


Thus, using this simple approach, we are able to form sorted list of nodes in order to make a decision, in which the node is the most inefficient one and should be switched off first during scale-in process (**Figure 4**). Obviously, this only makes sense for inhomogeneous systems where nodes are different from each other and can be sorted.

#### **4.2 Basic scheduling scheme**

As a basic scheduler in a system, it is proposed to use PCPB energy-aware scheduler that was proposed and further developed in [11–13]. The main idea of this

#### **Figure 4.**

*Sorted list of five nodes according to their integrated performance and power consumption criteria and their Pj* ¼ *f CPUj* � � *curves obtained experimentally.*

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*

scheduler is to use individual power consumption functions *Pj* ¼ *f CPUj* within the scheduling process in order to determine dynamically, on which node the task is going to consume less power. This approach considers performance criteria as well. The main idea of approach is similar to that one described for the nodes' ranging; however, in PCPB the current state of computing nodes is considered. As it possible to see in **Figure 4**, the increase in energy consumption at different levels of CPU load is different (the curves grow steeper when the load changes from 0 to 25% and flatter when the load changes from 75 to 100%).

The PCPB scheduling algorithm is described by **Figure 5**.

Scheduler gathers the data regarding current load of the nodes in a system. In Step 1 it evaluates the CPU utilization of each node at the time moment *τk*�1, before scheduling the next job in a queue.

Having the knowledge on how many resources the *jobi* requires, scheduler excludes those nodes that currently do not have enough RAM or cores available for the execution (Step 2).

In Step 3 scheduler calculates the theoretical total power that is going to be consumed by the whole computing system supposing that *jobi* is given for the processing to the node *Nj* in the moment *τ<sup>k</sup>* (Eq. (3)):

$$P\_{\Sigma\_i} \vert \pi\_k \& \mathcal{N}\_j = P\_{\Sigma} \vert \pi\_{k-1} + \Delta P\_{\vec{\eta}} \vert \pi\_k \tag{3}$$

where PΣ∣τ*<sup>k</sup>*�<sup>1</sup> is the total power consumption of the whole system at the moment τ*<sup>k</sup>*�<sup>1</sup> and Δ*Pij*∣τ*<sup>k</sup>* ¼ *f CPUj*j*τ<sup>k</sup>* is the increase of power consumption, in the case of *jobi* being allocated to the node *Nj* at the moment *τk*.

After that the nodes are sorted according to the current *P*Σ*<sup>i</sup>* ∣τk&*Nj* values and according to their performance value *flopsj* . The nodes get the mark for their position in both sorted lists. The job is allocated to the node with the maximal mark (the detailed description of PCPB approach is presented in [11]).

**Figure 5.** *PCPB scheduling algorithm.*

where *a, b, c, d* and *e* are fourth degree polynomial coefficients, defined within

1. For each node calculate the area under power consumption curve using Eq. (2).

*Pj CPUj*

3. Sort all nodes by their *flopsj* value (performance metric) in ascending order.

4.Grant each node with a mark that equals the sum of the node positions in two sorted arrays. The node with the highest mark is considered to be the best one.

Thus, using this simple approach, we are able to form sorted list of nodes in order to make a decision, in which the node is the most inefficient one and should be switched off first during scale-in process (**Figure 4**). Obviously, this only makes sense for inhomogeneous systems where nodes are different from each other and

As a basic scheduler in a system, it is proposed to use PCPB energy-aware scheduler that was proposed and further developed in [11–13]. The main idea of this

*Sorted list of five nodes according to their integrated performance and power consumption criteria and their*

nodes in the system, we can range them from the worst one to the best one as

� � functions and performance values *flopsj* (in FLOPS) for all

� � curves obtained for five

� �*dCPUj,* (2)

interpolation process. An example of the *Pj* ¼ *f CPUj*

*Sj* ¼

2. Sort all nodes by their *Sj* value in descending order.

100 ð

0

In Eq. (2) CPU load is expressed as a percentage from 0 to 100%.

computing nodes is presented in **Figure 4**.

*Scheduling Problems - New Applications and Trends*

Having *Pj* ¼ *f CPUj*

follows:

can be sorted.

**Figure 4.**

**54**

*Pj* ¼ *f CPUj*

� � *curves obtained experimentally.*

**4.2 Basic scheduling scheme**

#### **4.3 System state pattern determination**

Since within previous research [13], it was determined that energy-aware scheduling gives the best results in terms of energy efficiency while being used in conjunction with horizontal scaling; let us define the optimal system scale patterns in a form of set *n; tstart; t* f g *end* , where *n* is a number of active computing nodes in the system and *tstart; t* f g *end* denotes the boundaries of time interval of the day, during which these patterns remain optimal. These patterns are formed with respect to the power consumption and job loss probability metrics. In order to find an optimal pattern for each time interval, it is a need to determine these two metrics as functions of number of active nodes in the system.

The certain level of system availability for service user is guaranteed by the SLA as the probability that service will be available (i.e. the user's job will be served) when it is requested. Let the probability of the job loss required by SLA be defined as in Eq. (4):

$$p\_{\text{loss}\_{\text{SLA}}} = \mathbf{1} - p\_{\text{SLA}} \tag{4}$$

• Queue length: *Q* jobs or *k* ∗ *Q* queueing system requests

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

Serving discipline is basically defined by scheduler that is being used. In considered case, using PCPB, the jobs are selected from the queue according to the first-

The mean arrival rate can be defined on the basis of the workload statistics as it

However, in order to build a model, it is worthy to operate with the value *λTmax* that is the maximal value of load during the period *T* (*T* defines the time of one

In general case, in order to evaluate the service rate for a particular server of the system, it is necessary to determine the average number of requests that leave the server after a successful processing per time unit. This is a random value; within this study we will consider service rate to be determined experimentally (on the basis of statistic of load processing for a particular system) and defined by its mean value μ*avg* . In this case, the model is actually simplified, but still allows us to estimate the general relationship between the probability of loss and the number of nodes in the system.

To define the probability of job loss, *ploss* ¼ *f n*ð Þ as the function of the number of active servers *n* (nodes of computing system), such that 2 < *n* < *N,* where *N* is the

The probability of loss for the queueing system with a finite queue is defined by

*n*0

occupied servers, and *Sn*<sup>0</sup>

þk*Q*

<sup>þ</sup><sup>1</sup> � *Sn*<sup>0</sup>

!*n*0*kQ* (6)

<sup>þ</sup>*kQ* denotes

This system can be represented with a Markov chain (**Figure 6**), where *S*<sup>0</sup> denotes the state of the system, when 0 servers are occupied and the queue is

*ploss* <sup>¼</sup> *<sup>p</sup>*<sup>0</sup> <sup>∗</sup> <sup>ρ</sup>*<sup>n</sup>*<sup>0</sup>

all servers are occupied and some requests are placed to a queue.

• Service discipline:

in-first-out (FIFO) discipline.

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

• *The mean arrival rate:*

• *The mean service rate:*

**Queueing system problem:**

Eq. (6) [16]:

where

**Figure 6.**

**57**

*System model as a Markov chain.*

total number of nodes in the system.

empty, *S*<sup>1</sup> � *Sn*<sup>0</sup> denotes there are 1 *to n*<sup>0</sup>

is done in Eq. (5).

pattern validity).

where *PSLA* is guaranteed by SLA probability that the job will be served.

The more nodes available in the system, the less likely it is that a new incoming task will find the system in a state where all nodes and the queue are fully loaded. It means that the probability of job loss depends on the number of available nodes in computing system and can be presented as a function *ploss* ¼ *f n*ð Þ, where *n* is the number of active nodes in the system.

Thus, the purpose of scaling patterns is to answer the question: How many active nodes does the system need to have in order to fulfill the requirements to *ploss* and minimize total power consumption *PΣ*?

In order to estimate the dependency between the probability of job loss *ploss* and number of active nodes *n,* consider the queueing system with a finite queue*:* The basic concepts of queuing theory are requests (or customers) and servers [16]. The natural way of modeling considered system as a queueing system would be to treat jobs as requests and computing nodes as servers. However, in this case we would have to eliminate the fact that the job may be served by several cores of one server and one server may serve several jobs simultaneously as well. These facts bring the certain complexity to the queueing system modeling. To be more precise, consider one computing core to be a server in terms of queueing system. In order to model input workload as requests of queueing system, we introduce a correction factor *k* ¼ *cores*min*avg* that denotes how many cores in average are requested by an input job. Using this correction factor, we can represent an input workload as a number of queueing system requests per time unit [Eq. (5)]:

$$
\lambda(t) = k \ast \lambda\_{\text{stat}}(t), \tag{5}
$$

where *λstat*ð Þ*t* is the statistical workload represented as a number of computational jobs.

#### **Input data for queuing system:**


*Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*


**4.3 System state pattern determination**

*Scheduling Problems - New Applications and Trends*

functions of number of active nodes in the system.

number of active nodes in the system.

minimize total power consumption *PΣ*?

queueing system requests per time unit [Eq. (5)]:

• Number of active servers in the system:

where *kcorej* is the number of cores of *j*

computational jobs.

**56**

**Input data for queuing system:**

• *<sup>n</sup>* computing nodes or *<sup>n</sup>*<sup>0</sup> <sup>¼</sup> <sup>∑</sup>*<sup>n</sup>*

where *λstat*ð Þ*t* is the statistical workload represented as a number of

as in Eq. (4):

Since within previous research [13], it was determined that energy-aware scheduling gives the best results in terms of energy efficiency while being used in conjunction with horizontal scaling; let us define the optimal system scale patterns in a form of set *n; tstart; t* f g *end* , where *n* is a number of active computing nodes in the system and *tstart; t* f g *end* denotes the boundaries of time interval of the day, during which these patterns remain optimal. These patterns are formed with respect to the power consumption and job loss probability metrics. In order to find an optimal pattern for each time interval, it is a need to determine these two metrics as

The certain level of system availability for service user is guaranteed by the SLA as the probability that service will be available (i.e. the user's job will be served) when it is requested. Let the probability of the job loss required by SLA be defined

where *PSLA* is guaranteed by SLA probability that the job will be served.

The more nodes available in the system, the less likely it is that a new incoming task will find the system in a state where all nodes and the queue are fully loaded. It means that the probability of job loss depends on the number of available nodes in computing system and can be presented as a function *ploss* ¼ *f n*ð Þ, where *n* is the

Thus, the purpose of scaling patterns is to answer the question: How many active nodes does the system need to have in order to fulfill the requirements to *ploss* and

In order to estimate the dependency between the probability of job loss *ploss* and number of active nodes *n,* consider the queueing system with a finite queue*:* The basic concepts of queuing theory are requests (or customers) and servers [16]. The natural way of modeling considered system as a queueing system would be to treat jobs as requests and computing nodes as servers. However, in this case we would have to eliminate the fact that the job may be served by several cores of one server and one server may serve several jobs simultaneously as well. These facts bring the certain complexity to the queueing system modeling. To be more precise, consider one computing core to be a server in terms of queueing system. In order to model input workload as requests of queueing system, we introduce a correction factor *k* ¼ *cores*min*avg* that denotes how many cores in average are requested by an input job. Using this correction factor, we can represent an input workload as a number of

*plossSLA* ¼ 1 � *pSLA* (4)

*λ*ðÞ¼ *t k* ∗ *λstat*ð Þ*t ,* (5)

*<sup>j</sup>*¼<sup>1</sup>*kcorej* servers in terms of queueing system,

*th* node.

Serving discipline is basically defined by scheduler that is being used. In considered case, using PCPB, the jobs are selected from the queue according to the firstin-first-out (FIFO) discipline.

• *The mean arrival rate:*

The mean arrival rate can be defined on the basis of the workload statistics as it is done in Eq. (5).

However, in order to build a model, it is worthy to operate with the value *λTmax* that is the maximal value of load during the period *T* (*T* defines the time of one pattern validity).

• *The mean service rate:*

In general case, in order to evaluate the service rate for a particular server of the system, it is necessary to determine the average number of requests that leave the server after a successful processing per time unit. This is a random value; within this study we will consider service rate to be determined experimentally (on the basis of statistic of load processing for a particular system) and defined by its mean value μ*avg* . In this case, the model is actually simplified, but still allows us to estimate the general relationship between the probability of loss and the number of nodes in the system.

#### **Queueing system problem:**

To define the probability of job loss, *ploss* ¼ *f n*ð Þ as the function of the number of active servers *n* (nodes of computing system), such that 2 < *n* < *N,* where *N* is the total number of nodes in the system.

This system can be represented with a Markov chain (**Figure 6**), where *S*<sup>0</sup> denotes the state of the system, when 0 servers are occupied and the queue is empty, *S*<sup>1</sup> � *Sn*<sup>0</sup> denotes there are 1 *to n*<sup>0</sup> occupied servers, and *Sn*<sup>0</sup> <sup>þ</sup><sup>1</sup> � *Sn*<sup>0</sup> <sup>þ</sup>*kQ* denotes all servers are occupied and some requests are placed to a queue.

The probability of loss for the queueing system with a finite queue is defined by Eq. (6) [16]:

$$p\_{loss} = p\_0 \* \frac{\rho^{n'+kQ}}{n'!n'^{kQ}} \tag{6}$$

where

**Figure 6.** *System model as a Markov chain.*

$$p\_0 = \left(\mathbf{1} + \frac{\rho}{\mathbf{1}!} + \frac{\rho^2}{2!} + \dots + \frac{\rho^{\mathbf{n}'}}{\mathbf{n}'!} + \frac{\rho^{\mathbf{n}'+1}}{\mathbf{n}'\*\mathbf{n}'!} \* \frac{\left(\mathbf{1} - \left(\frac{\rho}{\mathbf{n}'}\right)^{\mathbf{k}\mathbf{Q}}\right)}{\mathbf{1} - \frac{\rho}{\mathbf{n}'}}\right)^{-1}$$

$$\rho = \lambda\_{T\text{max}}/\mu\_{\text{avg}}$$

There is another more generalized approach to evaluate power consumption of system nodes. Usually, servers are kept to be utilized at some average level *CPUavgj* that may be defined statistically for each system. It is actually more precise solution in comparison with analytical definition of CPU utilization that depends on scheduling being used and incoming load. For the whole system, total power consump-

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

*Pj CPUavgj*

is the individual functions of nodes' power consumption.

The mathematical models of total power consumption and loss probability mentioned above lead us to the optimization problem that can be formulated as follows: To define an optimal number of active nodes of the distributed computing system *n,* the objective function (Eq. (10)) is minimized subject to Eq. (11).

*Pj CPUavgj*

þk*Q*

To solve this problem, we need to choose the time intervals *T* for which we will create the patterns. Since patterns are created statically on the basis of statistical workload, it is possible to define the time moments, when thresholds are achieved so that *ploss* ¼ *plossSLA*. When it happens there is a need to increase the number of nodes (thus, to change the pattern). In case the load is decreasing, it is possible to define the moment when *P<sup>Σ</sup>* is not minimal anymore for the current statistical load. The above problem solved for each time interval *T* would allow to determine the

optimal number of processing nodes *n* for each time interval depending on the

number of nodes of the system for periods of the day. These patterns may be created once for the regular workload and be corrected during further system operation. Since the dependencies of energy consumption and loss probability from the number of active nodes in system are already defined, it requires only minimal

**4.4 Deviations from patterns detection and system reconfiguration**

for the next chosen time period and reconfigure the system, respectively.

In order to cope with unpredictable service workload deviations that can be caused by different reasons (e.g. holidays, special events, etc.), there is a need to detect significant deviations from the statistic workload curve, predict the workload

On the basis of the obtained values of *n, T*, it is possible to create patterns for the

incoming load. Meanwhile, the following conditions will be fulfilled:

1. Energy consumption of the system will be minimal.

2. Job loss probability will meet the SLA requirements.

effort to adapt the system to a new workload pattern.

*,* (9)

! *min* (10)

!*n*0*kQ* <sup>&</sup>lt; *plossSLA,* 1 < *<sup>n</sup>* <sup>&</sup>lt; *<sup>N</sup>* (11)

*P<sup>Σ</sup>* ¼ ∑ *n j*¼1

*P<sup>Σ</sup>* ¼ ∑ *n j*¼1

> *λTmax* <sup>μ</sup>*avg <sup>n</sup>*<sup>0</sup>

> > *n*0

*ploss* ¼ *p*<sup>0</sup> ∗

tion is then defined by Eq. (9):

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

where *Pj CPUavgj*

subject to:

**59**

*n*0 —number of servers in queueing system.

*kQ*—length of the queue.

Thus, the simplified model described above allows us to estimate the dependency between the number of nodes of the system and probability of the loss. This model should be precisely adjusted to each real system, but the general principle may still stay the same.

Let us estimate the power consumption of the system in order to find an optimal number of nodes so that the power consumption is minimized and probability of loss does not exceed the permissible by SLA value.

As the first step, we defined individual functions of power consumption *Pj* ¼ *f CPUj* � � for each node in the system. These functions may be formally represented in the form of polynomials (Eq. (1)).

The total power consumption of the whole system (as a sum of nodes' individual power consumptions) depends on the load that is being processed by the nodes. We have the daily workload on the system as an input data. However, according to the system model, current load of each system node highly depends on the scheduling technique.

Initially, input workload is represented as a "number of jobs per time unit". Each job may differ computationally and can be evaluated by its maximal execution time or job volume (as a number of floating-point operations). For the sake of simplicity, let us consider the static situation in some point of time, when we have *k* jobs that would totally fit to the processing nodes. Assume that these jobs in total form the load to the system of ∑*<sup>k</sup> <sup>i</sup>*¼<sup>1</sup>*Vi*½ � *operations :* In this case, scheduler will schedule these jobs accordingly to its policy. In the simplest case, if round-robin fair scheduler is used [17], it would schedule tasks in a way that each node would get an average *<sup>s</sup>* <sup>¼</sup> <sup>∑</sup>*<sup>k</sup> <sup>i</sup>*¼<sup>1</sup>*Vi <sup>n</sup>* of load. Let *s* be a scheduler coefficient, which should be defined for each concrete scheduler. In the case of using round-robin, the dependency of power

consumption of the node from its load can be formulated as Eq. (7):

$$P\_{\bar{f}} = f(CPU) = f\left(\frac{\sum\_{i=1}^{k} V\_i}{n} \ast C\right) = a \ast \left(\frac{\sum\_{i=1}^{k} V\_i}{n} \ast C\right)^4 + b \ast \left(\frac{\sum\_{i=1}^{k} V\_i}{n} \ast C\right)^3 + c \ast \left(\frac{\sum\_{i=1}^{k} V\_i}{n} \ast C\right)^2,\tag{7}$$

$$\ast \left(\frac{\sum\_{i=1}^{k} V\_i}{n} \ast C\right)^2 + d \ast \left(\frac{\sum\_{i=1}^{k} V\_i}{n} \ast C\right)^1 + e \ast \left(\frac{\sum\_{i=1}^{k} V\_i}{n} \ast C\right)^0,$$

where *C* is a constant, which expresses how the input load is converted into a CPU load in percentages. And for the more general case, Eq. (7) is transformed into Eq. (8):

$$\begin{aligned} P\_j = f(CPU) = f(\mathbf{s} \ast \mathbf{C}) &= a \ast (\mathbf{s} \ast \mathbf{C})^4 + b \ast (\mathbf{s} \ast \mathbf{C})^3 + \\ &+ c \ast \left(\mathbf{s} \ast \mathbf{C}\right)^2 + d \ast \left(\mathbf{s} \ast \mathbf{C}\right)^1 + e \ast \left(\mathbf{s} \ast \mathbf{C}\right)^0 \end{aligned} \tag{8}$$

This formula is very simplified though. Depending on scheduler being used, the load of the system's nodes may be different.

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*

There is another more generalized approach to evaluate power consumption of system nodes. Usually, servers are kept to be utilized at some average level *CPUavgj* that may be defined statistically for each system. It is actually more precise solution in comparison with analytical definition of CPU utilization that depends on scheduling being used and incoming load. For the whole system, total power consumption is then defined by Eq. (9):

$$P\_{\Sigma} = \sum\_{j=1}^{n} P\_j \left( \mathbf{CPU}\_{\text{avg}\_j} \right), \tag{9}$$

where *Pj CPUavgj* is the individual functions of nodes' power consumption.

The mathematical models of total power consumption and loss probability mentioned above lead us to the optimization problem that can be formulated as follows:

To define an optimal number of active nodes of the distributed computing system *n,* the objective function (Eq. (10)) is minimized subject to Eq. (11).

$$P\_{\Sigma} = \sum\_{j=1}^{n} P\_j \left( \text{CPU}\_{\text{avg}\_j} \right) \to \min \tag{10}$$

subject to:

*<sup>p</sup>*<sup>0</sup> <sup>¼</sup> <sup>1</sup> <sup>þ</sup> <sup>ρ</sup>

*kQ*—length of the queue.

may still stay the same.

load to the system of ∑*<sup>k</sup>*

*Pj* <sup>¼</sup> *f CPU* ð Þ¼ *<sup>f</sup>* <sup>∑</sup>*<sup>k</sup>*

*<sup>i</sup>*¼<sup>1</sup>*Vi <sup>n</sup>* <sup>∗</sup>*<sup>C</sup>* !

load of the system's nodes may be different.

<sup>∗</sup> <sup>∑</sup>*<sup>k</sup> <sup>i</sup>*¼<sup>1</sup>*Vi <sup>n</sup>* <sup>∗</sup>*<sup>C</sup>* !<sup>2</sup>

*n*0

*Pj* ¼ *f CPUj*

technique.

*<sup>s</sup>* <sup>¼</sup> <sup>∑</sup>*<sup>k</sup> <sup>i</sup>*¼<sup>1</sup>*Vi*

Eq. (8):

**58**

0 @

*Scheduling Problems - New Applications and Trends*

1! þ ρ2 2!

—number of servers in queueing system.

loss does not exceed the permissible by SLA value.

represented in the form of polynomials (Eq. (1)).

<sup>þ</sup> … <sup>þ</sup> <sup>ρ</sup>n<sup>0</sup> *n*0 ! <sup>þ</sup> <sup>ρ</sup>n<sup>0</sup> þ1 n<sup>0</sup> ∗ n<sup>0</sup> ! ∗

*ρ* ¼ *λTmax=*μ*avg*

Thus, the simplified model described above allows us to estimate the dependency between the number of nodes of the system and probability of the loss. This model should be precisely adjusted to each real system, but the general principle

Let us estimate the power consumption of the system in order to find an optimal number of nodes so that the power consumption is minimized and probability of

The total power consumption of the whole system (as a sum of nodes' individual power consumptions) depends on the load that is being processed by the nodes. We have the daily workload on the system as an input data. However, according to the system model, current load of each system node highly depends on the scheduling

Initially, input workload is represented as a "number of jobs per time unit". Each job may differ computationally and can be evaluated by its maximal execution time or job volume (as a number of floating-point operations). For the sake of simplicity, let us consider the static situation in some point of time, when we have *k* jobs that would totally fit to the processing nodes. Assume that these jobs in total form the

jobs accordingly to its policy. In the simplest case, if round-robin fair scheduler is used [17], it would schedule tasks in a way that each node would get an average

concrete scheduler. In the case of using round-robin, the dependency of power

consumption of the node from its load can be formulated as Eq. (7):

<sup>¼</sup> *<sup>a</sup>* <sup>∗</sup> <sup>∑</sup>*<sup>k</sup>*

<sup>þ</sup> *<sup>d</sup>* <sup>∗</sup> <sup>∑</sup>*<sup>k</sup>*

*<sup>n</sup>* of load. Let *s* be a scheduler coefficient, which should be defined for each

*<sup>i</sup>*¼<sup>1</sup>*Vi <sup>n</sup>* <sup>∗</sup>*<sup>C</sup>* !<sup>4</sup>

*<sup>i</sup>*¼<sup>1</sup>*Vi <sup>n</sup>* <sup>∗</sup>*<sup>C</sup>* !<sup>1</sup>

where *C* is a constant, which expresses how the input load is converted into a CPU load in percentages. And for the more general case, Eq. (7) is transformed into

This formula is very simplified though. Depending on scheduler being used, the

*Pj* <sup>¼</sup> *f CPU* ð Þ¼ *f s*ð Þ¼ <sup>∗</sup>*<sup>C</sup> <sup>a</sup>* <sup>∗</sup> ð Þ <sup>s</sup> <sup>∗</sup>*<sup>C</sup>* <sup>4</sup> <sup>þ</sup> *<sup>b</sup>* <sup>∗</sup> ð Þ <sup>s</sup> <sup>∗</sup>*<sup>C</sup>* <sup>3</sup>

*<sup>i</sup>*¼<sup>1</sup>*Vi*½ � *operations :* In this case, scheduler will schedule these

<sup>þ</sup> *<sup>b</sup>* <sup>∗</sup> <sup>∑</sup>*<sup>k</sup>*

<sup>þ</sup> *<sup>e</sup>* <sup>∗</sup> <sup>∑</sup>*<sup>k</sup>*

<sup>þ</sup> *<sup>c</sup>* <sup>∗</sup> ð Þ <sup>s</sup> <sup>∗</sup>*<sup>C</sup>* <sup>2</sup> <sup>þ</sup> *<sup>d</sup>* <sup>∗</sup> ð Þ *<sup>s</sup>* <sup>∗</sup>*<sup>C</sup>* <sup>1</sup> <sup>þ</sup> *<sup>e</sup>* <sup>∗</sup> ð Þ <sup>s</sup> <sup>∗</sup>*<sup>C</sup>* <sup>0</sup> (8)

*<sup>i</sup>*¼<sup>1</sup>*Vi <sup>n</sup>* <sup>∗</sup>*<sup>C</sup>* !<sup>3</sup>

*<sup>i</sup>*¼<sup>1</sup>*Vi <sup>n</sup>* <sup>∗</sup>*<sup>C</sup>* !<sup>0</sup>

þ

þ *c* ∗

(7)

*,*

As the first step, we defined individual functions of power consumption

� � for each node in the system. These functions may be formally

<sup>1</sup> � <sup>ρ</sup> n0 � �kQ � �

> <sup>1</sup> � <sup>ρ</sup> n0

1 A

�1

$$p\_{loss} = p\_0 \* \frac{\left(\frac{\lambda\_{\text{max}}}{\mu\_{\text{avg}}}\right)^{n'+kQ}}{n'!n'^{kQ}} < p\_{loss\text{Scalar}}, \ 1 < n < N \tag{11}$$

To solve this problem, we need to choose the time intervals *T* for which we will create the patterns. Since patterns are created statically on the basis of statistical workload, it is possible to define the time moments, when thresholds are achieved so that *ploss* ¼ *plossSLA*. When it happens there is a need to increase the number of nodes (thus, to change the pattern). In case the load is decreasing, it is possible to define the moment when *P<sup>Σ</sup>* is not minimal anymore for the current statistical load.

The above problem solved for each time interval *T* would allow to determine the optimal number of processing nodes *n* for each time interval depending on the incoming load. Meanwhile, the following conditions will be fulfilled:

1. Energy consumption of the system will be minimal.

2. Job loss probability will meet the SLA requirements.

On the basis of the obtained values of *n, T*, it is possible to create patterns for the number of nodes of the system for periods of the day. These patterns may be created once for the regular workload and be corrected during further system operation. Since the dependencies of energy consumption and loss probability from the number of active nodes in system are already defined, it requires only minimal effort to adapt the system to a new workload pattern.

#### **4.4 Deviations from patterns detection and system reconfiguration**

In order to cope with unpredictable service workload deviations that can be caused by different reasons (e.g. holidays, special events, etc.), there is a need to detect significant deviations from the statistic workload curve, predict the workload for the next chosen time period and reconfigure the system, respectively.

The authors of the research [18] have proposed an approach to hybrid resource provisioning in virtualized networks. The main idea of this approach is as follows:


This approach can be briefly explained using **Figure 7**, where an example of applying the approach is highlighted by red circle.

Within the current study, this approach may be adapted to serve the need of detecting deviations from the statistical workload in considered distributed systems and to adjust the number of active system nodes in accordance with defined optimization problem.

where:

**Figure 8.**

*W* is an new monitoring interval.

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

statistical workload curve).

*Ibase* is the baseline predefined monitoring interval.

*Scaling patterns of the system that correspond to the daily workload.*

next interval should be adjusted according to Eq. (13):

This approach is described in details in [18].

system according to the calculated optimal number.

systems as well. Matlab system was used to create the model.

current workload and statistical one.

**5. Modeling**

**61**

*λobs*ð Þ*t* is the current load arrival rate during the time *t*.

*K* is the normalization constant that should be defined for each system individually.

*λpred*ð Þ*t* is the predicted load arrival rate during the time *t* (according to the

If *λbasepred*ð Þ*t* is a basic (statistical) load arrival rate for a period of time *t* and *λobs*ð Þ*t* is the current load arrival rate during the time *t*, the load predicted for the

> *t*�1 *j*¼*t*�*h*

Thus, having the predicted value of workload for the next time period, we can

As a result of applying proposed steps, we get formed patterns *n; tstart; t* f g *end* for the static day workload and may adjust them according to the deviation between

Within the modeling the system with comparatively low workload and number of computing nodes was chosen for clarity, but such model can be scaled for larger

Suppose we have a daily workload curve depicted in **Figure 9** (the value of workload is defined for each minute, so we also have value *λ* for each minute). For this workload let us define static scaling patterns that describe the optimal numbers of active nodes and time periods, for which these numbers remain optimal.

recalculate the pattern for that period and change the number of nodes in the

*λobs*ðÞ�*j λpred*ð Þ*j*

*<sup>h</sup>* (13)

*h* is the number of preceding intervals considered by the algorithm.

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

*λpred*ðÞ¼ *t λbasepred*ðÞþ*t* ∑

Consider that the system has *k* scaling patterns that correspond to the daily workload (**Figure 8**). Pattern in this context means the number of active nodes that remains optimal for the certain time period, so the pattern may be denoted as a set *n; tstart; t* f g *end ,* where *n* is the number of active nodes and *tstart, tend* show the interval of the day, during which these patterns remain optimal. These patterns may contain other configuration information as well, but it lies beyond the scope of the current study.

According to the adapted approach proposed in [18], the current workload should be monitored throughout the day, but the intensity of the monitoring may vary according to the deviation between the statistical workload and the current one. Let *Ibase* be a baseline time monitoring interval. This interval should be determined empirically for each system. Monitoring interval then should be adjusted according to Eq. (12):

$$W(t) = I\_{base} - K \sum\_{j=t-h}^{t-1} \frac{\max\left(0; \lambda\_{obs}(t) - \lambda\_{pred}(t)\right)}{h} I\_{base} \tag{12}$$

**Figure 7.** *The main idea of hybrid resource provisioning approach [18].*

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*

#### **Figure 8.**

The authors of the research [18] have proposed an approach to hybrid resource provisioning in virtualized networks. The main idea of this approach is as follows:

• To react dynamically to deviations from the base workload, which exceeds the

• To predict the workload for the next time interval *T* and adjust the resource

This approach can be briefly explained using **Figure 7**, where an example of

Within the current study, this approach may be adapted to serve the need of detecting deviations from the statistical workload in considered distributed systems and to adjust the number of active system nodes in accordance with defined opti-

Consider that the system has *k* scaling patterns that correspond to the daily workload (**Figure 8**). Pattern in this context means the number of active nodes that remains optimal for the certain time period, so the pattern may be denoted as a set *n; tstart; t* f g *end ,* where *n* is the number of active nodes and *tstart, tend* show the interval of the day, during which these patterns remain optimal. These patterns may contain other configuration information as well, but it lies beyond the scope of the current

According to the adapted approach proposed in [18], the current workload should be monitored throughout the day, but the intensity of the monitoring may vary according to the deviation between the statistical workload and the current one. Let *Ibase* be a baseline time monitoring interval. This interval should be determined empirically for each system. Monitoring interval then should be adjusted

max 0; *<sup>λ</sup>obs*ðÞ�*<sup>t</sup> <sup>λ</sup>pred*ð Þ*<sup>t</sup>*

*<sup>h</sup> Ibase,* (12)

*t*�1 *j*¼*t*�*h*

• To use workload statistics to create a baseline resource allocation scheme

• To monitor deviation of the actual workload from the statistical one

permissible value

mization problem.

according to Eq. (12):

study.

**Figure 7.**

**60**

allocation accordingly

applying the approach is highlighted by red circle.

*Scheduling Problems - New Applications and Trends*

*W t*ðÞ¼ *Ibase* � *K* ∑

*The main idea of hybrid resource provisioning approach [18].*

*Scaling patterns of the system that correspond to the daily workload.*

where:

*W* is an new monitoring interval.

*Ibase* is the baseline predefined monitoring interval.

*K* is the normalization constant that should be defined for each system individually. *λobs*ð Þ*t* is the current load arrival rate during the time *t*.

*λpred*ð Þ*t* is the predicted load arrival rate during the time *t* (according to the statistical workload curve).

*h* is the number of preceding intervals considered by the algorithm.

If *λbasepred*ð Þ*t* is a basic (statistical) load arrival rate for a period of time *t* and *λobs*ð Þ*t* is the current load arrival rate during the time *t*, the load predicted for the next interval should be adjusted according to Eq. (13):

$$
\lambda\_{pred}(\mathbf{t}) = \lambda\_{basepred}(\mathbf{t}) + \sum\_{j=t-h}^{t-1} \frac{\lambda\_{obs}(j) - \lambda\_{pred}(j)}{h} \tag{13}
$$

This approach is described in details in [18].

Thus, having the predicted value of workload for the next time period, we can recalculate the pattern for that period and change the number of nodes in the system according to the calculated optimal number.

As a result of applying proposed steps, we get formed patterns *n; tstart; t* f g *end* for the static day workload and may adjust them according to the deviation between current workload and statistical one.

#### **5. Modeling**

Within the modeling the system with comparatively low workload and number of computing nodes was chosen for clarity, but such model can be scaled for larger systems as well. Matlab system was used to create the model.

Suppose we have a daily workload curve depicted in **Figure 9** (the value of workload is defined for each minute, so we also have value *λ* for each minute).

For this workload let us define static scaling patterns that describe the optimal numbers of active nodes and time periods, for which these numbers remain optimal.

**Figure 9.** *Daily workload curve used for modeling.*

**Figure 10.** *Analytical and graphical representation of the P* ¼ *f CPU* ð Þ *functions defined experimentally.*

As an input data for modeling, we also have the following:

1. *P* ¼ *f CPU* ð Þ functions for *N* ¼ 10 servers in the form of polynomials. These functions were defined experimentally and interpolated using fourth degree polynomials. Analytical and graphical representation of the *P* ¼ *f CPU* ð Þ functions is presented in **Figure 10**.

In order to create patterns for certain time periods, it is worthy to run calculations according to Eq. (1) for each minute at first. Then, as soon as the thresholds of *ploss* and *Pj*<sup>Σ</sup> are defined, it is possible to derive *tstart; t* f g *end* values for each pattern. Let us build the curves described by Eq. (10) and Eq. (11) for the first minute

In **Figure 11** it is possible to see that in order to meet the SLA requirements *plossSLA* <sup>¼</sup> <sup>10</sup>�6, we need to have at least five nodes in the system. We can also see that these five nodes will consume near 900 W of energy. As the nodes are sorted from the worst one to the best one, these five leftover nodes are the most energy

We need to do the same for the remaining part of workload curve. This process was modeled using Matlab. As a result, we got all the scaling patterns for the given

In **Figure 13**, the adjustment of the received patterns is shown in the right graph. As it is possible to see, the interval of patterns optimality and number of nodes were

Let us introduce some deviation to the statistical workload in order to apply pattern adjustment. Introduced workload deviation is circled in red in **Figure 13**.

Adjustment was made according to Eqs. 12 and 13 proposed in [18].

workload. Resulting curves are depicted in **Figure 11**.

*Loss probability and power consumption calculations for the first workload value.*

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

efficient and productive among the others.

*Created scaling patterns for the given input workload.*

input workload (**Figure 12**).

**Figure 11.**

**Figure 12.**

changed, respectively.

**63**


*Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*

#### **Figure 11.**

*Loss probability and power consumption calculations for the first workload value.*

#### **Figure 12.**

As an input data for modeling, we also have the following:

*Analytical and graphical representation of the P* ¼ *f CPU* ð Þ *functions defined experimentally.*

4.Average serving rate for given servers: μ*avg* ¼ 25 req*=*min.

6.Let the probability of loss be defined by SLA be *plossSLA* <sup>¼</sup> <sup>10</sup>�6.

functions is presented in **Figure 10**.

5. *Q* ¼ 5, the length of the queue.

these ten servers.

**Figure 10.**

**62**

**Figure 9.**

*Daily workload curve used for modeling.*

*Scheduling Problems - New Applications and Trends*

1. *P* ¼ *f CPU* ð Þ functions for *N* ¼ 10 servers in the form of polynomials. These functions were defined experimentally and interpolated using fourth degree polynomials. Analytical and graphical representation of the *P* ¼ *f CPU* ð Þ

2. Corresponding values of RAM volume, number of cores and performance for

3. Scheduler algorithm that is being used—PCPB algorithm (the details regarding PCPB algorithm modeling are provided within the previous research [11]).

In order to create patterns for certain time periods, it is worthy to run calculations according to Eq. (1) for each minute at first. Then, as soon as the thresholds of *ploss* and *Pj*<sup>Σ</sup> are defined, it is possible to derive *tstart; t* f g *end* values for each pattern.

Let us build the curves described by Eq. (10) and Eq. (11) for the first minute workload. Resulting curves are depicted in **Figure 11**.

In **Figure 11** it is possible to see that in order to meet the SLA requirements *plossSLA* <sup>¼</sup> <sup>10</sup>�6, we need to have at least five nodes in the system. We can also see that these five nodes will consume near 900 W of energy. As the nodes are sorted from the worst one to the best one, these five leftover nodes are the most energy efficient and productive among the others.

We need to do the same for the remaining part of workload curve. This process was modeled using Matlab. As a result, we got all the scaling patterns for the given input workload (**Figure 12**).

Let us introduce some deviation to the statistical workload in order to apply pattern adjustment. Introduced workload deviation is circled in red in **Figure 13**. Adjustment was made according to Eqs. 12 and 13 proposed in [18].

In **Figure 13**, the adjustment of the received patterns is shown in the right graph. As it is possible to see, the interval of patterns optimality and number of nodes were changed, respectively.

**References**

2019/

challe6010117

Melbourne; 2013

2005

pp. 12-23

USA. 2007

**65**

[1] Gartner. Gartner Top 10 Strategic Technology Trends for 2019 [Internet]. 2018. Available from: https://www.ga rtner.com/smarterwithgartner/gartnertop-10-strategic-technology-trends-for-

*DOI: http://dx.doi.org/10.5772/intechopen.86874*

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance…*

[8] Aldossary M, Djemame K. Performance and energy-based cost prediction of virtual machines autoscaling in clouds. In: Proceedings of the

44th Euromicro Conference on Software Engineering and Advanced Applications (SEAA 2018); 29-31 August 2018; Prague, Czech Republic. 2018. pp. 502-509. DOI: 10.1109/

[9] Liu W, Du W, Chen J, Wang W, Zeng G. Adaptive energy-efficient scheduling algorithm for parallel tasks on homogeneous clusters. Journal of Network and Computer Applications. 2013;**41**:101-113. DOI: 10.1016/j.

[10] Armenta-Cano F, Tchernykh A, Cortés-Mendoza J, Yahyapour R, Drozdov A, Bouvry P, et al.

Heterogeneous job consolidation for power aware scheduling with quality of service. In: Proceedings of the Russian Supercomputing Days. RuSCDays'15;

[11] Schill A, Globa L, Stepurin O, Gvozdetska N, Prokopets V. Power consumption and performance balance (PCPB) scheduling algorithm for computer cluster. In: Proceedings of the 2017 International Conference on Information and Telecommunication Technologies and Radio Electronics (UkrMiCo 2017); Odesa, Ukraine. 2017.

[12] Gvozdetska N, Stepurin O, Globa L.

scheduling algorithm. In: Proceedings of the 14th International Conference the

Experimental analysis of PCPB

Experience of Designing and Application of CAD Systems in Microelectronics (CADSM); 21-25 February 2017; Polyana-Svalyava (Zakarpattya), Ukraine. 2017

[13] Bezruk V, Globa L, Stryzhak O, editors. Knowledge-Based Technologies

SEAA.2018.00086

jnca.2013.10.009

Moskow. 2015

pp. 1-8

[2] Andrae A, Edler T. On global electricity usage of communication technology: Trends to 2030. Challenges.

2015;**6**:117-157. DOI: 10.3390/

[3] Beloglazov A. Energy-efficient management of virtual machines in data centers for cloud computing [thesis]. Department of Computing and

Information Systems, The University of

[4] Suleiman D, Ibrahim M, Hamarash I. Dynamic voltage frequency scaling (DVFS) for microprocessors power and energy reduction. In: Proceedings of the

[5] Akram S, Sartor J, Eeckhout L. DVFS performance prediction for managed multithreaded applications. In: Proceedings of the IEEE International Symposium on Performance Analysis of Systems and Software-ISPASS. 2016.

[6] Agarwal K, Nowka K. Dynamic power management by combination of

dual static supply voltages. In: Proceedings of the 8th International

Electronic Design (ISQED 2007); 26-28 March 2007; San Jose, CA,

Systems. 2014. pp. 1600-1614

[7] Möbius C, Dargie W, Schill A. Power consumption estimation models for processors, virtual machines, and servers. In: Proceedings of the IEEE Transactions on Parallel and Distributed

Symposium on Quality of

4th International Conference on Electrical and Electronics Engineering.

**Figure 13.** *Scaling patterns' dynamic adjustment result.*

Thus, created model fully illustrates the process of proposed intelligent workload scheduling approach which is improved through the use of scaling approaches. The model shows the main idea of proposed approach; however, in real systems it is worthy to add some redundancy and always keep at least one extra server active in order to cope with unpredicted workload deviations.

#### **6. Conclusion**

In this chapter an intelligent approach to the workload scheduling in distributed computing environment was proposed. According to the proposed approach, energyaware PCPB scheduling algorithm is combined with scaling approaches that allow to achieve an optimal balance between energy efficiency and performance while fulfilling the SLA requirements. In order to achieve these goals, we propose to create and dynamically adjust system scaling patterns while using energy-aware scheduling. An approach was modeled using Matlab. The simulation results showed that it is able to cope with the efficient processing of statistical load, as well as load deviations.

Within the future research, the system representation as a queueing system is going to be made more precisely, and proposed approach's efficiency should be proven by means of experiment.

#### **Author details**

Larysa Globa<sup>1</sup> \*, Oleksandr Stryzhak<sup>2</sup> , Nataliia Gvozdetska<sup>1</sup> and Volodymyr Prokopets<sup>1</sup>

1 National Technical University of Ukraine "Igor Sikorsky Kyiv Polytechnic Institute", Kyiv, Ukraine

2 National Academy of Sciences in Ukraine, Kyiv, Ukraine

\*Address all correspondence to: lgloba@its.kpi.ua

© 2019 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

*Intelligent Workload Scheduling in Distributed Computing Environment for Balance… DOI: http://dx.doi.org/10.5772/intechopen.86874*

#### **References**

Thus, created model fully illustrates the process of proposed intelligent workload scheduling approach which is improved through the use of scaling approaches. The model shows the main idea of proposed approach; however, in real systems it is worthy to add some redundancy and always keep at least one extra server active in

In this chapter an intelligent approach to the workload scheduling in distributed computing environment was proposed. According to the proposed approach, energyaware PCPB scheduling algorithm is combined with scaling approaches that allow to achieve an optimal balance between energy efficiency and performance while fulfilling the SLA requirements. In order to achieve these goals, we propose to create and dynamically adjust system scaling patterns while using energy-aware scheduling. An approach was modeled using Matlab. The simulation results showed that it is able to cope with the efficient processing of statistical load, as well as load deviations.

Within the future research, the system representation as a queueing system is going to be made more precisely, and proposed approach's efficiency should be

1 National Technical University of Ukraine "Igor Sikorsky Kyiv Polytechnic

© 2019 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium,

, Nataliia Gvozdetska<sup>1</sup>

order to cope with unpredicted workload deviations.

**6. Conclusion**

**Figure 13.**

**Author details**

Larysa Globa<sup>1</sup>

**64**

proven by means of experiment.

*Scaling patterns' dynamic adjustment result.*

*Scheduling Problems - New Applications and Trends*

and Volodymyr Prokopets<sup>1</sup>

Institute", Kyiv, Ukraine

\*, Oleksandr Stryzhak<sup>2</sup>

\*Address all correspondence to: lgloba@its.kpi.ua

provided the original work is properly cited.

2 National Academy of Sciences in Ukraine, Kyiv, Ukraine

[1] Gartner. Gartner Top 10 Strategic Technology Trends for 2019 [Internet]. 2018. Available from: https://www.ga rtner.com/smarterwithgartner/gartnertop-10-strategic-technology-trends-for-2019/

[2] Andrae A, Edler T. On global electricity usage of communication technology: Trends to 2030. Challenges. 2015;**6**:117-157. DOI: 10.3390/ challe6010117

[3] Beloglazov A. Energy-efficient management of virtual machines in data centers for cloud computing [thesis]. Department of Computing and Information Systems, The University of Melbourne; 2013

[4] Suleiman D, Ibrahim M, Hamarash I. Dynamic voltage frequency scaling (DVFS) for microprocessors power and energy reduction. In: Proceedings of the 4th International Conference on Electrical and Electronics Engineering. 2005

[5] Akram S, Sartor J, Eeckhout L. DVFS performance prediction for managed multithreaded applications. In: Proceedings of the IEEE International Symposium on Performance Analysis of Systems and Software-ISPASS. 2016. pp. 12-23

[6] Agarwal K, Nowka K. Dynamic power management by combination of dual static supply voltages. In: Proceedings of the 8th International Symposium on Quality of Electronic Design (ISQED 2007); 26-28 March 2007; San Jose, CA, USA. 2007

[7] Möbius C, Dargie W, Schill A. Power consumption estimation models for processors, virtual machines, and servers. In: Proceedings of the IEEE Transactions on Parallel and Distributed Systems. 2014. pp. 1600-1614

[8] Aldossary M, Djemame K. Performance and energy-based cost prediction of virtual machines autoscaling in clouds. In: Proceedings of the 44th Euromicro Conference on Software Engineering and Advanced Applications (SEAA 2018); 29-31 August 2018; Prague, Czech Republic. 2018. pp. 502-509. DOI: 10.1109/ SEAA.2018.00086

[9] Liu W, Du W, Chen J, Wang W, Zeng G. Adaptive energy-efficient scheduling algorithm for parallel tasks on homogeneous clusters. Journal of Network and Computer Applications. 2013;**41**:101-113. DOI: 10.1016/j. jnca.2013.10.009

[10] Armenta-Cano F, Tchernykh A, Cortés-Mendoza J, Yahyapour R, Drozdov A, Bouvry P, et al. Heterogeneous job consolidation for power aware scheduling with quality of service. In: Proceedings of the Russian Supercomputing Days. RuSCDays'15; Moskow. 2015

[11] Schill A, Globa L, Stepurin O, Gvozdetska N, Prokopets V. Power consumption and performance balance (PCPB) scheduling algorithm for computer cluster. In: Proceedings of the 2017 International Conference on Information and Telecommunication Technologies and Radio Electronics (UkrMiCo 2017); Odesa, Ukraine. 2017. pp. 1-8

[12] Gvozdetska N, Stepurin O, Globa L. Experimental analysis of PCPB scheduling algorithm. In: Proceedings of the 14th International Conference the Experience of Designing and Application of CAD Systems in Microelectronics (CADSM); 21-25 February 2017; Polyana-Svalyava (Zakarpattya), Ukraine. 2017

[13] Bezruk V, Globa L, Stryzhak O, editors. Knowledge-Based Technologies of Optimization and Management in Infocommunication Networks: Monograph. 1st ed. Kyiv: National Academy of Pedagogical Sciences of Ukraine; 2019. p. 194. ISBN 978-617- 7734-02-3

[14] Google. Google Transparency Report [Internet]. 2019. Available from: http://www.google.com/transparencyre port/traffic/

[15] Mastroianni G, Milovanovic G. Interpolation Processes: Basic Theory and Applications. 1st ed. Berlin, Heidelberg: Springer; 2008. p. 446. DOI: 10.1007/978-3-15540-68349-0

[16] Sztrik J. Basic Queueing Theory. 1st ed. Debrecen, Hungary: University of Debrecen, Faculty of Informatics; 2011. p. 193

[17] Wikipedia. Round-Robin Scheduling [Internet]. 2019. Available from: https://en.wikipedia.org/ wiki/Round-robin\_scheduling

[18] Sulima S, Skulysh M. Hybrid resource provisioning system for virtual network functions. Radio Electronics, Computer Science, Control. 2017;(1): 16-23. DOI: 10.15588/1607-3274- 2017-1-2

**67**

**Chapter 4**

**Abstract**

*Liliana Grigoriu*

the automotive industry.

**1. Introduction**

Approximation for Scheduling on

Parallel Machines with Fixed Jobs

We survey results that address the problem of non-preemptive scheduling on parallel machines with fixed jobs or unavailability periods with the purpose of minimizing the maximum completion time. We consider both identical and uniform processors, and also address the special case of scheduling on nonsimultaneous parallel machines, which may start processing at different times. The discussed results include polynomial-time approximation algorithms that achieve the best possible worst-case approximation bound of 1.5 in the class of polynomial algorithms unless P = NP for scheduling on identical processors with at most one fixed job on each machine and on uniform machines with at most one fixed job on each machine. The presented heuristics have similarities with the LPT algorithm or the MULTIFIT algorithm and they are fast and easy to implement. For scheduling on nonsimultaneous machines, experiments suggest that they would perform well in practice. We also include references to the relevant work in this area that contains more complex algorithms. We then discuss the main methods of argument used in the approximation bound proofs for the simple heuristics, and comment upon current challenges in this area by describing aspects of related practical problems from

**Keywords:** multiprocessor scheduling, availability constraints, fixed jobs, uniform processors, worst-case approximation, nonsimultaneous machines,

The necessity to assign resources such as machines to jobs that need to be performed without interruption, where the time required for a machine to perform a certain job is known in advance, is a widely encountered problem. It can occur for example in production planning or when assigning landing and take-off stripes to planes in airports. Sometimes these resources become unavailable for predetermined periods of time, for example because of necessary maintenance. Minimizing the maximum completion time of all tasks is often considered as a goal, for example such that the workers who operate the machines can undertake other activities afterward or go home early. As a consequence, the problem of scheduling on multiple machines with predefined unavailability periods (downtimes) to minimize the maximum completion time, that is, the latest completion time of a job in a schedule, has been considered. A closely related problem, of scheduling with

makespan, maximum completion time, unavailability

or Unavailability Periods

#### **Chapter 4**

of Optimization and Management in Infocommunication Networks: Monograph. 1st ed. Kyiv: National Academy of Pedagogical Sciences of Ukraine; 2019. p. 194. ISBN 978-617-

*Scheduling Problems - New Applications and Trends*

[14] Google. Google Transparency Report [Internet]. 2019. Available from: http://www.google.com/transparencyre

[15] Mastroianni G, Milovanovic G. Interpolation Processes: Basic Theory and Applications. 1st ed. Berlin,

10.1007/978-3-15540-68349-0

[17] Wikipedia. Round-Robin

[18] Sulima S, Skulysh M. Hybrid resource provisioning system for virtual network functions. Radio Electronics, Computer Science, Control. 2017;(1): 16-23. DOI: 10.15588/1607-3274-

Heidelberg: Springer; 2008. p. 446. DOI:

[16] Sztrik J. Basic Queueing Theory. 1st ed. Debrecen, Hungary: University of Debrecen, Faculty of Informatics; 2011.

Scheduling [Internet]. 2019. Available from: https://en.wikipedia.org/ wiki/Round-robin\_scheduling

7734-02-3

port/traffic/

p. 193

2017-1-2

**66**

## Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods

*Liliana Grigoriu*

#### **Abstract**

We survey results that address the problem of non-preemptive scheduling on parallel machines with fixed jobs or unavailability periods with the purpose of minimizing the maximum completion time. We consider both identical and uniform processors, and also address the special case of scheduling on nonsimultaneous parallel machines, which may start processing at different times. The discussed results include polynomial-time approximation algorithms that achieve the best possible worst-case approximation bound of 1.5 in the class of polynomial algorithms unless P = NP for scheduling on identical processors with at most one fixed job on each machine and on uniform machines with at most one fixed job on each machine. The presented heuristics have similarities with the LPT algorithm or the MULTIFIT algorithm and they are fast and easy to implement. For scheduling on nonsimultaneous machines, experiments suggest that they would perform well in practice. We also include references to the relevant work in this area that contains more complex algorithms. We then discuss the main methods of argument used in the approximation bound proofs for the simple heuristics, and comment upon current challenges in this area by describing aspects of related practical problems from the automotive industry.

**Keywords:** multiprocessor scheduling, availability constraints, fixed jobs, uniform processors, worst-case approximation, nonsimultaneous machines, makespan, maximum completion time, unavailability

#### **1. Introduction**

The necessity to assign resources such as machines to jobs that need to be performed without interruption, where the time required for a machine to perform a certain job is known in advance, is a widely encountered problem. It can occur for example in production planning or when assigning landing and take-off stripes to planes in airports. Sometimes these resources become unavailable for predetermined periods of time, for example because of necessary maintenance. Minimizing the maximum completion time of all tasks is often considered as a goal, for example such that the workers who operate the machines can undertake other activities afterward or go home early. As a consequence, the problem of scheduling on multiple machines with predefined unavailability periods (downtimes) to minimize the maximum completion time, that is, the latest completion time of a job in a schedule, has been considered. A closely related problem, of scheduling with

fixed jobs, where on each machine certain jobs have to be performed at predefined times, has also been considered. The difference between these two problems is in the meaning of the objective function: when scheduling with fixed jobs, the maximum completion time of the jobs must be at least the latest completion time of a fixed job, whereas the maximum completion time when scheduling in the presence of unavailability periods can occur before the end of an unavailability period. We consider the static nonresumable variant of the problem of scheduling with unavailability periods, where the downtimes are known for each machine before the schedule needs to be made, and where jobs that start executing before a downtime cannot resume execution after it.

In these problems, the job execution times are usually assumed to be given as an integer number of computing units such as clock cycles or of other suitable units such as time units. Similarly, the starttimes and endtimes of unavailability periods or of fixed jobs are assumed to be given as integer multiples of adequately chosen time units. We note that any problem with rational numbers as job durations and starttimes and endtimes of downtimes or of fixed jobs can be transformed into an equivalent problem where these entities are integers by multiplying them with an adequate factor, thus there is arguably no loss of generality in this assumption when considering the representation of any practical problem.

Both the problem of multiprocessor scheduling on fixed jobs and that of multiprocessor scheduling with unavailability periods are strongly NP-hard as they are more general than the strongly NP-hard multiprocessor scheduling problem (MSP), which has no downtimes or fixed jobs.

For scheduling with downtimes, it is NP-hard to find a schedule that ends within a given constant multiple of an optimal schedule even when scheduling on identical machines with at most one downtime on each machine. We discuss this in more detail in Section 4.2. To obtain approximation results for scheduling with unavailability periods in this context, assumptions about the downtimes were made such as the assumption that only a fraction of the processors can be unavailable at the same time [1, 2], or by comparing the generated schedule to the latest among the end of an optimal schedule or the latest end of a downtime, thus essentially considering scheduling with fixed jobs [3, 4].

To describe the performance of an approximation algorithm, we use the notion of a *worst-case approximation bound*. In this work, we call worst-case approximation bound of an algorithm A when applied to a scheduling problem SP the largest ratio between the maximum completion time of a schedule produced by A and the maximum completion time of an optimal schedule for a problem instance of SP.

For the problem of multiprocessor scheduling with fixed jobs to minimize the maximum completion time, even in the case where there is at most one fixed job on each machine, it has been shown in [5] that no polynomial algorithm can achieve a worst-case approximation bound that is less than 1.5 unless P = NP. Sharbrodt et al. [5] also give a polynomial-time approximation scheme (PTAS) for scheduling on a constant number of uniform processors with fixed jobs. Polynomial-time approximation algorithms for this problem that achieve the worst-case approximation bound of 1.5 were given for the general problem in [6]. For the case where there is at most one fixed job on each machine, significanlty simpler heuristics with lower time complexities resembling the largest processing time algorithm (LPT) [7] for identical processors and the MULTIFIT algorithm [8] for uniform processors also achieve this bound [3, 4].

The case where all downtimes are at the beginning of the processing time on all machines is called scheduling with nonsimultaneous machine available times, as the machines start processing jobs nonsimultaneously. For this problem, polynomialtime algorithms with constant worstcase approximation bounds exist.

**69**

**2.3 Proof techniques**

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods*

For scheduling on identical nonsimultaneous parallel machines, MULTIFIT achieves a tight worst-case approximation bound of 24/19 (~1.2632) [9] and another algorithm achieves a bound of 5/4 [10], while in the case of scheduling on uniform nonsimultaneous parallel machines, a MULTIFIT variant has a worst-case approximation bound of 1.382 [11], which was shown by generalizing the bound obtained for MULTIFIT when scheduling on uniform processors in [12]. Experimental results suggest that for scheduling on nonsimultaneous uniform machines, the MULTIFIT variant from [11] is adequate for use in practice, as we discuss in Section [4].

In Section 2, we describe the ways in which the content of this work can be used.

This work aims to provide a deeper understanding of multiple related problems that involve scheduling on parallel machines with fixed jobs or unavailability periods to minimize the maximum completion time. We explain why multiprocessor scheduling with at most one unavailability period on each machine does not have a polynomial-time approximation algorithm with a constant worst-case approximation bound unless P = NP, which is the main reason why results on this topic are hard to obtain. Furthermore, we observe that most results in this area involve variants of LPT and MULTIFIT, and comment on the other results obtained. We also hope that this work will increase awareness of these results and of how they relate to each other.

The heuristics presented and referenced in this work can be used directly in practice or for research purposes to solve the problems they address. The heuristics based on LPT and MULTIFIT are fast and easy to implement and some of them have best possible worst-case approximation bounds in the class of polynomial algorithms unless P = NP for the problems they address. In addition to worst-case approximation results, this work also highlights for some cases experimental insights into how the heuristics would perform in practice based on how they perform for randomly generated instances. As expected, they perform much better for such instances than in the worst case. Also, for some cases, references to more

This work presents the main proof techniques used to obtain worst-case approximation bounds for LPT- and MULTIFIT-like heuristics when the aim is to minimize the maximum completion time. Thus, the interested reader is provided with a

complex methods are provided in case the user prefers to use those.

In Section 3, we introduce the algorithms LPT and MULTIFIT. In Section 4, we consider scheduling with unavailability periods, while first focussing on scheduling with nonsimultaneous machine available times in Section 4.1, and on the more general case where downtimes do not have to occur at the beginning of the schedule in Section 4.2. In Section 5, we present results on scheduling with fixed jobs. Section 6 contains the description of main techniques used in the worst-case approximation bound proofs and Section 7 contains concluding remarks and a discussion of some

*DOI: http://dx.doi.org/10.5772/intechopen.89694*

of the challenges in this area.

**2.1 A deeper understanding**

**2. Contributions of this work**

**2.2 Practical use of the heuristics**

We next present ways to use the content of this work.

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods DOI: http://dx.doi.org/10.5772/intechopen.89694*

For scheduling on identical nonsimultaneous parallel machines, MULTIFIT achieves a tight worst-case approximation bound of 24/19 (~1.2632) [9] and another algorithm achieves a bound of 5/4 [10], while in the case of scheduling on uniform nonsimultaneous parallel machines, a MULTIFIT variant has a worst-case approximation bound of 1.382 [11], which was shown by generalizing the bound obtained for MULTIFIT when scheduling on uniform processors in [12]. Experimental results suggest that for scheduling on nonsimultaneous uniform machines, the MULTIFIT variant from [11] is adequate for use in practice, as we discuss in Section [4].

In Section 2, we describe the ways in which the content of this work can be used. In Section 3, we introduce the algorithms LPT and MULTIFIT. In Section 4, we consider scheduling with unavailability periods, while first focussing on scheduling with nonsimultaneous machine available times in Section 4.1, and on the more general case where downtimes do not have to occur at the beginning of the schedule in Section 4.2. In Section 5, we present results on scheduling with fixed jobs. Section 6 contains the description of main techniques used in the worst-case approximation bound proofs and Section 7 contains concluding remarks and a discussion of some of the challenges in this area.

#### **2. Contributions of this work**

We next present ways to use the content of this work.

#### **2.1 A deeper understanding**

*Scheduling Problems - New Applications and Trends*

cannot resume execution after it.

which has no downtimes or fixed jobs.

with fixed jobs [3, 4].

achieve this bound [3, 4].

considering the representation of any practical problem.

fixed jobs, where on each machine certain jobs have to be performed at predefined times, has also been considered. The difference between these two problems is in the meaning of the objective function: when scheduling with fixed jobs, the maximum completion time of the jobs must be at least the latest completion time of a fixed job, whereas the maximum completion time when scheduling in the presence of unavailability periods can occur before the end of an unavailability period. We consider the static nonresumable variant of the problem of scheduling with unavailability periods, where the downtimes are known for each machine before the schedule needs to be made, and where jobs that start executing before a downtime

In these problems, the job execution times are usually assumed to be given as an integer number of computing units such as clock cycles or of other suitable units such as time units. Similarly, the starttimes and endtimes of unavailability periods or of fixed jobs are assumed to be given as integer multiples of adequately chosen time units. We note that any problem with rational numbers as job durations and starttimes and endtimes of downtimes or of fixed jobs can be transformed into an equivalent problem where these entities are integers by multiplying them with an adequate factor, thus there is arguably no loss of generality in this assumption when

Both the problem of multiprocessor scheduling on fixed jobs and that of multiprocessor scheduling with unavailability periods are strongly NP-hard as they are more general than the strongly NP-hard multiprocessor scheduling problem (MSP),

For scheduling with downtimes, it is NP-hard to find a schedule that ends within a given constant multiple of an optimal schedule even when scheduling on identical machines with at most one downtime on each machine. We discuss this in more detail in Section 4.2. To obtain approximation results for scheduling with unavailability periods in this context, assumptions about the downtimes were made such as the assumption that only a fraction of the processors can be unavailable at the same time [1, 2], or by comparing the generated schedule to the latest among the end of an optimal schedule or the latest end of a downtime, thus essentially considering scheduling

To describe the performance of an approximation algorithm, we use the notion of a *worst-case approximation bound*. In this work, we call worst-case approximation bound of an algorithm A when applied to a scheduling problem SP the largest ratio between the maximum completion time of a schedule produced by A and the maximum completion time of an optimal schedule for a problem instance of SP. For the problem of multiprocessor scheduling with fixed jobs to minimize the maximum completion time, even in the case where there is at most one fixed job on each machine, it has been shown in [5] that no polynomial algorithm can achieve a worst-case approximation bound that is less than 1.5 unless P = NP. Sharbrodt et al. [5] also give a polynomial-time approximation scheme (PTAS) for scheduling on a constant number of uniform processors with fixed jobs. Polynomial-time approximation algorithms for this problem that achieve the worst-case approximation bound of 1.5 were given for the general problem in [6]. For the case where there is at most one fixed job on each machine, significanlty simpler heuristics with lower time complexities resembling the largest processing time algorithm (LPT) [7] for identical processors and the MULTIFIT algorithm [8] for uniform processors also

The case where all downtimes are at the beginning of the processing time on all machines is called scheduling with nonsimultaneous machine available times, as the machines start processing jobs nonsimultaneously. For this problem, polynomial-

time algorithms with constant worstcase approximation bounds exist.

**68**

This work aims to provide a deeper understanding of multiple related problems that involve scheduling on parallel machines with fixed jobs or unavailability periods to minimize the maximum completion time. We explain why multiprocessor scheduling with at most one unavailability period on each machine does not have a polynomial-time approximation algorithm with a constant worst-case approximation bound unless P = NP, which is the main reason why results on this topic are hard to obtain.

Furthermore, we observe that most results in this area involve variants of LPT and MULTIFIT, and comment on the other results obtained. We also hope that this work will increase awareness of these results and of how they relate to each other.

#### **2.2 Practical use of the heuristics**

The heuristics presented and referenced in this work can be used directly in practice or for research purposes to solve the problems they address. The heuristics based on LPT and MULTIFIT are fast and easy to implement and some of them have best possible worst-case approximation bounds in the class of polynomial algorithms unless P = NP for the problems they address. In addition to worst-case approximation results, this work also highlights for some cases experimental insights into how the heuristics would perform in practice based on how they perform for randomly generated instances. As expected, they perform much better for such instances than in the worst case. Also, for some cases, references to more complex methods are provided in case the user prefers to use those.

#### **2.3 Proof techniques**

This work presents the main proof techniques used to obtain worst-case approximation bounds for LPT- and MULTIFIT-like heuristics when the aim is to minimize the maximum completion time. Thus, the interested reader is provided with a

concise description of the tools that can be used to develop such proofs, and he or she may not have to read hundreds of pages in order to become aware of all of them or work with an expert in the area when developing such a proof. Even for people with expertise in the area, one or more of the ideas presented may be new and helpful.

#### **3. The algorithms LPT and MULTIFIT**

The algorithms LPT and MULTIFIT are among the most studied approximation algorithms for multiprocessor scheduling with or without unavailability periods or fixed jobs. In this section, we describe the basic versions of these algorithms for MSP, which can be stated as follows: given a set of *m* machines *P* and *n* jobs *J* find a non-preemptive schedule that ends at the earliest possible time. A non-preemptime schedule is an assignment of jobs to processors, together with an order in which the jobs on each processor are processed.

The algorithm LPT [7] works as follows:


The algorithm MULTIFIT was first introduced by Coffmann Garey and Johnson in 1978 [8]. It uses binary search for the end of its resulting schedule and receives as input an accuracy ε with which it determines this schedule end. In each iteration it assigns a deadline and attempts to create a schedule that contains all tasks that ends at or before that deadline by using the bin packing algorithm first fit decreasing (FFD). If a feasible schedule is created, it decreases the deadline and otherwise it increases the deadline. This process is repeated until the difference between the current deadline and the previously considered deadline is less than ε. More formally, the algorithm is described as Algorithm 2.

The MULTIFIT algorithm results in a schedule with a maximum completion time that is within ε of the maximum completion time of the schedule that would result if the binary search for the deadline would be continued.

An example of a LPT-schedule and a MULTIFIT schedule for the same problem instance are presented in **Figures 1** and **2** respectively.

#### **Figure 1.**

*A LPT schedule. The jobs are numbered according to the order in which they are considered. At start, when all processors are available at the same time, they are considered in the order p1, p2, p3 in this example.*

**71**

upon in [4].

**Figure 2.**

delivery times for their orders.

**3.1 Time complexity of MULTIFIT**

**Algorithm 2** The algorithm MULTIFIT

3: Assign b = (ub + lb)/2 as deadline.

6: Else increase the lower bound: lb = b. 7: If ub − lb ≥ ε loop back to Step 3.

1: Order the jobs in non-increasing order of their duration.

durations/number of processors, ub = sum of job durations).

deadline (the processors are considered in each iteration in the same order). 5: If all tasks are successfully scheduled decrease the upper bound: ub = b.

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods*

The MULTIFIT algorithm tends to produce more balanced schedules than LPT, and, as a consequence it tends to perform better when the aim is to minimize the maximum completion time. It also has a higher time complexity, as it tries to make a schedule about log2(*ub* − *lb*) times, whereas the LPT algorithm only does that once. When the instances are prohibitively big and the schedule needs to be made in a short time, it may be indicated to use LPT or another list scheduling algorithm to schedule the jobs. This is because in practical situations, there may not be enough time to go through the list of jobs more than once while scheduling thousands of jobs and making sure that all required constraints are obeyed by the schedule. The reason why such big schedules are made is that the companies aim to estimate

*A MULTIFIT schedule together with a possible deadline. The jobs are numbered according to the order in which they are considered. The processors are considered in the order p1, p2, p3 when generating the schedule.*

2: Assign upper bound (ub) and lower bound (lb) for the end of schedule; (for example, lb = sum of job

4: FFD: Assign tasks in non-increasing order on the first processor on which they fit while respecting the

If the parameter ε of MULTIFIT is adequately set, for example as a computer clock cycle, the algorithm returns the best possible MULTIFIT schedule, that is, running it further would not result in a better schedule, as was commented

The binary search for the deadline within the MULTIFIT algorithm happens within log2[(*ub* − *lb*)/ε] time, which is at most log2(*ub*/ε), which is the size of *ub* in binary, assuming that the numbers for the upper bound and the lower bound do not change their representation during the execution of the algorithm and that they allow within their representation for an accuracy of ε. In Section 1, we mentioned that the job durations are usually given as integer multiples of an adequately chosen (time)

*DOI: http://dx.doi.org/10.5772/intechopen.89694*

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods DOI: http://dx.doi.org/10.5772/intechopen.89694*

#### **Figure 2.**

*Scheduling Problems - New Applications and Trends*

**3. The algorithms LPT and MULTIFIT**

jobs on each processor are processed.

assigned.

The algorithm LPT [7] works as follows:

**Algorithm 1** The largest processing time algorithm (LPT) 1: Order jobs in nonincreasing order of their processing time.

the algorithm is described as Algorithm 2.

concise description of the tools that can be used to develop such proofs, and he or she may not have to read hundreds of pages in order to become aware of all of them or work with an expert in the area when developing such a proof. Even for people with expertise in the area, one or more of the ideas presented may be new and helpful.

The algorithms LPT and MULTIFIT are among the most studied approximation algorithms for multiprocessor scheduling with or without unavailability periods or fixed jobs. In this section, we describe the basic versions of these algorithms for MSP, which can be stated as follows: given a set of *m* machines *P* and *n* jobs *J* find a non-preemptive schedule that ends at the earliest possible time. A non-preemptime schedule is an assignment of jobs to processors, together with an order in which the

The algorithm MULTIFIT was first introduced by Coffmann Garey and Johnson in 1978 [8]. It uses binary search for the end of its resulting schedule and receives as input an accuracy ε with which it determines this schedule end. In each iteration it assigns a deadline and attempts to create a schedule that contains all tasks that ends at or before that deadline by using the bin packing algorithm first fit decreasing (FFD). If a feasible schedule is created, it decreases the deadline and otherwise it increases the deadline. This process is repeated until the difference between the current deadline and the previously considered deadline is less than ε. More formally,

2: In this order assign each job at the earliest possible time allowed by the schedule that exists when the job is

The MULTIFIT algorithm results in a schedule with a maximum completion time that is within ε of the maximum completion time of the schedule that would

An example of a LPT-schedule and a MULTIFIT schedule for the same problem

*A LPT schedule. The jobs are numbered according to the order in which they are considered. At start, when all processors are available at the same time, they are considered in the order p1, p2, p3 in this example.*

result if the binary search for the deadline would be continued.

instance are presented in **Figures 1** and **2** respectively.

**70**

**Figure 1.**

*A MULTIFIT schedule together with a possible deadline. The jobs are numbered according to the order in which they are considered. The processors are considered in the order p1, p2, p3 when generating the schedule.*


The MULTIFIT algorithm tends to produce more balanced schedules than LPT, and, as a consequence it tends to perform better when the aim is to minimize the maximum completion time. It also has a higher time complexity, as it tries to make a schedule about log2(*ub* − *lb*) times, whereas the LPT algorithm only does that once. When the instances are prohibitively big and the schedule needs to be made in a short time, it may be indicated to use LPT or another list scheduling algorithm to schedule the jobs. This is because in practical situations, there may not be enough time to go through the list of jobs more than once while scheduling thousands of jobs and making sure that all required constraints are obeyed by the schedule. The reason why such big schedules are made is that the companies aim to estimate delivery times for their orders.

#### **3.1 Time complexity of MULTIFIT**

If the parameter ε of MULTIFIT is adequately set, for example as a computer clock cycle, the algorithm returns the best possible MULTIFIT schedule, that is, running it further would not result in a better schedule, as was commented upon in [4].

The binary search for the deadline within the MULTIFIT algorithm happens within log2[(*ub* − *lb*)/ε] time, which is at most log2(*ub*/ε), which is the size of *ub* in binary, assuming that the numbers for the upper bound and the lower bound do not change their representation during the execution of the algorithm and that they allow within their representation for an accuracy of ε. In Section 1, we mentioned that the job durations are usually given as integer multiples of an adequately chosen (time)

unit; therefore, the end of any schedule is an integer, and thus, there is no point in making ε less than 1, in which case the MULTIFIT loop is repeated log2(*ub*) times.

As a consequence, the number of times the MULTIFIT loop is called is polynomial in the size of the input, as any reasonable upper bound is at most the sum of the processing times of all jobs, which can be represented within at most the total number of bits used to represent all jobs. In [4], Grigoriu and Friesen also comment that if the upper bound is 2 years, the lower bound is 0 and the deadline is determined with an accuracy of 10<sup>−</sup>13 s, the MULTIFIT loop is called at most 40 times.

The time complexity of MULTIFIT is thus *O*(*n* log*n* + *nm* log2(*ub*)), as the jobs need to be sorted according to their execution times in a non-increasing order in Step (1), and as in each iteration of the MULTIFIT loop, the algorithm looks for each job for the first processor on which it fits; thus, it will have to look at most at *m* processors. Recall that *n* is the number of jobs in the considered problem instance.

#### **4. Scheduling with unavailability periods**

In this section, we first present results for the case where all unavailability periods are at the beginning of the schedule. Then, we present results for the more general case where the unavailability periods can occur anywhere in the schedule.

#### **4.1 Scheduling with nonsimultaneous machine available times**

This section addresses the case where the processors may have unavailability periods at the start of their processing time. This situation is more general than the multiprocessor scheduling problem (where there are no fixed jobs or downtimes) and less general than the problems of scheduling with fixed jobs or with unavailability periods. As the less general multiprocessor scheduling problem is NP-hard, so are the problems of scheduling on identical machines with nonsimultaneous machine available times (NMSP: nonsimultaneous multiprocessor scheduling problem) and scheduling on uniform processors with nonsimultaneous machine available times (UNMSP) when minimizing the maximum completion time. Due to the NP-hardness of these problems, polynomial-time approximation algorithms like LPT and MULTIFIT and their variants have been studied for their solution. As before, we will continue to denote with the number of processors in the problem instance being considered with *m*.

#### *4.1.1 Scheduling on identical nonsimultaneous processors*

For NMSP, worst-case approximation bounds for LPT of 3/2 − 1/ (2*m*) and for a modified version of LPT (MLPT) of 4/3 have been obtained by Lee [13]. The bound obtained by Lee in [13] was improved upon by Kellerer in [10], where a dual approximation algorithm with a worst-case approximation bound of 5/4 was presented.

When MULTIFIT is used for MSP, a deadline results in periods of equal duration in which jobs can be scheduled on each processor; thus the schedules resulting from using any ordering of processors in step (4) of MULTIFIT have the same maximum completion time. When considering NMSP, thus allowing for nonsimultaneous machines, the order in which processors are considered becomes relevant, as the period in which jobs can be executed on each processor corresponding to a deadline depends on the time the processor becomes available. MULTIFIT variants that address such situations usually order the processors in non-decreasing order of their periods in which jobs can be scheduled. Thus, in this case, the ordering is in nonincreasing order of the times at which the processors become available.

**73**

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods*

A bound of 9/7 (about 1.2857) was obtained for MULTIFIT by Chang and Hwang [14]. In [10], Kellerer gives a problem instance of NMSP for which the approximation factor of its MULTIFIT schedule is 24/19 (about 1.2632). More recently, 24/19 was shown to be the exact worst-case approximation bound when using MULTIFIT for NMSP by Hwang and Lim [9]. By comparison, a tight worstcase approximation bound of 13/11 (about 1.18182) was shown by Yue [15] for

For the uniform multiprocessor scheduling problem with simultaneous machine available times (UMSP), that is, where processors execute jobs at different speeds, the amount of jobs that fit on a processor corresponding to a given MULTIFIT deadline depends on the speed of that processor. Usually, the slowest processor is considered to have a speed of 1, and for each job *j*, the time it would take to process it on this processor *lj* is given. Thus, on a machine with speed 5, a job *j* needs a time of *lj*/5 to be processed. As a consequence, the ordering in which the processors are considered in Step (4) of MULTIFIT is in most cases relevant to the maximum completion time of the resulting schedule. MULTIFIT for UMSP orders processors in each iteration before its Step (4) in non-decreasing order of the duration of the processing time on that processor times the speed of that

For UMSP, approximation bounds of 1.4 and 1.382 were obtained for MULTIFIT by Friesen and Langston [16] and by Chen [12] respectively. In [17], Burkard and

(about 1.2071) for the case where MULTIFIT is combined with LPT as an incum-

In [11], Grigoriu and Friesen show that bounds that apply to the MULTIFIT variants from previous work such as [12, 16, 17] where scheduling on two uniform processors is considered also apply to a slightly different proposed variant of MULTIFIT for UNMSP, LMULTIFIT, which was first proposed in [4] in a more general form. The difference between the MULTIFIT variants from [12, 16, 17] on the one hand and LMULTIFIT on the other hand is that in the latter, the choice of the initial upper and lower bounds is not given explicitly within the algorithm, and thus the worst-case approximation bound proofs are more general, as they work for any initial choices of upper and lower bounds for the duration of the resulting schedule. A first step in the proofs that the bounds hold in the more general case, where there are uniform nonsimultaneous parallel machines, was to show that LMULTIFIT obeys the bounds of the earlier MULTIFIT variants in the simultaneous machines

Using LPT for UNMSP has been considered in [18], where worst-case approximation bound of 5/3 was shown in the general case, as well as a better bound for the

For the case where the number of machines is constant, a PTAS exists for UNMSP [11], which was derived from a PTAS for scheduling on a constant number of uniform processors with fixed jobs from [5]. As the objective function for scheduling with fixed jobs that are at the beginning of the schedule and scheduling with unavailability periods that are at the beginning of the schedule differ, the PTAS from [5] can not be used unaltered to address UNMSP. To address UNMSP, the PTAS from [5] is first run for the transformed problem instance where the unavailability periods become fixed jobs, and then for all problem instances resulting from successively removing the machine with the latest end of a fixed job from

for UMSP with at most two processors, and show a better bound of (√

\_

6 /2 (about 1.2247) of MULTIFIT

\_ 2 + 1)/2

*DOI: http://dx.doi.org/10.5772/intechopen.89694*

MUTLIFIT when applied to MSP.

processor [12, 16].

bent algorithm.

*4.1.2 Scheduling on uniform nonsimultaneous processors*

He derive a worst-case approximation bound of √

case for the instances considered in those works.

case where there are only two machines.

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods DOI: http://dx.doi.org/10.5772/intechopen.89694*

A bound of 9/7 (about 1.2857) was obtained for MULTIFIT by Chang and Hwang [14]. In [10], Kellerer gives a problem instance of NMSP for which the approximation factor of its MULTIFIT schedule is 24/19 (about 1.2632). More recently, 24/19 was shown to be the exact worst-case approximation bound when using MULTIFIT for NMSP by Hwang and Lim [9]. By comparison, a tight worstcase approximation bound of 13/11 (about 1.18182) was shown by Yue [15] for MUTLIFIT when applied to MSP.

#### *4.1.2 Scheduling on uniform nonsimultaneous processors*

*Scheduling Problems - New Applications and Trends*

**4. Scheduling with unavailability periods**

instance being considered with *m*.

*4.1.1 Scheduling on identical nonsimultaneous processors*

For NMSP, worst-case approximation bounds for LPT of 3/2 − 1/

increasing order of the times at which the processors become available.

modified version of LPT (MLPT) of 4/3 have been obtained by Lee [13]. The bound obtained by Lee in [13] was improved upon by Kellerer in [10], where a dual approximation algorithm with a worst-case approximation bound of 5/4 was presented.

When MULTIFIT is used for MSP, a deadline results in periods of equal duration in which jobs can be scheduled on each processor; thus the schedules resulting from using any ordering of processors in step (4) of MULTIFIT have the same maximum completion time. When considering NMSP, thus allowing for nonsimultaneous machines, the order in which processors are considered becomes relevant, as the period in which jobs can be executed on each processor corresponding to a deadline depends on the time the processor becomes available. MULTIFIT variants that address such situations usually order the processors in non-decreasing order of their periods in which jobs can be scheduled. Thus, in this case, the ordering is in non-

(2*m*) and for a

unit; therefore, the end of any schedule is an integer, and thus, there is no point in making ε less than 1, in which case the MULTIFIT loop is repeated log2(*ub*) times. As a consequence, the number of times the MULTIFIT loop is called is polynomial in the size of the input, as any reasonable upper bound is at most the sum of the processing times of all jobs, which can be represented within at most the total number of bits used to represent all jobs. In [4], Grigoriu and Friesen also comment that if the upper bound is 2 years, the lower bound is 0 and the deadline is determined with an accuracy of 10<sup>−</sup>13 s, the MULTIFIT loop is called at most 40 times. The time complexity of MULTIFIT is thus *O*(*n* log*n* + *nm* log2(*ub*)), as the jobs need to be sorted according to their execution times in a non-increasing order in Step (1), and as in each iteration of the MULTIFIT loop, the algorithm looks for each job for the first processor on which it fits; thus, it will have to look at most at *m* processors. Recall that *n* is the number of jobs in the considered problem instance.

In this section, we first present results for the case where all unavailability periods are at the beginning of the schedule. Then, we present results for the more general case where the unavailability periods can occur anywhere in the schedule.

This section addresses the case where the processors may have unavailability periods at the start of their processing time. This situation is more general than the multiprocessor scheduling problem (where there are no fixed jobs or downtimes) and less general than the problems of scheduling with fixed jobs or with unavailability periods. As the less general multiprocessor scheduling problem is NP-hard, so are the problems of scheduling on identical machines with nonsimultaneous machine available times (NMSP: nonsimultaneous multiprocessor scheduling problem) and scheduling on uniform processors with nonsimultaneous machine available times (UNMSP) when minimizing the maximum completion time. Due to the NP-hardness of these problems, polynomial-time approximation algorithms like LPT and MULTIFIT and their variants have been studied for their solution. As before, we will continue to denote with the number of processors in the problem

**4.1 Scheduling with nonsimultaneous machine available times**

**72**

For the uniform multiprocessor scheduling problem with simultaneous machine available times (UMSP), that is, where processors execute jobs at different speeds, the amount of jobs that fit on a processor corresponding to a given MULTIFIT deadline depends on the speed of that processor. Usually, the slowest processor is considered to have a speed of 1, and for each job *j*, the time it would take to process it on this processor *lj* is given. Thus, on a machine with speed 5, a job *j* needs a time of *lj*/5 to be processed. As a consequence, the ordering in which the processors are considered in Step (4) of MULTIFIT is in most cases relevant to the maximum completion time of the resulting schedule. MULTIFIT for UMSP orders processors in each iteration before its Step (4) in non-decreasing order of the duration of the processing time on that processor times the speed of that processor [12, 16].

For UMSP, approximation bounds of 1.4 and 1.382 were obtained for MULTIFIT by Friesen and Langston [16] and by Chen [12] respectively. In [17], Burkard and He derive a worst-case approximation bound of √ \_ 6 /2 (about 1.2247) of MULTIFIT for UMSP with at most two processors, and show a better bound of (√ \_ 2 + 1)/2 (about 1.2071) for the case where MULTIFIT is combined with LPT as an incumbent algorithm.

In [11], Grigoriu and Friesen show that bounds that apply to the MULTIFIT variants from previous work such as [12, 16, 17] where scheduling on two uniform processors is considered also apply to a slightly different proposed variant of MULTIFIT for UNMSP, LMULTIFIT, which was first proposed in [4] in a more general form. The difference between the MULTIFIT variants from [12, 16, 17] on the one hand and LMULTIFIT on the other hand is that in the latter, the choice of the initial upper and lower bounds is not given explicitly within the algorithm, and thus the worst-case approximation bound proofs are more general, as they work for any initial choices of upper and lower bounds for the duration of the resulting schedule. A first step in the proofs that the bounds hold in the more general case, where there are uniform nonsimultaneous parallel machines, was to show that LMULTIFIT obeys the bounds of the earlier MULTIFIT variants in the simultaneous machines case for the instances considered in those works.

Using LPT for UNMSP has been considered in [18], where worst-case approximation bound of 5/3 was shown in the general case, as well as a better bound for the case where there are only two machines.

For the case where the number of machines is constant, a PTAS exists for UNMSP [11], which was derived from a PTAS for scheduling on a constant number of uniform processors with fixed jobs from [5]. As the objective function for scheduling with fixed jobs that are at the beginning of the schedule and scheduling with unavailability periods that are at the beginning of the schedule differ, the PTAS from [5] can not be used unaltered to address UNMSP. To address UNMSP, the PTAS from [5] is first run for the transformed problem instance where the unavailability periods become fixed jobs, and then for all problem instances resulting from successively removing the machine with the latest end of a fixed job from

the transformed instance [11]. This accounts for the cases where a number between 1 and *m* − 1 of processors start processing after the end of the optimal schedule.

In [19], a lower bound is derived for the end of an optimal schedule of an UNMSP instance, and using that bound approximation factors for LMULTIFIT schedules of randomly generated instances are determined. The reasonably extensive experiments described in [19] suggest that LMULTIFIT is a good option for solving UNMSP in practice, not only because of being fast and easy to implement, but also because it has very good approximation factors (less than 1.03) for the generated instances with an average of at least five jobs for each machine. In order to obtain the approximation factors, a lower bound for the end of the optimal schedule that can be calculated directly from the problem instance was used.

#### **4.2 Multiprocessor scheduling with availability constraints**

In this section, we consider the multiprocessor scheduling problem where downtimes can occur at any time during the scheduling horizon.

Surveys with focus on scheduling with availability constraints are given in [20–24]. Besides the makespan, the authors of these works survey work on various other objective functions such as total completion time, and also address additional variants of the problem, such as its resumable version.

Unless assumptions about the unavailability periods are made or unless P = NP, there is no polynomial-time approximation algorithm with a constant worst-case approximation bound for the problem of scheduling with unavailability periods to minimize the maximum completion time, since there is a polynomial-time reduction from the NP-hard problem of 3-Partition to the problem of finding a schedule that has a maximum completion time that is at most α times the end of an optimal schedule for this problem. We next outline such a reduction. Let *X* be an instance of 3-Partition, that is, a set of 3*m* positive integers, given with the purpose of finding out whether there is a partition of these numbers into *m* sets, such that the sum of the numbers in each set is the same for all sets. Let *S* be the sum of all numbers in *X*. The instance *Y* of scheduling with unavailability periods that we build is given as follows: there are *m* processors, each of which has an unavailability period of duration (α + 1)*S* that starts at time *S*/*m*, and the job durations in *Y* are the numbers in *X*. *X* is a yes-instance of 3-Partition if and only if in instance *Y*, the optimal schedule ends at time *S*/*m*. In such a situation, any approximation algorithm with worst-case approximation factor α for scheduling with availability constraints will find a schedule that ends at or before time *S*/*m* which is less than (α + 1)*S*. Thus, the found schedule must end before or when the unavailability periods start, at time *S*/*m*. In such a schedule, the sets of durations of jobs on each processor are a 3-Partition of *X*. Therefore, any polynomial-time approximation algorithm for scheduling with unavailability periods with a worst-case approximation factor α can be used to solve 3-Partition in polynomial time.

#### *4.2.1 Scheduling on identical machines with unavailability periods*

For resumable scheduling, where the execution of jobs may continue after a downtime that interrupted them, but where jobs cannot be preempted by the scheduling algorithm, and where one machine does not shut down and all other machines shut down at most once, Lee shows that the makespan of LPT is in the worst case (*m* + 1)/2 times the optimal makespan [25].

In [1], Hwang and Chang make the assumption that at most half of the machines are unavailable at any time, and show for this situation that the worst-case approximation bound of LPT is 2. In [3], it is shown that no polynomial algorithm can

**75**

Section 5.2.

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods*

have a better bound than 2 for this problem unless *P* = *NP*. The result from [1] is generalized in [2] where it is shown that if at most λ ∈ {1,…,*m* − 1} machines may be

In [26], scheduling with at most one unavailability period on each machine is considered and exact algorithms are given for small problem instances. The authors consider separately the case of identical jobs, and also consider total completion time beside the makespan as an objective function. For larger

instances, they propose an LPT-like algorithm, which assigns jobs in nonincreasing order of their processing time to the fastest machine on which they would finish being processed at the earliest time. They also do experiments on a total number of 68 generated instances where error margins of at most 5.6% are observed. They do not compare their heuristic to the previously proposed heuristic from [4], which we discuss in Section 5.1.2, which was also proposed for this problem, even though its worst-case approximation bound was shown for the objective function of

The problem of scheduling with fixed jobs is given as a number of processors, where each processor may have jobs that must be executed during certain given periods on it, together with a number of other jobs which can be executed by any processor. As noted in Section 1, job durations or required execution times are expressed for example as a number of significant units such as clock cycles. For uniform processors this number represents the time needed by a job to be executed on the slowest processor. In case there are uniform processors, each processor also has a speed factor, by which the time needed by a job on the slowest processor is divided in order to obtain the time needed for the processor to execute the job. As noted before, the problem of scheduling with fixed jobs differs from the problem of scheduling with unavailability periods in that its maximum completion

In [5], Scharbrodt et al. give a polynomial-time approximation scheme for scheduling on a constant number of uniform machines with fixed jobs. They also show that it is NP-hard to obtain a schedule that ends within a factor of less than 1.5 when scheduling on identical processors with at most one fixed job on each machine. Even though they do not specify their result in this way, their proof that no polynomial-time approximation algorithm can have a better worst-case approximation bound than 1.5 for multiprocessor scheduling with fixed jobs does not use the fact that there can be more than one fixed job on each machine, which implies the previous statement. If all fixed jobs are at the beginning of the schedule, the results presented in Section 4.1 apply, as the optimal schedule of each problem instance of scheduling on nonsimultaneous machines can only potentially get worse when scheduling with fixed jobs is considered instead, and since the resulting schedule of an approximation algorithm ends later for scheduling with fixed jobs only if its maximum completion time is the completion time of a fixed job, which the optimal schedule also needs to execute. We next consider the case where there is at most one fixed job on each machine in Section 5.1, and the case where there can be multiple fixed jobs on each machine in

time cannot be earlier than the latest completion time of a fixed job.

unavailable at any time, LPT has a worst-case approximation bound of

[*m*/(*m*−λ)], and that this bound is tight for LPT.

*4.2.2 Scheduling on uniform machines with unavailability periods*

*DOI: http://dx.doi.org/10.5772/intechopen.89694*

scheduling with fixed jobs.

**5. Scheduling with fixed jobs**

1 + \_1 2

#### *Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods DOI: http://dx.doi.org/10.5772/intechopen.89694*

have a better bound than 2 for this problem unless *P* = *NP*. The result from [1] is generalized in [2] where it is shown that if at most λ ∈ {1,…,*m* − 1} machines may be unavailable at any time, LPT has a worst-case approximation bound of 1 + \_1 2 [*m*/(*m*−λ)], and that this bound is tight for LPT.

#### *4.2.2 Scheduling on uniform machines with unavailability periods*

In [26], scheduling with at most one unavailability period on each machine is considered and exact algorithms are given for small problem instances. The authors consider separately the case of identical jobs, and also consider total completion time beside the makespan as an objective function. For larger instances, they propose an LPT-like algorithm, which assigns jobs in nonincreasing order of their processing time to the fastest machine on which they would finish being processed at the earliest time. They also do experiments on a total number of 68 generated instances where error margins of at most 5.6% are observed. They do not compare their heuristic to the previously proposed heuristic from [4], which we discuss in Section 5.1.2, which was also proposed for this problem, even though its worst-case approximation bound was shown for the objective function of scheduling with fixed jobs.

#### **5. Scheduling with fixed jobs**

*Scheduling Problems - New Applications and Trends*

the transformed instance [11]. This accounts for the cases where a number between 1 and *m* − 1 of processors start processing after the end of the optimal schedule. In [19], a lower bound is derived for the end of an optimal schedule of an UNMSP instance, and using that bound approximation factors for LMULTIFIT schedules of randomly generated instances are determined. The reasonably extensive experiments described in [19] suggest that LMULTIFIT is a good option for solving UNMSP in practice, not only because of being fast and easy to implement, but also because it has very good approximation factors (less than 1.03) for the generated instances with an average of at least five jobs for each machine. In order to obtain the approximation factors, a lower bound for the end of the optimal schedule

that can be calculated directly from the problem instance was used.

In this section, we consider the multiprocessor scheduling problem where

Surveys with focus on scheduling with availability constraints are given in [20–24]. Besides the makespan, the authors of these works survey work on various other objective functions such as total completion time, and also address additional

Unless assumptions about the unavailability periods are made or unless P = NP, there is no polynomial-time approximation algorithm with a constant worst-case approximation bound for the problem of scheduling with unavailability periods to minimize the maximum completion time, since there is a polynomial-time reduction from the NP-hard problem of 3-Partition to the problem of finding a schedule that has a maximum completion time that is at most α times the end of an optimal schedule for this problem. We next outline such a reduction. Let *X* be an instance of 3-Partition, that is, a set of 3*m* positive integers, given with the purpose of finding out whether there is a partition of these numbers into *m* sets, such that the sum of the numbers in each set is the same for all sets. Let *S* be the sum of all numbers in *X*. The instance *Y* of scheduling with unavailability periods that we build is given as follows: there are *m* processors, each of which has an unavailability period of duration (α + 1)*S* that starts at time *S*/*m*, and the job durations in *Y* are the numbers in *X*. *X* is a yes-instance of 3-Partition if and only if in instance *Y*, the optimal schedule ends at time *S*/*m*. In such a situation, any approximation algorithm with worst-case approximation factor α for scheduling with availability constraints will find a schedule that ends at or before time *S*/*m* which is less than (α + 1)*S*. Thus, the found schedule must end before or when the unavailability periods start, at time *S*/*m*. In such a schedule, the sets of durations of jobs on each processor are a 3-Partition of *X*. Therefore, any polynomial-time approximation algorithm for scheduling with unavailability periods with a worst-case approximation factor α can be

**4.2 Multiprocessor scheduling with availability constraints**

downtimes can occur at any time during the scheduling horizon.

variants of the problem, such as its resumable version.

used to solve 3-Partition in polynomial time.

*4.2.1 Scheduling on identical machines with unavailability periods*

worst case (*m* + 1)/2 times the optimal makespan [25].

For resumable scheduling, where the execution of jobs may continue after a downtime that interrupted them, but where jobs cannot be preempted by the scheduling algorithm, and where one machine does not shut down and all other machines shut down at most once, Lee shows that the makespan of LPT is in the

In [1], Hwang and Chang make the assumption that at most half of the machines are unavailable at any time, and show for this situation that the worst-case approximation bound of LPT is 2. In [3], it is shown that no polynomial algorithm can

**74**

The problem of scheduling with fixed jobs is given as a number of processors, where each processor may have jobs that must be executed during certain given periods on it, together with a number of other jobs which can be executed by any processor. As noted in Section 1, job durations or required execution times are expressed for example as a number of significant units such as clock cycles. For uniform processors this number represents the time needed by a job to be executed on the slowest processor. In case there are uniform processors, each processor also has a speed factor, by which the time needed by a job on the slowest processor is divided in order to obtain the time needed for the processor to execute the job.

As noted before, the problem of scheduling with fixed jobs differs from the problem of scheduling with unavailability periods in that its maximum completion time cannot be earlier than the latest completion time of a fixed job.

In [5], Scharbrodt et al. give a polynomial-time approximation scheme for scheduling on a constant number of uniform machines with fixed jobs. They also show that it is NP-hard to obtain a schedule that ends within a factor of less than 1.5 when scheduling on identical processors with at most one fixed job on each machine. Even though they do not specify their result in this way, their proof that no polynomial-time approximation algorithm can have a better worst-case approximation bound than 1.5 for multiprocessor scheduling with fixed jobs does not use the fact that there can be more than one fixed job on each machine, which implies the previous statement.

If all fixed jobs are at the beginning of the schedule, the results presented in Section 4.1 apply, as the optimal schedule of each problem instance of scheduling on nonsimultaneous machines can only potentially get worse when scheduling with fixed jobs is considered instead, and since the resulting schedule of an approximation algorithm ends later for scheduling with fixed jobs only if its maximum completion time is the completion time of a fixed job, which the optimal schedule also needs to execute.

We next consider the case where there is at most one fixed job on each machine in Section 5.1, and the case where there can be multiple fixed jobs on each machine in Section 5.2.

#### **5.1 Scheduling with at most one fixed job on each machine**

When scheduling on multiple processors with at most one fixed job on each machine, LPT and MULTIFIT variants have been shown to achieve a worst-case approximation bound of 1.5, which is best possible for this problem unless *P* = *NP*.

#### *5.1.1 Same-speed processors*

For scheduling on identical machines with at most one fixed job on each machine, an LPT-like algorithm, LPTX, was given in [3], for which a worst-case approximation bound of 1.5 was shown. Before running LPT, LPTX creates an order of processors, which is then used by LPT to break ties in case two processors become available at the same time. The ordered list of processors created before applying LPT is built in two steps:


#### *5.1.2 Uniform processors*

In the more general case of scheduling on uniform machines with at most one fixed job on each machine, a MULTIFIT-like algorithm, LMULTIFIT, was given in [4], which achieves the worst-case approximation bound of 1.5. For a MULTIFIT variant to work in the presence of downtimes, it must be specified how it deals with the fact that there are more than one time interval in which jobs can be scheduled on one processor.

After a MULTIFIT deadline is assigned and before applying the bin packing algorithm FFD (see Section 3), LMULTIFIT orders all time intervals in which jobs can be scheduled in non-decreasing order of their *length*. Here, the length of a time interval is the duration of the time interval multiplied by the speed factor of the processor on which the interval occurs.

#### **5.2 Scheduling with multiple fixed jobs on each machine**

For scheduling on identical processors with fixed jobs, where the number of fixed jobs on a machine can be arbitrary, approximation algorithms that are much more complex than LPT and MULTIFIT were given in [27], with a worst-case approximation bound of 1.5 + ε, where ε is the parameter of a fully polynomial time approximation scheme (FPTAS) for the multiple subset sum problem, and in [6] with a worst-case approximation bound of 1.5, where a FPTAS for the multiple knapsack problem is used as a subroutine.

In [28], a very long proof is outlined that LMULTIFIT achieves a worst-case approximation bound of 1.5 when scheduling on identical processors with at most two fixed jobs on each machine. In [29], an algorithm using two MULTIFIT-like algorithms is shown to have a worst-case approximation bound of 1.625, which likely can be improved to 1.6 without excessive effort.

The time complexity of the MULTIFIT-like and LPT-like algorithms is significanlty lower than that of the algorithms from [6, 27], and they are also significantly easier to

**77**

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods*

implement; however, there is little hope in our opinion that bounds better than 1.55 can be shown in the general case for such algorithms with proofs of reasonable length. Given such problems, the user must decide what is best suited for his or her needs.

Worst-case approximation results in this research area about LPT and MULTIFIT variants mainly use proofs by contradiction in which some proof techniques appear very often. We next describe two techniques that we consider to be the most relevant, and then comment upon some other methods that are used relatively often. In the following, we call job lengths the durations of the jobs on the

A very well-known proof method is that of assuming that there exists a minimal counterexample to a theorem T, that is, a problem instance for which the algorithm's schedule does not obey that theorem, with a minimal number of processors, of jobs, of downtimes (or of fixed jobs) that do not start at the beginning of the schedule, and/ or of other quantities that can be minimized which are chosen to fit the statements to prove. A minimal counterexample exists whenever there is a counterexample, and thus, showing that it does not exist proves T. In order to define minimality among counterexamples, the author of the proof first chooses a partial order among the problem instances. An instance which is minimal according to this partial order among the instances for which a theorem T does not apply is called a minimal counterexample. This method can be very powerful, because after assuming that a minimal counterexample does not obey a theorem T, many useful properties of a minimal counterexample can be derived from the fact that no *lesser* counterexample exists,

Here, a lesser counterexample is a counterexample with less processors, or less tasks, or less downtimes, or with a job with a smaller length, depending on how the order of instances was defined. Showing that a minimal counterexample does not

The theorem to prove could be that the worst-case approximation bound holds, but it can also be an intermediary result that is later used to prove the worst-case approximation bound. One could address instances that have a certain property first, and then show that the worst-case approximation bound holds for these, for example by using a minimal counterexample among these instances, and then do

Sometimes it is enough to define the partial order only using the number of processors [11], while in most cases, it is useful to include multiple characteristics of problem instances, such as all or a part of the characteristics enumerated above. In one situation, a minimal counterexample was defined to also have minimal job lengths, meaning that if in a minimal counterexample the length of one job is

For a problem instance that does not obey a worst-case approximation bound, there is a job (*X*) that is scheduled such that it crosses the bound to prove times the end of an optimal schedule (*B*) for LPT-like algorithms, or that can not be scheduled when the deadline is at *B* for MULTIFIT-like algorithms. If the order defined on

exist is usually significantly easier than developing a direct proof for T.

reduced, the resulting instance is not a counterexample [28].

*DOI: http://dx.doi.org/10.5772/intechopen.89694*

**6. Proof techniques**

slowest processor.

**6.1 Minimal counterexample**

which can ultimately lead to a contradiction.

the same for all other instances.

**6.2 Weighing arguments**

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods DOI: http://dx.doi.org/10.5772/intechopen.89694*

implement; however, there is little hope in our opinion that bounds better than 1.55 can be shown in the general case for such algorithms with proofs of reasonable length. Given such problems, the user must decide what is best suited for his or her needs.

#### **6. Proof techniques**

*Scheduling Problems - New Applications and Trends*

*5.1.1 Same-speed processors*

applying LPT is built in two steps:

can start executing jobs.

processor on which the interval occurs.

knapsack problem is used as a subroutine.

likely can be improved to 1.6 without excessive effort.

**5.2 Scheduling with multiple fixed jobs on each machine**

their downtime.

*5.1.2 Uniform processors*

**5.1 Scheduling with at most one fixed job on each machine**

When scheduling on multiple processors with at most one fixed job on each machine, LPT and MULTIFIT variants have been shown to achieve a worst-case approximation bound of 1.5, which is best possible for this problem unless *P* = *NP*.

For scheduling on identical machines with at most one fixed job on each machine, an LPT-like algorithm, LPTX, was given in [3], for which a worst-case approximation bound of 1.5 was shown. Before running LPT, LPTX creates an order of processors, which is then used by LPT to break ties in case two processors become available at the same time. The ordered list of processors created before

1.All processors that have an unavailability period that is not at the beginning of the schedule are assigned to this list in non-decreasing order of the start of

2.All other processors (that is, those which have the downtimes at the beginning of the scheduling period or have no downtime at all) are appended to the list built in the previous step in non-decreasing order of the times at which they

In the more general case of scheduling on uniform machines with at most one fixed job on each machine, a MULTIFIT-like algorithm, LMULTIFIT, was given in [4], which achieves the worst-case approximation bound of 1.5. For a MULTIFIT variant to work in the presence of downtimes, it must be specified how it deals with the fact that there are more than one time interval in which jobs can be scheduled on one processor. After a MULTIFIT deadline is assigned and before applying the bin packing algorithm FFD (see Section 3), LMULTIFIT orders all time intervals in which jobs can be scheduled in non-decreasing order of their *length*. Here, the length of a time interval is the duration of the time interval multiplied by the speed factor of the

For scheduling on identical processors with fixed jobs, where the number of fixed jobs on a machine can be arbitrary, approximation algorithms that are much more complex than LPT and MULTIFIT were given in [27], with a worst-case approximation bound of 1.5 + ε, where ε is the parameter of a fully polynomial time approximation scheme (FPTAS) for the multiple subset sum problem, and in [6] with a worst-case approximation bound of 1.5, where a FPTAS for the multiple

In [28], a very long proof is outlined that LMULTIFIT achieves a worst-case approximation bound of 1.5 when scheduling on identical processors with at most two fixed jobs on each machine. In [29], an algorithm using two MULTIFIT-like algorithms is shown to have a worst-case approximation bound of 1.625, which

The time complexity of the MULTIFIT-like and LPT-like algorithms is significanlty lower than that of the algorithms from [6, 27], and they are also significantly easier to

**76**

Worst-case approximation results in this research area about LPT and MULTIFIT variants mainly use proofs by contradiction in which some proof techniques appear very often. We next describe two techniques that we consider to be the most relevant, and then comment upon some other methods that are used relatively often. In the following, we call job lengths the durations of the jobs on the slowest processor.

#### **6.1 Minimal counterexample**

A very well-known proof method is that of assuming that there exists a minimal counterexample to a theorem T, that is, a problem instance for which the algorithm's schedule does not obey that theorem, with a minimal number of processors, of jobs, of downtimes (or of fixed jobs) that do not start at the beginning of the schedule, and/ or of other quantities that can be minimized which are chosen to fit the statements to prove. A minimal counterexample exists whenever there is a counterexample, and thus, showing that it does not exist proves T. In order to define minimality among counterexamples, the author of the proof first chooses a partial order among the problem instances. An instance which is minimal according to this partial order among the instances for which a theorem T does not apply is called a minimal counterexample.

This method can be very powerful, because after assuming that a minimal counterexample does not obey a theorem T, many useful properties of a minimal counterexample can be derived from the fact that no *lesser* counterexample exists, which can ultimately lead to a contradiction.

Here, a lesser counterexample is a counterexample with less processors, or less tasks, or less downtimes, or with a job with a smaller length, depending on how the order of instances was defined. Showing that a minimal counterexample does not exist is usually significantly easier than developing a direct proof for T.

The theorem to prove could be that the worst-case approximation bound holds, but it can also be an intermediary result that is later used to prove the worst-case approximation bound. One could address instances that have a certain property first, and then show that the worst-case approximation bound holds for these, for example by using a minimal counterexample among these instances, and then do the same for all other instances.

Sometimes it is enough to define the partial order only using the number of processors [11], while in most cases, it is useful to include multiple characteristics of problem instances, such as all or a part of the characteristics enumerated above. In one situation, a minimal counterexample was defined to also have minimal job lengths, meaning that if in a minimal counterexample the length of one job is reduced, the resulting instance is not a counterexample [28].

#### **6.2 Weighing arguments**

For a problem instance that does not obey a worst-case approximation bound, there is a job (*X*) that is scheduled such that it crosses the bound to prove times the end of an optimal schedule (*B*) for LPT-like algorithms, or that can not be scheduled when the deadline is at *B* for MULTIFIT-like algorithms. If the order defined on instances includes the number of jobs, there is only one such job in a minimal counterexample to (for example) a theorem that the analyzed algorithm (A) generates only schedules that obey the bound. Otherwise, all jobs that would be scheduled afterward can be removed and a lesser counterexample could be obtained, resulting in a contradiction. As a consequence of how LPT and MULTIFIT work, *X* is the smallest job of the minimal counterexample in both cases.

The schedule *SA* generated by an LPT-like algorithm A until a job would cross *B* and the schedule *SA* generated by a MULTIFIT-like algorithm A if the MULTIFIT deadline is at *B* do not contain the job *X*. An optimal schedule, however, contains all jobs, including *X*.

Therefore, the optimal schedule has more total execution time than *SA*. Also, if nonzero weights are assigned to each job, the optimal schedule has a total weight of all its jobs that is greater than that of *SA*, the difference being the weight of *X*. An adequate assignment of weights to jobs can lead to the conclusion that the sum of weights of all jobs contained in the schedule *SA* is at least the sum of the weights of all jobs in the considered optimal schedule, a contradiction.

There are infinite ways of assigning weights, and there is no unique strategy that leads to success. Usually, the weight function is monotonic with regard to job lengths, and, as *X* has the smallest job length, its weight can be set to 1. In the following, we denote both the job *X* and the time *X* would need to be executed on the slowest processor by *X*. The other weights can be assigned for intervals of job lengths, for example, a job with length within [*X*,1.5*X*) could be assigned weight 1. Weights can also be assigned otherwise: for example, a job with a certain property can be chosen to be the end of a weight interval. Jobs that have a certain property can also be assigned a specific weight that corresponds to that property. Of course, while proving different theorems that lead to the proof of a worst-case approximation bound, a new weight function can be chosen for each statement to prove.

#### **6.3 Normalizing time intervals and job execution times**

In order to reason easier about time, one can divide all durations of time intervals in which jobs can be scheduled by *X* if scheduling on identical processors. For uniform processors, such intervals can be divided by the time it would take *X* to execute on the processor on which the interval occurs, in order to derive the *length* of the interval [4]. Also, all job durations can be divided by *X* and these normalized durations can be used in the proofs. For example, a theorem could be proved that there are no jobs that have a longer duration than 5, or it can be stated that the unused time intervals on processors before the MULTIFIT deadline *B* all have length less than 1, as otherwise *X* would have been scheduled in one of those intervals.

#### **6.4 Task density**

In the case of uniform processors, the time intervals can have unbounded lengths because the speed factors may be arbitrarily high. A way to describe the amount of jobs assigned within a schedule in such an interval is to use *task densities*, which can be defined for each task as being the ratio between its weight and its length. Also, a *task type density* can be defined as a lower bound for all possible task densities of tasks of that type. The concept of task density can be used in order to reason about time intervals that may be very long. For example, the total weight of all tasks in an interval of length *t* is at most *t* times the maximum task type density among all task types represented within that interval.

**79**

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods*

We use the notations from the previous subsection. Since *X* is not contained in *SA*, there must be a processor *p*\* in the optimal schedule that has a total execution time that is greater than that of *SA* on *p*\*. Such a processor can be analyzed in detail and may be shown to have certain properties that, in conjunction with other methods, result in proofs of useful theorems. For example, the existence of *p*\* may imply a certain minimum duration of the optimal schedule, in conjunction with the observation that *X* could not be fitted by *A* on *p*\* without causing the maximum

In this work, we considered worst-case approximation for scheduling on multiple machines with availability constraints or with fixed jobs in order to minimize the maximum completion time. We surveyed results obtained in this research area

Prominent among these algorithms are LPT and MULTIFIT and their variants, whereas for multiprocessor scheduling with fixed jobs, more complicated algorithms were used to achieve best possible worst-case approximation bounds in the class of polynomial algorithms assuming that *P* ≠ *NP* in the general case where there

The problem of scheduling with availability constraints cannot be approximated by a polynomial-time algorithm with a constant worst-case approximation bound, even if there is at most one downtime on each machine, unless assumptions about the downtimes are made. The results we presented in this area address the problem of scheduling on identical processors with at most one downtime on each machine,

Due to its different objective function, the problem of scheduling on identical parallel machines with fixed jobs allowed for the development of a polynomial-time approximation algorithm with a worst-case approximation bound of 1.5, and the development of a PTAS for scheduling on a constant number of uniform machines

The MULTIFIT and LPT variants developed for the discussed variants of these problems could be useful in practice, as their time complexity is low and thus they should be able to address very large problem instances, as they are easy to implement, and because in some cases their worst-case approximation bounds could be considered to be good enough. In the case of scheduling on uniform nonsimultaneous machines, the average performance of a MULTIFIT variant was studied, and shown to be very good, as the experiments suggest that in general, for instances that can be relevant in practice and for which exhaustive search is not an option, the algorithm returns schedules with a maximum completion time that is within 3% of

We also elaborated on the most encountered proof techniques in worst-case

The limitations of the presented works result mainly from the difficulty of the problem of scheduling with unavailability periods when considering the subject of approximation. To assess how well the proposed heuristics for this problem perform under such conditions is difficult, as it is hard to have a good estimate of the optimal schedule unless it is computed by an exact algorithm as was done in [26]. This problem has therefore been addressed only by considering the special case where

approximation bound proofs for LPT and MULTIFIT variants.

there is at most one downtime on each machine.

**6.5 Processor with more execution time in the optimal schedule**

*DOI: http://dx.doi.org/10.5772/intechopen.89694*

completion time of *SA* to exceed *B*.

**7. Conclusions and future challenges**

and commented upon the algorithms used.

with various assumptions.

with fixed jobs was also possible.

that of an optimal schedule.

can be any number of fixed jobs on each machine.

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods DOI: http://dx.doi.org/10.5772/intechopen.89694*

#### **6.5 Processor with more execution time in the optimal schedule**

We use the notations from the previous subsection. Since *X* is not contained in *SA*, there must be a processor *p*\* in the optimal schedule that has a total execution time that is greater than that of *SA* on *p*\*. Such a processor can be analyzed in detail and may be shown to have certain properties that, in conjunction with other methods, result in proofs of useful theorems. For example, the existence of *p*\* may imply a certain minimum duration of the optimal schedule, in conjunction with the observation that *X* could not be fitted by *A* on *p*\* without causing the maximum completion time of *SA* to exceed *B*.

#### **7. Conclusions and future challenges**

*Scheduling Problems - New Applications and Trends*

jobs, including *X*.

statement to prove.

smallest job of the minimal counterexample in both cases.

all jobs in the considered optimal schedule, a contradiction.

**6.3 Normalizing time intervals and job execution times**

among all task types represented within that interval.

instances includes the number of jobs, there is only one such job in a minimal counterexample to (for example) a theorem that the analyzed algorithm (A) generates only schedules that obey the bound. Otherwise, all jobs that would be scheduled afterward can be removed and a lesser counterexample could be obtained, resulting in a contradiction. As a consequence of how LPT and MULTIFIT work, *X* is the

The schedule *SA* generated by an LPT-like algorithm A until a job would cross *B* and the schedule *SA* generated by a MULTIFIT-like algorithm A if the MULTIFIT deadline is at *B* do not contain the job *X*. An optimal schedule, however, contains all

Therefore, the optimal schedule has more total execution time than *SA*. Also, if nonzero weights are assigned to each job, the optimal schedule has a total weight of all its jobs that is greater than that of *SA*, the difference being the weight of *X*. An adequate assignment of weights to jobs can lead to the conclusion that the sum of weights of all jobs contained in the schedule *SA* is at least the sum of the weights of

There are infinite ways of assigning weights, and there is no unique strategy that leads to success. Usually, the weight function is monotonic with regard to job lengths, and, as *X* has the smallest job length, its weight can be set to 1. In the following, we denote both the job *X* and the time *X* would need to be executed on the slowest processor by *X*. The other weights can be assigned for intervals of job lengths, for example, a job with length within [*X*,1.5*X*) could be assigned weight 1. Weights can also be assigned otherwise: for example, a job with a certain property can be chosen to be the end of a weight interval. Jobs that have a certain property can also be assigned a specific weight that corresponds to that property. Of course, while proving different theorems that lead to the proof of a worst-case approximation bound, a new weight function can be chosen for each

In order to reason easier about time, one can divide all durations of time intervals in which jobs can be scheduled by *X* if scheduling on identical processors. For uniform processors, such intervals can be divided by the time it would take *X* to execute on the processor on which the interval occurs, in order to derive the *length* of the interval [4]. Also, all job durations can be divided by *X* and these normalized durations can be used in the proofs. For example, a theorem could be proved that there are no jobs that have a longer duration than 5, or it can be stated that the unused time intervals on processors before the MULTIFIT deadline *B* all have length less than 1, as otherwise *X* would have been scheduled in one of those

In the case of uniform processors, the time intervals can have unbounded lengths because the speed factors may be arbitrarily high. A way to describe the amount of jobs assigned within a schedule in such an interval is to use *task densities*, which can be defined for each task as being the ratio between its weight and its length. Also, a *task type density* can be defined as a lower bound for all possible task densities of tasks of that type. The concept of task density can be used in order to reason about time intervals that may be very long. For example, the total weight of all tasks in an interval of length *t* is at most *t* times the maximum task type density

**78**

intervals.

**6.4 Task density**

In this work, we considered worst-case approximation for scheduling on multiple machines with availability constraints or with fixed jobs in order to minimize the maximum completion time. We surveyed results obtained in this research area and commented upon the algorithms used.

Prominent among these algorithms are LPT and MULTIFIT and their variants, whereas for multiprocessor scheduling with fixed jobs, more complicated algorithms were used to achieve best possible worst-case approximation bounds in the class of polynomial algorithms assuming that *P* ≠ *NP* in the general case where there can be any number of fixed jobs on each machine.

The problem of scheduling with availability constraints cannot be approximated by a polynomial-time algorithm with a constant worst-case approximation bound, even if there is at most one downtime on each machine, unless assumptions about the downtimes are made. The results we presented in this area address the problem of scheduling on identical processors with at most one downtime on each machine, with various assumptions.

Due to its different objective function, the problem of scheduling on identical parallel machines with fixed jobs allowed for the development of a polynomial-time approximation algorithm with a worst-case approximation bound of 1.5, and the development of a PTAS for scheduling on a constant number of uniform machines with fixed jobs was also possible.

The MULTIFIT and LPT variants developed for the discussed variants of these problems could be useful in practice, as their time complexity is low and thus they should be able to address very large problem instances, as they are easy to implement, and because in some cases their worst-case approximation bounds could be considered to be good enough. In the case of scheduling on uniform nonsimultaneous machines, the average performance of a MULTIFIT variant was studied, and shown to be very good, as the experiments suggest that in general, for instances that can be relevant in practice and for which exhaustive search is not an option, the algorithm returns schedules with a maximum completion time that is within 3% of that of an optimal schedule.

We also elaborated on the most encountered proof techniques in worst-case approximation bound proofs for LPT and MULTIFIT variants.

The limitations of the presented works result mainly from the difficulty of the problem of scheduling with unavailability periods when considering the subject of approximation. To assess how well the proposed heuristics for this problem perform under such conditions is difficult, as it is hard to have a good estimate of the optimal schedule unless it is computed by an exact algorithm as was done in [26]. This problem has therefore been addressed only by considering the special case where there is at most one downtime on each machine.

In the future, it may be interesting to compare the heuristics proposed for the same problems experimentally.

Another limitation of the discussed works and of many other research works on scheduling results from the fact they attempt to understand problems with one, two, or at most three aspects at one time, whereas in many practical problems such as some production planning problems, many aspects occur at once. For example, availability constraints can appear alongside a multitude of other constraints that have to be considered simultaneously. These can be precedence constraints, that certain jobs have to be assigned to certain machines, or preferences of the manufacturer that the machines should not have more than a 60% or another predefined load for example in order to leave room for unexpected events. Furthermore, orders often come online, and if an urgent order from an important client needs to be given priority, this can alter the delivery times of other orders. Also, delivery times and delays have a big relevance in practice, as not delivering on time can cause fines. Such practical problems can also have sequence-dependent setup times, the necessity for setup operators to be present to perform setups, the preference that setup times are kept low by putting jobs from the same family of types of jobs consecutively on machines whenever possible, the necessity for workers to attend to certain machines while production takes place, and worker breaks and holidays. The preexisting schedule also has to be kept unchanged for a predefined time period since materials are brought to the production place in preparation for the production process. In addition, orders may have priorities and deadlines. For such problems, given the time constraints in which the schedule needs to be generated and that there can be thousands of jobs, usually a heuristic is employed that first orders the jobs for example by using priorities assigned to them and/or their deadlines and then schedules them on the machines in that order while also obeying all constraints and attempting to fulfill all preferences. Difficulties in researching such problems include that probably for different sets of orders different scheduling strategies may be better, and that an optimal schedule may be very hard to find and thus it is hard to quantify how well a heuristic performs.

#### **Acknowledgements**

This publication was supported by the Open Access Publication Fund of Technische Universität Berlin.

#### **Conflict of interest**

The author declares no conflict of interest.

#### **Abbreviations**


**81**

**Author details**

Liliana Grigoriu1,2

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods*

1 Department of Computer Science and Engineering, Faculty of Control and

2 Department of Mathematics, Technical University of Berlin, Berlin, Germany

© 2019 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium,

Computers, Politehnica University Bucharest, Bucharest, Romania

\*Address all correspondence to: liliana.grigoriu@cs.pub.ro

provided the original work is properly cited.

*DOI: http://dx.doi.org/10.5772/intechopen.89694*

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods DOI: http://dx.doi.org/10.5772/intechopen.89694*

### **Author details**

*Scheduling Problems - New Applications and Trends*

same problems experimentally.

a heuristic performs.

**Acknowledgements**

**Conflict of interest**

**Abbreviations**

Technische Universität Berlin.

The author declares no conflict of interest.

MSP multiprocessor scheduling problem

LPT largest processing time FFD first fit decreasing

NMSP nonsimultaneous multiprocessor scheduling problem

UNMSP uniform nonsimultaneous multiprocessor scheduling problem

In the future, it may be interesting to compare the heuristics proposed for the

Another limitation of the discussed works and of many other research works on scheduling results from the fact they attempt to understand problems with one, two, or at most three aspects at one time, whereas in many practical problems such as some production planning problems, many aspects occur at once. For example, availability constraints can appear alongside a multitude of other constraints that have to be considered simultaneously. These can be precedence constraints, that certain jobs have to be assigned to certain machines, or preferences of the manufacturer that the machines should not have more than a 60% or another predefined load for example in order to leave room for unexpected events. Furthermore, orders often come online, and if an urgent order from an important client needs to be given priority, this can alter the delivery times of other orders. Also, delivery times and delays have a big relevance in practice, as not delivering on time can cause fines. Such practical problems can also have sequence-dependent setup times, the necessity for setup operators to be present to perform setups, the preference that setup times are kept low by putting jobs from the same family of types of jobs consecutively on machines whenever possible, the necessity for workers to attend to certain machines while production takes place, and worker breaks and holidays. The preexisting schedule also has to be kept unchanged for a predefined time period since materials are brought to the production place in preparation for the production process. In addition, orders may have priorities and deadlines. For such problems, given the time constraints in which the schedule needs to be generated and that there can be thousands of jobs, usually a heuristic is employed that first orders the jobs for example by using priorities assigned to them and/or their deadlines and then schedules them on the machines in that order while also obeying all constraints and attempting to fulfill all preferences. Difficulties in researching such problems include that probably for different sets of orders different scheduling strategies may be better, and that an optimal schedule may be very hard to find and thus it is hard to quantify how well

This publication was supported by the Open Access Publication Fund of

**80**

Liliana Grigoriu1,2

1 Department of Computer Science and Engineering, Faculty of Control and Computers, Politehnica University Bucharest, Bucharest, Romania

2 Department of Mathematics, Technical University of Berlin, Berlin, Germany

\*Address all correspondence to: liliana.grigoriu@cs.pub.ro

© 2019 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

### **References**

[1] Hwang H-C, Chang SY. Parallel machines scheduling with machine shutdowns. Computers and Mathematics with Applications. June 1998;**36**:21-31

[2] Hwang H-C, Lee K, Chang SY. The effect of machine availability on the worst-case performance of LPT. Discrete Applied Mathematics. April 2005;**148**:49-61

[3] Grigoriu L, Friesen DK. Scheduling on same-speed processors with at most one downtime on each machine. Discrete Optimization. November 2010;**7**:212-221

[4] Grigoriu L, Friesen DK. Scheduling on uniform processors with at most one downtime on each machine. Discrete Optimization. November 2015;**17**:14-24

[5] Scharbrodt M, Steger A, Weisser H. Approximability of scheduling with fixed jobs. Journal of Scheduling. November 1999;**2**(6):267-284

[6] Jansen K, Pradel L, Schwarz UM, Svensson O. Faster approximation algorithms for scheduling with fixed jobs. In: 17th Conference of Computing: The Australasian Theory Symposium (CATS 2011), Perth, Australia, January. 2011

[7] Graham RL. Bounds on multiprocessing timing anomalies. SIAM Journal of Applied Mathematics. March 1969;**17**:416-429

[8] Coffman EG Jr, Garey MR, Johnson DS. An application of binpacking to multiprocessor scheduling. SIAM Journal on Computing. February 1978;**7**:1-17

[9] Hwang HC, Lim K. Exact performance of MULTIFIT for nonsimultaneous machines. Discrete Applied Mathematics. 2014;**167**:172-187 [10] Kellerer H. Algorithms for multiprocessor scheduling with machine release times. IIE Transactions. 1998;**30**:991-999

[11] Grigoriu L, Friesen DK. Approximation for scheduling on uniform nonsimultaneous parallel machines. Journal of Scheduling. December 2017;**20**:593-600

[12] Chen B. Tighter bound for multifit scheduling on uniform processors. Discrete Applied Mathematics. May 1991;**31**:227-260

[13] Lee CY. Parallel machine scheduling with nonsimultaneous machine available time. Discrete Applied Mathematics. January 1991;**30**:53-61

[14] Chang SY, Hwang HC. The worst-case analysis of the MULTIFIT algorithm for scheduling nonsimultaneous parallel machines. Discrete Applied Mathematics. June 1999;**92**:135-147

[15] Yue M. On the exact upper bound of the MULTIFIT processor scheduling algorithm. Annals of Operations Research. December 1990;**24**:233-259

[16] Friesen DK, Langston MA. Bounds for multifit scheduling on uniform processors. SIAM Journal on Computing. February 1983;**12**:60-69

[17] Burkard RE, He Y. A note on MULTIFIT scheduling for uniform machines. Computing. 1998;**61**:277-283

[18] He Y. Uniform machine scheduling with machine available *constraints*. Acta Matematicae Applicatae Sinica (English Series). 2000;**16**:122-129

[19] Grigoriu L, Friesen DK. Scheduling on uniform nonsimultaneous parallel machines. In: Fink A, Fiigenschuh A, Geiger M, editors. Operations Research

**83**

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods*

[PhD thesis]. College Station, TX, USA:

[29] Grigoriu L. Scheduling on parallel machines with variable availability patterns [PhD thesis]. Bucharest, Romania: Politehnica University

Texas A&M University; 2010

Bucharest; 2012

*DOI: http://dx.doi.org/10.5772/intechopen.89694*

Proceedings 2016 Selected Papers of the Annual International Conference of the German Operations Research Society (GOR), Hannover, August 30– September 2. 2016. pp. 467-473

[20] Lee CY, Lei L, Pinedo M. Current trends in deterministic scheduling. Annals of Operations Research. April

[21] Sanlaville E, Schmidt G. Machine scheduling with availability constraints.

[22] Schmidt G. Scheduling with limited machine availability. European Journal of Operational Research. February

[23] Lee C-Y. Machine scheduling with availability constraints. In: Leung JY-T, editor. Handbook of Scheduling: Algorithms, Models and Performance Analysis. London: Chapman & Hall/

[24] Ma Y, Chu C, Zuo C. A survey of scheduling with deterministic machine availability constraints. Computers & Industrial Engineering. 2010;**58**:199-211

[25] Lee CY. Machine scheduling with an availability constraint. Journal of Global Optimization. December

[26] Kaabi J, Harrath Y. Scheduling on uniform parallel machines with periodic unavailability constraints. International

Journal of Production Research.

[27] Diedrich F, Jansen K. Improved approximation algorithms for

of 20th ACM-SIAM Symposium on Discrete Algorithms (SODA).

[28] Grigoriu L. Multiprocessor

scheduling with fixed jobs. Proceedings

scheduling with availability constraints

CRC; 2004. pp. 22-1-22-13

Acta Informatica. September

1997;**70**:1-41

1998;**35**:795-811

2000;**121**:1-15

1996;**9**:395-416

2019;**57**(1):216-227

2009:675-684

*Approximation for Scheduling on Parallel Machines with Fixed Jobs or Unavailability Periods DOI: http://dx.doi.org/10.5772/intechopen.89694*

Proceedings 2016 Selected Papers of the Annual International Conference of the German Operations Research Society (GOR), Hannover, August 30– September 2. 2016. pp. 467-473

[20] Lee CY, Lei L, Pinedo M. Current trends in deterministic scheduling. Annals of Operations Research. April 1997;**70**:1-41

[21] Sanlaville E, Schmidt G. Machine scheduling with availability constraints. Acta Informatica. September 1998;**35**:795-811

[22] Schmidt G. Scheduling with limited machine availability. European Journal of Operational Research. February 2000;**121**:1-15

[23] Lee C-Y. Machine scheduling with availability constraints. In: Leung JY-T, editor. Handbook of Scheduling: Algorithms, Models and Performance Analysis. London: Chapman & Hall/ CRC; 2004. pp. 22-1-22-13

[24] Ma Y, Chu C, Zuo C. A survey of scheduling with deterministic machine availability constraints. Computers & Industrial Engineering. 2010;**58**:199-211

[25] Lee CY. Machine scheduling with an availability constraint. Journal of Global Optimization. December 1996;**9**:395-416

[26] Kaabi J, Harrath Y. Scheduling on uniform parallel machines with periodic unavailability constraints. International Journal of Production Research. 2019;**57**(1):216-227

[27] Diedrich F, Jansen K. Improved approximation algorithms for scheduling with fixed jobs. Proceedings of 20th ACM-SIAM Symposium on Discrete Algorithms (SODA). 2009:675-684

[28] Grigoriu L. Multiprocessor scheduling with availability constraints [PhD thesis]. College Station, TX, USA: Texas A&M University; 2010

[29] Grigoriu L. Scheduling on parallel machines with variable availability patterns [PhD thesis]. Bucharest, Romania: Politehnica University Bucharest; 2012

**82**

1978;**7**:1-17

2011

*Scheduling Problems - New Applications and Trends*

[10] Kellerer H. Algorithms for multiprocessor scheduling with

[11] Grigoriu L, Friesen DK. Approximation for scheduling on uniform nonsimultaneous parallel machines. Journal of Scheduling. December 2017;**20**:593-600

1998;**30**:991-999

1991;**31**:227-260

1999;**92**:135-147

machine release times. IIE Transactions.

[12] Chen B. Tighter bound for multifit scheduling on uniform processors. Discrete Applied Mathematics. May

[13] Lee CY. Parallel machine scheduling

[15] Yue M. On the exact upper bound of the MULTIFIT processor scheduling algorithm. Annals of Operations Research. December 1990;**24**:233-259

[16] Friesen DK, Langston MA. Bounds for multifit scheduling on uniform processors. SIAM Journal on

Computing. February 1983;**12**:60-69

[18] He Y. Uniform machine scheduling with machine available *constraints*. Acta Matematicae Applicatae Sinica (English

[19] Grigoriu L, Friesen DK. Scheduling on uniform nonsimultaneous parallel machines. In: Fink A, Fiigenschuh A, Geiger M, editors. Operations Research

[17] Burkard RE, He Y. A note on MULTIFIT scheduling for uniform machines. Computing. 1998;**61**:277-283

Series). 2000;**16**:122-129

with nonsimultaneous machine available time. Discrete Applied Mathematics. January 1991;**30**:53-61

[14] Chang SY, Hwang HC. The worst-case analysis of the MULTIFIT algorithm for scheduling nonsimultaneous parallel machines. Discrete Applied Mathematics. June

[1] Hwang H-C, Chang SY. Parallel machines scheduling with machine

Mathematics with Applications. June

[2] Hwang H-C, Lee K, Chang SY. The effect of machine availability on the worst-case performance of LPT. Discrete Applied Mathematics.

[3] Grigoriu L, Friesen DK. Scheduling on same-speed processors with at most one downtime on each machine. Discrete Optimization. November

[4] Grigoriu L, Friesen DK. Scheduling on uniform processors with at most one downtime on each machine. Discrete Optimization. November 2015;**17**:14-24

[5] Scharbrodt M, Steger A, Weisser H. Approximability of scheduling with fixed jobs. Journal of Scheduling. November 1999;**2**(6):267-284

[6] Jansen K, Pradel L, Schwarz UM, Svensson O. Faster approximation algorithms for scheduling with fixed jobs. In: 17th Conference of Computing: The Australasian Theory Symposium (CATS 2011), Perth, Australia, January.

[7] Graham RL. Bounds on

[8] Coffman EG Jr, Garey MR, Johnson DS. An application of binpacking to multiprocessor scheduling. SIAM Journal on Computing. February

[9] Hwang HC, Lim K. Exact performance of MULTIFIT for nonsimultaneous machines. Discrete Applied Mathematics. 2014;**167**:172-187

March 1969;**17**:416-429

multiprocessing timing anomalies. SIAM Journal of Applied Mathematics.

shutdowns. Computers and

1998;**36**:21-31

**References**

April 2005;**148**:49-61

2010;**7**:212-221

**Chapter 5**

**Abstract**

Approach

optimization techniques

**1. Introduction**

**85**

An Empirical Survey on Load

Balancing: A Nature-Inspired

*Surya Teja Marella and Thummuru Gunasekhar*

Since the dawn of humanity man tried to mimic several animals and their behavior be it in the age of hunting of while designing the aero plane. Human brain holds a significant amount of power in observing the species around him and trying to incorporate their behavior in several walks of life. This mimicking has helped human to evolve into beings which we are now. Some typical examples include navigation systems, designing several gadgets like aero planes, boats, etc. These days these inspirations are several, and their inspiration is being utilized in several fields like operations, supply-chain management, machine learning and several other fields. The similar kind of approach has been discussed in this paper where we tried to analyze different phenomenon in nature and how different algorithms were designed from these and how these can ultimately be used to solve different issues in cloud balancing. Essential component of cloud computing is load balancer which holds a crucial role of task allocation in virtual machines and several kinds of algorithms were developed on different ways of task allocation procedures each holding its significance here we tried to find the optimal resource allocation in terms of task allocation and rather than approaching through traditional methods we tried to solve this issue by using soft computing techniques. Specifically, nature-inspired algorithms as it hold the key to unlocking massive potential regarding research and problem-solving approach. The central idea of this paper is to connect different optimization techniques to load balancer and how could we make a hybrid algorithm to serve the purpose. We also discussed several different types of algorithms each bearing its roots from different natural procedures. All the algorithms in this paper can be broadly tabulated into three different types SO (Swarm optimization techniques), GO (Genetic-based algorithms), PO (Physics-based algorithms).

**Keywords:** load balancing, cloud computing, nature-inspired algorithms,

Load balancing implies guaranteeing the even distribution of workloads and to adjust the load among the accessible resources ideally. It helps in accomplishing a high client fulfillment and asset utilization proportion. Many scheduling algorithms have been proposed to maintain load balancing. The primary point is the ideal assets utilization resulting in improved throughput, migration times or smaller response,

#### **Chapter 5**

## An Empirical Survey on Load Balancing: A Nature-Inspired Approach

*Surya Teja Marella and Thummuru Gunasekhar*

#### **Abstract**

Since the dawn of humanity man tried to mimic several animals and their behavior be it in the age of hunting of while designing the aero plane. Human brain holds a significant amount of power in observing the species around him and trying to incorporate their behavior in several walks of life. This mimicking has helped human to evolve into beings which we are now. Some typical examples include navigation systems, designing several gadgets like aero planes, boats, etc. These days these inspirations are several, and their inspiration is being utilized in several fields like operations, supply-chain management, machine learning and several other fields. The similar kind of approach has been discussed in this paper where we tried to analyze different phenomenon in nature and how different algorithms were designed from these and how these can ultimately be used to solve different issues in cloud balancing. Essential component of cloud computing is load balancer which holds a crucial role of task allocation in virtual machines and several kinds of algorithms were developed on different ways of task allocation procedures each holding its significance here we tried to find the optimal resource allocation in terms of task allocation and rather than approaching through traditional methods we tried to solve this issue by using soft computing techniques. Specifically, nature-inspired algorithms as it hold the key to unlocking massive potential regarding research and problem-solving approach. The central idea of this paper is to connect different optimization techniques to load balancer and how could we make a hybrid algorithm to serve the purpose. We also discussed several different types of algorithms each bearing its roots from different natural procedures. All the algorithms in this paper can be broadly tabulated into three different types SO (Swarm optimization techniques), GO (Genetic-based algorithms), PO (Physics-based algorithms).

**Keywords:** load balancing, cloud computing, nature-inspired algorithms, optimization techniques

#### **1. Introduction**

Load balancing implies guaranteeing the even distribution of workloads and to adjust the load among the accessible resources ideally. It helps in accomplishing a high client fulfillment and asset utilization proportion. Many scheduling algorithms have been proposed to maintain load balancing. The primary point is the ideal assets utilization resulting in improved throughput, migration times or smaller response,

ideal adaptability, and overall system production [1]. There are individual difficulties in cloud computing, and that needed to be routed to give the most reasonable and productive effective load balancing algorithms. These challenges are:

The heap adjusting in the cloud is additionally alluded to as load adjusting as an

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

Load adjusting is to move the workload to computational assets that are underutilized, with an outrageous objective of lessening the general execution time. A considerable measure of research has been added to the point, and this case continues with framework figuring and disseminated computation [10]. In the area of multi-core computing, a typical multi-core framework comprises of same cores that communicate using shared memory space. Similarly stays consistent with GPUs also [11]. Thus, a notwithstanding dividing of the load among accessible cores should do the trick to deliver a base execution time. Regardless, this dispute is effectively countered by the manner in which that we can have a gathering of workloads, each with various or obscure computation requirements. An even or approach apportioning would not be doable. If a distributed memory system is utilized as an execution stage, correspondence overheads can turn into a genuine

As a rule, legitimately dividing the workload is basic to boosting execution. Toward this objective, we ought to think about a comparable number of the stage (e.g., computational speed) and issue attributes (e.g., cost of data transmission) as conceivable [12]. Dynamic load adjusting insinuates a wide assembling of computations that perform or change stack assignments on the Web, i.e., in the midst of

administration (LBaaS) [9] (**Figure 1**).

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

performance concern [11].

**Figure 1.**

**87**

*Load balancing model.*


The challenges as mentioned above remain unsolved. Researchers are going on to bring about changes in the existing algorithms and to create new algorithms to overcome these challenges.

Cloud load balancing is the activity of regulating the workload and computing assets in a cloud computing environment to accomplish high performance at potentially lower costs. This includes facilitating the dissemination of workload activity and requests that dwell over the Interweb [5]. As we know that, a load balancing technique is basically appropriating workloads among the servers and processing assets in a cloud domain in which the number of clients where more significant than the servers so that there can be the burden on the servers so we need to balance the load so we distribute the tasks among the servers equally so it cannot be the bash with any other server and in this way we can increase the performance of a server [6]. By allocating the resources among the various computer network or server, Load balancing allows companies or organizations to manage the applications or workload demands, so load balancing in cloud computing that incorporate facilitating the distribution of workload activity and request over the system so first level every one of the customers have been composed, In second level all the servers have been organized and in between these two a load balance rare used to balance the load among the server and is generally used by the company or organizations to manage their applications. Cloud computing is an advanced worldview to give benefits through the Interweb [7]. Load balancing is an essential part of cloud computing and avoids the situation in which a couple of nodes wind up finished weight while the others are sitting still or have little work to do. Load balancing can upgrade the Quality of Service (QoS) estimations, including response time, cost, throughput, execution and asset utilization. In computing, Load balancing [8] enhances the distribution of workloads over various figuring assets, for example, PCs, a PC gathering, central processing units, network links, or disk drives. Load balancing means to enhance asset usage, maximize throughput, confine response time, and maintain a strategic distance from over-weight of any single asset. Using different parts with load balancing rather than a single component may increase reliability and accessibility through excess. The load balancing in clouds may be among physical hosts or VMs. This balancing segment scatters the dynamic workload fairly among every one of the hubs (hosts or VMs).

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

The heap adjusting in the cloud is additionally alluded to as load adjusting as an administration (LBaaS) [9] (**Figure 1**).

Load adjusting is to move the workload to computational assets that are underutilized, with an outrageous objective of lessening the general execution time. A considerable measure of research has been added to the point, and this case continues with framework figuring and disseminated computation [10]. In the area of multi-core computing, a typical multi-core framework comprises of same cores that communicate using shared memory space. Similarly stays consistent with GPUs also [11]. Thus, a notwithstanding dividing of the load among accessible cores should do the trick to deliver a base execution time. Regardless, this dispute is effectively countered by the manner in which that we can have a gathering of workloads, each with various or obscure computation requirements. An even or approach apportioning would not be doable. If a distributed memory system is utilized as an execution stage, correspondence overheads can turn into a genuine performance concern [11].

As a rule, legitimately dividing the workload is basic to boosting execution. Toward this objective, we ought to think about a comparable number of the stage (e.g., computational speed) and issue attributes (e.g., cost of data transmission) as conceivable [12]. Dynamic load adjusting insinuates a wide assembling of computations that perform or change stack assignments on the Web, i.e., in the midst of

**Figure 1.** *Load balancing model.*

ideal adaptability, and overall system production [1]. There are individual difficulties in cloud computing, and that needed to be routed to give the most reasonable

1. Geographical/spatial distributions of the nodes: to design an LBA that works for spatially or geographically distributed nodes is an arduous task. It is because as the distance increases the speed of the network links among the

2. The complexity of algorithm: complexity affects the overall performance of a system. Generally, LBA has a less complicated implementation. Complexity

3. Point of failure: the load balancing algorithm ought to be planned in a way that

4.Static load balancing algorithm: a static load balancing algorithm works on the earlier state/previous data, not on the ongoing state. It cannot adjust to the load

The challenges as mentioned above remain unsolved. Researchers are going on to bring about changes in the existing algorithms and to create new algorithms to

Cloud load balancing is the activity of regulating the workload and computing

assets in a cloud computing environment to accomplish high performance at potentially lower costs. This includes facilitating the dissemination of workload activity and requests that dwell over the Interweb [5]. As we know that, a load balancing technique is basically appropriating workloads among the servers and processing assets in a cloud domain in which the number of clients where more significant than the servers so that there can be the burden on the servers so we need to balance the load so we distribute the tasks among the servers equally so it cannot be the bash with any other server and in this way we can increase the performance of a server [6]. By allocating the resources among the various computer network or server, Load balancing allows companies or organizations to manage the applications or workload demands, so load balancing in cloud computing that incorporate facilitating the distribution of workload activity and request over the system so first level every one of the customers have been composed, In second level all the servers have been organized and in between these two a load balance rare used to balance the load among the server and is generally used by the company or organizations to manage their applications. Cloud computing is an advanced worldview to give benefits through the Interweb [7]. Load balancing is an essential part of cloud computing and avoids the situation in which a couple of nodes wind up finished weight while the others are sitting still or have little work to do. Load balancing can upgrade the Quality of Service (QoS) estimations, including response time, cost, throughput, execution and asset utilization. In computing, Load balancing [8] enhances the distribution of workloads over various figuring assets, for example, PCs, a PC gathering, central processing units, network links, or disk drives. Load balancing means to enhance asset usage, maximize throughput, confine response time, and maintain a strategic distance from over-weight of any single asset. Using different parts with load balancing rather than a single component may increase reliability and accessibility through excess. The load balancing in clouds may be among physical hosts or VMs. This balancing segment scatters the

dynamic workload fairly among every one of the hubs (hosts or VMs).

and productive effective load balancing algorithms. These challenges are:

nodes is influenced which thusly influences the throughput [2].

lead to delays which further causes more problems [3].

they abstain from having a single point of failure.

*Scheduling Problems - New Applications and Trends*

changes at run-time [4].

overcome these challenges.

**86**

the execution of a program [13]. Dynamic load balancing is depicted by the ability to adjust to changes to the execution organize (e.g., hubs going isolates, correspondence joins finding the opportunity to be congested, and whatnot.) yet to the burden of additional coordination overhead [14]. Static load modifying can give a close ideal answer for the load-partitioning issue, the exchange offs being the failure to adapt to run-time changes and the need to develop insinuate learning about the execution characteristics of the individual fragments making up the execution arrange [15].

• To minimize time spent waiting in the queue.

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

• To facilitate improved resource utilization ratio

Each technique holds significance and a different approach to solve the problem. Swarm optimization is generally used to find an optimal solution it might not be the best fit solution, Genetic algorithms generally try to find the best fit but it consumes much time, and physics algorithm generally used as hybrid or support algorithm to minimize other procedures in different algorithms. Swarm optimization is generally inspired by observing different flock behaviors be it in frogs, bats, fireflies and ants and each takes a specific approach to the problem of food gathering, communication, foraging, etc. [22]. A genetic algorithm is approximately enlivened by Charles Darwin theory of survival of fittest and algorithms like a genetic algorithm, mimetic algorithm come under this category. Physics algorithms are inspired from different

To expand the general execution of the framework, load balancing is an intense instrument that aides in conveying bigger workloads into smaller processing workloads. To achieve proper resource utilization and excellent user satisfaction, it helps in the fair allocation of computing resources. It avoids bottlenecks and implements failover thus increasing the scalability. To transfer and receive data without any delay, load balancing divides the traffic between all the servers to get an optimum solution. The central vision of load balancing is to make sure that at any point in time, the processors in the system does the same amount of work. It is necessary for load balancing to utilize full parallel and distributed system's resources. Load balancing is classified as dynamic load balancing and static load balancing [23]. The processor's performance is decided at the beginning of execution in static load balancing. From that point onward, as per their execution, the workload is partitioned by the ace processor. It should be possible utilizing algorithms named "central manager algorithm," "threshold algorithm," and "round robin algorithm." The work is divided during the runtime in dynamic load balancing. With new information collected by the master, new processes it assigned to the slaves. Here, processes are allocated dynamically. It can be carried out using algorithms such as,

"local queue algorithm" and "central queue algorithm" [24]. A load balancer can perform the following functions:

2. According to demand, it can add and subtract the servers.

1. Distributes network load and requests of clients across many servers.

3. Provides high scalability, reliability and availability to the online servers.

physical phenomena like gravitation, mass-energy equivalence, simulated annealing, etc. These generally act as support factors for different algorithms. In every algorithm the process can be generalized as randomization, calculating fitness and arriving at a possible solution. The approach varies, but the process is more or less the same. The underlying algorithms used these days in different spheres are ant colony optimization; in the chapter, genetic algorithm and simulated annealing are also discussed. We also discussed concepts like task allocation based on a few traditional algorithms. Factors like green computing which affect the performance of the device considerably are also discussed. To conclude we tried to solve the optimal resource allocation in a natural way because nature itself looks for best fitting procedures for its procedures and mimicking it in computing could be

**1.3 Related works**

advantageous [25].

**89**

To attain these goals, two types of load balancing algorithms are designed:

#### **1.1 Static load balancing**

In static load balancing, cloud requires knowledge of processing power, performance, nodes capacity and memory [5]. The cloud additionally requires learning of client necessities which cannot be changed on run-time. It is simpler to mimic the static condition, yet in the event that client necessities change static condition cannot adjust to it. Two well-known algorithms applied in static environments are [16].

#### *1.1.1 Round Robin algorithm*

In the Round Robin algorithm, assets are allocated to errand on First-come-First-Serve (FCFS) premise. It implies the errand which arrives first; assets are distributed to it first. In this algorithm, tasks are scheduled in time sharing manner [17].

#### *1.1.2 Central load balancing decision model*

It is an improved approach to Round Robin algorithm. It uses the basics of the Round Robin algorithm. This algorithm calculates total execution time spent by a task on the cloud. It uses this information to calculate time elapsed during client and server communication [18].

#### **1.2 Dynamic load balancing**

In a dynamic environment, various resources are installed. In a dynamic environment, cloud considers runtime statistics [19]. In a dynamic environment, the cloud allows changes in user requirements on runtime. Algorithms in a dynamic environment can quickly adapt to runtime changes. The dynamic environment is challenging to simulate [20]. Various load balancing algorithms implemented in a dynamic environment are weighted least connection (WLC) algorithm, load balancing min-min (LBMM) algorithm and opportunistic load balancing (OLB) algorithm [21].

Considering the scalability and free nature of the cloud, dynamic environments are preferred over static environments for cloud implementation as it also satisfies the particular goals of load balancing as given below,

Goals of load balancing are:


#### **1.3 Related works**

the execution of a program [13]. Dynamic load balancing is depicted by the ability to adjust to changes to the execution organize (e.g., hubs going isolates, correspondence joins finding the opportunity to be congested, and whatnot.) yet to the burden of additional coordination overhead [14]. Static load modifying can give a close ideal answer for the load-partitioning issue, the exchange offs being the failure to adapt to run-time changes and the need to develop insinuate learning about the execution characteristics of the individual fragments making up the execution

To attain these goals, two types of load balancing algorithms are designed:

In static load balancing, cloud requires knowledge of processing power, performance, nodes capacity and memory [5]. The cloud additionally requires learning of client necessities which cannot be changed on run-time. It is simpler to mimic the static condition, yet in the event that client necessities change static condition cannot adjust to it. Two well-known algorithms applied in static environments are [16].

In the Round Robin algorithm, assets are allocated to errand on First-come-First-Serve (FCFS) premise. It implies the errand which arrives first; assets are distributed to it first. In this algorithm, tasks are scheduled in time sharing manner [17].

It is an improved approach to Round Robin algorithm. It uses the basics of the Round Robin algorithm. This algorithm calculates total execution time spent by a task on the cloud. It uses this information to calculate time elapsed during client and

In a dynamic environment, various resources are installed. In a dynamic environment, cloud considers runtime statistics [19]. In a dynamic environment, the cloud allows changes in user requirements on runtime. Algorithms in a dynamic environment can quickly adapt to runtime changes. The dynamic environment is challenging to simulate [20]. Various load balancing algorithms implemented in a dynamic environment are weighted least connection (WLC) algorithm, load balancing min-min (LBMM) algorithm and opportunistic load balancing (OLB)

Considering the scalability and free nature of the cloud, dynamic environments are preferred over static environments for cloud implementation as it also satisfies

arrange [15].

**1.1 Static load balancing**

*1.1.1 Round Robin algorithm*

server communication [18].

**1.2 Dynamic load balancing**

Goals of load balancing are:

algorithm [21].

**88**

*1.1.2 Central load balancing decision model*

*Scheduling Problems - New Applications and Trends*

the particular goals of load balancing as given below,

• To maintain the fault tolerance of the system.

• To improve efficiency and performance of the system.

• To maintain the stability of the system.

• To minimize job execution time.

Each technique holds significance and a different approach to solve the problem. Swarm optimization is generally used to find an optimal solution it might not be the best fit solution, Genetic algorithms generally try to find the best fit but it consumes much time, and physics algorithm generally used as hybrid or support algorithm to minimize other procedures in different algorithms. Swarm optimization is generally inspired by observing different flock behaviors be it in frogs, bats, fireflies and ants and each takes a specific approach to the problem of food gathering, communication, foraging, etc. [22]. A genetic algorithm is approximately enlivened by Charles Darwin theory of survival of fittest and algorithms like a genetic algorithm, mimetic algorithm come under this category. Physics algorithms are inspired from different physical phenomena like gravitation, mass-energy equivalence, simulated annealing, etc. These generally act as support factors for different algorithms. In every algorithm the process can be generalized as randomization, calculating fitness and arriving at a possible solution. The approach varies, but the process is more or less the same. The underlying algorithms used these days in different spheres are ant colony optimization; in the chapter, genetic algorithm and simulated annealing are also discussed. We also discussed concepts like task allocation based on a few traditional algorithms. Factors like green computing which affect the performance of the device considerably are also discussed. To conclude we tried to solve the optimal resource allocation in a natural way because nature itself looks for best fitting procedures for its procedures and mimicking it in computing could be advantageous [25].

To expand the general execution of the framework, load balancing is an intense instrument that aides in conveying bigger workloads into smaller processing workloads. To achieve proper resource utilization and excellent user satisfaction, it helps in the fair allocation of computing resources. It avoids bottlenecks and implements failover thus increasing the scalability. To transfer and receive data without any delay, load balancing divides the traffic between all the servers to get an optimum solution. The central vision of load balancing is to make sure that at any point in time, the processors in the system does the same amount of work. It is necessary for load balancing to utilize full parallel and distributed system's resources. Load balancing is classified as dynamic load balancing and static load balancing [23]. The processor's performance is decided at the beginning of execution in static load balancing. From that point onward, as per their execution, the workload is partitioned by the ace processor. It should be possible utilizing algorithms named "central manager algorithm," "threshold algorithm," and "round robin algorithm." The work is divided during the runtime in dynamic load balancing. With new information collected by the master, new processes it assigned to the slaves. Here, processes are allocated dynamically. It can be carried out using algorithms such as, "local queue algorithm" and "central queue algorithm" [24].

A load balancer can perform the following functions:


To scale with the increased demands, vendors of the cloud are more toward automatic load balancing services that allow the entities to increase the memory and count of CPU for their resources.

This technique has three different variants,

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

exponential time worst case scenario.

to find the optimal solution.

Present node = initialNode;

nextEvalatuation = -knf nextNode = NULL; for all x in L

k=neighbours(presentNode);

nextEvaluation = evaLuation(x);

return presentNode; presentNode = nextNode;

loop

**Figure 3.** *Hill climbing.*

**91**

nextNode = j;

1. **Coordinate descent**: this technique is optimally used to determine the optimal solution for the given problem but cannot be implemented as it has an

solution, but it is better than stochastic hill climbing regarding the time taken

3. **Traditional hill climbing approach**: this technique cannot be used in the load

2. **Stochastic hill climbing**: this technique does not guarantee an optimal

Hence, here we describe a stochastic hill climbing approach as it is best

balancer as the solution we get out of this is not optimal.

regarding both time complexity and optimization (**Figure 3**).

if (EVALuation(x) >nextEvalution)

if nextEvaluation<= evaluation(presentNode)

#### **2. Models of nature-inspired algorithms**

Nature-inspired algorithm is a capacity that aroused by activities that are perceived by nature. These registering approaches prompted the change of development named nature-inspired algorithms (NIA) [25]. This breakthrough is apt for computational agility. The objective of developing such algorithms is to optimize engineering problems [26] (**Figure 2**).

These algorithms use recombination and change overseers to streamline the perplexing issues, e.g., genetic algorithm and differential evolution et cetera. The basic objective of nature-inspired algorithms is to discover a universally response for a given issue. Two key factors normal in all nature-inspired algorithms are strengthening and expansion regularly named as Exploration and Exploitation [27].

Some of the algorithms are,

#### **2.1 Hill climbing**

It is a nature-inspired algorithm which takes its inspiration from a process of hill climbing. It is an iterative algorithm. This algorithm is thus helpful to find the minimal solution and can be used in the load balancer [28]. A tool called load balancer which is used to find the assets allocation in the cluster and several kinds of algorithms are used to find the resource allocation to the cluster and here to find the solution we can use the hill climbing algorithm.

Initially, the algorithm considers the cluster as a graph and mimics hill climbing behavior on that graph and generates a solution for optimal resource allocation [29].

To locate the ideal answer for the given issue this strategy can be utilized, this method can be utilized as a part of load adjusting to locate the ideal asset assignment for the given issue.

**Figure 2.** *Load balancing taxonomy.*

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

This technique has three different variants,

To scale with the increased demands, vendors of the cloud are more toward automatic load balancing services that allow the entities to increase the memory and

Nature-inspired algorithm is a capacity that aroused by activities that are perceived by nature. These registering approaches prompted the change of development named nature-inspired algorithms (NIA) [25]. This breakthrough is apt for computational agility. The objective of developing such algorithms is to optimize

These algorithms use recombination and change overseers to streamline the perplexing issues, e.g., genetic algorithm and differential evolution et cetera. The basic objective of nature-inspired algorithms is to discover a universally response for a given issue. Two key factors normal in all nature-inspired algorithms are strengthening and expansion regularly named as Exploration and Exploitation [27].

It is a nature-inspired algorithm which takes its inspiration from a process of hill

Initially, the algorithm considers the cluster as a graph and mimics hill climbing behavior on that graph and generates a solution for optimal resource allocation [29]. To locate the ideal answer for the given issue this strategy can be utilized, this method can be utilized as a part of load adjusting to locate the ideal asset assignment

climbing. It is an iterative algorithm. This algorithm is thus helpful to find the minimal solution and can be used in the load balancer [28]. A tool called load balancer which is used to find the assets allocation in the cluster and several kinds of algorithms are used to find the resource allocation to the cluster and here to find the

count of CPU for their resources.

**2. Models of nature-inspired algorithms**

*Scheduling Problems - New Applications and Trends*

engineering problems [26] (**Figure 2**).

Some of the algorithms are,

solution we can use the hill climbing algorithm.

**2.1 Hill climbing**

for the given issue.

**Figure 2.**

**90**

*Load balancing taxonomy.*


Hence, here we describe a stochastic hill climbing approach as it is best regarding both time complexity and optimization (**Figure 3**).

```
Present node = initialNode;
 loop
  k=neighbours(presentNode);
nextEvalatuation = -knf
nextNode = NULL;
   for all x in L
     if (EVALuation(x) >nextEvalution)
nextNode = j;
nextEvaluation = evaLuation(x);
   if nextEvaluation<= evaluation(presentNode)
```
return presentNode; presentNode = nextNode;

**Figure 3.** *Hill climbing.*

#### **2.2 Ant colony optimization**

In nature-inspired algorithms the "ant colony optimization algorithm (ACO)" is a probabilistic intends to determine computational issues which can be diminished to finding the correct routes through graphs. Artificial Ants remain for multi-agent strategies motivated by the conduct of genuine ants. The pheromone-based communication of organic ants is frequently the dominating worldview utilized. Mixes of artificial ants and nearby local search algorithms have turned into a strategy for decision for various improvement tasks including some like vehicle routing and Internet routing [30].

Load balancing technique is essentially procedure which is used to find the optimal solution to given resource distribution problem in the given cloud computing scenario. Ant colony optimization considers the given problem as a graph and tries to find the optimal path and optimal resource allocation for the given problem can be found by using this specific procedure. The algorithm starts from randomness to optimization and alleviates the problem of the cluster. Initially, ants wander randomly and come back to the source by laying pheromone in their path. Then remaining ants follow the path set by the ants using pheromone [31]. There is a problem of pheromone getting evaporated this will allow for the shortest path determination. If it takes more time in this path, then the pheromone will evaporate there only shortest path pheromone survives to contribute to the shortest path. All the ants follow the same path to follow others eventually Thus after getting the shortest path whole ants to follow this path leading to the whole system following this path. This algorithm is more advantageous as it tackles the dynamic allocation problem easily. To solve the load balancing in a cloud environment the ant-based control system was designed. Each and every node was configured with capacity of being a destination, the probability of being destination, pheromone table. There are many variants for this technique namely Elitist depicts that global best solution gives pheromone update after every iteration, Max-Min ant system takes a minmax data structure and updates its value from minimum to maximum, Rank-based ant system takes all the possible solution and ranks according to sum of weights, continuous orthogonal ant colony takes additional angle parameter which makes for efficient searching, Recursive ant colony optimization takes solution and uses genetics to find out best solution [32].

sources by foragers causing negative feedback [33]. In ABC, a state of artificial forager honey bees check for rich phony sustenance sources. To apply ABC, the treated change issue is first changed to the issue of finding the best parameter vector which lessens a goal work. By then, artificial forager honey bees erratically discover a people of beginning arrangement vectors and a while later iteratively improve them by using the techniques: moving toward better arrangements utiliz-

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

ing a neighbor search mechanism while forsaking poor arrangements [34].

divided into four different phases [35].

using this formula.

**93**

**Figure 4.**

*Ant colony optimization.*

A technique called artificial bee colony optimization which is used to find the optimal solution to the given problem. It models the given problem as a graph and algorithm mimic the behavior of bees to approach a solution to the given Here problem refers to optimal resource allocation in given load balancer then resource allocation is done accordingly. ABC is an algorithm which takes inspiration from bees and tries to find the shortest path for the given graph cluster. Derviskaraboga developed it in 2005. The position of bees is modified to find out best position with the highest nectar since it is a population-based search procedure. Generally, bees perform a waggle dance to convey information regarding distances and directions. The whole graph system can be modeled into two significant components of food sources and foragers. Further classified of foragers can be done as unemployed foragers, employed foragers and experienced foragers. The algorithm can again be

**(1) Initialization phase**: the initial food sources are allocated randomly by

Here lb, ub are **lower** and upper bound of solution space of objective function.

Km ¼ lb þ random 0ð Þ *;* 1 ∗ ð Þ ub � lb (1)

The whole algorithm can be divided into different phases Edge selection and pheromone update. Initially randomly all ants are placed in the random order and after all the ants placed we updated pheromone level by using this formula Pxy<- (1-p)\*pxy+ sum of all pheromone levels (**Figure 4**).

Here pxy is pheromone level which can be calculated by using this formula.

Del the k ð Þ¼ J here j is the perimeter of curve xy for straight line use 0*:*

#### **2.3 Artificial bee colony**

The "artificial bee colony (ABO)" algorithm is a swarm based meta-heuristic algorithm. The algorithm is constructed unequivocally with respect to the model that is proposed for the scrounging conduct of honey bee settlements. The excellent comprises of three imperative parts: used and unemployed foraging honey bees, and sustenance sources. The underlying two sections, used and unemployed foraging honey bees, examine for rich sustenance sources, which is the third fragment, close to their hive. The model in like manner describes two driving techniques for lead which are basic for self-sorting out and total knowledge: enlistment of foragers to bounteous sustenance sources achieving positive information and surrender of poor *An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

**Figure 4.** *Ant colony optimization.*

**2.2 Ant colony optimization**

*Scheduling Problems - New Applications and Trends*

Internet routing [30].

genetics to find out best solution [32].

**2.3 Artificial bee colony**

**92**

(1-p)\*pxy+ sum of all pheromone levels (**Figure 4**).

In nature-inspired algorithms the "ant colony optimization algorithm (ACO)" is a probabilistic intends to determine computational issues which can be diminished to finding the correct routes through graphs. Artificial Ants remain for multi-agent strategies motivated by the conduct of genuine ants. The pheromone-based communication of organic ants is frequently the dominating worldview utilized. Mixes of artificial ants and nearby local search algorithms have turned into a strategy for decision for various improvement tasks including some like vehicle routing and

Load balancing technique is essentially procedure which is used to find the optimal solution to given resource distribution problem in the given cloud computing scenario. Ant colony optimization considers the given problem as a graph and tries to find the optimal path and optimal resource allocation for the given problem can be found by using this specific procedure. The algorithm starts from randomness to optimization and alleviates the problem of the cluster. Initially, ants wander randomly and come back to the source by laying pheromone in their path. Then remaining ants follow the path set by the ants using pheromone [31]. There is a problem of pheromone getting evaporated this will allow for the shortest path determination. If it takes more time in this path, then the pheromone will evaporate there only shortest path pheromone survives to contribute to the shortest path. All the ants follow the same path to follow others eventually Thus after getting the shortest path whole ants to follow this path leading to the whole system following this path. This algorithm is more advantageous as it tackles the dynamic allocation problem easily. To solve the load balancing in a cloud environment the ant-based control system was designed. Each and every node was configured with capacity of being a destination, the probability of being destination, pheromone table. There are many variants for this technique namely Elitist depicts that global best solution gives pheromone update after every iteration, Max-Min ant system takes a minmax data structure and updates its value from minimum to maximum, Rank-based ant system takes all the possible solution and ranks according to sum of weights, continuous orthogonal ant colony takes additional angle parameter which makes for efficient searching, Recursive ant colony optimization takes solution and uses

The whole algorithm can be divided into different phases Edge selection and pheromone update. Initially randomly all ants are placed in the random order and after all the ants placed we updated pheromone level by using this formula Pxy<-

Here pxy is pheromone level which can be calculated by using this formula.

Del the k ð Þ¼ J here j is the perimeter of curve xy for straight line use 0*:*

The "artificial bee colony (ABO)" algorithm is a swarm based meta-heuristic algorithm. The algorithm is constructed unequivocally with respect to the model that is proposed for the scrounging conduct of honey bee settlements. The excellent comprises of three imperative parts: used and unemployed foraging honey bees, and sustenance sources. The underlying two sections, used and unemployed foraging honey bees, examine for rich sustenance sources, which is the third fragment, close to their hive. The model in like manner describes two driving techniques for lead which are basic for self-sorting out and total knowledge: enlistment of foragers to bounteous sustenance sources achieving positive information and surrender of poor sources by foragers causing negative feedback [33]. In ABC, a state of artificial forager honey bees check for rich phony sustenance sources. To apply ABC, the treated change issue is first changed to the issue of finding the best parameter vector which lessens a goal work. By then, artificial forager honey bees erratically discover a people of beginning arrangement vectors and a while later iteratively improve them by using the techniques: moving toward better arrangements utilizing a neighbor search mechanism while forsaking poor arrangements [34].

A technique called artificial bee colony optimization which is used to find the optimal solution to the given problem. It models the given problem as a graph and algorithm mimic the behavior of bees to approach a solution to the given Here problem refers to optimal resource allocation in given load balancer then resource allocation is done accordingly. ABC is an algorithm which takes inspiration from bees and tries to find the shortest path for the given graph cluster. Derviskaraboga developed it in 2005. The position of bees is modified to find out best position with the highest nectar since it is a population-based search procedure. Generally, bees perform a waggle dance to convey information regarding distances and directions. The whole graph system can be modeled into two significant components of food sources and foragers. Further classified of foragers can be done as unemployed foragers, employed foragers and experienced foragers. The algorithm can again be divided into four different phases [35].

**(1) Initialization phase**: the initial food sources are allocated randomly by using this formula.

$$\text{Km} = \text{lb} + \text{random}(\mathbf{0}, \mathbf{1}) \* (\mathbf{u}\mathbf{b} - \text{lb}) \tag{1}$$

Here lb, ub are **lower** and upper bound of solution space of objective function.

**(2) Employed bee phase**: the neighboring food source Nmi is determined by using the following formula.

$$\text{Nmi} = \text{Kmi} + \text{random}[-\mathbf{1}, \mathbf{1}] \* (\text{Kmi} - \text{Kki}) \tag{2}$$

Here i is any **randomly** selected parameter index.

Here fitness is **calculated** by using the following formula and a greedy algorithm is applied.

Fitness Km ð Þ¼ 1*=*1 þ obj Km ð Þ*,* obj Km ð Þ>0*,* Fitness Km ð Þ¼ 1 þ ∣obj Km ð Þ∣*,* obj Km ð Þ< 0

Here **obj**(Km) is objective function of Km.

**(3) Onlooker bee phase**: the quantity of food sources is the ratio of total fitness to the individual bee fitness.

Profitm ¼ individual fitness*=*sum of all fitness*:*

**Onlooker** bee uses the formula (2) for neighboring food source.

**(4) Scout phase**: the new solutions are randomly searched by the scout bees.

The new **solution** Km is randomly searched by following formula.

Km ¼ lb þ random 0ð Þ *;* 1 ∗ ð Þ ub � lb

Here ub and **lb** are upper and lower bounds to the solution phase (**Figure 5**).

#### **2.4 Genetic algorithm**

The approval of GA is situated on four considerations: populace estimate, mutation rate, crossover rate and the number of generations. To control the first rate individual among a masses, qualities of comparing people are ordered against the objective function. The formative structure through which another successor is conveyed is crossover and mutation. In the crossover mechanism, an offspring is conveyed by joining the characteristics of consolidating the qualities of chose people among populace while transformation causes some irregular changes in qualities of an individual in this manner delivering new hereditary person. The transformative mechanism is finished to the moment that joining criteria are satisfied [36].

implement these characteristics in our algorithm. The three significant steps in this

1.**Initialization step**: it is performed in randomness here we take all the possible

2. **Selection step**: with the help of probabilities possible solutions are listed out based on probabilities and parents are selected according to highest

3. **Termination step**: in the final step, we use different techniques like mutation, crossover, etc. to form a solution and this solution is evaluated by using fitness

algorithm are Initialization, selection and validation.

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

solutions and list them out.

**Figure 5.**

**95**

*Artificial bee colony (ABC).*

probabilities to form a solution.

The genetic algorithm is used to find out the optimal solution to the given cluster. The approval of GA is situated on four contemplations: populace estimate, A genetic algorithm is a refinement algorithm natural selection (survival of the fittest) is the one inspired genetic algorithm, Essentially we have to show the given bunch and attempt to explain it by utilizing a hereditary calculation. The genetic algorithm performs optimization and searching using three different bio-inspired operators such as mutation, crossover and selection [37]. One genetic representation of all the possible solutions and a fitness function is required by typical GA to figure out the quality of the given solution. The given problem can be either modeled as a graph or tree, and a genetic algorithm can be applied to this to determine the optimal solution. The genetic algorithm borrows its properties from natural selection by Darwin or Darwinian evolution theory. Hence we need to

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

**Figure 5.** *Artificial bee colony (ABC).*

implement these characteristics in our algorithm. The three significant steps in this algorithm are Initialization, selection and validation.


**(2) Employed bee phase**: the neighboring food source Nmi is determined by

Here fitness is **calculated** by using the following formula and a greedy

Fitness Km ð Þ¼ 1*=*1 þ obj Km ð Þ*,* obj Km ð Þ>0*,* Fitness Km ð Þ¼ 1 þ ∣obj Km ð Þ∣*,* obj Km ð Þ< 0

**(3) Onlooker bee phase**: the quantity of food sources is the ratio of total fitness

Profitm ¼ individual fitness*=*sum of all fitness*:*

**(4) Scout phase**: the new solutions are randomly searched by the scout bees.

Km ¼ lb þ random 0ð Þ *;* 1 ∗ ð Þ ub � lb

Here ub and **lb** are upper and lower bounds to the solution phase (**Figure 5**).

The approval of GA is situated on four considerations: populace estimate, mutation rate, crossover rate and the number of generations. To control the first rate individual among a masses, qualities of comparing people are ordered against the objective function. The formative structure through which another successor is conveyed is crossover and mutation. In the crossover mechanism, an offspring is conveyed by joining the characteristics of consolidating the qualities of chose people among populace while transformation causes some irregular changes in qualities of an individual in this manner delivering new hereditary person. The transformative mechanism is finished to the moment that joining criteria are satisfied [36]. The genetic algorithm is used to find out the optimal solution to the given cluster. The approval of GA is situated on four contemplations: populace estimate, A genetic algorithm is a refinement algorithm natural selection (survival of the fittest) is the one inspired genetic algorithm, Essentially we have to show the given bunch and attempt to explain it by utilizing a hereditary calculation. The genetic algorithm performs optimization and searching using three different bio-inspired operators such as mutation, crossover and selection [37]. One genetic representation of all the possible solutions and a fitness function is required by typical GA to figure out the quality of the given solution. The given problem can be either modeled as a graph or tree, and a genetic algorithm can be applied to this to determine the optimal solution. The genetic algorithm borrows its properties from natural selection by Darwin or Darwinian evolution theory. Hence we need to

**Onlooker** bee uses the formula (2) for neighboring food source.

The new **solution** Km is randomly searched by following formula.

Nmi ¼ Kmi þ random½ � �1*;* 1 ∗ ð Þ Kmi � Kki (2)

using the following formula.

*Scheduling Problems - New Applications and Trends*

algorithm is applied.

Here i is any **randomly** selected parameter index.

Here **obj**(Km) is objective function of Km.

to the individual bee fitness.

**2.4 Genetic algorithm**

**94**

function. This process is iterated until we form an optimal solution [38]. As it is an iterative technique this can perform for the infinite amount of time this should be terminated at some of the other instants to consider the optimal solution to the given problem. This can be terminated at either any of these cases:


In its heart, genetic algorithm follows each of this basic mechanism:


**2.5 Cuckoo search**

**Figure 7.** *Cuckoo search.*

**97**

arrangement is refined [39] (**Figure 7**).

"Cuckoo search algorithm (CSA)" is another algorithm and is inspired by the

To solve the problem of clusterin load balancer cuckoo search algorithm can be used. It does so by finding out the optimal resource allocation. Initially, we model

raising behavior of the cuckoo bird they select their home by self-assertively accepting control over the home of some extraordinary winged animals for an age. They lay their eggs in the picked home of host cuckoo bird and drop the host winged animal's egg. The host bird either drop cuckoo fledgling's egg or surrender the whole home Some female cuckoo can copy their eggs like host fowl's egg and lay their eggs just before the laying of host feathered creature's egg. This grows the probability of their chick survival. Each egg in settle speaks to one arrangement, and the cuckoo flying creature's egg speaks to another arrangement. Wellness for every arrangement is handled, and settle with the high bore of eggs addresses the best game plan. The methodology is continued with aside from if a worldwide ideal

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

**Figure 6.** *Genetic algorithm.*

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

**Figure 7.** *Cuckoo search.*

function. This process is iterated until we form an optimal solution [38]. As it is an iterative technique this can perform for the infinite amount of time this should be terminated at some of the other instants to consider the optimal solution to the given problem. This can be terminated at either any of these

a. If the latest solution persuades minimum criteria.

In its heart, genetic algorithm follows each of this basic mechanism:

variation as this would contribute to the formation of a solution.

a. Variation: this is implemented in the initialization part here we need to take

b.Selection: this is implemented in the selection part here we take or consider the solution which has a higher probability to form a solution and remaining are

c. Hereditary: this is implemented in the final stage whereby use of process like mutation allows the new solution to have two properties (**Figure 6**).

b.Fixed no of generations reached.

c. Allocated budget used up.

*Scheduling Problems - New Applications and Trends*

d.Manual inspection.

cases:

eliminated.

**Figure 6.** *Genetic algorithm.*

**96**

#### **2.5 Cuckoo search**

"Cuckoo search algorithm (CSA)" is another algorithm and is inspired by the raising behavior of the cuckoo bird they select their home by self-assertively accepting control over the home of some extraordinary winged animals for an age. They lay their eggs in the picked home of host cuckoo bird and drop the host winged animal's egg. The host bird either drop cuckoo fledgling's egg or surrender the whole home Some female cuckoo can copy their eggs like host fowl's egg and lay their eggs just before the laying of host feathered creature's egg. This grows the probability of their chick survival. Each egg in settle speaks to one arrangement, and the cuckoo flying creature's egg speaks to another arrangement. Wellness for every arrangement is handled, and settle with the high bore of eggs addresses the best game plan. The methodology is continued with aside from if a worldwide ideal arrangement is refined [39] (**Figure 7**).

To solve the problem of clusterin load balancer cuckoo search algorithm can be used. It does so by finding out the optimal resource allocation. Initially, we model

the given cluster into a graph and then find the optimal resource allocation to this graph. Global solution to the given problem can be found using this technique. It essentially mimics the behavior of cuckoos and their behavior in laying eggs [40].

a. The algorithm is roughly based on these ideas.

b.How cuckoos lay their eggs in host nests.

c. How the eggs are hatched by hosts, if not detected and destroyed.

d.How can we mimic this behavior to make an algorithm.

This algorithm can be divided into five different steps: Generating initial population: We are generating host nests for k nests.

ð Þ l1*;* b1 *,*ð Þ l2*;* b2 *,* ��������� ð Þ ln *;* bn

These are optimal parameters

(1) Lay the cuckoo eggs (lk', bk') in the n nest.

n nest is randomly selected. Both have similar structure.

Lk' <sup>¼</sup> lk <sup>þ</sup> Randomwalk Levy flight lk bk' <sup>¼</sup> bk <sup>þ</sup> Randomwalk Levy flight bk

(2) Compare the fitness of both eggs

The fitness can be found out by any statistical technique.


different kinds of algorithms. Here we are proposing this algorithm to solve the cluster of resource allocation in the load balancer. To solve the optimal resource allocation problem in the load balancer we use firefly optimization. Firefly optimization is unique in its approach as it tends to lead toward an optimal global solution. Essentially it mimics the behavior of fireflies, more explicitly flashing patterns of fireflies. Initially, we model the given problem into the graph, and we implement the firefly algorithm on this graph to find the optimal resource allocation [42].

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

1. Uses of flashing patterns like: communication, attracting prey, warning

the same species).

**Figure 8.** *Firefly optimization.*

**99**

2. Rules for the algorithm: Rule 1: fireflies are unisex.

mechanism (female flies react toward the male's unique pattern of flashing in

(5) Repeat step 2–5 until we satisfy termination condition.

#### **2.6 Firefly optimization**

"Firefly algorithm (FA)" is the most heuristic algorithm for worldwide improvement, which is enlivened by the blazing behavior of firefly creepy crawlies. Xin-She Yang proposed this algorithm in 2008. The basic role of an (FA) is to go about as a flag framework to draw in different fireflies. Xin-She Yang defined this firefly algorithm by accepting that whole firefly are epicene with the goal that any single firefly will be pulled in to every other firefly. Engaging quality is relative to their shine, and for any two fireflies, the less brilliant one will be pulled in by the brighter one. In any case, the power diminishes as their aggregate length raises. If near are no fireflies luminous than an accustomed firefly, it will move randomly. The illumination should be related to the objective function [41] (**Figure 8**).

A load balancer is a device which is used to solve cluster problems in resource allocation. To solve the optimal resource allocation problem in the cluster we use

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

the given cluster into a graph and then find the optimal resource allocation to this graph. Global solution to the given problem can be found using this technique. It essentially mimics the behavior of cuckoos and their behavior in laying eggs [40].

c. How the eggs are hatched by hosts, if not detected and destroyed.

ð Þ l1*;* b1 *,*ð Þ l2*;* b2 *,* ��������� ð Þ ln *;* bn

Lk' <sup>¼</sup> lk <sup>þ</sup> Randomwalk Levy flight lk bk' <sup>¼</sup> bk <sup>þ</sup> Randomwalk Levy flight bk

(4) If the host bird notices then leave that nest and search for other nest (to

"Firefly algorithm (FA)" is the most heuristic algorithm for worldwide improvement, which is enlivened by the blazing behavior of firefly creepy crawlies. Xin-She Yang proposed this algorithm in 2008. The basic role of an (FA) is to go about as a flag framework to draw in different fireflies. Xin-She Yang defined this firefly algorithm by accepting that whole firefly are epicene with the goal that any single firefly will be pulled in to every other firefly. Engaging quality is relative to their shine, and for any two fireflies, the less brilliant one will be pulled in by the brighter one. In any case, the power diminishes as their aggregate length raises. If near are no fireflies luminous than an accustomed firefly, it will move randomly. The illumina-

A load balancer is a device which is used to solve cluster problems in resource allocation. To solve the optimal resource allocation problem in the cluster we use

d.How can we mimic this behavior to make an algorithm.

This algorithm can be divided into five different steps:

a. The algorithm is roughly based on these ideas.

b.How cuckoos lay their eggs in host nests.

*Scheduling Problems - New Applications and Trends*

We are generating host nests for k nests.

(2) Compare the fitness of both eggs

avoid local optimization).

**2.6 Firefly optimization**

**98**

(1) Lay the cuckoo eggs (lk', bk') in the n nest. n nest is randomly selected. Both have similar structure.

The fitness can be found out by any statistical technique.

(3) Now replace the eggs according to the fitness value.

(5) Repeat step 2–5 until we satisfy termination condition.

tion should be related to the objective function [41] (**Figure 8**).

Generating initial population:

These are optimal parameters

different kinds of algorithms. Here we are proposing this algorithm to solve the cluster of resource allocation in the load balancer. To solve the optimal resource allocation problem in the load balancer we use firefly optimization. Firefly optimization is unique in its approach as it tends to lead toward an optimal global solution. Essentially it mimics the behavior of fireflies, more explicitly flashing patterns of fireflies. Initially, we model the given problem into the graph, and we implement the firefly algorithm on this graph to find the optimal resource allocation [42].


3. The principle of the algorithm:

This algorithm can be divided into six different steps, (a) Initializing the objective function:

$$\mathbf{I} = \mathbf{I}\_{-} \mathbf{0}\_{\;\;\theta}{}^{\left(-\text{kd}^{2}\right)}$$

Here k is the absorption coefficient and d is the distance. As we know,

$$\mathbf{I(d) = I(s)/d^2}$$

(b) Generating initial firefly population: we use this equation to initialize the firefly population

$$\mathbf{M}\mathbf{t} + \mathbf{1} = \mathbf{M}\mathbf{t} + \mathbf{B}\mathbf{o} \ast \left(\mathbf{e}^{-}\mathbf{k}\left(\mathbf{d}^{2}\right)\right) + \mathbf{a} \ast \mathbf{e}$$

second term attraction third term randomization.


$$\mathbf{B} = \mathbf{B}\mathbf{O} \ast\_{\oplus} (^{-\text{kd}^2})$$

A process to find the best solution:

order to find an optimal solution:

2. The energy goal function. E()

4.The acceptance probability p()

6. Initial temperature()

4.Efficient candidate generation

2. Transition probability

3. Acceptance probability

5. Avoiding barrier

6.Cooling procedure

**101**

to find out the optimal solution.

3. The candidate generator neighbor()

5. The annealing scheduling temperature()

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

1. The space state.

**Figure 9.**

*Simulated annealing.*

1. Selecting parameters: initially, we need to specify the following parameters in

Each step can be mapped to the original simulated annealing process where we perform all these steps to get metal without defects here we use a similar procedure


#### **2.7 Simulated annealing**

For approximating the worldwide ideal of an inclined function, "simulated annealing (SA)" is a valuable method. It is often worn when the pursuit space is detached. For issues where revelation a close global optimum is broader than completing up an obvious local optimum in a shot volume of age, simulated annealing may be attractive over decisions, for example, gradient descent [43].

Simulated annealing is a strategy for approximating the worldwide ideal of a given function. It is utilized for global enhancement in expansive search space. It is utilized when search space is discrete. Annealing technology in metallurgy rouses it. A procedure including both warming and simultaneously cooling to increase the size and to decrease abandons in the given material. This procedure is utilized to locate a right arrangement. A load balancer is an apparatus which is utilized to find the optimal asset allotment of a given cluster issue in the cloud, and we can utilize a few sorts of metaheuristics to locate an optimal solution here we utilize recreated toughening to locate the optimal solution for the given issue. This solution begins by modeling graph of the given cluster, and we have to apply this strategy on the chart which will correspond to the optimal resource allocation solution in the cluster [44].

Initial slow cooling can be explored as the probability to accept the worst solution when this solution is running iteratively we get the best possible solution. After generating each solution the algorithm checks for its fitness and compares with previous one and picks the best one [45] (**Figure 9**).

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

**Figure 9.** *Simulated annealing.*

Rule 2: attraction increases as the brightness of light increases and decreases as

Rule 3: the brightness of fireflies is generally determined by the objective function.

<sup>I</sup> <sup>¼</sup> I\_0 <sup>ⅇ</sup> �kd2 ð Þ

I dð Þ¼ I sð Þ*=*d<sup>2</sup>

(b) Generating initial firefly population: we use this equation to initialize the

Mt <sup>þ</sup> <sup>1</sup> <sup>¼</sup> Mt <sup>þ</sup> Bo <sup>∗</sup> <sup>e</sup>�k d<sup>2</sup> <sup>þ</sup> <sup>a</sup> <sup>∗</sup> <sup>e</sup>

(c) Determine the intensity of light: find brightness for every firefly using

<sup>B</sup> <sup>¼</sup> B0 <sup>∗</sup> <sup>ⅇ</sup> �kd<sup>2</sup> ð Þ

For approximating the worldwide ideal of an inclined function, "simulated annealing (SA)" is a valuable method. It is often worn when the pursuit space is detached. For issues where revelation a close global optimum is broader than completing up an obvious local optimum in a shot volume of age, simulated annealing

Simulated annealing is a strategy for approximating the worldwide ideal of a given function. It is utilized for global enhancement in expansive search space. It is utilized when search space is discrete. Annealing technology in metallurgy rouses it. A procedure including both warming and simultaneously cooling to increase the size and to decrease abandons in the given material. This procedure is utilized to locate a right arrangement. A load balancer is an apparatus which is utilized to find the optimal asset allotment of a given cluster issue in the cloud, and we can utilize a few sorts of metaheuristics to locate an optimal solution here we utilize recreated toughening to locate the optimal solution for the given issue. This solution begins by modeling graph of the given cluster, and we have to apply this strategy on the chart which will correspond to the optimal resource allocation solution in the cluster [44]. Initial slow cooling can be explored as the probability to accept the worst solution when this solution is running iteratively we get the best possible solution. After generating each solution the algorithm checks for its fitness and compares with

(f) Rank the flies and find the current best, Update the intensities.

may be attractive over decisions, for example, gradient descent [43].

the distance increases.

firefly population

**2.7 Simulated annealing**

**100**

As we know,

3. The principle of the algorithm:

(a) Initializing the objective function:

*Scheduling Problems - New Applications and Trends*

This algorithm can be divided into six different steps,

Here k is the absorption coefficient and d is the distance.

second term attraction third term randomization.

(e) Move the less bright fireflies to bright ones.

previous one and picks the best one [45] (**Figure 9**).

objective function equation. (d) Calculate the attractiveness of Firefly:

A process to find the best solution:

	- 1. The space state.
	- 2. The energy goal function. E()
	- 3. The candidate generator neighbor()
	- 4.The acceptance probability p()
	- 5. The annealing scheduling temperature()
	- 6. Initial temperature()

Each step can be mapped to the original simulated annealing process where we perform all these steps to get metal without defects here we use a similar procedure to find out the optimal solution.

Here we consider graph as metal and perform these tasks to find out the optimal solution.

the load balancer and then use this algorithm to find the optimal resource allocation. Every node in this algorithm consists of the capacity of VM, probability, etc. [48]. After graph modeling is done we continue with the stage of implementation using a

1. Initialization phase: firstly, we need to declare the population size (k), no of subarrays (M), no of iterations in local exploration (u), no of algorithmic iterations (I), after that we need to generate no of frogs (k) randomly.

2. Fitness phase: firstly, we need to check the fitness of every frog using fitness

3. Fitness functions: fitness = (1-(avg(load)/(avg(load)-least lode) + ((no of underloaded and overloaded nodes)/total no of nodes). Then after calculating the fitness of every frog, we need to sort them based on descending order of

4.Formation of sub array and subarray: initially partitioning the sorted fitness array into subarrays as declared initially and now partitioning each subarray

5. Local search phase: now perform a local search for every sub-array here is where this algorithm mimics frog leaping and perform search accordingly.

6.Convergence checking: now check for converging if convergence is satisfied

7. Off-spring generation phase: now perform this phase using fitness algorithm. Compare frogs and exchange information between sb, sw and continue this divide and conquer approach for u times, Now replace this final output by sb

The fitness for new product generated by the local search is calculated and this is

The "bat algorithm (BA)" is the most eristic algorithm for global improvement. It was propelled by the allotment conduct of microbats, with fluctuating heartbeat rates of outflow and din. Xin-She Yang built up this algorithm in 2010. Each virtual bat flies heedlessly with a speed at a circumstance with a shifting recurrence or wavelength and tumult as it ventures and finds its prey, it changes recurrence, din and heartbeat surge rate. A local random walk escalates seek. Decision of the best

this is optimal solution else repeat from frog fitness phase.

updated solutions and this process continues until termination is given.

Essentially this algorithm can be classified into five phases:

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

frog leaping algorithm (**Figure 10**).

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

functions.

fitness values.

value.

1. Termination phase:

c. Time took.

**2.9 Bat algorithm**

**103**

a. Number of generations.

b.The fitness of the optimal solution.

continues to the point that specific stop criteria are met [49].

into another sub-array.

#### **2.8 Shuffled frog leaping algorithm**

Load balancing using improved shuffled frog leaping algorithm. The "shuffled frog leaping algorithm (SFLA)" is a populace based algorithm excited by regular ridiculous. The virtual frogs go about as hosts or transporters of images where an image is a unit of social headway. The algorithm plays out an independent local search in each memeplex at the same time [46]. The local search is finished utilizing a particle swarm enhancement like technique adjusted for discrete issues, however, emphasizing a local search. To guarantee global investigation, the virtual frogs are intermittently rearranged and redesigned into new memeplexes in an approach indistinguishable from that well used in the rearranged complex evolution algorithm [47].

Load balancing technique essentially requires optimization technique to solve the given cluster problem of resource allocation. Any number of techniques can do this essentially we are using improved shuffled frog leaping algorithm which is also a part of swarm intelligence. To find the optimal solution to the given problem this algorithm imitates the behavior of frogs leaping and used this procedure. For load balancing with this technique, we require graph modeling of the cluster we get from

**Figure 10.** *Shuffled frog leaping algorithm.*

the load balancer and then use this algorithm to find the optimal resource allocation. Every node in this algorithm consists of the capacity of VM, probability, etc. [48]. After graph modeling is done we continue with the stage of implementation using a frog leaping algorithm (**Figure 10**).

Essentially this algorithm can be classified into five phases:


The fitness for new product generated by the local search is calculated and this is updated solutions and this process continues until termination is given.

	- a. Number of generations.
	- b.The fitness of the optimal solution.
	- c. Time took.

#### **2.9 Bat algorithm**

The "bat algorithm (BA)" is the most eristic algorithm for global improvement. It was propelled by the allotment conduct of microbats, with fluctuating heartbeat rates of outflow and din. Xin-She Yang built up this algorithm in 2010. Each virtual bat flies heedlessly with a speed at a circumstance with a shifting recurrence or wavelength and tumult as it ventures and finds its prey, it changes recurrence, din and heartbeat surge rate. A local random walk escalates seek. Decision of the best continues to the point that specific stop criteria are met [49].

Here we consider graph as metal and perform these tasks to find out the optimal

Load balancing using improved shuffled frog leaping algorithm. The "shuffled frog leaping algorithm (SFLA)" is a populace based algorithm excited by regular ridiculous. The virtual frogs go about as hosts or transporters of images where an image is a unit of

memeplex at the same time [46]. The local search is finished utilizing a particle swarm enhancement like technique adjusted for discrete issues, however, emphasizing a local

Load balancing technique essentially requires optimization technique to solve the given cluster problem of resource allocation. Any number of techniques can do this essentially we are using improved shuffled frog leaping algorithm which is also a part of swarm intelligence. To find the optimal solution to the given problem this algorithm imitates the behavior of frogs leaping and used this procedure. For load balancing with this technique, we require graph modeling of the cluster we get from

social headway. The algorithm plays out an independent local search in each

search. To guarantee global investigation, the virtual frogs are intermittently rearranged and redesigned into new memeplexes in an approach indistinguishable

from that well used in the rearranged complex evolution algorithm [47].

solution.

**Figure 10.**

**102**

*Shuffled frog leaping algorithm.*

**2.8 Shuffled frog leaping algorithm**

*Scheduling Problems - New Applications and Trends*

To solve the resource allocation problem in the given cluster a load balancer is an instrument which is utilized. We have to locate the ideal asset designation to take care of the issue of asset portion. The information for ideal asset portion is normally present in the cluster. We have to utilize any methods to locate the ideal answer for the given asset allotment issue. Here to locate the ideal answer for the given issue in the cluster we utilize the bat algorithm which impersonates the conduct of the bat. We need to use graph modeling of the given cluster to find the optimal solution initially. Essentially every node of cluster contains information about resource allocation, and when we use optimization on that graph, we find the optimal solution to the task which turns out to be optimal resource allocation for the given problem in the cluster. Here we are using Bat algorithm which is kind of swarm intelligence as it mimics the behavior of any flock of animals here we observe that we are mimicking the bat to find optimal solution hence bat algorithm [50].

Xin-She Yang proposed bat algorithm in the year 2010. It mimics the echolocation phenomenon seen in the bats. It uses sonar effect to navigate and communicate with other bats. Sonar is a form of ultrasonic sound only a few creatures like bats can understand and navigate through this. They calculate time delay to navigate, and the time delay is between emission and reflection. While reflecting bats use two notions zero means no emission one means maximum emission (**Figure 11**).

Ground Rules for this algorithm:

a. Bats can sense all kind of obstacles by this sound.

b.They fly randomly.

c. Loudness is always positive

Mathematical equations:

*Gravitational search algorithm.*

**Figure 12.**

**105**

x\* is current best solution.

K is random value between 0 and 1.

Fi ¼ f0 þ ð Þ f1 � f0 ∗K Vit ¼ vit � 1 þ ð Þ xit � x ∗ fi Xit ¼ xit � 1 þ vit

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

**Figure 11.** *Bat algorithm.*

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

**Figure 12.** *Gravitational search algorithm.*

Mathematical equations:

$$\mathbf{F}\mathbf{i} = \mathbf{f0} + (\mathbf{f1} - \mathbf{f0}) \ast \mathbf{K}$$

$$\mathbf{Vit} = \mathbf{vit} - \mathbf{1} + (\mathbf{xit} - \mathbf{x} \ast)\mathbf{fi}$$

$$\mathbf{Xit} = \mathbf{xit} - \mathbf{1} + \mathbf{vit}$$

K is random value between 0 and 1.

x\* is current best solution.

To solve the resource allocation problem in the given cluster a load balancer is an instrument which is utilized. We have to locate the ideal asset designation to take care of the issue of asset portion. The information for ideal asset portion is normally present in the cluster. We have to utilize any methods to locate the ideal answer for the given asset allotment issue. Here to locate the ideal answer for the given issue in the cluster we utilize the bat algorithm which impersonates the conduct of the bat. We need to use graph modeling of the given cluster to find the optimal solution initially. Essentially every node of cluster contains information about resource allocation, and when we use optimization on that graph, we find the optimal solution to the task which turns out to be optimal resource allocation for the given problem in the cluster. Here we are using Bat algorithm which is kind of swarm intelligence as it mimics the behavior of any flock of animals here we observe that we are mimicking the bat to find optimal solution hence bat

Xin-She Yang proposed bat algorithm in the year 2010. It mimics the echolocation phenomenon seen in the bats. It uses sonar effect to navigate and communicate with other bats. Sonar is a form of ultrasonic sound only a few creatures like bats can understand and navigate through this. They calculate time delay to navigate, and the time delay is between emission and reflection. While reflecting bats use two notions zero means no emission one means maximum emission

algorithm [50].

(**Figure 11**).

**Figure 11.** *Bat algorithm.*

**104**

Ground Rules for this algorithm:

*Scheduling Problems - New Applications and Trends*

b.They fly randomly.

c. Loudness is always positive

a. Bats can sense all kind of obstacles by this sound.


**Algorithm**

**107**

1. Cuckoo

Search

 **Advantages** 1. Deals with multi criteria

optimization

implement.

Aims to speed up

> 1. Firefly

1. It can deal with highly non-linear

optimization:

problems.

2. It does not use velocities. 3. Does not require good initial start

for

> 1. Simulated

> 1. It can deal with inconsistent

> and

1. Lot of choices are required to

1. It can be used to find accurate

solution as it approaches

the global solution.

 to find

1. Not adaptable as it takes lot of

computational

 time.

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

make it into actual algorithm.

2. It takes lot of

computation

 time

annealing:

noisy data.

2. To approach global optimum. 3. It is versatile as it does not rely on

restrictive property of model.

> 1. Shuffled Frog

1. Need not to model the given

1. Takes up more

resources.

2. Takes up more amount of time.

computational

1. This can be used for both static

1. Yes, as it does not always

require graph modeling.

allocation problem and dynamic

allocation problem.

cluster as a graph.

Leaping

Algorithm

2. Studies show that this algorithm is

directing toward global optimal

solution.

3. Optimal solution is found out in

iterative manner.

> 1. Bat

1. Automatic zooming

1. Limited accuracy

1. Can be used to find the

1. Not adaptive as it has limited

accuracy.

immediate solution.

Unable to predict best solution.

Parameter control Frequency tuning

Algorithm

1.

Gravitational

1. Less execution time.

2. Less

3. More optimal solution.

computational

 resource.

1. This algorithm cannot be used on

1. Utilization:

 for static allocation

 1. No, it is not adaptive as it

requires graph modeling.

its own but can be used as support

algorithm in hybrid

or for calculating fitness in other

algorithms.

functionality

search

algorithm:

**Table 1.** *Comparison*

 *of various algorithms.*

optimization.

convergence.

1. Global searching.

2. Slow converging 3. High possibility to get trapped in

the local optimum.

 speed.

 Simple to understand.

 problem. Easy to

**Disadvantages**

1. Cannot tackle dynamic resource

allocation.

**Utilization** 1. Similar to ABC it can be utilized

if we compromise

of solution. 1. It can be used to find the accurate

1. Not adaptive as it has slow

converging

 speed.

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

solution.

 on the quality

**Adaptive**

1. It is not adaptive as it does

not tackle dynamic resource

allocation.


#### *An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

**107**

**Algorithm**

**106**

1. Hill Climbing

 **Advantages**

 1. Better rather than FIFO, DFS, etc.

2. Can be used with less

computational

3. Takes lesser time.

4. Can be used in Dynamic

allocation.

1. Ant colony

1. Best optimal solution can be found

Optimization

out for both static and dynamic

problems. Takes relatively less

time than traditional algorithms.

As it has many variants like

recursive one it can be used based

on context.

> 1. Artificial bee

1. Can solve any kind of

1. The solution we get is optimal but

1. Static solution

environment,

 Initial

1. No, because not every problem can be modeled as

graph.

not perfect solution. Not adaptable

because every problem cannot be

modeled into a graph. Cannot

tackle dynamic allocation. Takes

optimization

can solve any kind of resource

allocation. Simple, Flexible and

robust. Ability to explore local

solutions. Ease of

> 1. Genetic

1. Takes up less amount of time.

More desirable than all the traditional algorithms in terms of

both time taken and forming

output.

Algorithm

implementation.

up more amount of time. Uses up

more

1. Needs more

to produce the ideal answer for the

issue. The algorithm irrespective

of its accuracy can find difficulty

to find global maximum and

sometimes struck at local maxima.

The termination unclear that is optimal solution is

always handle dynamic allocation.

comparative.

 Cannot

 is sometimes

computational

 resources.

computational

 assets

1. Generally used for static problem

1. Yes, this can be used on any kind

of problem cluster.

and can be used for iterative

solution making.

 problem in this case

colony:

 resources.

optimization

 technique

1. Co-ordinate used as it takes huge amount of

time to determine optimal solution. Stochastic hill climbing

cannot be used as it does not find the exact optimal solution. Is less

efficient when compared to other

iterative algorithms like ant colony

based, Genetic algorithm.

1. Best optimal solution can be found

1. This can be used to both find

1. Yes, it is adaptable as it has

*Scheduling Problems - New Applications and Trends*

many variants

initial solution and better the

solution by using iterative

variant.

but is relatively less effective than

genetic and such kind of

algorithms.

 descent cannot be

**Disadvantages**

**Utilization**

1. Can be used to find out initial optimal solution and can be put

in iterative optimal solutions to

find best solution.

**Adaptive**

1. Yes, because there are two

different variants of techniques with respect to the

given problem.

**Table 1.** *Comparison of various algorithms.*

Xnew ¼ xold þ H ∗ at

optimization. These algorithms are useful in finding optimized solutions for our lives by applying various laws and identifying the patterns of bats and flies like in Bat Algorithm, a search is identified by their local random walk and Firefly Algorithm.

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

Different optimization techniques can be used as a hybrid to suit the appropriate

usage to overcome the disadvantages of one over the other. New optimization

**5. Future scope**

**Author details**

**109**

Surya Teja Marella\* and Thummuru Gunasekhar

\*Address all correspondence to: suryatejamarella@gmail.com

Foundation Vijayawada, Guntur, India

provided the original work is properly cited.

Department of Computer Science Engineering, Koneru Lakshmaiah Educational

© 2020 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium,

techniques can be formulated from nature.

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

H is a random value between �1 and 1 (Loudness decreases as the bat have found prey).

#### **2.10 Gravitational search algorithm (GSA)**

"Gravitational search algorithm (GSA)" is a reality discovering algorithm which is picking up enthusiasm among scientific community these days. Gravitational Search Algorithm (GSA) is a populace search algorithm based on Newton's law of gravity and the law of movement. GSA is represented to be more instinctual. In GSA, the specialist has four parameters which are the position, inertial mass, unique gravitational mass, and uninvolved gravitational mass. The arrangements in the GSA masses are called specialists, and they speak with each other through the gravity compel. Its mass measures the execution of these agents. Each agent is considered an object and all object move toward different items with all the more extensive mass because of gravity compel [17] (**Figure 12**).

To solve the cluster problem of resource allocation Load balancing is the technique used, and several techniques can be used to solve this clustering problem. One such way is using gravitational search algorithm. The gravitational search algorithm uses evolutionary computing [51].

Evolutionary computing is more efficient than traditional algorithms because the solutions do not stagnate in local minima and are faster and robust when compared to other different algorithms.

It is memoryless takes up less computational time than other algorithms. The gravitational search algorithm is a likeness to the particle swarm algorithm. Gravitational search algorithm was proposed by Rashedi et al. in the year 2009. This metaheuristic comes in the category of computational intelligence. Initially, a cluster from the load balancer is taken as an input, and this is modeled into a graph. To find out the optimal resource allocation now Gravitational search algorithm is applied to the graph. This algorithm is inspired from Newtonian mechanics and specifically from Newton's second law and law of gravitation [52].

#### **3. Advantages and disadvantages of various algorithms**

Advantages, disadvantages, utilization and adaptivity of various nature-inspired algorithms are listed in **Table 1**.

#### **4. Conclusion**

In this paper we chew over different basic concepts of cloud computing, the primary focus has been kept to understand load balancer and how it functions to do task allocation and different traditional algorithms which help in task allocation have also been discussed, and nature-inspired algorithms were discussed in specific. These were classified into different types like swarm based, genetically inspired, physicsbased and different algorithms from each category were explained, and each was explained with different advantages, limitations, etc., and all were compared with respect to their positive points and working methodology and with relevance to load balancer An attempt has been made to survey out the different algorithms present in nature and provide relevant solution for optimal resource allocation for load balancer in cloud. All these different algorithms are nature-inspired and are used for global

optimization. These algorithms are useful in finding optimized solutions for our lives by applying various laws and identifying the patterns of bats and flies like in Bat Algorithm, a search is identified by their local random walk and Firefly Algorithm.

### **5. Future scope**

Xnew ¼ xold þ H ∗ at

H is a random value between �1 and 1 (Loudness decreases as the bat have

"Gravitational search algorithm (GSA)" is a reality discovering algorithm which is picking up enthusiasm among scientific community these days. Gravitational Search Algorithm (GSA) is a populace search algorithm based on Newton's law of gravity and the law of movement. GSA is represented to be more instinctual. In GSA, the specialist has four parameters which are the position, inertial mass, unique gravitational mass, and uninvolved gravitational mass. The arrangements in the GSA masses are called specialists, and they speak with each other through the gravity compel. Its mass measures the execution of these agents. Each agent is considered an object and all object move toward different items with all the more

To solve the cluster problem of resource allocation Load balancing is the technique used, and several techniques can be used to solve this clustering problem. One such way is using gravitational search algorithm. The gravitational search algorithm

Evolutionary computing is more efficient than traditional algorithms because the solutions do not stagnate in local minima and are faster and robust when

It is memoryless takes up less computational time than other algorithms. The gravitational search algorithm is a likeness to the particle swarm algorithm. Gravitational search algorithm was proposed by Rashedi et al. in the year 2009. This metaheuristic comes in the category of computational intelligence. Initially, a cluster from the load balancer is taken as an input, and this is modeled into a graph. To find out the optimal resource allocation now Gravitational search algorithm is applied to the graph. This algorithm is inspired from Newtonian mechanics and

Advantages, disadvantages, utilization and adaptivity of various nature-inspired

In this paper we chew over different basic concepts of cloud computing, the primary focus has been kept to understand load balancer and how it functions to do task allocation and different traditional algorithms which help in task allocation have also been discussed, and nature-inspired algorithms were discussed in specific. These were classified into different types like swarm based, genetically inspired, physicsbased and different algorithms from each category were explained, and each was explained with different advantages, limitations, etc., and all were compared with respect to their positive points and working methodology and with relevance to load balancer An attempt has been made to survey out the different algorithms present in nature and provide relevant solution for optimal resource allocation for load balancer in cloud. All these different algorithms are nature-inspired and are used for global

found prey).

**2.10 Gravitational search algorithm (GSA)**

*Scheduling Problems - New Applications and Trends*

uses evolutionary computing [51].

algorithms are listed in **Table 1**.

**4. Conclusion**

**108**

compared to other different algorithms.

extensive mass because of gravity compel [17] (**Figure 12**).

specifically from Newton's second law and law of gravitation [52].

**3. Advantages and disadvantages of various algorithms**

Different optimization techniques can be used as a hybrid to suit the appropriate usage to overcome the disadvantages of one over the other. New optimization techniques can be formulated from nature.

### **Author details**

Surya Teja Marella\* and Thummuru Gunasekhar Department of Computer Science Engineering, Koneru Lakshmaiah Educational Foundation Vijayawada, Guntur, India

\*Address all correspondence to: suryatejamarella@gmail.com

© 2020 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

### **References**

[1] Baran ME, Wu FF. Network reconfiguration in distribution systems for loss reduction and load balancing. IEEE Transactions on Power Delivery. 1989;**4**(2):1401-1407

[2] Randles M, Lamb D, Taleb-Bendiab A. A comparative study into distributed load balancing algorithms for cloud computing. In: 2010 IEEE 24th International Conference on Advanced Information Networking and Applications Workshops (WAINA); IEEE; April 2010. pp. 551-556

[3] Al Nuaimi K, Mohamed N, Al Nuaimi M, Al-Jaroodi J. A survey of load balancing in cloud computing: Challenges and algorithms. In: 2012 Second Symposium on Network Cloud Computing and Applications (NCCA); IEEE; December 2012. pp. 137-142

[4] Velayos H, Aleo V, Karlsson G. Load balancing in overlapping wireless LAN cells. In: 2004 IEEE International Conference on Communications; IEEE; June 2004; Vol. 7. pp. 3833-3836

[5] Tantawi AN, Towsley D. Optimal static load balancing in distributed computer systems. Journal of the ACM (JACM). 1985;**32**(2):445-465

[6] Yousaf FZ, Taleb T. Fine-grained resource-aware virtual network function management for 5G carrier cloud. IEEE Network. 2016;**30**(2): 110-115

[7] Cybenko G. Dynamic load balancing for distributed memory multiprocessors. Journal of Parallel and Distributed Computing. 1989;**7**(2):279-301

[8] Performance Tradeoffs in Static and Dynamic Load Balancing Strategies; NASA; March 1986

[9] Shirazi BA, Kavi KM, Hurson AR. Scheduling and Load Balancing in

Parallel and Distributed Systems. IEEE Computer Society Press; 1995

[18] Zaki MJ, Li W, Parthasarathy S. Customized dynamic load balancing for a network of workstations. In: 1996, Proceedings of 5th IEEE International Symposium on High Performance Distributed Computing; IEEE; August

*DOI: http://dx.doi.org/10.5772/intechopen.87002*

*An Empirical Survey on Load Balancing: A Nature-Inspired Approach*

[28] Mitchell M, Holland JH, Forrest S.

outperform hill climbing. In: Advances in Neural Information Processing

[29] Tsamardinos I, Brown LE, Aliferis CF. The max-min hill-climbing Bayesian network structure learning algorithm. Machine Learning. 2006;**65**(1):31-78

optimization algorithm. UbiCC Journal.

[31] Dorigo M. Ant colony optimization.

[32] Yaseen SG, Al-Slamy NM. Ant colony optimization. IJCSNS. 2008;**8**(6):351

[33] Karaboga D. Artificial bee colony algorithm. scholarpedia. 2010;**5**(3):6915

[34] Karaboga D, Akay B. A comparative study of artificial bee colony algorithm. Applied Mathematics and Computation.

[35] Karaboga D, Basturk B. A powerful and efficient algorithm for numerical function optimization: Artificial bee colony (ABC) algorithm. Journal of Global Optimization. 2007;**39**(3):

[36] Deb K, Pratap A, Agarwal S, Meyarivan TAMT. A fast and elitist multiobjective genetic algorithm: NSGA-II. IEEE Transactions on Evolutionary Computation. 2002;**6**(2):

[37] Morris GM, Goodsell DS, Halliday RS, Huey R, Hart WE, Belew RK, et al. Automated docking using a Lamarckian genetic algorithm and an empirical binding free energy function. Journal of Computational Chemistry. 1998;**19**(14):

[38] Deb K, Agrawal S, Pratap A, Meyarivan T. A fast elitist

When will a genetic algorithm

[30] Al Salami NM. Ant colony

Scholarpedia. 2007;**2**(3):1461

2009;**4**(3):823-826

2009;**214**(1):108-132

459-471

182-197

1639-1662

Systems; 1994. pp. 51-58

[19] Raz Y, Scherr AL, EMC Corp. Dynamic load balancing. U.S. Patent 5,

[20] Trigui H, Cuthill R, Kusyk RG. Reverb Networks. Dynamic load balancing. U.S. Patent 8, 498, 207. 2013

[21] Raz Y, Vishlitzky N, Alterescu B, EMC Corp. Dynamic load balancing. U.

[22] Hendrickson B, Devine K. Dynamic

load balancing in computational mechanics. Computer Methods in Applied Mechanics and Engineering.

[23] Sharma S, Singh S, Sharma M. Performance analysis of load balancing algorithms. World Academy of Science, Engineering and Technology. 2008;

[24] Boyan JA, Littman ML. Packet routing in dynamically changing networks: A reinforcement learning approach. In: Advances in Neural Information Processing Systems; 1994.

[25] Yang XS. Nature-Inspired Metaheuristic Algorithms. Luniver

[26] Fister I Jr, Yang XS, Fister I, Brest J, Fister D. A brief review of natureinspired algorithms for optimization. 2013. arXiv preprint arXiv:1307.4186

[27] Zang H, Zhang S, Hapeshi K. A review of nature-inspired algorithms. Journal of Bionic Engineering. 2010;

S. Patent 6, 173, 306. 2001

2000;**184**(2-4):485-500

**38**(3):269-272

pp. 671-678

press; 2010

**7**(4):S232-S237

**111**

1996. pp. 282-291

860, 137. 1999

[10] Cardellini V, Colajanni M, Yu PS. Dynamic load balancing on web-server systems. IEEE Internet Computing. 1999;**3**(3):28-39

[11] Schoonderwoerd R, Holland OE, Bruten JL, Rothkrantz LJ. Ant-based load balancing in telecommunications networks. Adaptive Behavior. 1997;**5**(2): 169-207

[12] Brendel J, Kring CJ, Liu Z, Marino CC. Resonate Inc. World-wide-web server with delayed resource-binding for resource-based load balancing on a distributed resource multi-node network. U.S. Patent 5, 774, 660. 1998

[13] Willebeek-LeMair MH, Reeves AP. Strategies for dynamic load balancing on highly parallel computers. IEEE Transactions on Parallel and Distributed Systems. 1993;**4**(9):979-993

[14] Miyazaki T, Wada M, Kawahara H, Sato M, Baba H, Shimada S. Dynamic load at baseline can predict radiographic disease progression in medial compartment knee osteoarthritis. Annals of the Rheumatic Diseases. 2002; **61**(7):617-622

[15] Devine KD, Boman EG, Heaphy RT, Hendrickson BA, Teresco JD, Faik J, et al. New challenges in dynamic load balancing. Applied Numerical Mathematics. 2005;**52**(2-3):133-152

[16] Kim C, Kameda H. An algorithm for optimal static load balancing in distributed computer systems. IEEE Transactions on Computers. 1992;**41**(3):381-384

[17] Rashedi E, Nezamabadi-Pour H, Saryazdi S. GSA: A gravitational search algorithm. Information Sciences. 2009; **179**(13):2232-2248

#### *An Empirical Survey on Load Balancing: A Nature-Inspired Approach DOI: http://dx.doi.org/10.5772/intechopen.87002*

[18] Zaki MJ, Li W, Parthasarathy S. Customized dynamic load balancing for a network of workstations. In: 1996, Proceedings of 5th IEEE International Symposium on High Performance Distributed Computing; IEEE; August 1996. pp. 282-291

**References**

1989;**4**(2):1401-1407

[1] Baran ME, Wu FF. Network

reconfiguration in distribution systems for loss reduction and load balancing. IEEE Transactions on Power Delivery.

*Scheduling Problems - New Applications and Trends*

Parallel and Distributed Systems. IEEE

[10] Cardellini V, Colajanni M, Yu PS. Dynamic load balancing on web-server systems. IEEE Internet Computing.

[11] Schoonderwoerd R, Holland OE, Bruten JL, Rothkrantz LJ. Ant-based load balancing in telecommunications networks. Adaptive Behavior. 1997;**5**(2):

[12] Brendel J, Kring CJ, Liu Z, Marino CC. Resonate Inc. World-wide-web server with delayed resource-binding for resource-based load balancing on a distributed resource multi-node network. U.S. Patent 5, 774, 660. 1998

[13] Willebeek-LeMair MH, Reeves AP. Strategies for dynamic load balancing on

Transactions on Parallel and Distributed

[14] Miyazaki T, Wada M, Kawahara H, Sato M, Baba H, Shimada S. Dynamic load at baseline can predict radiographic

[15] Devine KD, Boman EG, Heaphy RT, Hendrickson BA, Teresco JD, Faik J, et al. New challenges in dynamic load

[16] Kim C, Kameda H. An algorithm for optimal static load balancing in distributed computer systems. IEEE Transactions on

[17] Rashedi E, Nezamabadi-Pour H, Saryazdi S. GSA: A gravitational search algorithm. Information Sciences. 2009;

highly parallel computers. IEEE

Systems. 1993;**4**(9):979-993

disease progression in medial compartment knee osteoarthritis. Annals of the Rheumatic Diseases. 2002;

balancing. Applied Numerical Mathematics. 2005;**52**(2-3):133-152

Computers. 1992;**41**(3):381-384

**179**(13):2232-2248

**61**(7):617-622

Computer Society Press; 1995

1999;**3**(3):28-39

169-207

[2] Randles M, Lamb D, Taleb-Bendiab A. A comparative study into distributed load balancing algorithms for cloud computing. In: 2010 IEEE 24th

International Conference on Advanced

[4] Velayos H, Aleo V, Karlsson G. Load balancing in overlapping wireless LAN cells. In: 2004 IEEE International Conference on Communications; IEEE; June 2004; Vol. 7. pp. 3833-3836

[5] Tantawi AN, Towsley D. Optimal static load balancing in distributed computer systems. Journal of the ACM

[6] Yousaf FZ, Taleb T. Fine-grained resource-aware virtual network function management for 5G carrier cloud. IEEE Network. 2016;**30**(2):

[7] Cybenko G. Dynamic load balancing for distributed memory multiprocessors. Journal of Parallel and Distributed Computing. 1989;**7**(2):279-301

[8] Performance Tradeoffs in Static and Dynamic Load Balancing Strategies;

[9] Shirazi BA, Kavi KM, Hurson AR. Scheduling and Load Balancing in

(JACM). 1985;**32**(2):445-465

110-115

**110**

NASA; March 1986

Information Networking and Applications Workshops (WAINA); IEEE; April 2010. pp. 551-556

[3] Al Nuaimi K, Mohamed N, Al Nuaimi M, Al-Jaroodi J. A survey of load

balancing in cloud computing: Challenges and algorithms. In: 2012 Second Symposium on Network Cloud Computing and Applications (NCCA); IEEE; December 2012. pp. 137-142

[19] Raz Y, Scherr AL, EMC Corp. Dynamic load balancing. U.S. Patent 5, 860, 137. 1999

[20] Trigui H, Cuthill R, Kusyk RG. Reverb Networks. Dynamic load balancing. U.S. Patent 8, 498, 207. 2013

[21] Raz Y, Vishlitzky N, Alterescu B, EMC Corp. Dynamic load balancing. U. S. Patent 6, 173, 306. 2001

[22] Hendrickson B, Devine K. Dynamic load balancing in computational mechanics. Computer Methods in Applied Mechanics and Engineering. 2000;**184**(2-4):485-500

[23] Sharma S, Singh S, Sharma M. Performance analysis of load balancing algorithms. World Academy of Science, Engineering and Technology. 2008; **38**(3):269-272

[24] Boyan JA, Littman ML. Packet routing in dynamically changing networks: A reinforcement learning approach. In: Advances in Neural Information Processing Systems; 1994. pp. 671-678

[25] Yang XS. Nature-Inspired Metaheuristic Algorithms. Luniver press; 2010

[26] Fister I Jr, Yang XS, Fister I, Brest J, Fister D. A brief review of natureinspired algorithms for optimization. 2013. arXiv preprint arXiv:1307.4186

[27] Zang H, Zhang S, Hapeshi K. A review of nature-inspired algorithms. Journal of Bionic Engineering. 2010; **7**(4):S232-S237

[28] Mitchell M, Holland JH, Forrest S. When will a genetic algorithm outperform hill climbing. In: Advances in Neural Information Processing Systems; 1994. pp. 51-58

[29] Tsamardinos I, Brown LE, Aliferis CF. The max-min hill-climbing Bayesian network structure learning algorithm. Machine Learning. 2006;**65**(1):31-78

[30] Al Salami NM. Ant colony optimization algorithm. UbiCC Journal. 2009;**4**(3):823-826

[31] Dorigo M. Ant colony optimization. Scholarpedia. 2007;**2**(3):1461

[32] Yaseen SG, Al-Slamy NM. Ant colony optimization. IJCSNS. 2008;**8**(6):351

[33] Karaboga D. Artificial bee colony algorithm. scholarpedia. 2010;**5**(3):6915

[34] Karaboga D, Akay B. A comparative study of artificial bee colony algorithm. Applied Mathematics and Computation. 2009;**214**(1):108-132

[35] Karaboga D, Basturk B. A powerful and efficient algorithm for numerical function optimization: Artificial bee colony (ABC) algorithm. Journal of Global Optimization. 2007;**39**(3): 459-471

[36] Deb K, Pratap A, Agarwal S, Meyarivan TAMT. A fast and elitist multiobjective genetic algorithm: NSGA-II. IEEE Transactions on Evolutionary Computation. 2002;**6**(2): 182-197

[37] Morris GM, Goodsell DS, Halliday RS, Huey R, Hart WE, Belew RK, et al. Automated docking using a Lamarckian genetic algorithm and an empirical binding free energy function. Journal of Computational Chemistry. 1998;**19**(14): 1639-1662

[38] Deb K, Agrawal S, Pratap A, Meyarivan T. A fast elitist

non-dominated sorting genetic algorithm for multi-objective optimization: NSGA-II. In: International Conference on Parallel Problem Solving From Nature; Berlin, Heidelberg: Springer; September 2000. pp. 849-858

[39] Gandomi AH, Yang XS, Alavi AH. Cuckoo search algorithm: A metaheuristic approach to solve structural optimization problems. Engineering with Computers. 2013; **29**(1):17-35

[40] Yildiz AR. Cuckoo search algorithm for the selection of optimal machining parameters in milling operations. The International Journal of Advanced Manufacturing Technology. 2013;**64** (1-4):55-61

[41] Yang XS. Firefly algorithm, stochastic test functions and design optimisation. International Journal of Bio-Inspired Computation. 2010;**2**(2): 78-84

[42] Yang XS. Firefly algorithm, levy flights and global optimization. In: Research and Development in Intelligent Systems XXVI. London: Springer; 2010. pp. 209-218

[43] Corana A, Marchesi M, Martini C, Ridella S. Minimizing multimodal functions of continuous variables with the "simulated annealing" algorithm corrigenda for this article is available here. ACM Transactions on Mathematical Software (TOMS). 1987; **13**(3):262-280

[44] Kirkpatrick S, Gelatt CD, Vecchi MP. Optimization by simulated annealing. Science. 1983;**220**(4598): 671-680

[45] Szu H, Hartley R. Fast simulated annealing. Physics Letters A. 1987;**122** (3-4):157-162

[46] Eusuff MM, Lansey KE. Optimization of water distribution network design using the shuffled frog leaping algorithm. Journal of Water Resources Planning and Management. 2003;**129**(3):210-225

[47] Eusuff M, Lansey K, Pasha F. Shuffled frog-leaping algorithm: A memetic meta-heuristic for discrete optimization. Engineering Optimization. 2006;**38**(2):129-154

[48] Rahimi-Vahed A, Mirzaei AH. A hybrid multi-objective shuffled frogleaping algorithm for a mixed-model assembly line sequencing problem. Computers & Industrial Engineering. 2007;**53**(4):642-666

[49] Yang XS. A new metaheuristic batinspired algorithm. In: Nature Inspired Cooperative Strategies for Optimization (NICSO 2010). Berlin, Heidelberg: Springer; 2010. pp. 65-74

Section 3

Cloud Computing and Data

Science: Exploring the

Benefits of Task Scheduling

on Such Environments

**113**

[50] Yang XS, Hossein Gandomi A. Bat algorithm: A novel approach for global engineering optimization. Engineering Computations. 2012;**29**(5):464-483

[51] Rashedi E, Nezamabadi-Pour H, Saryazdi S. BGSA: Binary gravitational search algorithm. Natural Computing. 2010;**9**(3):727-745

[52] Rashedi E, Nezamabadi-Pour H, Saryazdi S. Filter modeling using gravitational search algorithm. Engineering Applications of Artificial Intelligence. 2011;**24**(1):117-122

## Section 3

Cloud Computing and Data Science: Exploring the Benefits of Task Scheduling on Such Environments

non-dominated sorting genetic algorithm for multi-objective

optimization: NSGA-II. In: International Conference on Parallel Problem Solving From Nature; Berlin, Heidelberg: Springer; September 2000. pp. 849-858

*Scheduling Problems - New Applications and Trends*

network design using the shuffled frog leaping algorithm. Journal of Water Resources Planning and Management.

[47] Eusuff M, Lansey K, Pasha F. Shuffled frog-leaping algorithm: A memetic meta-heuristic for discrete

Optimization. 2006;**38**(2):129-154

[48] Rahimi-Vahed A, Mirzaei AH. A hybrid multi-objective shuffled frogleaping algorithm for a mixed-model assembly line sequencing problem. Computers & Industrial Engineering.

[49] Yang XS. A new metaheuristic batinspired algorithm. In: Nature Inspired Cooperative Strategies for Optimization (NICSO 2010). Berlin, Heidelberg:

[50] Yang XS, Hossein Gandomi A. Bat algorithm: A novel approach for global engineering optimization. Engineering Computations. 2012;**29**(5):464-483

[51] Rashedi E, Nezamabadi-Pour H, Saryazdi S. BGSA: Binary gravitational search algorithm. Natural Computing.

[52] Rashedi E, Nezamabadi-Pour H, Saryazdi S. Filter modeling using gravitational search algorithm. Engineering Applications of Artificial Intelligence. 2011;**24**(1):117-122

optimization. Engineering

2007;**53**(4):642-666

Springer; 2010. pp. 65-74

2010;**9**(3):727-745

2003;**129**(3):210-225

[39] Gandomi AH, Yang XS, Alavi AH.

[40] Yildiz AR. Cuckoo search algorithm for the selection of optimal machining parameters in milling operations. The International Journal of Advanced Manufacturing Technology. 2013;**64**

[41] Yang XS. Firefly algorithm, stochastic test functions and design optimisation. International Journal of Bio-Inspired Computation. 2010;**2**(2):

[42] Yang XS. Firefly algorithm, levy flights and global optimization. In: Research and Development in Intelligent Systems XXVI. London: Springer; 2010. pp. 209-218

[43] Corana A, Marchesi M, Martini C, Ridella S. Minimizing multimodal functions of continuous variables with the "simulated annealing" algorithm corrigenda for this article is available

Mathematical Software (TOMS). 1987;

[44] Kirkpatrick S, Gelatt CD, Vecchi MP. Optimization by simulated annealing. Science. 1983;**220**(4598):

[45] Szu H, Hartley R. Fast simulated annealing. Physics Letters A. 1987;**122**

[46] Eusuff MM, Lansey KE. Optimization of water distribution

here. ACM Transactions on

**13**(3):262-280

671-680

**112**

(3-4):157-162

Cuckoo search algorithm: A metaheuristic approach to solve structural optimization problems. Engineering with Computers. 2013;

**29**(1):17-35

(1-4):55-61

78-84

**Chapter 6**

**Abstract**

load balance.

**1. Introduction**

big data

**115**

Balancing

Looking at Data Science through

the Lens of Scheduling and Load

*Diórgenes Eugênio da Silveira, Eduardo Souza dos Reis,*

*Cristiano André da Costa, Jorge Luis Victoria Barbosa,*

The growth in data generated by private and public organizations leads to several opportunities to obtain valuable knowledge. In this scenario, data science becomes pertinent to define a structured methodology to extract valuable knowledge from raw data. It encompasses a heterogeneous group of techniques that challenge the implementation of a single platform capable of incorporating all the available resources. Thus, it is necessary to formulate a data science workflow based on different tools to extract knowledge from massive datasets. In this context, highperformance computing (HPC) provides the infrastructure required to optimize the processing time of data science workflows, which become a collection of tasks that must be efficiently scheduled to provide results in acceptable time intervals. While

few studies explore the use of HPC for data science tasks, in the best of our

knowledge, none conducts an in-depth analysis of scheduling and load balancing on such workflows. In this context, this chapter proposes an analysis of scheduling and load balancing from the perspective of data science scenarios. It presents concepts, environments, and tools to summarize the theoretical background required to define, assign, and execute data science workflows. Furthermore, we are also presenting new trends concerning the intersection of data science, scheduling, and

**Keywords:** scheduling, load balance, high-performance computing, data science,

Private corporate networks, as well as the Internet, generate and share data at ever increasing rates. This unconstrained growth can easily lead disorganization and, as a consequence, missed opportunities to analyze and extract knowledge for these data. There is an essential difference between the concepts of data and information. Data cannot express something outside a particular field of expertise.

*Rodrigo Simon Bavaresco, Marcio Miguel Gomes,*

*Rodolfo Stoffel Antunes, Alvaro Machado Júnior,*

*Rodrigo Saad and Rodrigo da Rosa Righi*

#### **Chapter 6**

## Looking at Data Science through the Lens of Scheduling and Load Balancing

*Diórgenes Eugênio da Silveira, Eduardo Souza dos Reis, Rodrigo Simon Bavaresco, Marcio Miguel Gomes, Cristiano André da Costa, Jorge Luis Victoria Barbosa, Rodolfo Stoffel Antunes, Alvaro Machado Júnior, Rodrigo Saad and Rodrigo da Rosa Righi*

#### **Abstract**

The growth in data generated by private and public organizations leads to several opportunities to obtain valuable knowledge. In this scenario, data science becomes pertinent to define a structured methodology to extract valuable knowledge from raw data. It encompasses a heterogeneous group of techniques that challenge the implementation of a single platform capable of incorporating all the available resources. Thus, it is necessary to formulate a data science workflow based on different tools to extract knowledge from massive datasets. In this context, highperformance computing (HPC) provides the infrastructure required to optimize the processing time of data science workflows, which become a collection of tasks that must be efficiently scheduled to provide results in acceptable time intervals. While few studies explore the use of HPC for data science tasks, in the best of our knowledge, none conducts an in-depth analysis of scheduling and load balancing on such workflows. In this context, this chapter proposes an analysis of scheduling and load balancing from the perspective of data science scenarios. It presents concepts, environments, and tools to summarize the theoretical background required to define, assign, and execute data science workflows. Furthermore, we are also presenting new trends concerning the intersection of data science, scheduling, and load balance.

**Keywords:** scheduling, load balance, high-performance computing, data science, big data

#### **1. Introduction**

Private corporate networks, as well as the Internet, generate and share data at ever increasing rates. This unconstrained growth can easily lead disorganization and, as a consequence, missed opportunities to analyze and extract knowledge for these data. There is an essential difference between the concepts of data and information. Data cannot express something outside a particular field of expertise.

dataset must go through a cleaning process that ensures the uniformity of values and the elimination of duplicated data. On one hand, a large dataset with highquality data enables an insightful model. On the other hand, the computational power required to process data is directly proportional to the size of the available dataset. In this scenario, high-performance computing (HPC) provides the infrastructure (clusters, grids, and cloud platforms) required to optimize the processing time of data science workflows. In particular, data science demands are transformed in a collection of tasks, with or without the notion of dependency among them, which must be efficiently scheduled along the computational resources [memory, processors, cores, cluster nodes, graphical processing unit (GPU) cores, grid nodes, and virtual machines, for example] to provide the results in an acceptable time interval. To map such tasks to resources, a scheduling policy takes place where load balancing algorithms are important to provide a better execution equilibrium among the tasks and a fast response time, mainly when considering either dynamic or heterogeneous environments. While some articles explore the use of HPC for data science tasks [4–6], in the best of our knowledge, there are no studies that conduct an in-depth analysis of how the aspects of scheduling and load balancing

*Looking at Data Science through the Lens of Scheduling and Load Balancing*

*DOI: http://dx.doi.org/10.5772/intechopen.92578*

Hence, the present book chapter proposes an analysis of scheduling and load balancing from the perspective of data science scenarios. Furthermore, it presents concepts, environments, and tools for data science to summarize the theoretical background required to understand the definition and execution of data science workflows. Even though its focus lies on presenting concepts, the chapter also illustrates new trends concerning the intersection of data science, scheduling, and

The remainder of this chapter is organized as follows: Section 2 presents an indepth explanation of concepts, workflow, problem classes, and tools used by data science. Section 3 explores scheduling and load balancing as tools to leverage the computational power required by data science applications. Section 4 points to open challenges and trends in the use of HPC applied to data science problems. Finally, Section 5 concludes the chapter with closing remarks and directions for

This section presents the fundamental concepts related to data science. These are

Data science is highly dependent on its application domain and employs complex methods. Nevertheless, it has a very organized pipeline, which varies in the number of steps required to extract knowledge. Current work explores a pipeline that varies between five and seven steps, but in all cases, the process yields similar outputs. This section aims at presenting the most complete process, composed of seven steps, widely used by both companies and researchers. **Figure 2** depicts the flow of information step by step. Moreover, the seven proposed steps can be enu-

key to understand the concept of HPC, more specifically scheduling and load balancing, impact data science processes, as discussed later in the chapter. The remainder of the section discusses the fundamental components of a data science

affect data science workflows.

load balance.

future work.

merated as:

**117**

**2. Fundamental concepts**

**2.1 Data science workflow**

pipeline, as observed in real-world scenarios.

In turn, information enables the coherent transmission of knowledge. Data science aims to close the gap between data and knowledge through the use of computational tools. More specifically, data science is a tool for converting raw data into knowledge [1]. The field of data science leverages many methods originating from computer science and statistics [2]. **Figure 1** illustrates a Venn's diagram that correlates the research areas with major influence in data science.

Although data science receives significant influence from expert knowledge, it is plausible to say that a data scientist knows more about computer science than a statistician and more about statistics than a computer scientist [3]. Besides, it also encompasses the intersection of data analytics and machine learning. Therefore, data science encompasses a heterogeneous group of studies and methodologies such as big data, machine learning, data analytics, and statistics, which challenge the implementation of a single platform capable of incorporating all the available techniques.

There are a variety of widely adopted platforms available for data analysis and knowledge extraction, for example, Tableau,<sup>1</sup> Dataiko,<sup>2</sup> Microsoft Azure Machine Learning Studio,<sup>3</sup> Orange BioLab,<sup>4</sup> each one suitable for a specific step of a data science process. A workflow can be formulated based on the coordinated application of different tools to extract knowledge from massive datasets. In this context, the use of cloud platforms for data science steadily grows because they offer scalability and distributed execution of individual tasks.

In data science, a large dataset allows the generation of a more in-depth model, which provides more robust insights because there are more instances to compose the statistical analysis of data. One of the most relevant aspects regarding a dataset is the quality of available data. Thus, before the use of any statistical method, the

<sup>1</sup> https://www.tableau.com/

<sup>2</sup> https://www.dataiku.com/

<sup>3</sup> https://azure.microsoft.com/en-us/services/machine-learning-studio/

<sup>4</sup> https://orange.biolab.si/

#### *Looking at Data Science through the Lens of Scheduling and Load Balancing DOI: http://dx.doi.org/10.5772/intechopen.92578*

dataset must go through a cleaning process that ensures the uniformity of values and the elimination of duplicated data. On one hand, a large dataset with highquality data enables an insightful model. On the other hand, the computational power required to process data is directly proportional to the size of the available dataset. In this scenario, high-performance computing (HPC) provides the infrastructure (clusters, grids, and cloud platforms) required to optimize the processing time of data science workflows. In particular, data science demands are transformed in a collection of tasks, with or without the notion of dependency among them, which must be efficiently scheduled along the computational resources [memory, processors, cores, cluster nodes, graphical processing unit (GPU) cores, grid nodes, and virtual machines, for example] to provide the results in an acceptable time interval. To map such tasks to resources, a scheduling policy takes place where load balancing algorithms are important to provide a better execution equilibrium among the tasks and a fast response time, mainly when considering either dynamic or heterogeneous environments. While some articles explore the use of HPC for data science tasks [4–6], in the best of our knowledge, there are no studies that conduct an in-depth analysis of how the aspects of scheduling and load balancing affect data science workflows.

Hence, the present book chapter proposes an analysis of scheduling and load balancing from the perspective of data science scenarios. Furthermore, it presents concepts, environments, and tools for data science to summarize the theoretical background required to understand the definition and execution of data science workflows. Even though its focus lies on presenting concepts, the chapter also illustrates new trends concerning the intersection of data science, scheduling, and load balance.

The remainder of this chapter is organized as follows: Section 2 presents an indepth explanation of concepts, workflow, problem classes, and tools used by data science. Section 3 explores scheduling and load balancing as tools to leverage the computational power required by data science applications. Section 4 points to open challenges and trends in the use of HPC applied to data science problems. Finally, Section 5 concludes the chapter with closing remarks and directions for future work.

#### **2. Fundamental concepts**

This section presents the fundamental concepts related to data science. These are key to understand the concept of HPC, more specifically scheduling and load balancing, impact data science processes, as discussed later in the chapter. The remainder of the section discusses the fundamental components of a data science pipeline, as observed in real-world scenarios.

#### **2.1 Data science workflow**

Data science is highly dependent on its application domain and employs complex methods. Nevertheless, it has a very organized pipeline, which varies in the number of steps required to extract knowledge. Current work explores a pipeline that varies between five and seven steps, but in all cases, the process yields similar outputs. This section aims at presenting the most complete process, composed of seven steps, widely used by both companies and researchers. **Figure 2** depicts the flow of information step by step. Moreover, the seven proposed steps can be enumerated as:

In turn, information enables the coherent transmission of knowledge. Data science aims to close the gap between data and knowledge through the use of computational tools. More specifically, data science is a tool for converting raw data into knowledge [1]. The field of data science leverages many methods originating from computer science and statistics [2]. **Figure 1** illustrates a Venn's diagram that correlates

Although data science receives significant influence from expert knowledge, it is plausible to say that a data scientist knows more about computer science than a statistician and more about statistics than a computer scientist [3]. Besides, it also encompasses the intersection of data analytics and machine learning. Therefore, data science encompasses a heterogeneous group of studies and methodologies such as big data, machine learning, data analytics, and statistics, which challenge the implementation of a single platform capable of incorporating all the available

There are a variety of widely adopted platforms available for data analysis and knowledge extraction, for example, Tableau,<sup>1</sup> Dataiko,<sup>2</sup> Microsoft Azure Machine Learning Studio,<sup>3</sup> Orange BioLab,<sup>4</sup> each one suitable for a specific step of a data science process. A workflow can be formulated based on the coordinated application of different tools to extract knowledge from massive datasets. In this context, the use of cloud platforms for data science steadily grows because they offer scal-

In data science, a large dataset allows the generation of a more in-depth model, which provides more robust insights because there are more instances to compose the statistical analysis of data. One of the most relevant aspects regarding a dataset is the quality of available data. Thus, before the use of any statistical method, the

the research areas with major influence in data science.

*Venn's diagram for correlating the influence of other research areas on data science.*

*Scheduling Problems - New Applications and Trends*

ability and distributed execution of individual tasks.

https://azure.microsoft.com/en-us/services/machine-learning-studio/

techniques.

**Figure 1.**

1

2

3

4

**116**

https://www.tableau.com/

https://www.dataiku.com/

https://orange.biolab.si/


Step 1 refers to the process of understanding in which context the data are inserted on, and what is the expected output. This is a high time-consuming process in a project. However, data scientist must have a deep understanding about the application domain to validate the model's structure as well as its outputs. After understanding the scope of the project, on Step 2, exploring the data that correlate with the problem understood in the last step. These data can be hosted at the client or not. If the client does not have useful data available, the data scientist must look for a synthetic or publicly available dataset to extract the knowledge. Furthermore, on Step 3, techniques are employed to clean data because there is a high chance that it is unorganized or unreadable, so it is necessary to preprocess and standardize it. An example of this step is a dataset that has a column with country names, but in some registers, the value of this column is "Brasil" and in others, it is "Brazil," both values symbolize the same information but are encoded in different languages. Regarding Step 4, the data are organized, and it is indispensable to execute a

detailed analysis in order to figure out patterns or insights that would be valuable to the client. In this stage, the data scientist usually uses plotting techniques to make

On Step 5, previously identified insights serve as input. But at this step, it is vital to fully understand the data since, without formal knowledge, it is very hard to fit a model that correctly represents it. At this stage, it is required that the data scientist uses computer science expertise to choose the better approach to plan and validate the model. In Step 6, outputs generated by the model are evaluated in order to analyze how useful they actually are. Usually, this evaluation is conducted by the client and the data scientist together, to examine graphs, numbers, and tables and define if the model generated acceptable results. Finally, on Step 7, the results are validated, and the model is ready to be implemented and deployed in production; thus, it is applied to prediction tasks, having real data as input. The architecture used to implement the model is very important, that is, it is necessary to understand what will be used for the client application since if the client needs a real-time response, the structure will be very different than a nonreal-time

Data science is not exclusively employed in business scenarios, and it can be generalized to a plethora of applications, such as in Obama's campaign for US presidential elections in 2012. In the context of this election, technology was applied to identify who were the voters that should receive more attention and marketing influence. Some analysts highlighted the use of data science as fundamental to Obama's victory. However, data science is not limited to the analysis of scenarios, such as in the above example. Many other challenges can benefit from solutions based on data science methodologies. For instance, some problem classes in data science are pattern detection, anomaly detection, cleaning, alignment, classification, regression, knowledge base construction, and density estimation [7]. These

The patterns existing in a dataset are not always easily identifiable due to the organization of the data. It is the method employed to discover information standards in the dataset. Figuring patterns hidden into data is a relevant task in several scenarios, for example, to join the clients with similar characteristics, such as those

The distribution of a dataset regards the positions of data points among each other in the dataset. Usually, the representation of this distribution employs a Cartesian plane, in which each point is an instance of the dataset. Within this representation, regions with a defined concentration of data points become clusters. Therefore, outliers are the data points that are too far from these clusters. Anomaly detection aims to classify each data into a dataset as an outlier or not. For example, the banks employ this approach in the scenario of fraud detection. In this scenario, transactions of a client become clusters, and a new transaction is con-

the data more readable and figure out information.

*DOI: http://dx.doi.org/10.5772/intechopen.92578*

*Looking at Data Science through the Lens of Scheduling and Load Balancing*

**2.2 Solving problems with data science**

classes of problems are explored next.

with the same taste or opinion.

sidered as unclassified data.

**119**

*2.2.2 Anomaly detection*

*2.2.1 Pattern detection*

scenario.

**Figure 2.** *Flow diagram of data science steps.*

#### *Looking at Data Science through the Lens of Scheduling and Load Balancing DOI: http://dx.doi.org/10.5772/intechopen.92578*

detailed analysis in order to figure out patterns or insights that would be valuable to the client. In this stage, the data scientist usually uses plotting techniques to make the data more readable and figure out information.

On Step 5, previously identified insights serve as input. But at this step, it is vital to fully understand the data since, without formal knowledge, it is very hard to fit a model that correctly represents it. At this stage, it is required that the data scientist uses computer science expertise to choose the better approach to plan and validate the model. In Step 6, outputs generated by the model are evaluated in order to analyze how useful they actually are. Usually, this evaluation is conducted by the client and the data scientist together, to examine graphs, numbers, and tables and define if the model generated acceptable results. Finally, on Step 7, the results are validated, and the model is ready to be implemented and deployed in production; thus, it is applied to prediction tasks, having real data as input. The architecture used to implement the model is very important, that is, it is necessary to understand what will be used for the client application since if the client needs a real-time response, the structure will be very different than a nonreal-time scenario.

#### **2.2 Solving problems with data science**

Data science is not exclusively employed in business scenarios, and it can be generalized to a plethora of applications, such as in Obama's campaign for US presidential elections in 2012. In the context of this election, technology was applied to identify who were the voters that should receive more attention and marketing influence. Some analysts highlighted the use of data science as fundamental to Obama's victory. However, data science is not limited to the analysis of scenarios, such as in the above example. Many other challenges can benefit from solutions based on data science methodologies. For instance, some problem classes in data science are pattern detection, anomaly detection, cleaning, alignment, classification, regression, knowledge base construction, and density estimation [7]. These classes of problems are explored next.

#### *2.2.1 Pattern detection*

1.business understanding;

*Scheduling Problems - New Applications and Trends*

2.data extraction;

3.data preparation;

6. results evaluation; and

Step 1 refers to the process of understanding in which context the data are inserted on, and what is the expected output. This is a high time-consuming process in a project. However, data scientist must have a deep understanding about the application domain to validate the model's structure as well as its outputs. After understanding the scope of the project, on Step 2, exploring the data that correlate with the problem understood in the last step. These data can be hosted at the client or not. If the client does not have useful data available, the data scientist must look for a synthetic or publicly available dataset to extract the knowledge. Furthermore, on Step 3, techniques are employed to clean data because there is a high chance that it is unorganized or unreadable, so it is necessary to preprocess and standardize it. An example of this step is a dataset that has a column with country names, but in some registers, the value of this column is "Brasil" and in others, it is "Brazil," both values symbolize the same information but are encoded in different languages. Regarding Step 4, the data are organized, and it is indispensable to execute a

7.implementation.

4.data exploring;

5.data model;

**Figure 2.**

**118**

*Flow diagram of data science steps.*

The patterns existing in a dataset are not always easily identifiable due to the organization of the data. It is the method employed to discover information standards in the dataset. Figuring patterns hidden into data is a relevant task in several scenarios, for example, to join the clients with similar characteristics, such as those with the same taste or opinion.

#### *2.2.2 Anomaly detection*

The distribution of a dataset regards the positions of data points among each other in the dataset. Usually, the representation of this distribution employs a Cartesian plane, in which each point is an instance of the dataset. Within this representation, regions with a defined concentration of data points become clusters. Therefore, outliers are the data points that are too far from these clusters. Anomaly detection aims to classify each data into a dataset as an outlier or not. For example, the banks employ this approach in the scenario of fraud detection. In this scenario, transactions of a client become clusters, and a new transaction is considered as unclassified data.

#### *2.2.3 Cleaning*

Dataset contents can present a broad variety of formats, for example, dates, numeric values, and text data. In many cases, values may also be differently formatted across dataset entries, even for the same field, due to human error or lack of standardization. This situation incurs in errors in the dataset, resulting in possible information loss when processing it. The best solution to this problem is to employ methods that manage the dataset contents and standardize the data. For example, in a dataset containing clients birthdays, it is possible that a user fills the information with an invalid date. This case results in information loss because the analysis cannot extract useful information related to the user's birthday.

#### *2.2.4 Alignment*

An organized and standardized dataset is fundamental for the generation of trustworthy outputs from data science processes. The process of data alignment is an essential step in dataset standardization. It involves updating the dataset to avoid the use of multiple values to represent the same information. For example, in a dataset containing a gender field, users may use both "M" and "Male" values to represent the same gender. In this context, it is fundamental to unify both entries in one because the information in both is the same.

standardize data. There are a broad group of knowledge bases on the Internet, for

Store data MySql, Mongo DB, Cassandra, PLSql, Redis, HBase

Data model Python, R, Julia, Clojure, SPSS, SAS, Apache Manhout

Development Apache Hadoop, Java, Scala, C, Apache Spark, Haskell

Results evaluation Tableau, Cognos, ggplot, QlikView, Power BI

Density estimation focuses on identifying the clusters that group sets of data points that represent the entries in a dataset. This process is a fundamental step to generate the clusters required by anomaly detection methodologies, as described above. Clustering is another suitable technique to identify groups of entries that

It is difficult to find a tool that fits all data science processes because, as previously mentioned, there are multiple steps with a variety of methods available for use. Hence, there are specific tools for each step, which will provide the most appropriate result. **Table 1** summarizes the most commonly cited tools for each one of the data science workflow steps. The table has a row that is not considered a step of the process, but it is fundamental to results that are Storage Data, which refer to all technologies used for persisting the data in an environment. In the section of data model, some programming languages are cited, but it is hard for a data scientist to employ a language without libraries. For example, using Python is very usual to use

**3. Exploring scheduling and load balancing on data science demands**

The scheduling problem, in a general view, comprises both a set of resources and a set of consumers [8]. Its focus is to find an appropriate policy to manage the use of resources by several consumers in order to optimize a particular performance metric chosen as a parameter. The evaluation of a scheduling proposal commonly considers two features: (1) performance and (2) efficiency [9]. More specifically, the evaluation comprises the obtained scheduling as well as the time spent to execute the scheduler policies. For example, if the parameter to analyze the

example, Kaggle,<sup>5</sup> UCI Repository,<sup>6</sup> Quandl,<sup>7</sup> and MSCOCO.8

may contain related knowledge within a dataset.

**Stage Tools**

*DOI: http://dx.doi.org/10.5772/intechopen.92578*

Data preparation Apache Hive Data exploring Knime, Elasticsearch

*Looking at Data Science through the Lens of Scheduling and Load Balancing*

libraries such as pandas, sci-kit learn, numpy, and ggplot.

*2.2.8 Density estimation*

*Tools used per step of data science.*

**Table 1.**

**2.3 Data science tools**

5

6

7

8

**121**

https://www.kaggle.com

https://www.quandl.com/

http://cocodataset.org/home

https://archive.ics.uci.edu/ml/index.php

#### *2.2.5 Classification*

Classification regards assigning specific labels to entries in a dataset. A label is any information that presents a limited scope of possibilities, for example, a dozen options present in a specific dataset field. Examples of labels include sentiments, states, and the scale of integer numbers. This dataset field can then be used to group multiple dataset entries according to the unique values that the label may take. For example, in a dataset about client's purchases, each product may be associated with a set of keywords. These keywords can then be used to classify the types of purchases a particular client makes, enabling targeted recommendations for other products.

#### *2.2.6 Regression*

Datasets do not always contain fields with labels that enable the classification of data. Nevertheless, in some problems, it is necessary to label values without a restricted group of options, for example, using a field that contains real numbers. This scenario requires a regression approach to estimate which classes an entry should receive, without considering the limited options available in labels. For example, in a dataset with prices and sizes of houses in New York, it is possible to use regression to estimate the price of a new house according to its size. Although the regression problem has an output similar to classification, its output does not have a limited set of values, as occurs in labeling.

#### *2.2.7 Knowledge base construction*

Datasets are essential for data science, and the problem of knowledge base construction refers to the process of compiling information to create them. Frequently, this process requires the use of cleaning and alignment methods to

*Looking at Data Science through the Lens of Scheduling and Load Balancing DOI: http://dx.doi.org/10.5772/intechopen.92578*


#### **Table 1.**

*2.2.3 Cleaning*

birthday.

*2.2.4 Alignment*

*2.2.5 Classification*

products.

**120**

*2.2.6 Regression*

Dataset contents can present a broad variety of formats, for example, dates, numeric values, and text data. In many cases, values may also be differently formatted across dataset entries, even for the same field, due to human error or lack of standardization. This situation incurs in errors in the dataset, resulting in possible information loss when processing it. The best solution to this problem is to employ methods that manage the dataset contents and standardize the data. For example, in a dataset containing clients birthdays, it is possible that a user fills the information with an invalid date. This case results in information loss because the analysis cannot extract useful information related to the user's

An organized and standardized dataset is fundamental for the generation of trustworthy outputs from data science processes. The process of data alignment is an essential step in dataset standardization. It involves updating the dataset to avoid the use of multiple values to represent the same information. For example, in a dataset containing a gender field, users may use both "M" and "Male" values to represent the same gender. In this context, it is fundamental to unify both entries in

Classification regards assigning specific labels to entries in a dataset. A label is any information that presents a limited scope of possibilities, for example, a dozen options present in a specific dataset field. Examples of labels include sentiments, states, and the scale of integer numbers. This dataset field can then be used to group multiple dataset entries according to the unique values that the label may take. For example, in a dataset about client's purchases, each product may be associated with a set of keywords. These keywords can then be used to classify the types of purchases a particular client makes, enabling targeted recommendations for other

Datasets do not always contain fields with labels that enable the classification of

data. Nevertheless, in some problems, it is necessary to label values without a restricted group of options, for example, using a field that contains real numbers. This scenario requires a regression approach to estimate which classes an entry should receive, without considering the limited options available in labels. For example, in a dataset with prices and sizes of houses in New York, it is possible to use regression to estimate the price of a new house according to its size. Although the regression problem has an output similar to classification, its output does not

Datasets are essential for data science, and the problem of knowledge base construction refers to the process of compiling information to create them. Frequently, this process requires the use of cleaning and alignment methods to

one because the information in both is the same.

*Scheduling Problems - New Applications and Trends*

have a limited set of values, as occurs in labeling.

*2.2.7 Knowledge base construction*

*Tools used per step of data science.*

standardize data. There are a broad group of knowledge bases on the Internet, for example, Kaggle,<sup>5</sup> UCI Repository,<sup>6</sup> Quandl,<sup>7</sup> and MSCOCO.8

#### *2.2.8 Density estimation*

Density estimation focuses on identifying the clusters that group sets of data points that represent the entries in a dataset. This process is a fundamental step to generate the clusters required by anomaly detection methodologies, as described above. Clustering is another suitable technique to identify groups of entries that may contain related knowledge within a dataset.

#### **2.3 Data science tools**

It is difficult to find a tool that fits all data science processes because, as previously mentioned, there are multiple steps with a variety of methods available for use. Hence, there are specific tools for each step, which will provide the most appropriate result. **Table 1** summarizes the most commonly cited tools for each one of the data science workflow steps. The table has a row that is not considered a step of the process, but it is fundamental to results that are Storage Data, which refer to all technologies used for persisting the data in an environment. In the section of data model, some programming languages are cited, but it is hard for a data scientist to employ a language without libraries. For example, using Python is very usual to use libraries such as pandas, sci-kit learn, numpy, and ggplot.

#### **3. Exploring scheduling and load balancing on data science demands**

The scheduling problem, in a general view, comprises both a set of resources and a set of consumers [8]. Its focus is to find an appropriate policy to manage the use of resources by several consumers in order to optimize a particular performance metric chosen as a parameter. The evaluation of a scheduling proposal commonly considers two features: (1) performance and (2) efficiency [9]. More specifically, the evaluation comprises the obtained scheduling as well as the time spent to execute the scheduler policies. For example, if the parameter to analyze the

<sup>5</sup> https://www.kaggle.com

<sup>6</sup> https://archive.ics.uci.edu/ml/index.php

<sup>7</sup> https://www.quandl.com/

<sup>8</sup> http://cocodataset.org/home

achieved scheduling is the application execution time, the lower this value, the better the scheduler performance. In turn, efficiency refers to the policies adopted by the scheduler and can be evaluated using computational complexity functions [10].

architecture are unpredictable, and the runtime environment takes the decision of the consumer-resource mapping. The responsibility of global scheduling can be assigned either to a single processor (physically nondistributed) or practiced by a set of processors (physically distributed). Within the realm of this last classification, the taxonomy may also distinguish between those mechanisms that involve cooperation between the distributed components (cooperative) and those in which the individual processors make decisions independent of the actions of the other processors (noncooperative). In the cooperative case, each processor has the responsibility to carry out its portion of the scheduling, but all processors are working

*Looking at Data Science through the Lens of Scheduling and Load Balancing*

Data science comprises the manipulation of a large set of data to extract knowledge [13, 14]. To accomplish this, we have input that is passed through processing engines to generate valuable outputs. In particular, this second step is usually processed as sequential programs that implement both artificial intelligence and statistical-based computational methods. We can take profit from the several processing cores that exist in today's processors to map this sequential demand to be executed in a multithreading program. To accomplish this, Pthreads library and OpenMP are the most common approaches to write multithread parallel programs, where each thread can be mapped to a different core, so exploiting the full power of

In addition to multiprocessor architectures, it is possible to transform a sequential code in message passing interface (MPI)-based parallel one, so targeting distributed architectures such as clusters and grids [15]. In this way, contrary to the prior alternative that encompasses the use of standard multiprocessor systems, the efficient use of MPI needs a parallel machine that generally has higher financial costs. Also, a distributed program is more error prone, since problems in the nodes or the network can put all application down. Repairing these future problems sometimes is not trivial, requiring graphical tools to observe processes' interactions. Finally, in addition to multicore and multicomputer architectures, we also have the use of GPU, where graphic cards present a set of nongeneral purpose processors to execute vector calculus much faster than the conventional general-purpose processors [14]. The challenge consists in transforming a sequential code in a parallel one in a transparent way at the user viewpoint, in such a way the data science demand can run faster in parallel deployments. Moreover, the combination of these three aforesaid parallel techniques is also a challenge since optimizations commonly vary

Cloud computing environments today also represent a viable solution to run data science demands [16]. Providers such as Amazon EC2, Microsoft Azure, and

multicomputer, and GPU parallelism. In particular, different from standard distributed systems, cloud computing presents the resource elasticity feature where an initial deployment can be on-the-fly changed following the input demand. Thus, it is possible to scale resources in or out (through the addition or removal of containers/virtual machines) or to scale down or up (by performing resource resizing in virtual units) in a transparent way to the user. Logically, the own data science application must be written in such a way to take profit of newly available resources

The CPU load is the most common metric to drive resource elasticity data science demands since most of them execute CPU-bound artificial intelligencebased algorithms. Any network data manipulation through the TCP protocol uses CPU cycles since this is a software protocol executed in the kernel of the operating

Load balancing and resource scheduling are sometimes seen as having the same functionality. However, there is a slight difference: one of the members of resource

system and executes software routines to provide data transfer reliability.

Google Cloud have HPC-driven architectures to exploit multiprocessor,

toward a common system-wide goal.

*DOI: http://dx.doi.org/10.5772/intechopen.92578*

a multiprocessor HPC architecture.

from one application to another.

as the current set of working resources.

**123**

The general scheduling problem is the unification of two terms in everyday use in the literature. There is often an implicit distinction between the terms scheduling and allocation. Nevertheless, it can be argued that these are merely alternative formulations of the same problem, with allocation posed in terms of resource allocation (from the resources point of view), and scheduling viewed from the consumers' point of view. In this sense, allocation and scheduling are merely two terms describing the same general mechanism but described from different viewpoints. One important issue when treating scheduling is the grain of the consumers [11]. For example, we can have a graph of tasks, a set of processes, and jobs that need resources to execute. In this context, scheduling schemes for multiprogrammed parallel systems can be viewed in two levels. In the first level, processors are allocated to a specific job. In the second level, processes from a job are scheduled using this pool of processors.

We define static scheduling considering the scheduling grain as a task [8]. If data such as information about the processors, the execution time of the tasks, the size of the data, the communication pattern, and the dependency relation among the tasks are known in advance, we can affirm that we have a static or deterministic scheduling model. In this approach, each executable image in the system has a static assignment to a particular set of processors. Scheduling decisions are made deterministically or probabilistically at compile time and remain constant during runtime. The static approach is simple to be implemented. However, it is pointed out that it has two significant disadvantages [11]. First, the workload distribution and the behavior of many applications cannot be predicted before program execution. Second, static scheduling assumes that the characteristics of the computing resources and communication network are known in advance and remain constant. Such an assumption may not be applied to grid environments, for instance.

In the general form of a static task scheduling problem, an application is represented by a directed acyclic graph (DAG) in which nodes represent application tasks, and edges represent intertask data dependencies [12].

Each node label shows computation cost (expected computation time) of the task, and each edge label shows intertask communication cost (expected communication time) between tasks. The objective function of this problem is to map tasks onto processors and order their executions, so that task-precedence requirements are satisfied, and the minimum overall completion time is obtained.

In the case that all information regarding the state of the system as well as the resource needs of a process is known, an optimal assignment can be proposed [11]. Even with all information required for the scheduling, the static method is often computationally expensive getting to the point of being infeasible. Thus, this fact results in suboptimal solutions. We have two general categories within the realm of suboptimal solutions for the scheduling problem: (1) approximate and (2) heuristic. Approximate scheduling uses the same methods used in the optimal one, but instead exploring all possible ideal solutions, it stops when a good one is achieved. Heuristic scheduling uses standard parameters and ideas that affect the behavior of the parallel system. For example, we can group processes with higher communication rate to the same local network or sort works and processors in lists following some predefined criteria in order to perform an efficient mapping among them (list scheduling).

Dynamic scheduling works with the idea that a little (or none) a priori knowledge about the needs and the behavior of the application is available [9]. It is also unknown in what environment the process will execute during its lifetime. The arrival of new tasks, the relation among them, and data about the target

#### *Looking at Data Science through the Lens of Scheduling and Load Balancing DOI: http://dx.doi.org/10.5772/intechopen.92578*

architecture are unpredictable, and the runtime environment takes the decision of the consumer-resource mapping. The responsibility of global scheduling can be assigned either to a single processor (physically nondistributed) or practiced by a set of processors (physically distributed). Within the realm of this last classification, the taxonomy may also distinguish between those mechanisms that involve cooperation between the distributed components (cooperative) and those in which the individual processors make decisions independent of the actions of the other processors (noncooperative). In the cooperative case, each processor has the responsibility to carry out its portion of the scheduling, but all processors are working toward a common system-wide goal.

Data science comprises the manipulation of a large set of data to extract knowledge [13, 14]. To accomplish this, we have input that is passed through processing engines to generate valuable outputs. In particular, this second step is usually processed as sequential programs that implement both artificial intelligence and statistical-based computational methods. We can take profit from the several processing cores that exist in today's processors to map this sequential demand to be executed in a multithreading program. To accomplish this, Pthreads library and OpenMP are the most common approaches to write multithread parallel programs, where each thread can be mapped to a different core, so exploiting the full power of a multiprocessor HPC architecture.

In addition to multiprocessor architectures, it is possible to transform a sequential code in message passing interface (MPI)-based parallel one, so targeting distributed architectures such as clusters and grids [15]. In this way, contrary to the prior alternative that encompasses the use of standard multiprocessor systems, the efficient use of MPI needs a parallel machine that generally has higher financial costs. Also, a distributed program is more error prone, since problems in the nodes or the network can put all application down. Repairing these future problems sometimes is not trivial, requiring graphical tools to observe processes' interactions. Finally, in addition to multicore and multicomputer architectures, we also have the use of GPU, where graphic cards present a set of nongeneral purpose processors to execute vector calculus much faster than the conventional general-purpose processors [14]. The challenge consists in transforming a sequential code in a parallel one in a transparent way at the user viewpoint, in such a way the data science demand can run faster in parallel deployments. Moreover, the combination of these three aforesaid parallel techniques is also a challenge since optimizations commonly vary from one application to another.

Cloud computing environments today also represent a viable solution to run data science demands [16]. Providers such as Amazon EC2, Microsoft Azure, and Google Cloud have HPC-driven architectures to exploit multiprocessor, multicomputer, and GPU parallelism. In particular, different from standard distributed systems, cloud computing presents the resource elasticity feature where an initial deployment can be on-the-fly changed following the input demand. Thus, it is possible to scale resources in or out (through the addition or removal of containers/virtual machines) or to scale down or up (by performing resource resizing in virtual units) in a transparent way to the user. Logically, the own data science application must be written in such a way to take profit of newly available resources as the current set of working resources.

The CPU load is the most common metric to drive resource elasticity data science demands since most of them execute CPU-bound artificial intelligencebased algorithms. Any network data manipulation through the TCP protocol uses CPU cycles since this is a software protocol executed in the kernel of the operating system and executes software routines to provide data transfer reliability.

Load balancing and resource scheduling are sometimes seen as having the same functionality. However, there is a slight difference: one of the members of resource

achieved scheduling is the application execution time, the lower this value, the better the scheduler performance. In turn, efficiency refers to the policies adopted by the scheduler and can be evaluated using computational complexity functions [10].

The general scheduling problem is the unification of two terms in everyday use in the literature. There is often an implicit distinction between the terms scheduling and allocation. Nevertheless, it can be argued that these are merely alternative formulations of the same problem, with allocation posed in terms of resource allocation (from the resources point of view), and scheduling viewed from the consumers' point of view. In this sense, allocation and scheduling are merely two terms describing the same general mechanism but described from different viewpoints. One important issue when treating scheduling is the grain of the consumers [11]. For example, we can have a graph of tasks, a set of processes, and jobs that

need resources to execute. In this context, scheduling schemes for

are scheduled using this pool of processors.

*Scheduling Problems - New Applications and Trends*

(list scheduling).

**122**

multiprogrammed parallel systems can be viewed in two levels. In the first level, processors are allocated to a specific job. In the second level, processes from a job

Such an assumption may not be applied to grid environments, for instance. In the general form of a static task scheduling problem, an application is represented by a directed acyclic graph (DAG) in which nodes represent applica-

Each node label shows computation cost (expected computation time) of the task, and each edge label shows intertask communication cost (expected communication time) between tasks. The objective function of this problem is to map tasks onto processors and order their executions, so that task-precedence requirements

In the case that all information regarding the state of the system as well as the resource needs of a process is known, an optimal assignment can be proposed [11]. Even with all information required for the scheduling, the static method is often computationally expensive getting to the point of being infeasible. Thus, this fact results in suboptimal solutions. We have two general categories within the realm of suboptimal solutions for the scheduling problem: (1) approximate and (2) heuristic. Approximate scheduling uses the same methods used in the optimal one, but instead exploring all possible ideal solutions, it stops when a good one is achieved. Heuristic scheduling uses standard parameters and ideas that affect the behavior of the parallel system. For example, we can group processes with higher communication rate to the same local network or sort works and processors in lists following some predefined criteria in order to perform an efficient mapping among them

Dynamic scheduling works with the idea that a little (or none) a priori knowledge about the needs and the behavior of the application is available [9]. It is also unknown in what environment the process will execute during its lifetime. The arrival of new tasks, the relation among them, and data about the target

tion tasks, and edges represent intertask data dependencies [12].

are satisfied, and the minimum overall completion time is obtained.

We define static scheduling considering the scheduling grain as a task [8]. If data such as information about the processors, the execution time of the tasks, the size of the data, the communication pattern, and the dependency relation among the tasks are known in advance, we can affirm that we have a static or deterministic scheduling model. In this approach, each executable image in the system has a static assignment to a particular set of processors. Scheduling decisions are made deterministically or probabilistically at compile time and remain constant during runtime. The static approach is simple to be implemented. However, it is pointed out that it has two significant disadvantages [11]. First, the workload distribution and the behavior of many applications cannot be predicted before program execution. Second, static scheduling assumes that the characteristics of the computing resources and communication network are known in advance and remain constant. scheduling is the scheduling, and this policy can employ or not load balancing algorithms [14]. The basic idea of load balancing is to attempt to balance the load on all processors in such a way to allow all processes on all nodes to proceed at approximately with the same rate. The most significant reason to launch the load balancing is the fact that exists an amount of processing power that is not used efficiently, mainly in dynamic and heterogeneous environments, including grids. In this context, schedulers' policies can use load balancing mechanisms for several purposes, such as: (1) to choose the amount of work to be sent to a process; (2) to move work from an overloaded processor to another that presents a light load; (3) to choose a place (node) to launch a new process from a parallel application; and (4) to decide about process migration. Load balancing is especially essential for some parallel applications that present synchronization points, in which the processes must execute together with the next step.

• Automatic transformation of a sequential data science demand to a parallel one—today data science executes locally to query databases and to build knowledge graphs. Sometimes these tasks are time consuming, then it is pertinent to transform a sequential demand in a parallel one to execute faster

• Use of GPU cards as an accelerator for data science algorithms—write of data science demands that combine R and Python together with OpenCL or CUDA programming languages, so combining CPU and GPU codes with running fast

• Combination of multimetric load balancing engine to handle data science efficiently—data science typically encompasses excellent access to IO (including main memory and hard disk) and a high volume of CPU cycles to process CPU-bound algorithms. In this way, the idea is to execute data science demands and learn their behavior, so proposing an adaptable load balancing

• Task migration heuristics—when developing long-running data science parallel codes, it is essential to develop task migration alternatives to reschedule

• Cloud elasticity to address data science demand—cloud elasticity comes to adapt the number of the resource following the current demand. Thus, we propose a combination of vertical and horizontal elasticity, together with reactive and proactive approaches to detect abnormal situations. We can use both consolidation and inclusion of resources, aiming to always accommodate the most appropriate number of resources for a particular and momentaneous

• Definition of a standard API to deal with data science—frequently enterprises present several departments, each one with its data science demands. In this way, we envisage an opportunity on developing a standard framework (with a standard API too) to support the data science demands of the whole enterprise. The idea is to provide a dashboard with a collection of data science functions,

• Smart correlation of events—enterprises regularly have timed data in several databases. We present an opportunity, at each time a problem is found, to take this particular timestamp and compare in the data sources looking for eventual data correlations. Thus, we can perceive relations such as: (1) if this happens, these other things will also happen and (2) this event happened because a set of

• Benchmark to evaluate a mapping of data science tasks to HPC resources—how we know if particular scheduling outperforms another one for executing a particular data science demand? We see as an opportunity for the exploration of benchmarks to evaluate scheduling and load balancing techniques that manipulate data science tasks. Thus, such benchmarks must define what they expect as input and provide a set of metrics as output. Yet, the output can be a single value, a collection of values (as a data vector), or a collection of elements of a data structure (e.g., timestamp and data are useful to develop user profiles

also expressing the expected input and the output for each one.

demands from one resource to another. This is particularly pertinent on dynamic

on multicore, multinode, and GPU architectures.

*DOI: http://dx.doi.org/10.5772/intechopen.92578*

*Looking at Data Science through the Lens of Scheduling and Load Balancing*

and in parallel to address a particular data science demand.

metrics that take into account different parameters as input.

environments, either at the application or infrastructure level.

data science demand.

prior events happened beforehand.

and tracking of assets).

**125**

The most fundamental topic in load balancing consists of determining the measure of the load [13, 15]. There are many different possible measures of load including: (1) number of tasks in a queue; (2) CPU load average; (3) CPU utilization at specific moment; (4) I/O utilization; (5) amount of free CPU; (6) amount of free memory; (7) amount of communication among the processes; and so on. Besides this, we can have any combinations of the above indicators. Considering the scope of processes from the operating system, such measures will influence in deciding about when to trigger the load balancing, which processes will be involved, and where are the destination places in which these processes will execute. Especially on the last topic, other factors to consider when selecting where to put a process include the nearness to resources, some processor and operating system capabilities, and specialized hardware/software features. We must first determine when to balance the load to turn the mechanism useful. Doing so is composed of two phases: (1) detecting that a load unbalancing exists and (2) determining if the cost of load balancing exceeds its possible benefits.

The use of load balancing in data science demands can vary depending on the structure of the parallel applications: Master-Slave, Bag of Tasks, Divide-and-Conquer, Pipeline, or Bulk-Synchronous Parallel [15, 16]. In the first two, we usually have a centralized environment where it is easy to know data about the whole set of resources, to dispatching tasks to them following their load and theoretical capacity. A traditional example of a combination of these parallel applications is the MapReduce framework. In the divide-and-conquer applications, we have a recursive nature to execute the parallel application where new levels of child nodes are created with the upper one cannot execute the tasks in an acceptable time interval. The challenge consists of dividing the tasks rightly following the capacity of the resources. Pipeline-based applications, in their turn, have a set of stages where each incoming task must cross. In order to maintain the cadence between the stages, they must execute in the same time interval, so an outcoming task from the stage *n* serves as the direct input for the stage *n* + 1. However, the fact of guaranteeing this capacity is not a trivial procedure because of the stages commonly present different complexities in terms of execution algorithms. Finally, bulk-synchronous applications are composed by supersteps, each one with local processing, and arbitrary communication and barrier phases. Load balancing is vital to guarantee that the slowest process does not compromise the performance of the entire application.

#### **4. Open opportunities and trends**

This section aims at compiling the previous two sections, so detailing open opportunities and trends when joining resource scheduling and load balancing and the area of data science. In this way, we compile these aspects as follows:

*Looking at Data Science through the Lens of Scheduling and Load Balancing DOI: http://dx.doi.org/10.5772/intechopen.92578*


scheduling is the scheduling, and this policy can employ or not load balancing algorithms [14]. The basic idea of load balancing is to attempt to balance the load on

The most fundamental topic in load balancing consists of determining the mea-

The use of load balancing in data science demands can vary depending on the structure of the parallel applications: Master-Slave, Bag of Tasks, Divide-and-Conquer, Pipeline, or Bulk-Synchronous Parallel [15, 16]. In the first two, we usually have a centralized environment where it is easy to know data about the whole set of resources, to dispatching tasks to them following their load and theoretical capacity.

A traditional example of a combination of these parallel applications is the MapReduce framework. In the divide-and-conquer applications, we have a recursive nature to execute the parallel application where new levels of child nodes are created with the upper one cannot execute the tasks in an acceptable time interval. The challenge consists of dividing the tasks rightly following the capacity of the resources. Pipeline-based applications, in their turn, have a set of stages where each incoming task must cross. In order to maintain the cadence between the stages, they must execute in the same time interval, so an outcoming task from the stage *n* serves as the direct input for the stage *n* + 1. However, the fact of guaranteeing this capacity is not a trivial procedure because of the stages commonly present different complexities in terms of execution algorithms. Finally, bulk-synchronous applications are composed by supersteps, each one with local processing, and arbitrary communication and barrier phases. Load balancing is vital to guarantee that the slowest process does not compromise the performance of the entire application.

This section aims at compiling the previous two sections, so detailing open opportunities and trends when joining resource scheduling and load balancing and

the area of data science. In this way, we compile these aspects as follows:

sure of the load [13, 15]. There are many different possible measures of load including: (1) number of tasks in a queue; (2) CPU load average; (3) CPU utilization at specific moment; (4) I/O utilization; (5) amount of free CPU; (6) amount of free memory; (7) amount of communication among the processes; and so on. Besides this, we can have any combinations of the above indicators. Considering the scope of processes from the operating system, such measures will influence in deciding about when to trigger the load balancing, which processes will be involved, and where are the destination places in which these processes will execute. Especially on the last topic, other factors to consider when selecting where to put a process include the nearness to resources, some processor and operating system capabilities, and specialized hardware/software features. We must first determine when to balance the load to turn the mechanism useful. Doing so is composed of two phases: (1) detecting that a load unbalancing exists and (2) determining if the cost of load

all processors in such a way to allow all processes on all nodes to proceed at approximately with the same rate. The most significant reason to launch the load balancing is the fact that exists an amount of processing power that is not used efficiently, mainly in dynamic and heterogeneous environments, including grids. In this context, schedulers' policies can use load balancing mechanisms for several purposes, such as: (1) to choose the amount of work to be sent to a process; (2) to move work from an overloaded processor to another that presents a light load; (3) to choose a place (node) to launch a new process from a parallel application; and (4) to decide about process migration. Load balancing is especially essential for some parallel applications that present synchronization points, in which the pro-

cesses must execute together with the next step.

*Scheduling Problems - New Applications and Trends*

balancing exceeds its possible benefits.

**4. Open opportunities and trends**

**124**


#### **5. Conclusion**

The continuous generation of data by different industry segments presents a valuable opportunity for analysis and knowledge extraction through data science methods. There is a high interest in studies that explore the application of data science to a variety of scenarios, each one with distinct characteristics that reflect on the composition of available datasets. Furthermore, there is not a single data science methodology that is applied to all possible data science problems. Consequently, the most common approach to data science problems is to define a sequence of methods that depend on the characteristics of the dataset and the intended results.

The constant growth in dataset sizes and the complexity of specific data science methods also impose a considerable challenge to provide the computational power required to process data and extract meaningful knowledge. In this context, cloud, fog, and grid computing architectures present themselves as ideal solutions to apply data science processes to massively sized datasets.

The distributed nature of such environments raises a series of new challenges, some of which widely studied in the literature. Nevertheless, the unique characteristics of data science workloads bring new aspects to these challenges, which require renewed attention from the scientific community.

**Author details**

**127**

Diórgenes Eugênio da Silveira1

\*

Marcio Miguel Gomes<sup>1</sup>

Rodrigo da Rosa Righi<sup>1</sup>

Rodolfo Stoffel Antunes<sup>1</sup>

, Eduardo Souza dos Reis1

© 2020 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium,

, Cristiano André da Costa<sup>1</sup>

1 Universidade do Vale do Rio dos Sinos, São Leopoldo, RS, Brazil

*Looking at Data Science through the Lens of Scheduling and Load Balancing*

*DOI: http://dx.doi.org/10.5772/intechopen.92578*

2 DELL Computadores do Brasil, Eldorado do Sul, RS, Brazil

\*Address all correspondence to: rrrighi@unisinos.br

provided the original work is properly cited.

, Alvaro Machado Júnior<sup>2</sup>

, Rodrigo Simon Bavaresco<sup>1</sup>

, Jorge Luis Victoria Barbosa<sup>1</sup>

, Rodrigo Saad<sup>2</sup> and

,

,

This chapter focused on the specific challenge of scheduling and load balancing in the context of computational environments applied to data science. We presented an overview of data science processes, in addition to how scheduling and load balancing methodologies impact these processes and what aspects to consider when using distributed environments applied to data science. In particular, the challenge of enabling the automatic transformation of sequential data science demands into parallel ones is of particular interest because it abstracts part of the complexity involved in parallelizing data science tasks. As a result, such an automatic transformation promotes wider adoption of distributed environments as standard tools for large-scale data science processes.

Another notable challenge is to develop cloud elasticity techniques tailored to data science tasks. Such techniques must consider the specific requirements of data science processes to guarantee the proper reservation of resources and migration of tasks in order to guarantee a high throughput for such scenarios. These and the other investigated challenges represent prime research opportunities to increase the performance of data science processes.

*Looking at Data Science through the Lens of Scheduling and Load Balancing DOI: http://dx.doi.org/10.5772/intechopen.92578*

#### **Author details**

• Simulation environment to execute data science demands on distributed

and load balancing algorithms for data science.

*Scheduling Problems - New Applications and Trends*

science demands.

**5. Conclusion**

resources, but doing all of this a local program—simulation environments, like Simgrid or GridSim, are useful to use a sequential program to test and simulate complex parallel demands on a set of virtual resources. Thus, we can save time on testing different parameters and algorithms when developing scheduling

• Definition of metrics to evaluate the scheduling and/or load balancing of data science tasks—CPU load, memory footprint, disk space, network throughput, and cache hit rate are examples of metrics that are commonly employed on distributed systems. Data science is a new area of knowledge, where we encourage the definition of new metrics to compare the execution of data

The continuous generation of data by different industry segments presents a valuable opportunity for analysis and knowledge extraction through data science methods. There is a high interest in studies that explore the application of data science to a variety of scenarios, each one with distinct characteristics that reflect on the composition of available datasets. Furthermore, there is not a single data science methodology that is applied to all possible data science problems. Consequently, the most common approach to data science problems is to define a sequence of methods

The constant growth in dataset sizes and the complexity of specific data science methods also impose a considerable challenge to provide the computational power required to process data and extract meaningful knowledge. In this context, cloud, fog, and grid computing architectures present themselves as ideal solutions to apply

The distributed nature of such environments raises a series of new challenges, some of which widely studied in the literature. Nevertheless, the unique characteristics of data science workloads bring new aspects to these challenges, which require

This chapter focused on the specific challenge of scheduling and load balancing

presented an overview of data science processes, in addition to how scheduling and load balancing methodologies impact these processes and what aspects to consider when using distributed environments applied to data science. In particular, the challenge of enabling the automatic transformation of sequential data science demands into parallel ones is of particular interest because it abstracts part of the complexity involved in parallelizing data science tasks. As a result, such an automatic transformation promotes wider adoption of distributed environments as

Another notable challenge is to develop cloud elasticity techniques tailored to data science tasks. Such techniques must consider the specific requirements of data science processes to guarantee the proper reservation of resources and migration of tasks in order to guarantee a high throughput for such scenarios. These and the other investigated challenges represent prime research opportunities to increase the

in the context of computational environments applied to data science. We

that depend on the characteristics of the dataset and the intended results.

data science processes to massively sized datasets.

renewed attention from the scientific community.

standard tools for large-scale data science processes.

performance of data science processes.

**126**

Diórgenes Eugênio da Silveira1 , Eduardo Souza dos Reis1 , Rodrigo Simon Bavaresco<sup>1</sup> , Marcio Miguel Gomes<sup>1</sup> , Cristiano André da Costa<sup>1</sup> , Jorge Luis Victoria Barbosa<sup>1</sup> , Rodolfo Stoffel Antunes<sup>1</sup> , Alvaro Machado Júnior<sup>2</sup> , Rodrigo Saad<sup>2</sup> and Rodrigo da Rosa Righi<sup>1</sup> \*

1 Universidade do Vale do Rio dos Sinos, São Leopoldo, RS, Brazil

2 DELL Computadores do Brasil, Eldorado do Sul, RS, Brazil

\*Address all correspondence to: rrrighi@unisinos.br

© 2020 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

### **References**

[1] Amirian P, van Loggerenberg F, Lang T. Data Science and Analytics. Cham: Springer International Publishing; 2017. pp. 15-37

[2] Gibert K, Horsburgh JS, Athanasiadis IN, Holmes G. Environmental data science. Environmental Modelling and Software. 2018;**106**:4-12. Special Issue on Environmental Data Science. Applications to Air quality and Water cycle

[3] Grus J. Data Science from Scratch: First Principles with Python. 1st ed. O'Reilly Media, Inc.; 2015. Available from: https://www.amazon.com/ Data-Science-Scratch-Principles-Python/dp/149190142X

[4] Ahmad A, Paul A, Din S, Rathore MM, Choi GS, Jeon G. Multilevel data processing using parallel algorithms for analyzing big data in high-performance computing. International Journal of Parallel Programming. 2018;**46**(3):508-527

[5] Bomatpalli T, Wagh R, Balaji S. High performance computing and big data analytics paradigms and challenges. International Journal of Computer Applications. 2015;**116**(04):28-33

[6] Singh D, Reddy CK. A survey on platforms for big data analytics. Journal of Big Data. 2014;**2**(1):8

[7] Dorr BJ, Greenberg CS, Fontana P, Przybocki M, Le Bras M, Ploehn C, et al. A new data science research program: evaluation, metrology, standards, and community outreach. International Journal of Data Science and Analytics. 2016;**1**(3):177-197

[8] Chasapis D, Moreto M, Schulz M, Rountree B, Valero M, Casas M. Power efficient job scheduling by predicting the impact of processor manufacturing variability. In: Proceedings of the ACM International Conference on Supercomputing (ICS'19). New York, NY, USA: ACM; 2019. pp. 296-307

Proceedings of the ACM MobiHoc Workshop on Pervasive Systems in the IoT Era (PERSIST-IoT'19). New York, NY, USA: ACM; 2019. pp. 13-18

Workshop on Extreme Scale

ACM; 2017. pp. 4:1-4:7

27-38

**129**

[15] Bak S, Menon H, White S, Diener M, Kale L. Integrating openmp into the charm++ programming model. In: Proceedings of the Third International

*DOI: http://dx.doi.org/10.5772/intechopen.92578*

*Looking at Data Science through the Lens of Scheduling and Load Balancing*

Programming Models and Middleware (ESPM2'17). New York, NY, USA:

[16] Gandhi R, Liu HH, Hu YC, Lu G, Padhye J, Yuan L, et al. Duet: Cloud scale load balancing with hardware and

software. SIGCOMM Computer Communication Review. 2014;**44**(4):

[9] Liu L, Tan H, Jiang SH-C, Han Z, Li X-Y, Huang H. Dependent task placement and scheduling with function configuration in edge computing. In: Proceedings of the International Symposium on Quality of Service (IWQoS'19). New York, NY, USA: ACM; 2019. pp. 20:1-20:10

[10] Palyvos-Giannas D, Gulisano V, Papatriantafilou M. Haren: A framework for ad-hoc thread scheduling policies for data streaming applications. In: Proceedings of the 13th ACM International Conference on Distributed and Event-based Systems (DEBS '19). New York, NY, USA: ACM; 2019. pp. 19-30

[11] Feng Y, Zhu Y. PES: Proactive event scheduling for responsive and energyefficient mobile web computing. In: Proceedings of the 46th International Symposium on Computer Architecture (ISCA '19). New York, NY, USA: ACM; 2019. pp. 66-78

[12] Topcuoglu H, Hariri S, Min-You WU. Performance-effective and lowcomplexity task scheduling for heterogeneous computing. IEEE Transactions on Parallel and Distributed Systems. 2002;**13**(3):260-274

[13] Menon H, Kale L. A distributed dynamic load balancer for iterative applications. In: Proceedings of the International Conference on High Performance Computing, Networking, Storage and Analysis (SC'13). New York, NY, USA: ACM; 2013. pp. 15: 1-15:11

[14] Schepis L, Cuomo F, Petroni A, Biagi M, Listanti M, Scarano G. Adaptive data update for cloud-based internet of things applications. In:

*Looking at Data Science through the Lens of Scheduling and Load Balancing DOI: http://dx.doi.org/10.5772/intechopen.92578*

Proceedings of the ACM MobiHoc Workshop on Pervasive Systems in the IoT Era (PERSIST-IoT'19). New York, NY, USA: ACM; 2019. pp. 13-18

**References**

[1] Amirian P, van Loggerenberg F, Lang T. Data Science and Analytics. Cham: Springer International Publishing; 2017. pp. 15-37

*Scheduling Problems - New Applications and Trends*

International Conference on

ACM; 2019. pp. 20:1-20:10

pp. 19-30

2019. pp. 66-78

Supercomputing (ICS'19). New York, NY, USA: ACM; 2019. pp. 296-307

[9] Liu L, Tan H, Jiang SH-C, Han Z, Li X-Y, Huang H. Dependent task placement and scheduling with function configuration in edge computing. In: Proceedings of the International Symposium on Quality of Service (IWQoS'19). New York, NY, USA:

[10] Palyvos-Giannas D, Gulisano V, Papatriantafilou M. Haren: A

framework for ad-hoc thread scheduling policies for data streaming applications. In: Proceedings of the 13th ACM

International Conference on Distributed and Event-based Systems (DEBS '19). New York, NY, USA: ACM; 2019.

[11] Feng Y, Zhu Y. PES: Proactive event scheduling for responsive and energyefficient mobile web computing. In: Proceedings of the 46th International Symposium on Computer Architecture (ISCA '19). New York, NY, USA: ACM;

[12] Topcuoglu H, Hariri S, Min-You WU. Performance-effective and lowcomplexity task scheduling for heterogeneous computing. IEEE

Transactions on Parallel and Distributed

New York, NY, USA: ACM; 2013. pp. 15:

[14] Schepis L, Cuomo F, Petroni A, Biagi M, Listanti M, Scarano G. Adaptive data update for cloud-based internet of things applications. In:

[13] Menon H, Kale L. A distributed dynamic load balancer for iterative applications. In: Proceedings of the International Conference on High Performance Computing, Networking,

Systems. 2002;**13**(3):260-274

Storage and Analysis (SC'13).

1-15:11

Environmental Modelling and Software.

Environmental Data Science. Applications

[3] Grus J. Data Science from Scratch: First Principles with Python. 1st ed. O'Reilly Media, Inc.; 2015. Available from: https://www.amazon.com/ Data-Science-Scratch-Principles-

Multilevel data processing using parallel algorithms for analyzing big data in high-performance computing. International Journal of Parallel Programming. 2018;**46**(3):508-527

[5] Bomatpalli T, Wagh R, Balaji S. High performance computing and big data analytics paradigms and challenges. International Journal of Computer Applications. 2015;**116**(04):28-33

[6] Singh D, Reddy CK. A survey on platforms for big data analytics. Journal

[7] Dorr BJ, Greenberg CS, Fontana P, Przybocki M, Le Bras M, Ploehn C, et al. A new data science research program: evaluation, metrology, standards, and community outreach. International Journal of Data Science and Analytics.

[8] Chasapis D, Moreto M, Schulz M, Rountree B, Valero M, Casas M. Power efficient job scheduling by predicting the impact of processor manufacturing variability. In: Proceedings of the ACM

of Big Data. 2014;**2**(1):8

2016;**1**(3):177-197

**128**

[2] Gibert K, Horsburgh JS, Athanasiadis IN, Holmes G. Environmental data science.

2018;**106**:4-12. Special Issue on

to Air quality and Water cycle

Python/dp/149190142X

[4] Ahmad A, Paul A, Din S, Rathore MM, Choi GS, Jeon G. [15] Bak S, Menon H, White S, Diener M, Kale L. Integrating openmp into the charm++ programming model. In: Proceedings of the Third International Workshop on Extreme Scale Programming Models and Middleware (ESPM2'17). New York, NY, USA: ACM; 2017. pp. 4:1-4:7

[16] Gandhi R, Liu HH, Hu YC, Lu G, Padhye J, Yuan L, et al. Duet: Cloud scale load balancing with hardware and software. SIGCOMM Computer Communication Review. 2014;**44**(4): 27-38

**131**

**Chapter 7**

**Abstract**

Environment

*Tahani Aladwani*

and total finish time (TFT).

**1. Introduction**

**Keywords:** task scheduling algorithms, load balance, performance

Cloud computing is a new technology derived from grid computing and distributed computing and refers to using computing resources (hardware, software, and platforms) as a service and provided to beneficiaries on demand through the Internet [1]. It is the first technology that uses the concept of commercial implementation of computer science with public users [2]. It relies on sharing resources among users through the use of the virtualization technique. High performance can be provided by a cloud computing, based on distributing workloads across all resources fairly and effectively to get less waiting time, execution time, maximum throughput, and exploitation of resources effectively. Still, there are many challenges prevalent in cloud computing, Task scheduling and load balance are the

Types of Task Scheduling

Algorithms in Cloud Computing

Cloud computing is one of the most important technologies used in recent times, it allows users (individuals and organizations) to access computing resources (software, hardware, and platform) as services remotely through the Internet. Cloud computing is distinguished from traditional computing paradigms by its scalability, adjustable costs, accessibility, reliability, and ondemand pay-as-you-go services. As cloud computing is serving millions of users simultaneously, it must have the ability to meet all users requests with high performance and guarantee of quality of service (QoS). Therefore, we need to implement an appropriate task scheduling algorithm to fairly and efficiently meet these requests. Task scheduling problem is the one of the most critical issues in cloud computing environment because cloud performance depends mainly on it. There are various types of scheduling algorithms; some of them are static scheduling algorithms that are considered suitable for small or medium scale cloud computing; and dynamic scheduling algorithms that are considered suitable for large scale cloud computing environments. In this research, we attempt to show the most popular three static task scheduling algorithms performance there are: first come first service (FCFS), short job first scheduling (SJF), MAX-MIN. The CloudSim simulator has been used to measure their impact on algorithm complexity, resource availability, total execution time (TET), total waiting time (TWT),

#### **Chapter 7**
