Научная статья на тему 'Use of the approximate method for solving the assignment problem'

Use of the approximate method for solving the assignment problem Текст научной статьи по специальности «Компьютерные и информационные науки»

CC BY
45
11
i Надоели баннеры? Вы всегда можете отключить рекламу.
Ключевые слова
ПРИБЛИЖЕННЫЙ МЕТОД / НАБЛИЖЕНИЙ МЕТОД / APPROXIMATE METHOD / НАБЛИЖЕНИЙ РОЗВ'ЯЗОК / ЗАДАЧА ПРО ПРИЗНАЧЕННЯ / ПРИБЛИЖЕННОЕ РЕШЕНИЕ / APPROXIMATE SOLUTION / ЗАДАЧА О НАЗНАЧЕНИИ / ASSIGNMENT PROBLEM

Аннотация научной статьи по компьютерным и информационным наукам, автор научной работы — Marko M., Tsegelik G.

The object of research is the assignment problem, which consists in finding the minimum (or maximum) weight between the elements of two finite sets. An approximate method of solving the assignment problem is considered, which makes it possible to distribute the workers in such way so that the total costs in performing the work are minimal. Also, an algorithm is constructed to solve the task of assigning workers for work distribution, using the Hungarian method, where in a specific example, its use is shown. Three iterations are carried out, that is, one worker is relocated from work, after which more than one worker is assigned to work, for which no worker is assigned. Also, an approximate method to solve this problem is used and a concrete example is given. These algorithms allow to find the minimum costs when performing work by workers.

i Надоели баннеры? Вы всегда можете отключить рекламу.
iНе можете найти то, что вам нужно? Попробуйте сервис подбора литературы.
i Надоели баннеры? Вы всегда можете отключить рекламу.

Текст научной работы на тему «Use of the approximate method for solving the assignment problem»

ISSN 2226-3780 MACROECONOMICS

DEVELOPMENT OF PRODUCTIVE FORCES AND REGIONAL ECONOMY

UDC 330.34

DOI: 10.15587/2312-8372.2017.113285

Marko m., USE OF THE APPROXIMATE METHOD

Tsegeuit g. fOR SOLVING THE ASSIGNMENT

PROBLEM

Розглянуто наближенийметодрозв'язання задачг про призначення, який даезмогу такрозпо-дшити робтнитв по роботах, щоб загальнг затрати при виконаннг робт були б мтгмальними. В даному дослгдження використано два методи: угорський метод та наближений метод для побудови алгоритму. Для ¡люстрацп роботи алгоритму наведений приклад. Дане дослгдження дае змогу оптимгзувати робочий процес в сшьському господарств1, торггвлг, на тдприемствах, в органгзацгях.

Клпчов1 слова: наближений метод, наближений розв'язок, задача про призначення.

1. Introduction

With the development of market relations, the improvement of management in all spheres of purposeful human activity in a wide variety of fields (industry, agriculture, trade, consumer services, health care, nature protection, etc.), problems arise that require complex solution. Especially now it concerns the development of the economy in Ukraine, the current state of which requires the expansion of existing production facilities and the creation of new ones. In connection with this, when putting into operation new enterprises or creating new works at operating enterprises, the so-called assignment problem often arises, that is, the task of assignment of employees to vacant posts so as to ensure the most efficient performance of work. Such task arises when creating new organizations or when they are expanded.

2. The object of research and its technological audit

The object of research is assignment problem.

The assignment problem is one of the basic problems of combinatorial optimization in the field of optimization or investigation of operations in applied mathematics. It consists in finding the minimum (or maximum) weight between the elements of two finite sets. It can be represented as the finding of control in a weighted two-lane graph. On the other hand, the assignment problem relates to linear programming problems. It is a special case of a transport problem, which in turn can be represented as a problem of a minimum value stream.

The assignment problem can be described through various application situations. For example, there are a number of agents and a number of tasks. Any agent can be designed to perform any task. The agent's performance of the task is associated with costs that vary depending on which agent performs the task. It is necessary to complete all tasks by assigning only one agent for each task, so that the total costs are minimal.

In this case, the problem of distribution of workers for work is considered, so that the total costs in performing the work would be minimal.

To achieve this aim, the following tasks are set:

1. To build a mathematical model of the problem for the assignment problem.

2. To build an algorithm for solving this problem, using the Hungarian method and the approximate method, and also give an example of a solution.

4. Research of existing solutions of the problem

The assignment problem was first considered in geometric form [1] in 1784. However, at the beginning of the twentieth century, Monge solution was found to be incorrect. The following steps in solving the assignment problem made by Koenig and Egervari in the first third of the 20th century. In [2, 3] this problem was considered as the problem of finding the perfect matching of the minimal weight in a weighted two-legged graph [4]. Their work became the basis for the Hungarian method, developed [5] in the 50th of the last century. In 1947 [6], a simplex method was proposed for solving the general problem of linear programming, in which the assignment problem is easily reduced. The assignment problem posed in [6] can also be considered as the problem of the maximum flow of the minimum value. In 1961 [7], an algorithm was published to solve it. This algorithm for the general problem, like the simplex method algorithm, has exponential complexity, and for the assignment problem -polynomial. Theoretical analysis of the complexity of the algorithms shows that the algorithms [5] and [7] have the same theoretical complexity less than the Goldberg-Tarjan algorithm. Also, models, methods and algorithms that determine the decision-making processes [4, 8, 9] were investigated. However, the answer to the question of determining the best algorithm requires empirical research.

3. The aim and objectives of research

5. Methods of research

The aim of research is showing how, using an approximate method, it is possible to solve the assignment problem.

To solve the assignment problem in the literature, the method proposed by the Hungarian mathematician

TECHNOLOGY AUDiT AND PRODUCTiON RESERVES — № 5/5(37), 2017, © Marko M., Tsegelik G.

c

MAKPOEKOHOMIKA:

PO3BMTOK nPOAYKTMBHMX CUfl I PEHOHAflbHA EKOHOMIKA

ISSN 2226-3780

is known [2]. This method is included in the literature under the name of the Hungarian method [10]. However, this method is inconvenient for a lost implementation. Therefore, in the article a new approximate method [9] is proposed, which is easily implemented programmati-cally. Let's note that the Hungarian method is constructed similarly to the method of solving the transport problem [11].

Formation of the problem. Let's suppose that to perform n different works, and for each work, it is possible to assign only one worker. The costs Cj of doing i-th work to j-th workers are known. The task is assignment of the workers for the work, so that the total costs in performing the work would be minimal.

Mathematical model of the problem. If entering the variables Xj that define by formula:

[1, if i-th work is assigned for j-th worker, 11 [0, in the other case,

then the mathematical model of the problem will be as follows: it is necessary to find the minimum of a linear function:

kers for work, the minimum total costs for the work are 17 units.

L X X cijxij i=l j=l

in the case of

X xij = 1 i = 1

j=1

X Xij = J = 2,..., n;

Xij e {0,1}, i = 1,2,...,n, j = 1,2,...,n.

(1)

(2)

(3)

(4)

\vj Ui\ 8 6 3 6

0 8 1 0 6 9 10

1 3 - 5 + 2 7

1 0

-1 6 + 2 - 4 8

1

1 3 4 0 2 5 1

Fig. 1. Solution of the problem by the Hungarian method

\vj Ui\ 8 6 8 11

0 8 - 6 9 + 10

1 0

6 3 5 1 2 7

6 + 2 - 4 8

4 1 0

3 4 + 2 - 5

6 1 1

Fig. 2. Solution of the problem by the Hungarian method

Method for solving the problem. The algorithm of the method consists of two stages.

At the first stage there is an initial assignment of the workers for the work, which will be optimal if the conditions (3) are not taken into account (one worker may have more than one assigned worker, and not one worker). The second stage involves re-assignment of workers, if there is at least one work for initial assignment, after which more than one worker is assigned. The second stage consists of a number of steps, and at each step, one worker is redistribution from work, after which more than one worker is assigned, to a work where no worker is assigned so as to achieve a minimum increase in the value of the objective function. The execution of the second stage of the algorithm is continued until the distribution of workers for works that satisfies condition (3) is found.

6. Research results

The example considered in [10], and its solution by the Hungarian method (Fig. 1-3).

The costs of the optimal distribution are 8+2+2+5 = = 17 units.

Let's now consider the solution of this example, by our method considered in [9] (Fig. 4-6).

The solution is 17 units. That is, using a Hungarian or an approximate method, we distributed the wor-

\vj Ui\ 8 5 7 10

0 8 1 6 9 10 0

5 3 5 2 1 7

3 6 2 1 4 0 8

5 3 4 2 0 5 1

Fig. 3. Solution of the problem by the Hungarian method

Fig. 4. Solution of the problem by an approximate method (first step)

e 32

TEXHOnoriHHMM AYflMT TA PE3EPBM BMPOEHMUTBA — № 5/5(37), 2017

ISSN 222Б-3780

MACROECONOMICS:

DEVELOPMENT OF PRODUCTIVE FORCES AND REGIONAL ECONOMY

Fig. 5. Solution of the problem by an approximate method (second step)

Fig. 6. Solution of the problem by an approximate method (third step)

7. SWOT analysis of research results

Strengths. This research allows to assign the workers for the works, so that the costs are minimal.

Weaknesses. The weaknesses of this research are related to the fact that the Hungarian method is difficult in software implementation.

Opportunities. Additional opportunities to achieve the aim of research can be associated with the distribution of workers for work, so that the overall efficiency of all works is the greatest.

Also in the future, we will consider mathematical models for the effective distribution of candidates for vacant positions.

Threats. In our opinion, the threats for implementation of this model using an approximate method should not arise.

8. Conclusions

1. As a result of research, a model of the assignment problem is built, in which it is necessary to find the minimum of a linear function where costs Cij are known.

2. An algorithm for solving this problem for the distribution of workers by works is also built, using the Hungarian method, where in a specific example it is shown its use.

3. Three iterations are carried out, that is, one worker is relocated from work, after which more than one worker is assigned to work, for which no worker is assigned. Also, an approximate method to solve this problem is used and a concrete example is given. These algorithms allow to find the minimum costs when performing work by workers.

This algorithm can be applied at enterprises, in agriculture, in trade, etc. The article gives examples of the use of Hungarian and approximate methods.

References

1. Cayley. On Monge's «Memoire sur la Theorie des Deblais et des Remblais» [Text] / Cayley // Proceedings of the London Mathematical Society. - 1882. - Vol. s1-14, No. 1. -P. 139-143. doi:10.1112/plms/s1-14.1.139

2. Egervary, E. Matrixok Kombinatorius Tulajdonsagairol [Text] / E. Egervary // Matematikai es Fizikai Lapok. - 1931. - No. 38. -P. 16-28.

3. Konig, D. Grafok es matrixok [Text] / D. Konig // Matematikai es Fizikai Lapok. - 1931. - No. 38. - P. 116-119.

4. Kvyk, M. Ya Matematychni metody i modeli pidtrymky pry-iniattia rishen v upravlinni malymy pidpryiemstvamy [Text]: PhD thesis / M. Ya. Kvyk. - Lviv: LNU n. a. I. Franka, 2015. - 20 p.

5. Frank, A. On Kuhn's Hungarian Method?A tribute from Hungary [Text] / A. Frank // Naval Research Logistics. - 2005. -Vol. 52, No. 1. - P. 2-5. doi:10.1002/nav.20056

iНе можете найти то, что вам нужно? Попробуйте сервис подбора литературы.

6. Dantzig, G. B. Programming of Interdependent Activities: II Mathematical Model [Text] / G. B. Dantzig // Econometrica. -1949. - Vol. 17, No. 3/4. - P. 200. doi:10.2307/1905523

7. Busacker, R. G. A Procedure for Determining a Family of Minimal-cost Network Flow Patterns [Text] / R. G. Busacker, P. J. Gowen. - Maryland: The Johns, Hopkins University, 1960. -49 p. doi:10.21236/ad0249662

8. Voloshyn, O. F. Modeli ta metody pryiniattia rishen [Text]: Handbook [Text] / O. F. Voloshyn, S. O. Mashchenko. -Kyiv: Vydavnycho-polihrafichnyi tsentr «Kyivskyi universytet», 2010. - 336 p.

9. Marko, M. Ya. Nablyzhenyi alhorytm rozviazuvannia zadachi pro pryznachennia [Text] / M. Ya. Marko, G. G. Tsegelik. -Pereyaslav-Khmelnytsky: Pereyaslav-Khmelnytsky State Pedagogical University named after Gregory Skovoroda, 2017. - 24 p.

10. Barsuk, V. A. Matematicheskie metody planirovaniia i uprav-leniia v hoziaistve sviazi [Text] / V. A. Barsuk, N. M. Gu-bin. - Moscow: Sviaz, 1966. - 340 p.

11. Tsehelik, G. G. Matematychne prohramuvannia [Text]: Handbook / G. G. Tsehelik. - Lviv: LNU n. a. I. Franka, 2011. -337 p.

ИСПОЛЬЗОВАНИЕ ПРИБЛИЖЕННОГО МЕТОДА ДЛЯ РЕШЕНИЯ ЗАДАЧИ О НАЗНАЧЕНИИ

Рассмотрен приближенный метод решения задачи о назначении, который позволяет так распределить рабочих по работам, чтобы общие затраты при выполнении работ были бы минимальными. В данном исследования использованы два метода: венгерский метод и приближенный метод для построения алгоритма. Для иллюстрации работы алгоритма приведен пример. Данное исследование позволяет оптимизировать рабочий процесс в сельском хозяйстве, торговле, на предприятиях, в организациях.

Ключевые слова: приближенный метод, приближенное решение, задача о назначении.

Marco Maria, Postgraduate Student, Department of Mathematical

Modeling of Economic and Social Processes, Ivan Franko National

University of Lviv, Ukraine, e-mail: mariiamarko@gmail.com, ORCID:

http://orcid.org/0000-0002-7795-7121

Tsegelik Grigorii, Doctor of Physics and Mathematics, Professor, Head of the Department of Mathematical Modeling of Economic and Social Processes, Ivan Franko National University of Lviv, Ukraine, ORCID: https://orcid.org/0000-0002-2758-4283

TECHNOLOGY AUDIT AND PRODUCTION RESERVES — № 5/5(37), 2017

i Надоели баннеры? Вы всегда можете отключить рекламу.