Comment #2 on issue 2206 by asmeurer: plus-minus object http://code.google.com/p/sympy/issues/detail?id=2206
I didn't think of things like limit(x**pm). I suppose that anything that doesn't know how to handle it explicitly should just treat it as a Symbol. My problem was mainly one of algebraic manipulation.
For pm*x => [x, -x], I suppose there should just be a function or a method pm_to_list() that would do it (or pm_to_Tuple()). Actually, it would also be useful to have a function that could convert two expressions that differ only by minus signs on terms to a single expression with pm. Then, for example, you could take the result of solve(a*x**2 + b*x + c, x) and deal with it as a single expression (this is essentially what I was doing when I realized that pm would be nice to have).
By the way, you can think of it as being similar to having something like sign(t) multiplying the terms instead of pm, where t is just some parameter. So really computing limit(x**pm, x, 0) is no different from computing limit(x**a, x, 0), where a is Real, except pm is even easier to deal with than a assumptions wise because it only has two possible values.
Actually, the only thing I see as really a potential problem is that mp should always equal -pm. But I'm not entirely sure if that would even ever come up as an issue or not.
-- You received this message because you are subscribed to the Google Groups "sympy-issues" group. 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-issues?hl=en.
