Hi,
I am AMiT Kumar, a 3rd year Undergrad Pursuing Mathematics and Computing Engineering, at Delhi Technological University, India.
I was going through the inequalities solvers, while working on this issue:
https://github.com/sympy/sympy/issues/8715 , I saw that inequality solvers returns sympy Boolean objects such as And/Or. I think this limits the extending capabilities of inequalities solver, since we can't manipulate these objects, for e.g. say removing an element from the returned solution, as in the issue #8715 we saw that solve
(x + 1/x > -2 + 1/x) returns a solution which makes denominator zero.
I was trying to implement a check for singularities (as suggested by @smichr) : which will find singularities and remove those from the solution. This can easily be done if I convert the Boolean object into a set Interval by using .as_set() (which I have fixed for infinite intervals: https://github.com/sympy/sympy/pull/8784), but at the time I don't see a method to convert the set interval object into Boolean object such as And/Or to return the solution in the form of current output API.
So, I think converting the output API to return a set interval (for univariate) solves the problem.
Also (1, 2) is more readable than And(1 < x, x < 2).
Please, do tell me if I am going the wrong way, would love to hear from you.
Cheers!
Amit Kumar