Académique Documents
Professionnel Documents
Culture Documents
Illustration de la notion
Illustration de la notion
Illustration de la notion
Les problèmes (P) et (D) utilisent en fait exactement les mêmes données
numériques. On peut les lire directement à partir du tableau ci-dessous ; (P)
correspond à une lecture ligne par ligne, (D) à une lecture colonne par
colonne.
Dualité en programmation linéaire
n
Sujet à
j =1
e kj x j f k k = 1,2,..., r (demandes)
vk
g
j =1
lj x j hl l = 1,2,..., s (disponibilités)
wl
xj 0 j = 1,2,..., n
Dualité en programmation linéaire
Illustration de la notion
n
• L’entrepreneur doit
min z = c
j =1
jxj
g
j =1
lj x j hl l = 1,2,..., s (disponibilités) wl
xj 0 j = 1,2,..., n
Dualité en programmation linéaire
Illustration de la notion
• Problème de l’entreprise: multiplions les contraintes de disponibilités
par -1
n n
min z = c j x j min z = c j x j
j =1 j =1
n n
Sujet à e kj x j fk k = 1,2,..., r (demandes) Sujet à e j =1
kj x j fk k = 1,2,..., r (demandes)
j =1
n
− glj x j −hl
n
−1 g x
j =1
lj j hl l = 1,2,..., s (disponibilités)
j =1
l = 1,2,..., s (disponibilités)
xj 0 j = 1,2,..., n xj 0 j = 1,2,..., n
Dualité en programmation linéaire
Illustration de la notion
r s
e
k =1
v − glj wl
kj k
l =1
≤ cj
r s
Sujet à e
k =1
kj v k − g
l =1
lj wl cj j = 1,2,..., n
vk 0 k = 1,2,..., r
wl 0 l = 1,2,..., s
Dualité en programmation linéaire
n Primal
min z = c x
j =1
j j min z = c T x
Sujet à
n
E f
Sujet à
j =1
e kj x j f k k = 1,2,..., r (demandes) −G x
−h w
x0
n min c T x
− g lj x j −hl l = 1,2,..., s (disponibilités) Sujet à Ax b
j =1 x0
xj 0 j = 1,2,..., n
Dual v
max p = f T − h T
r s w
max p = f k vk − h w l l Sujet à
E T − G T v c
k =1 l =1
r s w
Sujet à e
k =1
kj v k − g
l =1
lj wl cj j = 1,2,..., n v, w 0 max bT y
Sujet à AT y c
vk 0 k = 1,2,..., r
y0
wl 0 l = 1,2,..., s
Dualité en programmation linéaire
Problème primal et problème dual
Problème de programmation linéaire avec inégalités
Problème primal Problème dual
min c T x max bT y
Sujet à Ax b y Sujet à AT y c x
x0 y0
min c T x max bT y
Sujet à Ax = b y Sujet à AT y c x
x0
Dualité en programmation linéaire
Pour remplir contraintes de non-négativité il faut Inverser tous les operateurs des
contraintes
Exemple 1
20 5 25
x
c = (6 9) x = 1 A = 30 20 y = (yA yB yC ) b = 60
x2 5 10 15
min 6 x1 + 9 x2
max 25 y A + 60 y B + 15 y C
20 x1 + 5 x2 25
30 x 20 y A + 30 y B + 5 yC 6
+ 20 x2 60
s.c. 1
s.c. 5 y A + 20 y B + 10 y C 9
5 x1 + 10 x2 15 y 0 y 0
A yC 0
x1 0 x2 0 B
308
Algorithme dual du simplexe
min z = c1 x1 + c2 x2 + cn xn
Sujet à
a11 x1 + a12 x2 + ... + a1n xn = b1
a21 x1 + a22 x2 + ... + a2 n xn = b2
. . . .
. . . .
am1 x1 + am 2 x2 + ... + amn xn = bm
xj 0 j = 1, 2,..., n
Algorithme dual du simplexe
• À chaque itération nous avons une solution de base du problème qui n’est
pas réalisable, sauf à la dernière itération de l’algorithme, et pour laquelle les
coûts relatifs de toutes les variables sont non négatifs.
• Par exemple, considérons le problème
min z = 3 / 2u + 1/ 2h − 27
Sujet à x + 1/ 4u − 1/ 4h = −6 / 4
− 1/ 4u + p − 3 / 4h = 15 / 2
y − 1/12u + 5 /12h = 13 / 2
x, y , u , p , h 0
Algorithme dual du simplexe
Si non
Soit b r = min bi 0 . Si a rj 0 j = 1, 2,..., n, alors
1i m
le problème n'est pas réalisable. En effet puisque
n
a rj x j 0 et br 0
j =1
n
il est impossible que a rj x j = b r .
j =1
Algorithme dual du simplexe: Critère de sortie
1i m
Sinon soit b r = min b i 0. x jr est la variable de sortie.
Le pivot se fera dans la ligne r du tableau.
Algorithme dual du simplexe: Critère d’entrée
a rs 0
ar1 ar 2 1 arn br
0 1 0 0
ars ars ars ars ars
Si arj 0 pour tout j alors x : Ax = b, x 0
est vide et l’algorithme se termine
a rs 0
Pivot
319
320
Exemple 1:
min z = 4 x1 + x2 + x3
S .C.
− x1 − x2 −8
− 8 x1 + x2 + 9 x3 −1
x1 , x2 , x3 0
Exemple 1:
min z = 4 x1 + x2 + x3
S .C. − x1 − x2 + x4 = −8
− 8 x1 + x2 + 9 x3 + x5 = −1
x1 , x2 , x3 , x4 , x5 0
X5 est la variable
sortante et x1 la
variable entrante
La solution
optimale est
x1=1 , x2=7 et
x3=0
La valeur
optimale z*=11
Exemple 2:
Min z = 70 y1 + 90 y2 Min z = 70 y1 + 90 y2
S .C. y1 + 2 y2 30 S .C. y1 + 2 y2 − u1 = 30
y1 + y2 20 y1 + y2 − u2 = 20
y1 , y2 0 y1 , y2 0
Exemple 2:
Le problème dual :
Max f = 30 x1 + 20 x2 Max f = 30 x1 + 20 x2
S .C. x1 + x2 70 S .C. x1 + x2 + e1 = 70
2 x1 + x2 90 2 x1 + x2 + e2 = 90
x1 , x2 , e1 , e2 0
x1 , x2 0
Exemple 2:
x1 x2 e1 e2 b R
e1 1 1 1 0 70 70/1
e2 2 1 0 1 90 90/2
f 30 20 0 0 0
x1 x2 e1 e2 b R
e1 0 1/2 1 -1/2 25 50
x1 1 1/2 0 1/2 45 90
f 0 5 0 -15 -1350
Exemple 2:
x1 x2 e1 e2 b R
x2 0 1 2 -1 50
x1 1 0 -1 1 20
f 0 0 -10 -10 -1600
y1 e1 y1 = 10
x1 = 20;
y2 e2 y2 = 10
x2 = 50
u1 x1 u1 = 0 f * = 1600
e1 = e2 = 0
u2 x2 u2 = 0
Exemple 2:
x1 x2 e1 e2 b R
x2 0 1 2 -1 50
x1 1 0 -1 1 20
f 0 0 -10 -10 -1600
y1 e1 y1 = 10
y2 e2 y2 = 10
Z * = 1600
u1 x1 u1 = 0
u2 x2 u2 = 0
Ou :
x1 = 20; x2 = 50
f * = 1600
e1 = e2 = 0
Exemple 3:
1 0 0
1 0 1 2
0 1 0
A= AT = 0 1 2 1
1 2 1 0 0 1 2
2 1 2
Exemple 3:
Max f = 10 x1 + 15 x2 + 60 x3 + 95 x4
S .C. x1 + x2 + 2 x4 + e1 = 2
x2 + 2 x3 + x4 + e2 = 5
x3 + 2 x4 + e3 = 3
x1 , x2 , x3 , x4 , e1 , e2 , e3 0
Exemple 3:
x1 x2 x3 x4 e1 e2 e3 b R
e1 1 0 1 2 1 0 0 2 1
e2 0 1 2 1 0 1 0 5 5
e3 0 0 1 2 0 0 1 3 3/2
f 10 15 60 95 0 0 0 0
x1 x2 x3 x4 e1 e2 e3 b R
x4 1/2 0 1/2 1 1/2 0 0 1 --
e2 -1/2 1 3/2 0 -1/2 1 0 4 4
e3 -1 0 0 0 -1 0 1 1 --
f -75/2 15 25/2 0 -95/2 0 0 -95
Exemple 3:
x1 x2 x3 x4 e1 e2 e3 b R
x4 1/2 0 1/2 1 1/2 0 0 1
x2 -1/2 1 3/2 0 -1/2 1 0 4
e3 -1 0 0 0 -1 0 1 1
f -30 0 -10 0 -40 -15 0 -155
y1 = 40 𝑢1 = 30
𝑢2 = 0
y2 = 15 z* = 155 𝑢3 = 10
y3 = 0 𝑢4 = 0
Ou :
x1 = 0, x2 = 4, x3 = 0, x4 = 1
f * = 155
e1 = 0, e2 = 0, e3 = 1