I'm working on a program where I want to solve problems of the type:
$$Ax\leq b $$
Where $A$ is a $m\times n$ matrix with $a_{ij} \in \mathbb{R}$, $x \in \mathbb{R^n} $ and $b \in \mathbb{R^m} $.
With the following conditions:
- $\sum_{j=0}^n x_j= 1$
- $x_j\geq 0, \forall \,j\in J$
- $b_i\geq 0, \forall \, i\in I$
There's three kind of solutions i want to find:
- The one(s) that minimizes $x$
- The one(s) that maximizes $x,$ along with some indication of which $x_j$ that make it be maxed - see the example below I don't know how to describe this properly.
- The solution that is the closest to $x_j = \frac{1}{n}, \: \forall \,j\in J $
A very simple example:
given:
$\:A = (1.5, 0.2)$
$\:b=1$
I would want to find the following solutions:
- $S_1=\{x_1=0\quad \wedge\quad x_2=1\} $
- $S_2 =\{x_1=0.615\quad \wedge\quad x_2=0.385\},\quad$ "$x_1$ is the variable that makes this meet the limit".
- $S_3=\{x_1=0.5\quad \wedge\quad x_2=0.5\} $
I thought it would be straight forward by implementing the Simplex algorithm. But then i would need to have an objective function (don't I?) which I can't see that i have.
Can I construct Objective functions for the different cases I want to solve or any good suggestions on how to do this?
It might be worth mentioning that $\#J, \#I \leq 20$ and that I have never worked with linear programming before :)
Thanks.
*Edit*, yea what do i mean about max/minimizing..
Something like this:
$min\{c^T x\,|\, x\in \mathbb{R^n} \wedge Ax \leq b \wedge x,b \geq 0\}$
$max\{c^T x\,|\, x\in \mathbb{R^n} \wedge Ax \leq b \wedge x,b \geq 0\}$
I'm not really sure about the c vector but as far as i understand it's the one I'm missing?
Most of what i know about LP is from here:
https://en.wikipedia.org/wiki/Linear_programming#