function IvyAir()
% Solve Exercise 1.2 about the Ivy Air airline
% Michael Floater, 30/01/2020.

c = [300,160,360,220,130,280,100,80,140]'
b = [4,8,3,8,13,10,22,20,18,30,30]'
A = zeros(11,9);
A(1,1) = 1;
A(2,2) = 1;
A(3,3) = 1;
A(4,4) = 1;
A(5,5) = 1;
A(6,6) = 1;
A(7,7) = 1;
A(8,8) = 1;
A(9,9) = 1;
A(10,1) = 1;
A(10,3) = 1;
A(10,4) = 1;
A(10,6) = 1;
A(10,7) = 1;
A(10,9) = 1;
A(11,2) = 1;
A(11,3) = 1;
A(11,5) = 1;
A(11,6) = 1;
A(11,8) = 1;
A(11,9) = 1;

[description,x,eta,it,B,N,dict] = simplex(A,b,c)

xmat = zeros(3,3);
xmat(1,1) = x(1);
xmat(1,2) = x(2);
xmat(1,3) = x(3);
xmat(2,1) = x(4);
xmat(2,2) = x(5);
xmat(2,3) = x(6);
xmat(3,1) = x(7);
xmat(3,2) = x(8);
xmat(3,3) = x(9);

xmat

