On 01/05/2020 23:44, Oscar Benjamin wrote:
On Fri, 1 May 2020 at 12:09, David Bailey <[email protected]> wrote:
On 01/05/2020 00:32, Oscar Benjamin wrote:

Hi Aaron,

Yes, if we had Equation we should disallow its use in an expression. I
don't see any situation where it would make sense. We would need a
clear distinction between Equation and Equality as well as methods to
convert between them.

1. Equality is a Boolean
2. Equation is Basic
3. Neither is Expr
4. You can use `.as_Boolean/.as_Equation` or something to convert between
5. Equation should be used instead of Equality for e.g. passing
equations to solve/dsolve and for returning solutions.
6. Equation should be invalid in any Boolean context
7. Equality should not support any of the arithmetic manipulations
that Equation does
8. Equation should be usable in subs or subseq or something (but
Equality should not)
9. Equation should have a solve method for making something the lhs
10. Documentation should find a way of making this understandable...

Hang on, doesn't that exclude the very operations we were just discussing, such 
as

3+Equation(a-3,b-3)
That example works fine with Equation:

In [5]: a, b = symbols('a, b')

In [6]: 3+Equation(a-3,b-3)
Out[6]: a = b

Yes but isn't that inconsistent with your statement "Yes, if we had Equation we should disallow its use in an expression"? Surely the example we are discussing *is *an Equation embedded in an expression!

Sorry, I am probably missing something!

David

--
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sympy/446ac9c7-bd50-142c-1f06-9d75eb8af9b5%40dbailey.co.uk.

Reply via email to