Inequation solution doesn't isolate the operational variable
This is a follow-up to
- Ask Sage question 57318: Use solve with inequality extracted from polytope
- Ask Sage question 57359: Symbolic expression not scriptable in Solve
One more time I encounter a problem I cannot find a solution by myself. In the following code:
D = polytopes.dodecahedron()
DH = D.Hrepresentation()
x = list(var('x_%i' % i) for i in (0..2))
# show(DH)
Ineq=[[el.A()*vector(x) >= -el.b()] for el in DH]
# show(Ineq)
sol = [solve(ieq[0], x[0]) for ieq in Ineq]
sol1 = [el[1] for el in sol]
show(sol1)
when ieq[0]
doesn't depend on x[0]
, sol1
is returned as entered.
It's perfectly normal. But I ask to solve on x[0]
. Many answers do not
isolate x[0]
(for instance, it is the case for sol[2]
) which is what
I ask for. How can I code in such way that SageMath does it by default?