Skip to content
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

Simplification doesn't pull unary minus out of brackets with more subtraction terms #996

Open
christianp opened this issue Feb 23, 2023 · 0 comments
Labels
Difficult! Issues that will take a long time to implement, or involve big breaking changes

Comments

@christianp
Copy link
Member

Here's a small example: -a + b - 2c + 0. I'd expect this to simplify to b - a - 2c, with all the rules turned on.

I think the problem is that the rule for pulling out unary minus, ?;x + (-?;y), matches with strictInverse turned on, so while extra addition terms are matched under rest, extra subtraction terms are not. Could getTerms be changed to capture inverse terms only under rest, and not consider them for the match?

@christianp christianp added the Difficult! Issues that will take a long time to implement, or involve big breaking changes label May 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Difficult! Issues that will take a long time to implement, or involve big breaking changes
Projects
None yet
Development

No branches or pull requests

1 participant