ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Sat, 19 Mar 2016 20:56:05 +0100Simplifying an inequalityhttps://ask.sagemath.org/question/32786/simplifying-an-inequality/I ask:
var('x,y')
ineq = (x+2<y+2)
simplify(ineq)
and get:
x + 2 < y + 2
How can I get Sage to simplify this inequality to:
x < y
?
Sun, 13 Mar 2016 09:27:08 +0100https://ask.sagemath.org/question/32786/simplifying-an-inequality/Answer by calc314 for <p>I ask:</p>
<pre><code>var('x,y')
ineq = (x+2<y+2)
simplify(ineq)
</code></pre>
<p>and get:</p>
<pre><code>x + 2 < y + 2
</code></pre>
<p>How can I get Sage to simplify this inequality to: </p>
<pre><code>x < y
</code></pre>
<p>?</p>
https://ask.sagemath.org/question/32786/simplifying-an-inequality/?answer=32829#post-id-32829You can simplify this using
solve(ineq,x)
Sat, 19 Mar 2016 20:56:05 +0100https://ask.sagemath.org/question/32786/simplifying-an-inequality/?answer=32829#post-id-32829