-
-
Notifications
You must be signed in to change notification settings - Fork 489
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Perform safe simplifications in Expression.simplify() #12650
Comments
Author: Michael Orlitzky |
comment:2
I'm happy with the overall plan, but the upgrade to Maxima 5.26 (#10682, merged in 5.0.beta8) produces a conflict. With your patch, we have the following doctests from sage.calculus.wester.
Before your patch, the first f.simplify() didn't do much:
|
Reviewer: David Roe |
comment:4
Thanks, I'm building beta9 already and will refresh the patch ASAP. |
Updated patch against 5.0.beta9 |
Attachment: sage-trac_12650.patch.gz Changes from the previous patch |
comment:5
Attachment: sage-trac_12650-review.patch.gz This turned out to be an easy fix: It is likely that users will want to set the simplification domain to 'real' in some cases, but doing it sneakily like that is a bad way to go about it. Once I'm done with this and |
comment:6
I don't think this is the right fix.
I think that it might make sense to look over the Maxima documentation and code very carefully and determine if something like the factorial simplification truly is the same in all cases, like it would be with I'm especially mystified as to what the difference between |
comment:7
Apply sage-trac_12650.patch (for the patchbot) |
comment:8
Replying to @kcrisman:
I brought this up in my initial message to sage-devel, but didn't get any comments. I agree it's not perfect, but,
I am open to other ideas, though. I personally would be satisfied with |
comment:9
Unfortunately I don't have time right now to discuss this more. I agree that it is frustrating that sage-devel folks haven't responded. I suspect that if behavior actually changes, there would be more complaints :) Oh, I believe that the two Deciding which simplifications were 'safe' is probably the first step. Under what circumstances all the other ones could go wrong, I mean, if any. |
comment:10
No problem. I would suggest removing |
comment:11
Replying to @orlitzky:
Now that I think about it, since I don't consider |
comment:12
I think this might be a way to deal with this, given that others also feel this way (e.g., Paul Zimmerman). But that should be at that other ticket, not here. |
comment:13
Well, it turns out |
comment:15
Hmm, we can close this. Can someone give it a positive review? |
comment:17
Appears to have been forgotten. |
Changed author from Michael Orlitzky to none |
Changed reviewer from David Roe to MIchael Orlitzky, Karl-Dieter Crisman, Ralf Stephan |
Changed reviewer from MIchael Orlitzky, Karl-Dieter Crisman, Ralf Stephan to Michael Orlitzky, Karl-Dieter Crisman, Ralf Stephan |
This is part 1 (of n, n >= 1) of an attempt to make simplification safer.
Right now,
simplify()
doesn't attempt anything drastic: it sends the expression to Maxima and back. So if you want a non-trivial simplification, you have to use something else.That something else is
full_simplify()
, unless you want to write your own simplification function. Butfull_simplify()
has a problem: the evil radcan.And a simple example that logix was nice enough to dig out of my code on IRC:
The goal is to make simplification safer, through some combination of,
simplify()
more useful.full_simplify()
can do some, uh, unintuitive things.Unless there are objections, I see no reason not to make
simplify()
perform all "safe" simplifications; that is, simplifications for whichsimplify(expr) == expr
with some certainty.Component: symbolics
Reviewer: Michael Orlitzky, Karl-Dieter Crisman, Ralf Stephan
Issue created by migration from https://trac.sagemath.org/ticket/12650
The text was updated successfully, but these errors were encountered: