Lokacijski problemi - transportne mreze

Preview:

Citation preview

1

Lokacijski problemi

Dr Dušan Teodorović

2

Osnovne postavke teorije lokacije

Teorija lokacije pokušava da da odgovore na sledeća pitanja:

a) Koliki je ukupan broj objekata na mreži u kojima se obavlja opsluga?

b) Gde locirati ove objekte?

c) Na koji način izvršiti alokaciju klijenata koji zahtevaju opslugu po pojedinim objektima? (Odrediti za svaki od objekata skup klijenata koji će da budu opsluženi iz objekta).

3

Osnovne postavke teorije lokacije

U određenim slučajevima objekte je moguće locirati u bilo kojoj tački posmatranog regiona (kontinualni lokacijski problemi)

Drugu grupu lokacijskih problema predstavljaju problemi u kojima se podrazumeva da je lociranje objekata moguće izvršiti samo u određenim, unapred definisanim tačkama (diskretni lokacijski problemi).

4

Osnovne postavke teorije lokacije

Predmet našeg razmatranja biće lokacijski problemi kod kojih je lociranje objekata dozvoljeno samo u određenim tačkama.

Najveći broj saobraćajnih terminala moguće je zbog postojanja geografskih, urbanističkih, pravnih, ekonomskih i organizacionih ograničenja locirati samo u određenom broju čvorova.

5

Osnovne postavke teorije lokacije

Prvi rad posvećen delom i lokacijskim problemima potiče iz 19‑tog veka. Znameniti matematičar Fermat je ukazao u svom radu na sledeći problem:

“Za zadate tri tačke u ravni pronaći četvrtu, tako da zbir rastojanja između četvrte tačke i datih triju tačaka bude minimalan.”

Začetnikom moderne lokacijske analize se smatra Alfred Weber koje je razmatrao problem lokacije skladista (1909) i težio u svojoj analizi da minimizira rastojanja izmedju skladišta i korisnika skladišta

6

Osnovne postavke teorije lokacije

Od položaja određenih objekata na transportnoj mreži bitno zavise kako kvalitet saobraćajnih usluga, tako i ukupni troškovi transportnog sistema.

Položaj objekta na mreži u kojima se vrši neko opsluživanje zavisi od vrste samog opsluživanja (vazduhoplovno pristanište, stanice javnog gradskog prevoza, vatrogasna brigada, stanica hitne pomoći , policijske stanice)

7

Osnovne postavke teorije lokacije

Skladišta, robni centri, deponije za odlaganje opasnih materijala, deponije za odlaganje smeća, aerodromi, habovi, škole, garaže, autobuske stanice, stanice hitne pomoći, bolnice, bazeni, obdaništa, domovi zdravlja, vatrogasne brigade, restorani brze hrane i stanice za brzo otklanjanje naftnih mrlja

8

Klasifikacija lokacijskih problema

A. Broj objekata na mrežiNa transportnoj mreži treba locirati samo jedan objekat

Na transportnoj mreži treba locirati veći broj objekata

B. Dozvoljena mesta za lociranje objekataObjekte je moguće locirati u bilo kojoj tački posmatranog regiona (kontinualni lokacijski problem)

Objekte je moguće locirati samo u određenim, unapred definisanim tačkama (diskretni lokacijski problemi)

9

Klasifikacija lokacijskih problemaC. Vrsta objekta na mreži

Medijane (Potrebno je locirati jedan ili više objekata na mreži, tako da se minimizira prosečno rastojanje između objekata i korisnika usluga)

Centri (Potrebno je locirati jedan ili više objekata na mreži, tako da se minimizira rastojanje do najudaljenijeg korisnika)

Objekti sa prethodno definisanim perfomansama sistema (Potrebno je locirati jedan ili više objekata na mreži, tako da se zadovolje unapred definisani standardi u pogledu pređenih rastojanja, vremena putovanja, vremena čekanja na opslugu ili nekog drugog atributa. Ovaj tip problema sa naziva problemima zahtevanja)

10

Klasifikacija lokacijskih problema

D. Tip algoritma za rešavanje lokacijskih problema

• Egzaktni algoritmi• Heuristički algoritmi

E. Broj kriterijumskih funkcija na osnovu kojih se određuje lokacija objekata

• Postoji jedna kriterijumska funkcija• Postoji više kriterijumskih funkcija

(problemi višekriterijumske optimizacije)

11

Merenje rastojanja u lokacijskim problemima

• Euclidska rastojanja

• Manhattan rastojanja

12

Merenje rastojanja u lokacijskim problemima

y

x

Manhattan Distance

Euclidian Distance

Manhattan rastojanje i Euklidsko rastojanje

13

Merenje rastojanja u lokacijskim problemima

• Čvorovi j(xj, yj) i i(xi, yi):

• Manhattan rastojanje m(i, J) između čvora i(xi, yi)

i čvora j(xj, yj) je jednako

jiji yyxxJIm ,

14

Merenje rastojanja u lokacijskim problemima

Rešetkasta mreža

15

Merenje rastojanja u lokacijskim problemima

• Euklidsko rastojanje e(I, J):

• Manhattan rastojanje i Euklidsko rastojanje su specijalni slučajevi lp rastojanja

e I J x x y yi j i j, 2 2

l I J x x y yp i j

p

i j

p p,

1

16

Merenje rastojanja u lokacijskim problemima

P = 1:

P = 2:

Međugradska rastojanja u putnoj mreži su obično 10‑30% veća od odgovarajućihz Euklidskih rastojanja

m I J l I J, , 1

e I J l I J, , 2

17

Medijane

U slučaju problema medijane potrebno je locirati jedan ili više objekata na mreži‚ tako da se minimizira prosečno rastojanje (prosečno vreme putovanja, prosečni transportni troškovi) od objekta do korisnika ili od korisnika do objekta.

Problem medijane su naročito značajni za transportnu delatnost, s obzirom da se ova grupa problema javlja prilikom projektovanja različitih distributivnih sistema.

Problem p medijana prvi je formulisao Hakimi (1964).

18

Medijane

G = (N, A) - transportna mreža

N - skup čvorova mreže

ai - potražnja u čvoru i

dij – rastojanje između čvora i i čvora j

p - ukupan broj objekata koje treba locirati

Objekti mogu da budu locirani u bilo kome čvoru mreže

19

Medijane

Problem p medijana:

Minimizirati

otherwise,0

nodein locatedfacility in the served are node from clientswhen ,1 jix ji

n

i

n

jjijii xdaF

1 1

min

20

Medijane

pri ograničenjima:

nixn

jji ,,2,1,1

1

pxn

jjj

1

jinjixx jijj ;,,2,1,,

njix ji ,,2,1,,1,0

21

Medijane

Definisana kriterijumska funkcija odražava težnju da se minimizira ukupno pređeno rastojanje između objekata i korisnika.

Prvo ograničenje se odnosi na činjenicu da je svaki klijent (svaki čvor) opslužen od strane samo jednog objekta. Drugim ograničenjem se ukazuje da na mreži treba da postoji ukupno p objekata. Svaki klijent lociran u nekom od objekata dobija opslugu iz tog objekta. Ovo je iskazano kroz treće ograničenje.

22

Medijane

Hakimi (1964) je pokazao da postoji najmanje jedan skup p‑medijana u čvorovima mreže G, što znači da p optimalnih lokacija objekata u mreži mora da se nalazi isključivo u čvorovima mreže.

Ova činjenica u znatnoj meri olakšava proceduru iznalaženja p‑medijana, jer je potrebno ispitati samo lokacije koje se nalaze u čvorovima.

23

Medijane

Algoritam za generisanje skupa dopustivih rešenja

Algoritmi zasnovani na teoriji grafova

Heuristički algoritmi

Algoritmi zasnovani na matematičkom programiranju

24

Medijane

• Algoritam za generisanje skupa dopustivih rešenja podrazumeva ispitivanje svih mogućih rešenja lokacija p‑medijana, izračunavanje odgovarajućih vrednosti definisane kriterijumske funkcije i određivanja optimalnog rešenja.

• Ovakav pristup moguće primeniti jedino u slučaju mreža sa manjim brojem čvorova na kojima treba locirati manji broj objekata.

25

Algoritam za određivanje jedne medijane mreže

Jednostavan algoritam kojim se generiše skup dopustivih rešenja i određuje lokacija jedne medijane u slučaju neorijentisane mreže predložio je Hakimi (1965).

Algoritam se sastoji iz sledećih algoritamskih koraka:

26

Algoritam za određivanje jedne medijane mreže

KORAK 1: Izračunati dužine najkraćih puteva dij između svih parova čvorova (i, j) mreže G i prikazivati ih u matrici najkraćih puteva D (Čvorovi i predstavljaju moguće lokacije za medijanu, a čvorovi j predstavljaju lokacije klijenata koji zahtevaju opslugu).

27

Algoritam za određivanje jedne medijane mreže

KORAK 2. Pomnožiti j‑tu kolonu matrice najkraćih puteva sa

brojem zahteva za opslugom aj iz čvora j. Element ajdij matrice [ajdij]

predstavlja “rastojanje” koje prevale korisnici iz čvora j koji se opslužuju u čvoru i. Matricu [ajdij] označiti sa D.

28

Algoritam za određivanje jedne medijane mreže

KORAK 3: Izvršiti sumiranje duž svake vrste i matrice D. Izraz

predstavlja ukupno “rastojanje” koje prevale korisnici u slučaju kada je oblekat lociran u čvoru

i.

KORAK 4: Čvor čijoj vrsti odgovara najmanje ukupno “rastojanje” koje prevaljuju korisnici predstavlja lokaciju za medijanu.

a dj i jj

n

1

29

Algoritam za određivanje jedne medijane mreže

Primer

Transportna mreža na kojoj treba odrediti lokaciju jedne medijane

30

Algoritam za određivanje jedne medijane mreže

Čvorovi transportne mreže su označeni respektivno sa A, B, C, .., H. Dnevni zahtevi za opslugom dati su u zagradama pored čvorova. Takođe su označene i dužine svih grana u mreži.

Problem koji treba da rešimo sastoji se u sledećem: Gde locirati objekat u kome se pruža određena opsluga, tako da ukupno rastojanje koje prevale korisnici usluga do objekta bude minimalno (Korisnici usluga se nalaze u čvorovima).

Na osnovu Hakimi‑jeve teoreme (1964) možemo da zaključimo da postoji 8 mesta‑kandidata za lociranje objekta. To su čvorovi A, B, C, .., H.

31

Algoritam za određivanje jedne medijane mreže

Matrica najkraćih rastojanja:

02734486

20626475

76049647

32405253

469503105

44623072

874510705

65735250

H

G

F

E

D

C

B

A

d

HGFEDCBA

ji

32

Algoritam za određivanje jedne medijane mreže

U sledećem koraku izračunajmo izraze ajdij, tako što ćemo svaku kolonu matrice najkraćih rastojanja pomnožiti sa brojem zahteva za opslugom u čvoru j.

33

Algoritam za određivanje jedne medijane mreže

0602800608003204800600

1000024004012003204200500

350018008018004802400700

1500601600010001603000300

2000180360010002406000500

200012024004060004200200

4000210160010020005600500

3000150280060100016030000

H

G

F

E

D

C

B

A

da

HGFEDCBA

jij

34

Algoritam za određivanje jedne medijane mreže

Sumiranjem po vrstama matrice [ajdij] dobijaju se ukupna rastojanja koja bi prešli korisnici usluga, ukoliko bi objekat bio smešten u pojedinim čvorovima duž čijih vrsta se vrši sumiranje.

Objekat treba locirati u onom čvoru duž čije vrste je dobijen najmanji zbir po izvršenom sumiranju.

35

Algoritam za određivanje jedne medijane mreže

Lokacija objekta je u čvoru

Broj ostvarenih putničkih

kilometara

Lokacija objekta je u čvoru

Broj ostvarenih putničkih kilometara

A 10170 E 7620

B 8970 F 9140

C 9760 G 9660

D 12620 H 9440

Brojevi ostvarenih putničkih kilometara

36

Algoritam za određivanje jedne medijane mreže

Objekat treba locirati u čvoru E

Lociranje objekta u čvoru E

37

Algoritam za određivanje jedne medijane orijentisane mreže

Izloženi algoritam za odeđivanje lokacije jedne medijane u slučaju neorijentisane mreže, može se u potpunosti primeniti i za određivanje lokacije ulazne, odnosno izlazne medijane.

Neophodno je jedino voditi računa o orijentaciji mreže, odnosno o dužinama najkraćih puteva između pojedinih parova čvorova.

38

Algoritam za određivanje jedne medijane orijentisane mreže

Orijentisana mreža u kojoj treba odrediti lokaciju jedne medijane

39

Algoritam za određivanje jedne medijane orijentisane mreže

Čvorovi: A, B, C, D, E

Matrica najkraćih rastojanja :

04367

40523

46054

62702

74510

E

D

C

B

A

d

EDCBA

ji

40

Algoritam za određivanje jedne medijane orijentisane mreže

Ukoliko ulazna medijana bude u čvoru A, ukupno rastojanje koje će preći korisnici iznosi:

5420740032046002800100

41

Algoritam za određivanje jedne medijane orijentisane mreže

Lokacija ulazne medijane je u čvoru

Broj ostvarenih putničkih kilometara

A 5420B 5540C 2160D 4240E 3660

Broj ostvarenih putničkih kilometara

42

Algoritam za određivanje jedne medijane orijentisane mreže

• Ulazna medijana treba da bude locirana u čvoru C

Loikacija ulazne medijane u čvoru C

43

7.6. Solving p median problem by generating set of feasible solution • Algorithms for generating the set of feasible

solutions consists of the following steps• Generate all possible feasible solutions• For every feasible solution calculate objective

function value• Identify the optimal solution• The total number of solutions in the case of n

nodes and p facilities equals

44

7.6. Solving p median problem by generating set of feasible solution

• n - the total number of nodes in the network (the total number of candidates for location of p medians)

• dij -the length of the shortest path between node i and node j

• dij = ajdij - “distance” traveled by users from node j when receiving service in node i

p

n

45

7.6. Solving p median problem by generating set of feasible solution• D - matrix whose elements are dij

• Xp = {vj1, vj2, ..., vjp}

• one of the possible subsets that contains p nodes• The following sum should be calculate for every

of the n C p subsets that contain p nodes:

n

jjjjjjj p

ddd1

,,,min 21

46

7.6. Solving p median problem by generating set of feasible solution• The subset with the smallest value of the sum

represents the set of nodes where p medians should be located

• Example: Identify the best locations for the two medians

47

7.6. Solving p median problem by generating set of feasible solution

Figure 7.7 A transportation network on which two facilities should be located

48

7.6. Solving p median problem by generating set of feasible solution• Nodes: A, B, C, D, E• Network contains 5 nodes• The total number of combinations for location of

two facilities equals

• Medians could be located in the following pairs of nodes

102

5

EDECDCEBDBCBEADACABA ,i,,,,,,,,,,,,,,,,,

49

7.6. Solving p median problem by generating set of feasible solution• Let us calculate the total distance traveled by the

users when facilities are located in the nodes A and B

• Users from the node A will be served in the node A. In the same way, users from the node B will be served in the node B

• The distance between the nodes C and A is smaller than the distance between the nodes C and B

50

7.6. Solving p median problem by generating set of feasible solution• Users from the node D will be served in the node

B• Users from the node E will also be served in the

node B• The total distance traveled by the users when

facilities are located in the nodes A and B equals

20408011120580710001000

51

7.6. Solving p median problem by generating set of feasible solution

Facility locations

The total distance

traveled by the users

Facility locations

The total distance

traveled by the users

(A, B) 2040 (B, D) 1660(A, C) 2190 (B, E) 1780(A, D) 1410 (C, D) 1630(A, E) 1830 (C, E) 2410(B, C) 1780 (D, E) 1730

Table 7.3 Different facility locations and the corresponding total distance traveled by the users

52

7.6. Solving p median problem by generating set of feasible solution• Medians should be located in the nodes A and D

Figure 7.8 Medians A and D and the nodes served by these medians

53

7.6. Solving p median problem by generating set of feasible solution• Example: Determine the locations of two medians

in the case of transportation network shown in the Figure 7.9. Nodes are denoted by A, B, C, .., H. Daily number of users, as well as link lengths are also shown in the figure.

54

7.6. Solving p median problem by generating set of feasible solution

Figure 7.9 Transportation network in which locations of two medians should be determined

55

7.6. Solving p median problem by generating set of feasible solution• In total, there are different

possibilities for locations of two medians28

2

8

56

7.6. Solving p median problem by generating set of feasible solution  Node pair The total

distance  Node pair The total

distance1. (A, B) 5970 15. (C, E) 69602. (A, C) 8160 16. (C, F) 55603. (A, D) 8170 17. (C, G) 86404. (A, E) 7380 18. (C, H) 75005. (A, F) 6770 19. (D, E) 66206. (A, G) 7600 20. (D, F) 54007. (A, H) 6880 21. (D, G) 83808. (B, C) 4560 22. (D, H) 84609. (B, D) 4620 23. (E, F) 5420

10. (B, E) 4620 24. (E, G) 710011. (B, F) 6530 25. (E, H) 592012. (B, G) 4660 26. (F, G) 546013. (B, H) 3340 27. (F, H) 424014. (C, D) 8960 28. (G, H) 8260

Table 7.4: The total distance traveled

57

7.6. Solving p median problem by generating set of feasible solution• The minimum total distance traveled will be

achieved when medians are located in the nodes B and H

58

7.6. Solving p median problem by generating set of feasible solution

Figure 7.10 Medians located in the nodes B and H

59

7.7. Heuristic algorithm for the p-medians problem

• Maranzana (1964):• Step 1: arbitrarily choose p nodes and locate

medians in these nodes• Step 2: every node in the network assign to

the closest median. In this way, the set of n nodes is divided into p subsets

• Step 3: for every created subset determine the location of single median. Replace with these medians, medians created in the step 1

60

7.7. Heuristic algorithm for the p-medians problem

• Step 4: Repeat steps 2 and 3, until set of medians is unchanged

• Experience gained in using this algorithm shows that sometimes the same solution can appear periodically. In such situation, the algorithm must stop when the same solution is generated for the second time

61

7.7. Heuristic algorithm for the p-medians problem

• Example: Using Maranzana’s heuristic algorithm determine the locations of two medians in the case of transportation network shown in the Figure 7.11. Nodes are denoted by A, B, C, .., H. Daily number of users, as well as link lengths are also shown in the figure.

62

7.7. Heuristic algorithm for the p-medians problem

Figure 7.11 Transportation network in which locations of two medians should be determined

63

7.7. Heuristic algorithm for the p-medians problem

• We arbitrarily choose nodes D and F , and we temporarily locate medians in these two nodes

• Median D serves nodes D, C, H, A and G, while median F serves nodes F, B and E

• Two subsets of nodes are generated

64

7.7. Heuristic algorithm for the p-medians problem

Figure 7.12: Two subsets of nodes and temporary median locations

65

7.7. Heuristic algorithm for the p-medians problem

• For every created subset we determine the location of single median

• In the case of the subset composed of the nodes F, B and E median should be located in the node B

• In the case of the subset composed of the nodes D, C, H, A and G median should be located in the node H

• Two medians are now temporarily located in the nodes B and H

66

7.7. Heuristic algorithm for the p-medians problem

Figure 7.13 Two subsets of nodes and new temporary median locations

67

7.7. Heuristic algorithm for the p-medians problem

• Two subsets of nodes are generated• For every created subset we determine the location

of single median.• Medians should be located in the nodes B and H. • Since, we again got the same solution, we

conclude that the medians should be located in the nodes B and H

68

7.7. Heuristic algorithm for the p-medians problem

Figure 7.14 Medians located in the nodes B and H

69

7.7. Heuristic algorithm for the p-medians problem

• Teitz and Bart (1968) proposed, and Larson and Odoni (1981) improved the following heuristic algorithm for p-medians problem

• The algorithm starts with finding the location of one median and a new median is found with each additional step. The algorithm is finished when all p medians have been found

• M - the set of nodes in which median are temporarily located

• m – the total number of nodes in the set M

70

7.7. Heuristic algorithm for the p-medians problem

• While searching for the p median location m will increase from 1 to p

• Step 1: Let m = 1. Find the location for one median. Let this median be located in node i. This means that M = {i}.

• Step 2: The next median is located in a node from the set N\M, so that it achieves the greatest improvement to the objective function. Now, increase m by 1 (m = m + 1).

71

7.7. Heuristic algorithm for the p-medians problem

• Step 3: We now try to improve the value of the objective function by systematically replacing one of the nodes in set M, by one of the nodes in set N\M every time an improvement takes place. When no more improvements can be made to the objective function, go to step 4.

• Step 4: If m = p the algorithm is finished. If not (m<p), go to Step 2

72

7.7. Heuristic algorithm for the p-medians problem

• Example: Use the described algorithm to find the 2 medians in the transportation network shown in Figure 7.15

73

7.7. Heuristic algorithm for the p-medians problem

Figure 7.15 Transportation network in which locations of two medians should be determined

74

7.7. Heuristic algorithm for the p-medians problem

• In the first step, we determine that the optimal location for one median is node E

• For this reason M = {E}. • In the second step we must compare the objective

function values for the cases when the medians are located in the following node pairs:

• Node pair (B, E) has the smallest objective function value (4620)

HEGEFEEDECEBEA ,i,,,,,,,,,,,,

75

7.7. Heuristic algorithm for the p-medians problem

• This means that now M = {B, E}• We now compare this solution with the following

solutions:

• Since the objective function value is 3340 for the solution (B, H) , this is now the new solution.

• This means that now M = {B, H}• We now compare this solution with the following

solutions

HBGBFBDBCBBA ,i,,,,,,,,,

HGHFHEHDHCHA ,i,,,,,,,,,

76

7.7. Heuristic algorithm for the p-medians problem

• After these comparisons, there are no improvements in the objective function. The solution (B, H) is compared to the following solutions

• No improvements can be made to the objective function after these comparisons, either

• Since m = 2 = p, we have completed the algorithm with the solution M = {B, H}.

GBFBEBDBCBBA ,i,,,,,,,,,

77

7.7. Heuristic algorithm for the p-medians problem

Figure 7.16 Medians located in nodes B and H

78

7.8. Determining transportation network centers

• When locating centers we strive to minimize the distance (travel time) to the farthest user

• Emergency facilities: Firehouses, Emergency medical service facilities, Police stations

• Shortest paths between all pairs of nodes must be calculated before applying a suitable algorithm for determining the center of a given transportation network

• G = (N, A) - transportation network

79

7.8. Determining transportation network centers

• x  € G - some point in the network (x can be located at any node or at any link)

• f(x) - the distance between point x and the node of network G which is farthest from point x

ixNi

dxf ,max

80

7.8. Determining transportation network centers

Figure 7.17 The shortest distance dx‚i between point x and the node i

81

7.8. Determining transportation network centers

• a  € A - link in the network G• Point xa on link a is called the local center of link

a if the following is true for every point x  €  a

• The distance between any link local center and its farthest node is less than or equal to the distance between any other point on the link and the farthest node from that point

xfxf a

82

7.8. Determining transportation network centers

• Node j(c) is called the node center of network G if the following is true for every node i € N

• The distance between the node center of network and its farthest node is less than or equal to the distance between any node in the network and its farthest node

  ifjf c )(

83

7.8. Determining transportation network centers

• Point x0 is called the absolute center of network G

if the following is true for every x  G:

• The distance between the absolute center and its farthest node is less than or equal to the distance between any point in the network and its farthest node

xfxf 0

84

7.9. Single Center Algorithm

• Step 1: find local center xa for every link in

the network G• Step 2: choose the local center with the

smallest value f(xa). This local center represents

the absolute center x0 of network G.

• Example: determine the node center and absolute center of the network shown in figure 7.18

85

7.9. Single Center Algorithm

Figure 7.18 Transportation network for which the node center and the absolute center has to be determined

86

7.9. Single Center Algorithm

• Link lengths are shown in the figure

• We find the lengths dij of the shortest paths

between all pairs of nodes

0243

2062

4604

3205

5450

5E

D

C

B

A

d

EDCBA

ji

7

7

7

7

87

7.9. Single Center Algorithm

• The node that has the minimum value of the maximum elements of its row is the optimal location for the center

• In our case node E is the optimal location for the center

• Let us consider link (A, B) whose length equals 5

88

7.9. Single Center Algorithm

Figure 7.19 Finding local center of the link (A, B)

89

7.9. Single Center Algorithm

• For all point x located on link (A, B) we draw function dx,i for i = A, B, C, D, E.

• For example, if we put x = 0 in A and x = 5 in B, then:

50, , xforxd Ax

50,5 , xforxd Bx

54for,12

40for,4 , xx

xxd Cx

90

7.9. Single Center Algorithm

• Function f(x) is drawn on Figure 7.19 with a thick line

• Node E is the absolute center since node E has the smallest f(xa) value (f(xa) = 5)

50,7 , xforxd Dx

55.1for,8

5.10for,5 , xx

xxd Ex

91

7.9. Single Center AlgorithmLink Function

f(x)Local Center

(A, B) f(xa) = 6 1 unit from A or 2 units from A

(A, E) f(xa) = 4.5 0.5 units from E

(A, C) f(xa) = 7 In A and C

(E, C) f(xa) = 5 In E

(B, E) f(xa) = 5 In E

(B, D) f(xa) = 6.5 1.5 units from B

(D, E) f(xa) = 5 In E

Table 7.5 Local centers

92

7.10.Requirements problems

• Requirements: • Achieve certain standard of performance (cost,

time, area covered, etc)• How many facilities do we need to achieve

defined standard of performance?• Where these facilities should be located?• Requirements problems could appear when

designing emergency services (Firehouses, Emergency medical service facilities, Police stations)

93

7.10.Requirements problems

• Examples:• 95% of rural calls for emergency medical service

should be reached within 30 minutes• 95% of urban calls for emergency medical service

should be reached within 10 minutes• Larson and Odoni: • Emergency Medical Service Coverage Algorithm• Bn = {b1, b2, ..., bn} - set of n nodes in the

network G in which demand is generated

94

7.10.Requirements problems

• Am = {a1, a2, ..., am} - set of m points in the network

G, that are candidates for location of emergency facilities

• d* - the maximum allowed “distance” between the facility located at aj  Am and the point bi  Bn that

should be served from the facility located at aj € Am

• If the distance between aj  Am and the bi  Bn is less

than d* , point aj “covers” point bi (d(aj, bi)  d* )

95

7.10.Requirements problems

• In the opposite case, point aj “does not cover”

point bi (d(aj, bi)>d*)

• The set covering problem consists in of finding the minimum number of points x*

, of points from the

set Am, needed to “cover” all points in the set Bn.

• Example:

• 8 demand nodes: A, B, C, D, E, F, G, H

• 6 potential locations: I, J, K, L, M, N

96

7.10.Requirements problems

• If the distance between potential location and demand point is less than or equal to 60, potential location covers demand point

• The shortest distance matrix [d(i, j)] :

97

7.10.Requirements problems

7429697529962742

3288913090888961

6044667657291429

7076467428778442

4642879627327175

207174586243299

,

objects

N

M

L

K

J

I

jid

HGFEDCBA

clients

98

7.10.Requirements problems

• Coverage matrix [p(i, j)]:

• where p(i, j) is element of the matrix [p(i, j)]

• Coverage matrix [p(i, j)]:

otherwise,0

60),(for,1,

jidjip

99

7.10.Requirements problems

01001011

10010000

11001111

00101001

11001100

10010111

,

objects

N

M

L

K

J

I

jip

HGFEDCBA

clients

100

7.10.Requirements problems

• Coverage matrix provides information about clients coverage by objects

• For example, point K covers points A, D, and F.• Set covering problem (Larson and Odoni (1981)):• Reduce the number of rows in coverage matrix

[p(i, j)] to the minimum possible number, so that the each column in the reduced matrix has at least single element equal to 1

101

7.10.Requirements problems

• Step 1: If thee are at least one column of the coverage matrix whose elements are equal to zero, stop. In this case there is no feasible solution. (In order to obtain feasible solution, we must increase the number of objects, and/or change “coverage distance” between the object and the client)

102

7.10.Requirements problems

• Step 2: Explore is there any column that have only one element that is not zero. Assume that nonzero element is in the row i* . The object must be located at the point that corresponds to the row i* .This point is included in the list of points that contain objects. Eliminate row i* and all columns having a 1 in row i* from the matrix

• Step 3: Eliminate row i if all its elements are less than or equal to the corresponding elements of another row i (p(i, j)<p(i, j) for j).

103

7.10.Requirements problems• Step 4: Eliminate column j if all its elements

are greater than or equal to the corresponding elements of another column j (p(i, j)  p(i, j) for j).

• Step 5: Repeat steps 2‑4 until: (a) the coverage matrix become completely empty; or (b) no row or column can be eliminated.

• The needed number of objects and their locations are determines when coverage matrix is completely empty.

• When no row or column can be eliminated it is necessary to apply some other algorithm

104

7.10.Requirements problems

• Example: Apply Matrix reduction algorithm for set covering in the following case:

0 1 0 0 1 0 1 1

1 0 0 1 0 0 0 0

1 1 0 0 1 1 1 1

0 0 1 0 1 0 0 1

1 1 0 0 1 1 0 0

1 0 0 1 0 1 1 1

,

objects

N

M

L

K

J

I

j i p

H G F E D C B A

clients

105

7.10.Requirements problems

• The distances between nodes are given in the previous example

• Step 1: Feasible solution exists, since all columns of the matrix [p(i, j)] contain at least one nonzero element

• Step2: Column F has one nonzero element (in row K). Object must be located in point K. Point K is included in the list of points that contain objects.

106

7.10.Requirements problems

• We eliminate row K and all columns having a 1 in row K* from the matrix (p(K, A) = p(K, D) = p(K, F) = 1). Reduced matrix reads

107

7.10.Requirements problems

01001

10100

11011

11010

10111

,

objects

N

M

L

J

I

jip

HGECB

clients

108

7.10.Requirements problems

• Step 3: We eliminate row J and row M. All elements in row J are less than or equal to the corresponding elements of row L. In the same way, all elements in row M are less than or equal to the corresponding elements of row I. Reduced matrix reads:

11011

10111,

objects

L

Ijip

HGECB

clients

109

7.10.Requirements problems

• Step 4: We eliminate column B and column C , since all elements in these columns are greater than or equal to the corresponding elements in the columns E and G respectively. Reduced matrix reads:

110

101,

objects

L

Ijip

HGE

clients

110

7.10.Requirements problems

• We eliminate column H (all elements in this columns are greater than or equal to the corresponding elements in the columns E and G). Reduced matrix reads:

10

01,

objects

L

Ijip

GE

clients

111

7.10.Requirements problems

• Columns E and G has one nonzero element (rows I and L). Objects must be located in points I and L.

• Points I and L are included in the list of points that contain objects. We eliminate rows I and L. Coverage matrix is empty.

• Minimum number of objects for covering points A, B, C, D, E, F, G, and H equals 3

• Objects should be located in the points K, I and L

112

7.10.Requirements problems

• The shortest distance matrix reads:

6044667657291429

7076467428778442

207174586243299

,

objects

L

K

I

jid

HGFEDCBA

clients

113

7.10.Requirements problems

• Every point is covered from the closest object .• The distance between any object and

corresponding demand point is less than or equal to 60.