Sage can “distribute” many operations on equalities operands, such as :
sage: var("a, b") (a, b) sage: (a==b)+3 a + 3 == b + 3 sage: 3*(a==b) 3*a == 3*b sage: (a==b)^3 a^3 == b^3 But not common functions : sage: log(a==b) log(a == b) sage: sin(a==b) sin(a == b) In both cases above, “distributing” the function would have been either right ((a==b)==> sin(a)==sin(b)) or at least possible (a==b implies that any value log(a) has an equal value of log(b)). The case of inequalities is more questionable : sage: 3*(a<b) 3*a < 3*b # Right sage: (-3)*(a<b) -3*a < -3*b # Wrong, wrong, wrong What would be expected in the ideal : sage: log(a==b) cases([(a>0 and b>0), log(a)==log(b)), (True, log(a==b))]) sage: (-3)*(a<b) -3*a>-3*b sage: c*(a<b) cases([((c>0),a<b),((c<0),a>b)),((c==0), True),(True,c*(a-b))]) etc… Would work in this direction be useful to Sage ? Advice ? -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/4b71608b-27d8-4ed3-9fdd-7ff6394c83e1n%40googlegroups.com.