Matrix simplex method
LP standard model in matrix form
Basic solutions and basis
The simplex tableau in matrix form
Reviewed primal simplex method
Product form for inverse matrix
Steps of the reviewed primal
simplex method
LP standard model in
matrix form
The LP standard problem can be
expressed in matrix form as follows:
Maximize o Minimize z = CX
s. t.
(A,I) X = b
X0
LP standard model in
matrix form
Where I is the mxm identity matrix:
X ( x1 , x2 ,..., xn ) ,
T
a11
a
21
A
...
am1
C (c1 , c2 ,..., cn )
a1,n m
a12
...
a22
...
... a2,n m
...
am 2 ... am ,n m
b1
b
2
...
bm
LP standard model in
matrix form
The identity matrix I can always be
written in the form it appears in
the constraint equations. This can
be done augmenting or arranging
the defect, excess and/or artificial
variables, as necessary.
LP standard model in
matrix form
This means that the n elements of
vector X include any augmented
variables (defect, excess and
artificial), where the m elements
located to the right edge represent
the variables corresponding to the
initial solution.
Example:
Basic solutions and basis
Since (A,I) X = b has m equations and
n unknowns [X=(x1,x2,,xn)T], a basic
solution can be obtained setting n-m
variables to zero, and then solving the
remaining m equations with m
unknowns, whenever a unique solution
does exist.
An extreme point is associated to one
(or several) basic solution.
Basic solutions and basis
Let
( A, I) X P j x j
j 1
Where Pj is the jth column vector of (A,I).
Whatever m linearly independent
vectors taken from P1, P2, Pn
correspond to a basic solution of
(A,I)X=b and so, to an extreme point in
the space of solutions. Such vectors form
a basis, which associated matrix is
nonsingular .
Example:
The simplex tableau in
matrix form
Maximize
Z=CX
s.t. (A,I)X= b, X0
Vector X is divided into X and X
I
II
where XII corresponds to the elements
of X associated to the initial basis B=I
In the same way, C is also divided into
CI and CII corresponding to XI and XII.
The simplex tableau in
matrix form
The LP standard problem can be written as:
1 CI
0 A
z
0
C II
X I
I
b
X II
The simplex tableau in
matrix form
For each iteration, let XB be the
representation of the current basic
variables and B its associated basis.
This means that XB represents m
elements of X and B represents the
vectors of (A,I) associated to XB.
Accordingly, let CB be the
representation of the elements of C
associated to XB.
The simplex tableau in
matrix form
BXB=b
and
In other words we have:
1 CB
B
0
z=CBXB
z 0
XB b
The simplex tableau in
matrix form
It is possible to obtain the current
values of Z and XB inverting the subdivided matrix, getting:
z 1 CBB
1
B
XB 0
0 CBB b
b B1b
The simplex tableau in
matrix form
The general simplex tableau
corresponding to XB is determined
taking into consideration that:
1 CBB
1
0
B
1 CI
0 A
C II
1 C B B1
X I
1
0
B
X
II
0
b
The simplex tableau in
matrix form
Computing the indicated operations between
matrixes, it is obtained the following general
simplex iteration, expressed in matrix form:
Basic
XI
XII
CBB-1A-CI
CBB-1-CII
CBB-1b
XB
B-1A
B-1
B-1b
The simplex tableau in
matrix form
The complete tableau, at any
iteration, can be computed once it
is known the basis B associated to
XB (and therefore its inverse B-1).
Each element in the tableau is a
function of B-1 and the original data
of the problem
Example:
Reviewed primal simplex
method
The simplex methods, primal or
dual, expressed in matrix form,
differ only on the selection of the
incoming and the outgoing vector.
Every compute else are the same.
Reviewed primal simplex
method
The reviewed simplex method offers
an advantageous procedure from
the point of view of the computing
precision, due to the way to
compute the inverse matrix B -1
Product form for inverse
matrix
Given the current basis B, the next
basis Bnxt in the following iteration
will differ from B only in one
column.
B-1nxt is obtained pre-multiplying
the current inverse B-1 by an
specially constructed matrix E.
Product form for inverse
matrix
Let us define the identity
matrix Im as
I m (e1 , e2 ,..., em )
Where ei is a unitary column
vector with a number 1 at the
ith place and 0 elsewhere
Product form for inverse
matrix
Suppose that B and B-1 are given and
that vector Pr is replaced by vector Pj in
matrix B (Pj and Pr are the incoming and
the outgoing vectors, respectively)
B Pj
j
Product form for inverse
matrix
So that jk is the kth element of j.
Then the new inverse B-1nxt can be
computed as follows:
Bnxt-1=EB-1
Product form for inverse
matrix
Where:
E (e1 ,..., er 1 , , er 1 ,..., em )
Product form for inverse
matrix
/
j
1
j
2
j
r
j
r
...
j
1/ r
...
j / j
m
r
rth place
Product form for inverse
matrix
Whenever rj0. Otherwise Bnxt-1
does not exist.
Notice that E is obtained from Im
replacing its rth column er by .
Example:
Steps of the reviewed
primal simplex method
The main idea of the reviewed
method is to use the inverse of the
current base B-1, and the original
data of the problem to do
necessary computing in order to
determine the incoming and the
outgoing variables
Steps of the reviewed
primal simplex method
Given the initial basis I, it is
determined its objective
coefficients vector CB associated,
depending whether the initial basic
variables are of defect, excess
and/or artificial type
Step 1
Incoming vector Pj
Compute Y = CBB-1. Then for each
non basic vector Pj, compute
z j c j YPj c j
Step 1
In maximization (minimization)
problems, choose the incoming vector Pj
with the more negative (positive) zj-cj;
ties are broken arbitrarily.
If every zj-cj are greater or equal than 0,
the optimal solution is reached and it is
given by:
XB =B-1b and z = CBXB
Otherwise go to step 2.
Step 2
Outgoing vector Pr
Given the incoming vector Pj,
compute:
1. The values of the current basic
variables, that is: XB=B-1b
2. The constraint coefficients of the
incoming variables, that is: j=B-1Pj
Step 2
The outgoing vector Pr (for maximization
and minimization) must be associated to:
( B 1b) k
j
min
, k 0
j
k
k
Where (B-1b)k and jk are the kth elements
of B-1b and j
If every jk 0, the problem has an
unbounded solution
Step 3
Next basis
Given the current inverse basis B-1, it
is known that the next inverse basis
is given by:
Bnxt-1=EB-1
Now set B-1 = B-1nxt and go back to step
1.
Step 3
Steps 1 and 2 are exactly the same as
those in the original simplex tableau,
as it is shown in the following table:
Step 3
Basic
x1
z1-c1
XB
x2
z2-c2
xj
xn
zj-cj
zncn
B-1Pj
Solutio
n
B-1b