Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
24 views

Exercice 1.2.1

This document summarizes the steps to solve several linear programming problems using the simplex method. It begins with an example problem to maximize x1 + 2x2 subject to constraints. The problem is converted to standard form and an initial basic feasible solution is found. The simplex method proceeds through iterations of entering and leaving variables from the basis until an optimal solution is reached. Subsequent examples demonstrate solving additional problems, including some that are unbounded or have no feasible solution.

Uploaded by

Amine Brahmi
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views

Exercice 1.2.1

This document summarizes the steps to solve several linear programming problems using the simplex method. It begins with an example problem to maximize x1 + 2x2 subject to constraints. The problem is converted to standard form and an initial basic feasible solution is found. The simplex method proceeds through iterations of entering and leaving variables from the basis until an optimal solution is reached. Subsequent examples demonstrate solving additional problems, including some that are unbounded or have no feasible solution.

Uploaded by

Amine Brahmi
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 17

Exercice 1.2.1.

Resoudre par le simplexe


Max x
1
+2x
2
sous
_

_
3x
1
+ 2x
2
2
x
1
+ 2x
2
4
x
1
+ x
2
5
x
i
0 i = 1, 2
1) Forme standard
Min z = (x
1
+2x
2
)
sous
_

_
3x
1
+ 2x
2
+ x
3
= 2
x
1
+ 2x
2
+ x
4
= 4
x
1
+ x
2
+ x
5
= 5
x
i
0 i = 1, . . . , 5
1
2) Tableau du simplexe (forme canonique !)
x
1
x
2
x
3
x
4
x
5
z b
-1 -2 0 0 0 -1 0
-3 2 1 0 0 0 2
-1 2 0 1 0 0 4
1 1 0 0 1 0 5
3) Si SBR, alors phase II (sinon phase I)
Ici, evident
_

_
x
1
= x
2
= 0
x
3
= 2 0
x
4
= 4 0
x
5
= 5 0
4) sol pas optimale car c
j
0
5) Changement de base :
c
2
+ negatif que c
1
x
2
rentre dans la base.
? Variable x
s
sortant de la base
t = argmin
i
{
b
i
a
i2
}|
a
i2
0
= min{
2
2
,
4
2
,
5
1
} =
2
2
t = 1
x
s
tq B
1
a
s
= e
t
=
_
_
_
1
0
0
_
_
_ s = 3
2
6) Tableau canonique de la nouvelle base
l

2
= l
2
/2
l

1
= l
1
+l
2
l

3
= l
3
l
2
l

4
= l
4
l
2
/2
x
1
x
2
x
3
x
4
x
5
z b
-4 0 1 0 0 -1 2
-
3
2
1
1
2
0 0 0 1
2 0 -1 1 0 0 2
5
2
0 -
1
2
0 1 0 4
7) seul c
1
< 0 x
1
entre en base
min{
2
2
,
4
5/2
} =
2
2
x
4
sort de la base
l

3
= l

3
/2
l

1
= l

1
+2l

3
l

2
= l

2
+3l

3
/4
l

4
= l

4
5l

3
/4
3
x
1
x
2
x
3
x
4
x
5
z b
0 0 -1 2 0 -1 6
0 1 -
1
4
3
4
0 0
5
2
1 0 -
1
2
1
2
0 0 1
0 0
3
4
-
5
4
1 0
3
2
8) seul c
3
< 0 x
3
entre en base
min{
3/2
3/4
} x
5
sort de la base
l

4
= 4l

4
/3
l

1
= l

1
+4l

4
/3
l

2
= l

2
+l

4
/3
l

3
= l

3
+2l

4
/3
x
1
x
2
x
3
x
4
x
5
z b
0 0 0
1
3
4
3
-1 8
0 1 0
1
3
1
3
0 3
1 0 0 -
1
3
2
3
0 2
0 0 1 -
5
3
4
3
0 2
sol : x
1
= 2; x
2
= 3; x
3
= 2; x
4
= x
5
= 0
co ut = -8
sol optimale car tous les c
j
0
4
Exercice 1.2.2.
x
1
x
2
x
3
x
4
z b
0 6 0 0 -1 31
0 5 1 0 0 7
1 4 0 0 0 5
0 7 0 1 0 12
Optimum, x
1
= 5; x
2
= 0; x
3
= 7; x
4
= 12,
co ut=-31
x
1
x
2
x
3
x
4
x
5
z b
0 -1 0 4 0 -1 0
1 -2 0 6 0 0 8
0 0 0 6 1 0 1
0 -1 1 2 0 0 1
Optimum non borne ()
x
1
x
2
x
3
z b
-4 0 0 -1 -2
1 1 0 0 -1
2 0 1 0 2
Impossible !
5
Exercice 1.2.5.
Max x
1
sous
_

_
x
1
x
2
1
2x
1
x
2
2
x
1
+x
2
7
x
1
0
x
2
0
Resoudre par le simplexe. Comparer avec les
solutions obtenues graphiquement.
1) Forme standard
Min z = x
1
sous
_

_
x
1
x
2
+x
3
= 1
2x
1
x
2
+x
4
= 2
x
1
+x
2
+x
5
= 7
x
i
0 i = 1, . . . , 5
6
2) Tableau du simplexe
x
1
x
2
x
3
x
4
x
5
z b
-1 0 0 0 0 -1 0
1 -1 1 0 0 0 1
2 -1 0 1 0 0 2
1 1 0 0 1 0 7
SBR (VHB : x
1
= x
2
= 0 ; VB : x
3
= 1; x
4
=
2; x
5
= 7)
3) Phase II
x
1
entre dans la base
min{
1
1
,
2
2
,
7
1
} = 1 x
3
ou x
4
sort de la base.
Choix : x
3
sort
l
1
l
1
+l
2
l
3
l
3
2l
2
l
4
l
4
l
2
x
1
x
2
x
3
x
4
x
5
z b
0 -1 1 0 0 -1 1
1 -1 1 0 0 0 1
0 1 -2 1 0 0 0
0 2 -1 0 1 0 6
7
x
2
entre dans la base
min{
0
1
,
6
2
} = 0 x
4
sort de la base.
l
1
l
1
+l
3
l
2
l
2
+l
3
l
4
l
4
2l
3
x
1
x
2
x
3
x
4
x
5
z b
0 0 -1 1 0 -1 1
1 0 -1 1 0 0 1
0 1 -2 1 0 0 0
0 0 3 -2 1 0 6
x
3
entre dans la base, x
5
en sort.
l
1
l
1
+l
4
/3
l
2
l
2
+l
4
/3
l
3
l
3
+2l
4
/3
l
4
l
4
/3
x
1
x
2
x
3
x
4
x
5
z b
0 0 0 1/3 1/3 -1 3
1 0 0 1/3 1/3 0 3
0 1 0 -1/3 2/3 0 4
0 0 1 -2/3 1/3 0 2
8
Optimum :
x
1
= 3 ; x
2
= 4 ; x
3
= 2 ; x
4
= x
5
= 0 ; z = 3
Remarque : si on avait fait sortir x
4
au debut
l
1
l
1
+l
3
/2
l
2
l
2
l
3
/2
l
3
l
3
/2
l
4
l
4
l
3
/2
x
1
x
2
x
3
x
4
x
5
z b
0 -1/2 0 1/2 0 -1 1
0 -1/2 1 -1/2 0 0 0
1 -1/2 0 1/2 0 0 1
0 3/2 0 -1/2 1 0 6
l
1
l
1
+l
4
/3
l
2
l
2
+l
4
/3
l
3
l
3
+l
4
/3
l
4
2/3l
4
x
1
x
2
x
3
x
4
x
5
z b
0 0 0 1/3 1/3 -1 3
0 0 1 -2/3 1/3 0 2
1 0 0 1/3 1/3 0 3
0 1 0 -1/3 2/3 0 4
Solution optimale identique mais avec une etape de
moins.
9
Exercice 1.2.3.
Resoudre par la methode du simplexe
Min x
1
x
2
+x
3
sous
_

_
x
1
+3x
2
4
x
1
+x
2
x
3
10
x
i
0 i = 1, . . . , 3
1) Forme standard
Min x
1
x
2
+x
3
sous
_

_
x
1
+3x
2
x
4
= 4
x
1
+x
2
x
3
+x
5
= 10
x
i
0 i = 1, . . . , 5
2) Pas de base realisable initiale Phase I
Variable articielle : a
6
Min a
6
(

y
i
)
sous
_
x
1
+3x
2
x
4
+a
6
= 4
x
1
+x
2
x
3
+x
5
= 10
x
i
0 i = 1, . . . , 5; a
6
0
10
SBR : x
T
=(0 0 0 0 10 4)
Fonction objectif sous forme canonique :
z = a
6
= 4 x
1
3x
2
+x
4
x
1
3x
2
+x
4
z = 4
x
1
x
2
x
3
x
4
x
5
a
6
z b
-1 -3 0 1 0 0 -1 -4
1 3 0 -1 0 1 0 4
1 1 -1 0 1 0 0 10
x
2
rentre ; min{
4
3
,
10
1
} a
6
sort
l
1
l
1
+l
2
l
2
l
2
/3
l
3
l
3
l
2
/3
x
1
x
2
x
3
x
4
x
5
a
6
z b
0 0 0 0 0 1 -1 0
1/3 1 0 -1/3 0 1/3 0 4/3
2/3 0 -1 1/3 1 -1/3 0 26/3
a
6
= 0 nest plus necessaire
on a la SBRO du probl`eme min a
6
, a
6
0
11
on a une SBR du probl`eme de depart :
x
T
=(0 4/3 0 0 26/3)
Base : x
2
, x
5
3) Phase II
Exprimer la fct objectif en fct des VHB
z = x
1
+x
3
+
x
1
x
4
4
3
=
4x
1
3
+x
3

x
4
3

4
3
x
1
x
2
x
3
x
4
x
5
z b
4/3 0 1 -1/3 0 -1 4/3
1/3 1 0 -1/3 0 0 4/3
2/3 0 -1 1/3 1 0 26/3
x
1
x
2
x
3
x
4
x
5
z b
2 0 0 0 1 -1 10
1 1 -1 0 1 0 10
2 0 -3 1 3 0 26
Optimum : x
T
=(0 10 0 26 0) ; z=-10
12
Exercice 1.2.4.
Resoudre par la methode du simplexe
Min x
2
2x
1
sous
_
2 x
1
8
x
2
x
1
x
2
+2
Comparer avec les solutions obtenues graphi-
quement
1) Forme standard
Min x
2
2x
1
sous
_

_
x
1
x
3
= 2
x
1
+x
4
= 8
x
1
x
2
x
5
= 0
x
1
x
2
+x
6
= 2
x
i
0 i = 1, . . . , 6
Il manque une VB
13
2) Phase I
Min x
7
sous
_

_
x
1
x
3
+x
7
= 2
x
1
+x
4
= 8
x
1
+x
2
+x
5
= 0
x
1
x
2
+x
6
= 2
x
i
0 i = 1, . . . , 7
z = x
7
= 2 x
1
+x
3
x
3
x
1
z = 2
x
1
x
2
x
3
x
4
x
5
x
6
x
7
z b
-1 0 1 0 0 0 0 -1 -2
1 0 -1 0 0 0 1 0 2
1 0 0 1 0 0 0 0 8
-1 1 0 0 1 0 0 0 0
1 -1 0 0 0 1 0 0 2
x
1
rentre ; min{
2
1
,
8
1
,
2
1
} x
6
ou x
7
sort (x
7
pour terminer phase I)
14
x
1
x
2
x
3
x
4
x
5
x
6
x
7
z b
0 0 0 0 0 0 1 -1 0
1 0 -1 0 0 0 1 0 2
0 0 1 1 0 0 -1 0 6
0 1 -1 0 1 0 1 0 2
0 -1 1 0 0 1 -1 0 0
z = 0 = x
7
OK; SBR : x
T
=(2 0 0 6 2 0)
VB : x
1
, x
4
, x
5
, x
6
; VHB : x
2
, x
3
3) Phase II
z = x
2
2x
1
= x
2
2(x
3
+2) x
2
2x
3
z = 4
x
1
x
2
x
3
x
4
x
5
x
6
z b
0 1 -2 0 0 0 -1 4
1 0 -1 0 0 0 0 2
0 0 1 1 0 0 0 6
0 1 -1 0 1 0 0 2
0 -1 1 0 0 1 0 0
x
6
sort, x
3
rentre
l
1
l
1
+2l
5
l
2
l
2
+l
5
l
3
l
3
l
5
l
4
l
4
+l
5
15
x
1
x
2
x
3
x
4
x
5
x
6
z b
0 -1 0 0 0 2 -1 4
1 -1 0 0 0 1 0 2
0 1 0 1 0 -1 0 6
0 0 0 0 1 1 0 2
0 -1 1 0 0 1 0 0
x
4
sort, x
2
rentre
l
1
l
1
+l
3
l
2
l
2
+l
3
l
5
l
5
+l
3
x
1
x
2
x
3
x
4
x
5
x
6
z b
0 0 0 1 0 1 -1 10
1 0 0 1 0 0 0 8
0 1 0 1 0 -1 0 6
0 0 0 0 1 1 0 2
0 0 1 1 0 0 0 6
Optimum : x
T
=(8 6 6 0 2 0) ; z=-10
16
4) Remarque :
Substitution : x

1
= x
1
2
Min x
2
2(x

1
+2) Min x
2
2x

1
sous
_

_
0 x

1
6
x
2
2 x

1
x
2
x

1
, x
2
0

_
x

1
+x
3
= 6
x

1
x
2
+x
4
= 0
x

1
+x
2
+x
5
= 2
x
i
0 i = 1, . . . , 6
simplexe canonique !
5) Resolution graphique
17

You might also like