The Assignment Problem E.A Dinic, M.A Kronrod Moscow State - - PowerPoint PPT Presentation

the assignment problem
SMART_READER_LITE
LIVE PREVIEW

The Assignment Problem E.A Dinic, M.A Kronrod Moscow State - - PowerPoint PPT Presentation

Introduction Algorithm The Assignment Problem E.A Dinic, M.A Kronrod Moscow State University Soviet Math.Dokl. 1969 January 30, 2012 E.A Dinic and M.A Kronrod Introduction Algorithm 1 Introduction Motivation Problem Definition 2 Algorithm


slide-1
SLIDE 1

Introduction Algorithm

The Assignment Problem

E.A Dinic, M.A Kronrod

Moscow State University Soviet Math.Dokl. 1969

January 30, 2012

E.A Dinic and M.A Kronrod

slide-2
SLIDE 2

Introduction Algorithm

1 Introduction

Motivation Problem Definition

2 Algorithm

Basic Idea Deficiency reduction Finding Maximum delta

E.A Dinic and M.A Kronrod

slide-3
SLIDE 3

Introduction Algorithm Motivation Problem Definition

Outline

1 Introduction

Motivation Problem Definition

2 Algorithm

Basic Idea Deficiency reduction Finding Maximum delta

E.A Dinic and M.A Kronrod

slide-4
SLIDE 4

Introduction Algorithm Motivation Problem Definition

Find the best way to assign each constructor with a job, paying the minimal cost.

E.A Dinic and M.A Kronrod

slide-5
SLIDE 5

Introduction Algorithm Motivation Problem Definition

Find the best way to assign each constructor with a job, paying the minimal cost.

Valid solution 2082$

E.A Dinic and M.A Kronrod

slide-6
SLIDE 6

Introduction Algorithm Motivation Problem Definition

Find the best way to assign each constructor with a job, paying the minimal cost.

Valid solution 2081$

E.A Dinic and M.A Kronrod

slide-7
SLIDE 7

Introduction Algorithm Motivation Problem Definition

Find the best way to assign each constructor with a job, paying the minimal cost.

Optimal solution 1912$

E.A Dinic and M.A Kronrod

slide-8
SLIDE 8

Introduction Algorithm Motivation Problem Definition

Outline

1 Introduction

Motivation Problem Definition

2 Algorithm

Basic Idea Deficiency reduction Finding Maximum delta

E.A Dinic and M.A Kronrod

slide-9
SLIDE 9

Introduction Algorithm Motivation Problem Definition

Problem Definition

Input: Square matrix, A, of order n Output: A set of an n elements (cells), exactly one in each row and each column, such that the sum of these elements is minimal with respect to all such sets.

E.A Dinic and M.A Kronrod

slide-10
SLIDE 10

Introduction Algorithm Motivation Problem Definition

So what is a solution?

A permutaion β over the set {1, ..., n} such that for any permutation λ: n

i=1 ai,β(i) ≤ n i=1 ai,λ(i).

In which cases is it easy to find the solution? Example

E.A Dinic and M.A Kronrod

slide-11
SLIDE 11

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Outline

1 Introduction

Motivation Problem Definition

2 Algorithm

Basic Idea Deficiency reduction Finding Maximum delta

E.A Dinic and M.A Kronrod

slide-12
SLIDE 12

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Definition

Let some vector ∆ = (∆1, ....., ∆n) be given. An element, ai j, of the matrix A is called ∆-minimal if

∀1≤k≤n ai j − ∆j ≤ ai k − ∆k

Example:

1 2 3 4 1

2 5 4 1

2

9 8 10 2

3

12 15 7 4

4

7 8 9 3

3 7 3 1

E.A Dinic and M.A Kronrod

slide-13
SLIDE 13

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Definition

Let some vector ∆ = (∆1, ....., ∆n) be given. An element, ai j, of the matrix A is called ∆-minimal if

∀1≤k≤n ai j − ∆j ≤ ai k − ∆k

Example:

1 2 3 4 1

2 5 4 1

2

9 8 10 2

3

12 15 7 4

4

7 8 9 3

3 7 3 1 →

1 2 3 4 1

2 5 4 1

2

9 8 10 2

3

12 15 7 4

4

7 8 9 3

E.A Dinic and M.A Kronrod

slide-14
SLIDE 14

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Let some vector ∆ = (∆1, ....., ∆n) be given. An element, ai j, of the matrix A is called ∆-minimal if

∀1≤k≤n ai j − ∆j ≤ ai k − ∆k

Lemma For any ∆ let there be given a set of n ∆-minimal elements: a1j1, a2j2, ...., anjn, one from each row and each column. Then this set is an optimal solution for the Assignment Problem.

E.A Dinic and M.A Kronrod

slide-15
SLIDE 15

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Let some vector ∆ = (∆1, ....., ∆n) be given. An element, ai j, of the matrix A is called ∆-minimal if

∀1≤k≤n ai j − ∆j ≤ ai k − ∆k

Lemma For any ∆ let there be given a set of n ∆-minimal elements: a1j1, a2j2, ...., anjn, one from each row and each column. Then this set is an optimal solution for the Assignment Problem. Proof

1 For some vector ∆ = (∆1, ....., ∆n) .

A set of n ∆-minimal elements has the minimal sum among all sets of n elements one from each column.

2 A set of n ∆-minimal elements one from each row and each column

is a minimal and valid solution.

E.A Dinic and M.A Kronrod

slide-16
SLIDE 16

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

For some vector ∆ = (∆1, ....., ∆n) . A set of n ∆-minimal elements has the minimal sum among all sets of n elements one from each column. Proof: Let there be a set of n elements a1j1, a2j2, ...., anjn we can write the sum of the set as: n

i=1 ai ji = n k=1 ∆k + n i=1(ai ji − ∆ji)

Let there be a set of n ∆-minimal elements a∗1c1, a∗2c2, ...., a∗ncn n

i=1 a∗i ci = n k=1 ∆k + n i=1(a∗i ci − ∆ji)

⇓ ∀1≤k≤n ai j − ∆j ≤ ai k − ∆k n

k=1 ∆k + i=1 n

(a∗i ci − ∆ci) ≤ n

k=1 ∆k + i=1 n

(ai ji − ∆ji) ⇓ n

i=1 a∗i ci ≤ n i=1 ai ji

E.A Dinic and M.A Kronrod

slide-17
SLIDE 17

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

More definitions

Given a vector ∆, an element ai j is a basic if it is a ∆-minimal element of the row i. A set of basics is a set of n basics, one from each row. Deficiency of a set of basics is the number of free columns, i.e. columns without a basic.

1 2 3 1

2 5 4

2

9 8 10

3

12 15 7

1 1 5 .

E.A Dinic and M.A Kronrod

slide-18
SLIDE 18

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

More definitions

Given a vector ∆, an element ai j is a basic if it is a ∆-minimal element of the row i. A set of basics is a set of n basics, one from each row. Deficiency of a set of basics is the number of free columns, i.e. columns without a basic.

1 2 3 1

2 5 4

2

9 8 10

3

12 15 7

1 1 5 deficiency=2.

E.A Dinic and M.A Kronrod

slide-19
SLIDE 19

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Redfenition of problem

Input: Square matrix, A, of order n Output: vector, ∆, of size n a set of an n basics, with deficiancy 0.

E.A Dinic and M.A Kronrod

slide-20
SLIDE 20

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Integer linear programming problem

Given the n ∗ n matrix C we will define an n ∗ n matrix X of integer variables. The following constraints define the equivalent linear programming problem. linear constraints:

1 All the variables of X are 0 or 1:

∀i, j xi,j ∈ {0, 1}.

2 In each row and column the sum of variables is 1:

∀i n

j=0 xi,j = n j=0 xj,i = 1.

Goal function: minimize n

i=0

n

i=0 xi,jci,j.

E.A Dinic and M.A Kronrod

slide-21
SLIDE 21

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Primal-dual method

In the primal-dual method we generate a dual linear programing problem such that for every variable in the original problem we have a constraint in the dual problem, and for every constraint in the original we have a variable in the dual.

E.A Dinic and M.A Kronrod

slide-22
SLIDE 22

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Primal-dual method

We iterate on the pairs: primal and dual solutions. At any time we have a NON-FEASIBLE primal solution S to the primal problem, while the dual solution PROVES that S is OPTIMAL among the ”similarly non-feasible” primal solutions. In the end of the process we have a feasible, and thus optimal solution to the original problem.

E.A Dinic and M.A Kronrod

slide-23
SLIDE 23

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Intuition continues

We would want a function f such that for a matrix A with a soultion β, f (A) is a matrix for which β is a row minimal soultion. Example: f-function Notice: f (A) is obtaind by substracting 1 from all the elemnts of the first column of A.

E.A Dinic and M.A Kronrod

slide-24
SLIDE 24

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

The function f

Input: ∆ = (∆1, ....., ∆n), A an n ∗ n matrix Output: f∆(A) = B = (bi,j) for every indice (i, j) ∈ {1, ..., n}2 bi,j = ai,j − ∆j.

E.A Dinic and M.A Kronrod

slide-25
SLIDE 25

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Redfenition of problem

Input: Square matrix, A, of order n Output: vector, ∆, of size n a set of an n basics, with deficiancy 0.

E.A Dinic and M.A Kronrod

slide-26
SLIDE 26

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Deficiency reduction

We will solve this in an iterative maner, such that in each itration we will reduce the deficiency by 1. Input: Square matrix, A, of order n vector, ∆, of size n a set of n basics, with deficiancy m. Output: vector, ∆′, of size n a set of n basics, with deficiancy m-1. In the first itration we start with ∆ = (0, ..., 0), finding the basics and the deficiancy takes O(n2).

E.A Dinic and M.A Kronrod

slide-27
SLIDE 27

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Outline

1 Introduction

Motivation Problem Definition

2 Algorithm

Basic Idea Deficiency reduction Finding Maximum delta

E.A Dinic and M.A Kronrod

slide-28
SLIDE 28

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Finding alternative Basics

We begin with vector ∆ and a set of basics a1,j(1), ..., an,j(n)

E.A Dinic and M.A Kronrod

slide-29
SLIDE 29

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Finding alternative Basics

Let s1 be the index of a free column.

E.A Dinic and M.A Kronrod

slide-30
SLIDE 30

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Finding alternative Basics

We will increase ∆s1 with maximal δ1 such that all basics remain ∆-minimal elements (lets assume we have a function which finds such a δ).

E.A Dinic and M.A Kronrod

slide-31
SLIDE 31

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Finding alternative Basics

We obtain that for some row index i1 ai1,s1 − ∆s1 = ai1,j(i1) − ∆j(i1). ai1,s1 is called an alternative basic.

E.A Dinic and M.A Kronrod

slide-32
SLIDE 32

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Finding alternative Basics

We define s2 = j(i1).

E.A Dinic and M.A Kronrod

slide-33
SLIDE 33

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Finding alternative Basics

We now increase ∆s1, ∆s2 with maximal δ2 such that all basics remain ∆-minimal.

E.A Dinic and M.A Kronrod

slide-34
SLIDE 34

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Finding alternative Basics

Again for same row index i2 = i1 ai2,sk − ∆sk = ai2,j(i2) − ∆j(i2) were k ∈ {1, 2}. ai2,sk is an alternative basic.

E.A Dinic and M.A Kronrod

slide-35
SLIDE 35

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Finding alternative Basics

We define s3 = j(i2). We will continue this process until we find an alternative basic in a column with 2 or more basics.

E.A Dinic and M.A Kronrod

slide-36
SLIDE 36

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Pseudo Code

Input: (ax,y) nxn matrix ∆ n long vector j(i) function such that for each row ai,j(i) is a basic

S = {chooseEmptyColumn(j)} R = {} do: δ = findMaxPreserving∆Minimalty(R, S, (ax,y), ∆, j(i)) for s ∈ S do: ∆s = ∆s + δ let i ∈ {1, ..., n} \ R such that ∃s ∈ S ai,j(i) − ∆j(i) = ai,s − ∆s. R = R ∪ {i} S = S ∪ {j(i)} while every column in S has 1 or 0 basics.

E.A Dinic and M.A Kronrod

slide-37
SLIDE 37

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 1 - Complexity Analysis

In each step of phase 1: δ is found - O(n2) ∆ is updated - O(n) A new alternative basic is found (during the search of δ)- O(1) In each round the size of S increses by 1, and S is bounded by n ⇓ There are at most n − 1 steps in phase 1. Total complexity: O(n)x[O(n2) + O(n) + O(1)] =

O(n3)

E.A Dinic and M.A Kronrod

slide-38
SLIDE 38

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 2 - Change of basics

Now as we mark a column (s3) with 2 or more basics. This is the end of phase 1. We start changing our basics.

E.A Dinic and M.A Kronrod

slide-39
SLIDE 39

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 2 - Change of basics

We reduce the number of basics for our last marked column by

  • ne.

E.A Dinic and M.A Kronrod

slide-40
SLIDE 40

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 2 - Change of basics

In total we reduce the deficiency by 1.

E.A Dinic and M.A Kronrod

slide-41
SLIDE 41

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Phase 2 - Complexity Analysis

The complexity of this step is O(n) as the number of basics.

E.A Dinic and M.A Kronrod

slide-42
SLIDE 42

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Example continues

We start phase 1 again and choose a column s1 with no basics. S = {s1}. ∆ remains as it was built at the previous iteration ⇒ all basics remain ∆-minimal.

E.A Dinic and M.A Kronrod

slide-43
SLIDE 43

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Example continues

We find a maximal δ to add to ∆s were s ∈ S, such that it preserves ∆-minimality.

E.A Dinic and M.A Kronrod

slide-44
SLIDE 44

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Example continues

For some row index i1 ai1,s1 − ∆s1 = ai1,j(i1) − ∆j(i1). ai1,s1 is an alternative basic.

E.A Dinic and M.A Kronrod

slide-45
SLIDE 45

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Example continues

We end phase 1 as we found a column j(i1) = s2 ∈ S with more then one basic.

E.A Dinic and M.A Kronrod

slide-46
SLIDE 46

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Example continues

Changing our basics leads us to a set of basics with deficiency m = 0. Therefor it is a optimal solution. B = (ai,j − ∆j).

E.A Dinic and M.A Kronrod

slide-47
SLIDE 47

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Outline

1 Introduction

Motivation Problem Definition

2 Algorithm

Basic Idea Deficiency reduction Finding Maximum delta

E.A Dinic and M.A Kronrod

slide-48
SLIDE 48

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Naive computation δ = mini∈R,s∈S[(ai,s − ∆s) − (ai,j(i) − ∆j(i))]

Where: R -set of row indices which do not contain alternative basics S -set of potential alternative basics column indices (ax,y) -nxn matrix ∆ -n long vector j(i) -function such that for each row ai,j(i) is the basic in row i

Computing δ in a strightforward manner takes O(n2)

E.A Dinic and M.A Kronrod

slide-49
SLIDE 49

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Total Complexity Analysis

The maximum deficiency is n − 1. In each itration we preform phase 1 + phase 2: O(n3) + O(n) Total complexity: O(n)x[O(n3) + O(n)] = O(n4)

E.A Dinic and M.A Kronrod

slide-50
SLIDE 50

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] For each k, let bk= (b1k, ..., bnk) be a column of the values: bi k = [(aik − ∆k) − (aiji − ∆ji)] Let B be the nxn matrix: (b∗

1, ..., b∗ n),

where b∗

k = Sort(bk)

Example

1 2 3 1

2 5 4

2

9 8 10

3

12 15 7

E.A Dinic and M.A Kronrod

slide-51
SLIDE 51

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] For each k, let bk= (b1k, ..., bnk) be a column of the values: bi k = [(aik − ∆k) − (aiji − ∆ji)] Let B be the nxn matrix: (b∗

1, ..., b∗ n),

where b∗

k = Sort(bk)

Example

1 2 3 1

2 5 4

2

9 8 10

3

12 15 7

∆ b1

1 5

b2

3 8

b3

2 2

E.A Dinic and M.A Kronrod

slide-52
SLIDE 52

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] For each k, let bk= (b1k, ..., bnk) be a column of the values: bi k = [(aik − ∆k) − (aiji − ∆ji)] Let B be the nxn matrix: (b∗

1, ..., b∗ n),

where b∗

k = Sort(bk)

Example

1 2 3 1

2 5 4

2

9 8 10

3

12 15 7

∆ b1

1 5

b2

3 8

b3

2 2 B

b∗

1

b∗

2

b∗

3

1 3 2 5 8 2

E.A Dinic and M.A Kronrod

slide-53
SLIDE 53

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] For each k, let bk= (b1k, ..., bnk) be a column of the values: bi k = [(aik − ∆k) − (aiji − ∆ji)] Let B be the nxn matrix: (b∗

1, ..., b∗ n),

where b∗

k = Sort(bk)

What is the compexity of the construction of B?

E.A Dinic and M.A Kronrod

slide-54
SLIDE 54

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] For each k, let bk= (b1k, ..., bnk) be a column of the values: bi k = [(aik − ∆k) − (aiji − ∆ji)] Let B be the nxn matrix: (b∗

1, ..., b∗ n),

where b∗

k = Sort(bk)

What is the compexity of the construction of B? n × O(n log(n)) ↓

O(n2 log(n))

E.A Dinic and M.A Kronrod

slide-55
SLIDE 55

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

As preprocessing phase of an iteration build matrix B O(n2 log n). In each succeeding step of phase 1: clear the matrix from items of rows which are not in R. n × O(1) = O(n) find mink∈Sbk O(n)

E.A Dinic and M.A Kronrod

slide-56
SLIDE 56

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

As preprocessing phase of an iteration build matrix B O(n2 log n). In each succeeding step of phase 1: clear the matrix from items of rows which are not in R. n × O(1) = O(n) find mink∈Sbk O(n)

What is the total complexity?

E.A Dinic and M.A Kronrod

slide-57
SLIDE 57

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

As preprocessing phase of an iteration build matrix B O(n2 log n). In each succeeding step of phase 1: clear the matrix from items of rows which are not in R. n × O(1) = O(n) find mink∈Sbk O(n)

What is the total complexity? n × [O(n2 log n)

  • phase0

+ n × (O(n) + O(n) + O(n))

  • phase1

+ n

  • phase2

]

  • ne iteration

E.A Dinic and M.A Kronrod

slide-58
SLIDE 58

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

First improvement

As preprocessing phase of an iteration build matrix B O(n2 log n). In each succeeding step of phase 1: clear the matrix from items of rows which are not in R. n × O(1) = O(n) find mink∈Sbk O(n)

What is the total complexity? O(n3 log n)

E.A Dinic and M.A Kronrod

slide-59
SLIDE 59

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second Improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)]

E.A Dinic and M.A Kronrod

slide-60
SLIDE 60

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second Improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] ↓

E.A Dinic and M.A Kronrod

slide-61
SLIDE 61

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second Improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] ↓

δ = mini∈R[ mins∈S[(ais − ∆s) − (aiji − ∆ji)] ]

E.A Dinic and M.A Kronrod

slide-62
SLIDE 62

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second Improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] ↓

δ = mini∈R[ mins∈S[(ais − ∆s)]− (aiji − ∆ji)

  • const. for a row

]

E.A Dinic and M.A Kronrod

slide-63
SLIDE 63

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second Improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] ↓

δ = mini∈R[ mins∈S[(ais − ∆s)]− (aiji − ∆ji)

  • const. for a row

] ↓

E.A Dinic and M.A Kronrod

slide-64
SLIDE 64

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second Improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] ↓

δ = mini∈R[ mins∈S[(ais − ∆s)]− (aiji − ∆ji)

  • const. for a row

] ↓ δ = mini∈R[ mins∈S(ais − ∆s) −(aiji − ∆ji)]

E.A Dinic and M.A Kronrod

slide-65
SLIDE 65

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second Improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] ↓

δ = mini∈R[ mins∈S[(ais − ∆s)]− (aiji − ∆ji)

  • const. for a row

] ↓ δ = mini∈R[ mins∈S(ais − ∆s)

  • qi

−(aiji − ∆ji)]

E.A Dinic and M.A Kronrod

slide-66
SLIDE 66

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second Improvement

δ = mini∈R,s∈S[(ais − ∆s) − (aiji − ∆ji)] ↓

δ = mini∈R[ mins∈S[(ais − ∆s)]− (aiji − ∆ji)

  • const. for a row

] ↓ δ = mini∈R[ mins∈S(ais − ∆s)

  • qi

−(aiji − ∆ji)]

At the begining of an iteration compute the column vector qi In each succeeding step of phase 1: update the vector q: ∀i qi ← min[aism − ∆sm; qi − δ]

E.A Dinic and M.A Kronrod

slide-67
SLIDE 67

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second improvement

At the begining of an iteration compute the column vector qi O(n) In each succeeding step of phase 1: update the vector q: ∀i qi ← min[aism − ∆sm; qi − δ] O(n) What is the total complexity?

E.A Dinic and M.A Kronrod

slide-68
SLIDE 68

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second improvement

At the begining of an iteration compute the column vector qi O(n) In each succeeding step of phase 1: update the vector q: ∀i qi ← min[aism − ∆sm; qi − δ] O(n) What is the total complexity? n × [O(n)

phase0

+ n × O(n)

  • phase1

+ n

  • phase2

]

  • ne iteration

E.A Dinic and M.A Kronrod

slide-69
SLIDE 69

Introduction Algorithm Basic Idea Deficiency reduction Finding Maximum delta

Second improvement

At the begining of an iteration compute the column vector qi O(n) In each succeeding step of phase 1: update the vector q: ∀i qi ← min[aism − ∆sm; qi − δ] O(n) What is the total complexity? O(n3)

E.A Dinic and M.A Kronrod