1

I am trying to find a way to solve system of linear inequalities such as:

c>0
y+c<0
x+c>0
x+y+c<0
w+c>0
w+y+c>0
w+x+c>0
w+x+y+c<0

I have had no luck in finding a fast computational method to solve them. I have tried using wolfram alpha. It works for some sets but not for others. Moreover I also tried solving such systems using matlab's solve function but with no luck. Any help regarding this matter would be very much appreciated.

1 Answers1

1

In general there are infinite solutions to an under determined system. You could however search for the smallest solution of an adapted problem. In that case you could preceed as follows:

You first vectorize your problem

x = [c y x w].';
M = [1 0 0 0
     1 1 0 0
     1 1 1 0
     1 0 0 1
     1 1 0 1
     1 0 1 1
     1 1 1 1];
y = [ 1 -1 1 -1 1 1 1 -1].';

You can set the values of ylike you want. They only need to suffice the conditions of your inequalities (i.e y(1)>0, y(2)<0,...). Now you solve the under determined system Mx=y.

The smallest solution of this system can be found by using the pseudo-inverse of M.

x = M.'(M*M.')^(-1)*y;

If you have chosen yaccordingly to your restrictions, the solution of this problem is also a solution of your problem.

If you want the smallest solution to your problem, just give y only an epsilon room (but then you should calculate it analytical).

StefanM
  • 797
  • 1
  • 10
  • 17
  • Thanks for the reply. I am unfamiliar with this method solving system of inequalities. I am rusty on my mathematics skills. Do you have any online resource to read more on this method? – Hisenbeeeerg Sep 25 '16 at 10:39
  • Explains the use of the pseudo-inverse: http://people.csail.mit.edu/bkph/articles/Pseudo_Inverse.pdf (You might need https://en.wikipedia.org/wiki/Underdetermined_system and https://en.wikipedia.org/wiki/Lagrange_multiplier) – StefanM Sep 25 '16 at 11:02
  • For further reading you can take a look at this: https://arxiv.org/pdf/cs/0702105 – StefanM Sep 25 '16 at 11:03