@asmeurer,
I would like to start working on this, if no one else already has. We could 
create a class 'pm' which would return, as you suggested x for pm[0] and -x 
for pm[1]. We could go further and overload the different binary operators 
like +,-,* etc for pm such that-
x + y**2*(z+pm(c)) gives
[x+y**2*(z+c), x+y**2*(z-c)]
This list could then be used to access both the values. Moreover, two 
expressions with a single difference of plus or minus could be combined by 
recursively breaking down the expression and its sub-expressions to their 
args until we get the difference in sign. This would take some efforts, but 
can be done. (if this is not true, to_pm would return False)

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/sympy/-/vLmyWg0SUW8J.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sympy?hl=en.

Reply via email to