Upload
marcus-mckinney
View
220
Download
0
Embed Size (px)
Citation preview
FBA (1)
Author: Tõnis Aaviksaar
TALLINN 2006
CCFFT
2
Contents
• Intro• Systems of linear equations• Solution by row operations• Steady state mass balance• Linear Programming
3
Metabolic Networks• Metabolic networks consist of
reactions between metabolites
• Flux Balance Analysis (FBA) calculates flux patterns from a system of linear equations– Flux value = rate of reaction– Flux pattern is a collection of
flux valuesO2KG
OOXA
OAce-CoAOPYR
OPEP
CO2
CO2
PEPAce-CoA
Mal
Fum
Suc-CoAIcit
CO2
3PG O3PG
GAP DHAP
FBP
E4P
S7P
X5P
R5P
Ru5P
HOO4C 3CH22CH2
1COOH
1C
2CH3
O OH
1C
2CH3
O OH
2C
3CH3
O
1CO OH
HOO4C 3CH22C
O
1COOH
2CH23CH
HO 6COOH
HOO1C 4C
H H
5COOH
HOO5C 4CH23CH2
2C
O
1COOH
mdh
fumA
D
sucD
Eicd
acn
gltA
pckAacs
QACE I ppd
gpmeno
BPG
B
pgk
gapA
tpiA
fbaA1
F6P
fbp1pfk21
G6P
pgi
ppcoadA2
oadA1
GF
zwf
H1
rpe
rpiB
H2
SBP
fbp2
fbaA2
tal
rbcL
CO2
CO2
CO2
pfk22
CO2
OR5P
OE4P
ODHAP
OG6P
OF6P
ORu5P
OS7P
OGAP
4
v3
v4
v2
v1
A
B
C
....
........
v5
Flux Patterns
v3
v4
v2
v1
A
B
C
....
........
v5
v1
v2
v3
v4
v5
v =v3
v4
v2
v1
A
B
C
....
........
v5
5
Metabolic Networks• Metabolic networks consist of
reactions between metabolites– Thousands of metabolites– More reactions than metabolites
• Flux Balance Analysis (FBA) calculates flux patterns from a system of linear equations– Flux value = rate of reaction– Flux pattern is a collection of
flux valuesO2KG
OOXA
OAce-CoAOPYR
OPEP
CO2
CO2
PEPAce-CoA
Mal
Fum
Suc-CoAIcit
CO2
3PG O3PG
GAP DHAP
FBP
E4P
S7P
X5P
R5P
Ru5P
HOO4C 3CH22CH2
1COOH
1C
2CH3
O OH
1C
2CH3
O OH
2C
3CH3
O
1CO OH
HOO4C 3CH22C
O
1COOH
2CH23CH
HO 6COOH
HOO1C 4C
H H
5COOH
HOO5C 4CH23CH2
2C
O
1COOH
mdh
fumA
D
sucD
Eicd
acn
gltA
pckAacs
QACE I ppd
gpmeno
BPG
B
pgk
gapA
tpiA
fbaA1
F6P
fbp1pfk21
G6P
pgi
ppcoadA2
oadA1
GF
zwf
H1
rpe
rpiB
H2
SBP
fbp2
fbaA2
tal
rbcL
CO2
CO2
CO2
pfk22
CO2
OR5P
OE4P
ODHAP
OG6P
OF6P
ORu5P
OS7P
OGAP
6
FBA
• Steady-state mass balance equations• Weighted sums (linear combinations) of
– Reaction stoichiometries– Flux patterns
7
Contents
• Intro• Systems of linear equations• Solution by row operations• Steady state mass balance• Linear Programming
8
Linear equation
2x1 + 3x2 + 4x3 = 11
9
Linear equation
Linear equationa1x1 + a2x2 + a3x3 = b
in matrix form
x1
x2
x3
a1 a2 a3 b× =
2x1 + 3x2 + 4x3 = 11
10
Linear equation
Linear equationa1x1 + a2x2 + a3x3 = b
in matrix form
x1
x2
x3
a1 a2 a3 b× = a1x1 + a2x2 + a3x3 =
2x1 + 3x2 + 4x3 = 11
11
System of linear equations
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
x1
x2
x3
× =
a11 a12 a13
a21 a22 a23
a31 a32 a33
a11x1 + a12x2 + a13x3
a21x1 + a22x2 + a23x3
a31x1 + a32x2 + a33x3
=
b1
b2
b3
12
System of linear equations
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
x1
x2
x3
× =
a11 a12 a13
a21 a22 a23
a31 a32 a33
a11x1 + a12x2 + a13x3
a21x1 + a22x2 + a23x3
a31x1 + a32x2 + a33x3
=
b1
b2
b3
13
System of linear equations
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
x1
x2
x3
× =
a11 a12 a13
a21 a22 a23
a31 a32 a33
a11x1 + a12x2 + a13x3
a21x1 + a22x2 + a23x3
a31x1 + a32x2 + a33x3
=
b1
b2
b3
14
System of linear equations
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
x1
x2
x3
× =
a11 a12 a13
a21 a22 a23
a31 a32 a33
a11x1 + a12x2 + a13x3
a21x1 + a22x2 + a23x3
a31x1 + a32x2 + a33x3
=
b1
b2
b3
15
System of linear equations
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
x1
x2
x3
× =
b1
b2
b3
a11 a12 a13
a21 a22 a23
a31 a32 a33
16
Linear Combination of Columns
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
x1
x2
x3
× =
b1
b2
b3
a11 a12 a13
a21 a22 a23
a31 a32 a33
17
Linear Combination of Columns
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
=
a11
a21
a31
a12
a22
a32
a13
a23
a33
x1 + x2 + x3
x1
x2
x3
×
a11 a12 a13
a21 a22 a23
a31 a32 a33
18
Linear Combination of Columns
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
=
x1
x2
x3
×
a11 a12 a13
a21 a22 a23
a31 a32 a33
a11x1 + a12x2 + a13x3
a21x1 + a22x2 + a23x3
a31x1 + a32x2 + a33x3
19
Linear Combination of Columns
System of linear equationsa11x1 + a12x2 + a13x3 = b1
a21x1 + a22x2 + a23x3 = b2
a31x1 + a32x2 + a33x3 = b3
in matrix form
x1
x2
x3
× =
b1
b2
b3
a11 a12 a13
a21 a22 a23
a31 a32 a33
20
Contents
• Intro• Systems of linear equations
– Rows correspond to equations– Linear combination of columns
• Solution by row operations• Steady state mass balance• Linear Programming
21
Matrices
• Identity matrixI
• Inverse of a matrixAA-1 = Iif AB = I and BA = I then B = A-1 and A = B-1
• Solution to a system of linear equationsAx = bA-1Ax = A-1b
I =
1
1
1
22
Matrices
• Identity matrixI
• Inverse of a matrixAA-1 = Iif AB = I and BA = I then B = A-1 and A = B-1
• Solution to a system of linear equationsAx = bA-1Ax = A-1bIx = A-1bx = A-1b
I =
1
1
1
x1
x2
x3
×Ix =
1
1
1
=
x1
x2
x3
23
Matrices
• Identity matrixI
• Inverse of a matrixAA-1 = Iif AB = I and BA = I then B = A-1 and A = B-1
• Solution to a system of linear equationsAx = bA-1Ax = A-1bIx = A-1bx = A-1b
I =
1
1
1
x1
x2
x3
×Ix =
1
1
1
=
x1
x2
x3
24
Matrix Row Operations
–7 –6 –12 –33
5 5 7 24
1 4 5
1 6/7 12/7 33/7
5 5 7 24
1 4 5
1 6/7 12/7 33/7
5/7 –11/7 3/7
–6/7 16/7 2/7
· (–1 / 7)
– 5 · R1
– 1 · R1
25
Matrix Row Operations
–7 –6 –12 –33
5 5 7 24
1 4 5
1 6/7 12/7 33/7
5 5 7 24
1 4 5
· (–1 / 7)
– 5 · R1
– 1 · R1
1 −3
1 5
1 2
.….
1 6/7 12/7 33/7
5/7 –11/7 3/7
–6/7 16/7 2/7
· 7 / 5
26
Matrix Row Operations
• Equivalent systems of equations– Two systems of equations are equivalent if they have
same solution sets
• Row operations produce equivalent systems of equations– Changing the order of rows– Multiplication of a row by a constant
2x = 4 is equivalent to 4x = 8
– Addition of a row to another row2x1 + 3x2 = 5-x1 + 2x2 = 1
2x1 + 3x2 = 5x1 + 5x2 = 6
is equivalent to
27
Matrix Row Operations
• Equivalent systems of equations– Two systems of equations are equivalent if they have
same solution sets
• Row operations produce equivalent systems of equations– Changing the order of rows– Multiplication of a row by a constant
2x = 4 is equivalent to 4x = 8
– Addition of a row to another row2x1 + 3x2 = 5-x1 + 2x2 = 1
2x1 + 3x2 = 5x1 + 5x2 = 6
is equivalent to
28
Gaussian Elimination
• Given a system of linear equationsAx = b
• Matrix A is augmented by b[A | b]
• Which is then simplified by row operations to produce[I | c]
• Which corresponds to system of equationsIx = c
• Which is equivalent to the original systemAx = b
29
• System of equations−7x1 − 6x2 − 12x3 = −33
5x1 + 5x2 + 7x3 = 24
x1 + 4x3 = 5
• Row-Reduced [A | b] ~ [I | c] =
• Simplified equivalent system of equations, only one solutionx1 = −3
x2 = 5
x3 = 2
Row-Reduced [A | b] Examples
1 −3
1 5
1 2
−7 −6 −12 −33
5 5 7 24
1 4 5
[A | b] =
30
Row-Reduced [A | b] Examples
• System of equationsx1 − x2 + 2x3 = 1
2x1 + x2 + x3 = 8
x1 + x2 = 5
• Row-Reduced [A | b]
• Simplified equivalent system of equations, infinite number of solutions (solution space)x1 + x3 = 3
x2 − x3 = 2
1 1 3
1 −1 2
31
Row-Reduced [A | b] Examples
• System of equations2x1 + x2 + 7x3 − 7x4 = 2
−3x1 + 4x2 − 5x3 − 6x4 = 3
x1 + x2 + 4x3 − 5x4 = 2
• Row-Reduced [A | b]
• Inconsistent system, no solutions0x1 + 0x2 + 0x3 − 0x4 ≠ 1
1 3 −2
1 1 −3
1
32
Gaussian Elimination
• Carl Friedrich Gauss (1777–1855)
• Chiu-chang suan-shu or The Nine Chapters on the Mathematical Art, written around 250 BCE
33
Contents
• Intro• Systems of linear equations• Solution by row operations
– Equivalent linear systems– Reduced row echelon form
• Steady state mass balance• Linear programming
34
Steady State Approximation
• Steady state conditionFluxes ≠ 0
Concentrations = const
• Steady state mass balanceCompound production = consumption
Production – consumption = 0
v2
v1
A
....
....
35
Mass Balance Equations
v1 – v2 = 0
v2 – v3 – v5 = 0
v3 – v4 = 0
1 -1
1 -1 -1
1 -1
A
B
C
v1 v2 v3 v4 v5 v1
v2
v3
v4
v5
× =
Nv = 0
v3
v4
v2
v1
A
B
C
....
........
v5
36
Stoichiometry Matrix
…
…
…
…
…
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
37
Stoichiometry Matrix
…
…
…
…
…
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
38
Stoichiometry Matrix
-2 …
…
…
…
…
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
39
Stoichiometry Matrix
-2 …
…
2 …
…
…
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
40
Stoichiometry Matrix
-2 …
1 …
2 …
…
…
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
41
Stoichiometry Matrix
-2 …
1 …
2 …
…
…
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
42
Stoichiometry Matrix
-2 …
1 …
2 …
…
…
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
43
Stoichiometry Matrix
-2 …
1 …
2 -3 …
-1 …
2 …
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
44
Stoichiometry Matrix
-2 …
1 …
2 -3 …
-1 …
2 …
H2O
O2
H2
N2
NH3
v1 v2 …
v1
v2
…
×v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
45
Stoichiometry Matrix
-2
1
2
H2O
O2
H2
N2
NH3
v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
-3
-1
2
v1 + v2 + ….
v1 v2
46
Stoichiometry Matrix
-2
1
2
H2O
O2
H2
N2
NH3
v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
-3
-1
2
v1 + v2 + …. =
v1 = 3
v2 = 2
v1 v2
47
Stoichiometry Matrix
-6
3
6
H2O
O2
H2
N2
NH3
v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
-6
-3
6
v1 + v2 + …. =
v1 = 3
v2 = 2
v1 v2
48
Stoichiometry Matrix
-6
3
6
H2O
O2
H2
N2
NH3
v2
H2N2
1N2 + 3H2 = 2NH3
2H2O = 2H2 + 1O2
O2
NH3
H2Ov1
-6
-3
6
v1 + v2 + …. =
v1 = 3
v2 = 2
v1 v2
49
Calculable Fluxes
v1 – v2 = 0
v2 – v3 – v5 = 0
v3 – v4 = 0
v3
v4
v2
v1
A
B
C
....
........
v5
1 -1
1 -1 -1
1 -1
A
B
C
v1 v2 v3 v4 v5 v1
v2
v3
v4
v5
× =A
B
C
Nv = 0
50
Calculable Fluxes
v1 – v2 = 0
v2 – v3 – v5 = 0
v3 – v4 = 0
v3
v4
v2
v1
A
B
C
....
........
v5
1 -1
1 -1 -1
1 -1
A
B
C
v1 v2 v3 v4 v5 v1
v2
v3
v4
v5
× =A
B
C
Nv = 0
51
Calculable Fluxes
v3
v4
v2
v1
A
B
C
....
........
v5
1 -1
1 -1 -1
1 -1
A
B
C
v1 v2 v3 v4 v5 v1
v2
v3
v4
v5
× =
Nv = 0
A
B
C
-1
1 -1 -1
1
A
B
C
v2 v3 v5
v1
v4
+ =1
-1
v1 v4
v2
v3
v5
× ×
Nclcvclc + Nexpvexp = 0 v1 = 1.0
v4 = .4
A
B
C
52
Calculable Fluxes
v3
v4
v2
v1
A
B
C
....
........
v5
1 -1
1 -1 -1
1 -1
A
B
C
v1 v2 v3 v4 v5 v1
v2
v3
v4
v5
× =
Nv = 0
A
B
C
-1
1 -1 -1
1
A
B
C
v2 v3 v5
1.0
.4+ =
1
-1
v1 v4
v2
v3
v5
× ×
Nclcvclc + Nexpvexp = 0 v1 = 1.0
v4 = .4
A
B
C
53
Calculable Fluxes
v3
v4
v2
v1
A
B
C
....
........
v5
1 -1
1 -1 -1
1 -1
A
B
C
v1 v2 v3 v4 v5 v1
v2
v3
v4
v5
× =
Nv = 0
A
B
C
-1
1 -1 -1
1
A
B
C
v2 v3 v5
+ =
v2
v3
v5
×
Nclcvclc + Nexpvexp = 0
1.0
-.4
bexp
A
B
C
v1 = 1.0
v4 = .4
54
Calculable Fluxes
v3
v4
v2
v1
A
B
C
....
........
v5
1 -1
1 -1 -1
1 -1
A
B
C
v1 v2 v3 v4 v5 v1
v2
v3
v4
v5
× =
Nv = 0
A
B
C
Nclcvclc + Nexpvexp = 0
-1
1 -1 -1
1
A
B
C
v2 v3 v5
=-1.0
.4
A
B
C
bclc
v2
v3
v5
×
55
Row-Reduced [A | b] Examples
• System of equationsx1 − x2 + 2x3 = 1
2x1 + x2 + x3 = 8
x1 + x2 = 5
• Row-Reduced [A | b]
• Simplified equivalent system of equations, infinite number of solutions (solution space)x1 + x3 = 3
x2 − x3 = 2
1 1 3
1 −1 2
56
Dependent and Free Fluxes
-1 1
1 -1 -1
1 -1
A
B
C
v2 v3 v5 v1 v4 v2
v3
v5
v1
v4
× =A
B
C
1 -1
1 -1
1 -1 1
v2 v3 v5 v1 v4
v3
v4
v2
v1
A
B
C
....
........
v5
Nv = 0Nclcvclc + Nexpvexp = 0
57
Dependent and Free Fluxes
v1 v2 v5 v3 v4
1 -1 -1
1 -1 -1
1 -1
1 -1
1 -1 -1
1 -1
+ R3
+ R2
1 -1 -1
1 -1 -1
1 -1
+ R3v3
v4
v2
v1
A
B
C
....
........
v5
58
Dependent and Free Fluxes
v1 v2 v3 v4 v5
-1 1 1
1 -1 -1
1 -1
1 -1 -1
1 -1 -1
1 -1
+ R1
· (-1)
-1 1 1
-1 1
1 -1
v3
v4
v2
v1
A
B
C
....
........
v5
59
Dependent and Free Fluxes
v1 v2 v3 v4 v5
1 -1 -1
-1 1 1
1 -1
1 -1 -1
1 -1 -1
1 -1
+ R2
· (-1)
1 -1
-1 1 1
1 -1
v3
v4
v2
v1
A
B
C
....
........
v5
60
Contents
• Intro• Systems of linear equations• Solution by row operations• Steady state mass balance
– Steady state mass balance– Stoichiometry matrix– Dependent and free fluxes
• Linear Programming
61
Underdetermined Systems
• Be content with infinite solution space• Make more measurements• Assign “experimental” values• Assume that the microorganism “tries” to optimize
an objective– Maximize biomass production– Maximize ATP production– ….
62
The Simplex Method
• Objective function– A linear function
• Constraints– Linear inequalities
• Assumption that all variables are nonnegative– xi ≥ 0
• Solution space is a convex polytope– An optimal solution is a vertex– Move to neighboring vertex with highest objective
function value
63
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v3 =0C → max
64
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v3 =0
+v1 −v2 =0
+v2 −v3 −v4 =0
+v1 ≤5
C
A
B
→ max
65
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v3 =0
+v1 −v2 =0
+v2 −v3 −v4 =0
+v1 +x5 =5
C
A
B
→ max
66
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v3 =0
+v1 −v2 ≤0
+v1 −v2 ≥0
+v2 −v3 −v4 ≤0
+v2 −v3 −v4 ≥0
+v1 +x5 =5
C
A
A
B
B
→ max
67
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v3 =0
+v1 −v2 ≤0
−v1 +v2 ≤0
+v2 −v3 −v4 ≤0
−v2 +v3 +v4 ≤0
+v1 +x5 =5
C
A
A
B
B
→ max
68
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v3 =0
+v1 −v2 +x1 =0
−v1 +v2 +x2 =0
+v2 −v3 −v4 +x3 =0
−v2 +v3 +v4 +x4 =0
+v1 +x5 =5
C
A
A
B
B
→ max
69
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v3 =0
+v1 −v2 +x1 =0
−v1 +v2 +x2 =0
+v2 −v3 −v4 +x3 =0
−v2 +v3 +v4 +x4 =0
+v1 +x5 =5
C
A
A
B
B
→ max
70
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v2 +v4 +x4 =0
+v1 −v2 +x1 =0
−v1 +v2 +x2 =0
+x3 +x4 =0
−v2 +v3 +v4 +x4 =0
+v1 +x5 =5
C
A
A
B
B
→ max
71
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v2 +v4 +x4 =0
+v1 −v2 +x1 =0
−v1 +v2 +x2 =0
+x3 +x4 =0
−v2 +v3 +v4 +x4 =0
+v1 +x5 =5
C
A
A
B
B
→ max
72
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v1 +v4 +x2 +x4 =0
+x1 +x2 =0
−v1 +v2 +x2 =0
+x3 +x4 =0
−v1 +v3 +v4 +x2 +x4 =0
+v1 +x5 =5
C
A
A
B
B
→ max
73
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z −v1 +v4 +x2 +x4 =0
+x1 +x2 =0
−v1 +v2 +x2 =0
+x3 +x4 =0
−v1 +v3 +v4 +x2 +x4 =0
+v1 +x5 =5
C
A
A
B
B
→ max
74
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z +v4 +x2 +x4 +x5 =5
+x1 +x2 =0
+v2 +x2 +x5 =5
+x3 +x4 =0
+v3 +v4 +x2 +x4 +x5 =5
+v1 +x5 =5
C
A
A
B
B
→ max
75
Simplex Example (1)
v3
z
v2
v1
A
B
C
....
........
v4
+z +v4 +x2 +x4 +x5 =5
+x1 +x2 =0
+v2 +x2 +x5 =5
+x3 +x4 =0
+v3 +v4 +x2 +x4 +x5 =5
+v1 +x5 =5
C
A
A
B
B
→ max
76
Simplex Example (2)
z
v3
v1
A B
C
....
........
v4
v2
....
2A + 3B = 1C
+z −v3 =0
+v1 −2v3 −v4 +x1 =0
−v1 +2v3 +v4 +x2 =0
+v2 −3v3 +x3 =0
−v2 +3v3 +x4 =0
+v1 +x5 =1
+v2 +x6 =1
77
Simplex Example (2)
z
v3
v1
A B
C
....
........
v4
v2
....
2A + 3B = 1C
+z −v3 =0
+v1 −2v3 −v4 +x1 =0
−v1 +2v3 +v4 +x2 =0
+v2 −3v3 +x3 =0
−v2 +3v3 +x4 =0
+v1 +x5 =1
+v2 +x6 =1
78
Simplex Example (2)
+z −1/3v2 +1/3x4 =0
+v1 −2/3v2 −v4 +x1 +2/3x4 =0
−v1 +2/3v2 +v4 +x2 +2/3x4 =0
+x3 +x4 =0
−1/3v2 +v3 +1/3x4 =0
+v1 +x5 =1
+v2 +x6 =1
79
Simplex Example (2)
+z −1/3v2 +1/3x4 =0
+v1 −2/3v2 −v4 +x1 +2/3x4 =0
−v1 +2/3v2 +v4 +x2 +2/3x4 =0
+x3 +x4 =0
−1/3v2 +v3 +1/3x4 =0
+v1 +x5 =1
+v2 +x6 =1
80
Simplex Example (2)
+z −1/2v1 +1/2v4 +1/2x2 =0
+x1 +x2 =0
−3/2v1 +2/3v2 +3/2v4 +3/2x2 −x4 =0
+x3 +x4 =0
−1/2v1 +v3 +1/2v4 +1/2x2 =0
+v1 +x5 =1
+3/2v1 −3/2v4 −3/2x2 +x4 +x6 =1
81
Simplex Example (2)
+z −1/2v1 +1/2v4 +1/2x2 =0
+x1 +x2 =0
−3/2v1 +2/3v2 +3/2v4 +3/2x2 −x4 =0
+x3 +x4 =0
−1/2v1 +v3 +1/2v4 +1/2x2 =0
+v1 +x5 =1
+3/2v1 −3/2v4 −3/2x2 +x4 +x6 =1
82
Simplex Example (2)
+z +1/3x4 +1/3x6 =1/3
+x1 +x2 =0
+v2 +x6 =1
+x3 +x4 =0
+v3 +1/3x4 +1/3x6 =1/3
+v4 +x2 −2/3x4 +x5 −2/3x6 =1/3
+v1 −v4 −x2 +2/3x4 +2/3x6 =2/3
83
Simplex Example (2)
+z +1/3x4 +1/3x6 =1/3
+x1 +x2 =0
+v2+x6 =1
+x3 +x4 =0
+v3+1/3x4 +1/3x6 =1/3
+v4+x2 −2/3x4 +x5 −2/3x6 =1/3
+v1 −v4−x2 +2/3x4 +2/3x6 =2/3
z
v3
v1
A B
C
....
........
v4
v2
....
2A + 3B = 1C
84
Simplex Example (2)
+z +1/3x4 +1/3x6 =1/3
+x1 +x2 =0
+v2+x6 =1
+x3 +x4 =0
+v3+1/3x4 +1/3x6 =1/3
+v4+x2 −2/3x4 +x5 −2/3x6 =1/3
+v1 −v4−x2 +2/3x4 +2/3x6 =2/3
z
v3
v1
A B
C
....
........
v4
v2
....
2A + 3B = 1C
85
Simplex Example (2)
+z +1/3x4 +1/3x6 =1/3
+x1 +x2 =0
+v2+x6 =1
+x3 +x4 =0
+v3+1/3x4 +1/3x6 =1/3
+v4+x2 −2/3x4 +x5 −2/3x6 =1/3
+v1+x5 =1
z
v3
v1
A B
C
....
........
v4
v2
....
2A + 3B = 1C
86
Simplex Example (2)
+z +1/3x4 +1/3x6 =1/3
+x1 +x2 =0
+v2+x6 =1
+x3 +x4 =0
+v3+1/3x4 +1/3x6 =1/3
+v4+x2 −2/3x4 +x5 −2/3x6 =1/3
+v1+x5 =1
z
v3
v1
A B
C
....
........
v4
v2
....
2A + 3B = 1C
87
Contents
• Intro• Systems of linear equations• Solution by row operations• Steady state mass balance• Linear Programming
– Objective Function– Convex Solution Space– The Simplex Method– Multiple Optimal Solutions