# get range of values for inequalities

If I have a bunch of inequalities like $x>y, y>z, z \neq 5,x<z+y$<="" p="">

how do I get a range of values of each variable for which all these inequalities are satisfied? Thanks.

Edit: I found that this can be achieved with mathematica as mentioned in the below link:

mathematica.stackexchange.com/questions/38507/solve-the-system-of-equalities-and-inequalities

But, I want an open source solution. Is it possible with sage at all?

edit retag close merge delete

Sort by » oldest newest most voted

You can try with solve or solve_ineq, see http://doc.sagemath.org/html/en/refer...

Another possibility would be to use qepcad, see http://doc.sagemath.org/html/en/refer...

Tell us if it works as expected, so that we can report the bug in case of problem (which happens sometimes in such situations).

more

Simply using solve or solve_ineq is not solving the problem. For example, look at the piece of code mentioned in the sage docs:

sage: solve_ineq([x-y<0,x+y-3<0]) # random [[x < y, y < -x + 3, x < (3/2)]]

I get some other inequalities as output!

As for qepcad package, I too read that it might offer a solution to my problem and try to go through the docs. I couldn't really wrap my head around what's written there and I have very less time to do this :(

This is just a one time requirement for me. I don't really have to deal with sage or any other mathematics software again. Heck, I read about sage, mathematica etc for the first time yesterday. As for my mathematics prowess, I haven't really worked on this since my college :)

It would be really helpful if one could solve atleast one

For the following set of inequalities, a == b + c && a >= 12 && b <= 10 && c <= 10 && b >= 1 && c >= 1 I expect the solution to be, 12 <= a <= 20 && 2 <= b <= 10 && 2 <= c <= 10 I would want range of values of the variables involved as the output