Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 4

MAXIMAL FLOW TECHNIQUE

Initial C
1
1
2
3
4
5
6

2
3

1
0
0

3
10

4
2
1
3

2
2

1
1

1
6
1

1st Iteration
1
1
2
3
4
5
6

2
-3

+1
0
0

3
10

4
2
1
3

6
-2

1
1

1
6

+2
1
0
Rantai= [1-2-6]
O=min [3,2]=2
2nd Iteration
1

1
2
3
4
5
6

2
-1

+3
0
0 +1

3
10

4
2
-1
3

0
2

1
1

+4
+1 0
Rantai= [1-2-4-6]
0=min [1, 1, 1] =1
3rd Iteration

-1
6

1
1
2
3
4
5
6

2
0

4
+0
0

3
-10

4
2
0
3

6
0

-2

1
+1

0
-6

4
2 +0
Rantai= [1-3-5-6]
0=min [10, 2, 6] =2
4th Iteration
1

1
2
3
4
5
6

4
2
0

2
0
2

3
8

4
2
0
3

6
0

1
3

0
4

4
2
2
Rantai= [1-4-3-5-6]
0=min [2, 1, 0, 4] =0
5th Iteration
1

1
2
3
4
5
6

4
2
0

2
0
2

3
8

4
2
0
3

6
0

1
3

0
4

4
2
2
Rantai= [1-4-6]
0=min [2, 0] =0
6th Iteration
1

1
2
3
4
5
6

0
4
2
0

2
0
3

0
0

1
3

0
4

4
2
2
Rantai= [1-3-4-6]
0=min [2, 0] =0
7th Iteration
1

1
2
3
4
5
6

2
0

4
2
0

3
8

4
2
0
3

6
0

1
3

0
4

4
2
2
Rantai= [1-3-4-2-6]
0=min [8, 3, 2, 0] =0
Result
X=C-C*
1

2
3

3
2

4
0
1
0

1
2
0
3
0
2
4
0
0
0
5
3
6
0
0
0
#If C-C*=NEGATIVE, CHANGE

6
2
0
2
TO 0

(Cars per Hour)


PATH

FLOW

1-2-6
1-2-4-6
1-3-5-6

200
100
200
Total = 500

You might also like