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

Simplify numbers with integer values to integers #668

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

hersle
Copy link

@hersle hersle commented Oct 29, 2024

I'm trying to fix JuliaSymbolics/Symbolics.jl#1299. Following @ChrisRackauckas suggestion, I have tried to add the code in this PR. But it does not work yet:

using SymbolicUtils
simplify(7.0) # outputs 7.0, but I want 7

Even though (with TYPE_RULES added in this PR):

SymbolicUtils.Chain(TYPE_RULES)(7.0) # outputs 7, as desired

Am I doing something wrong? Sorry for my lack of familiarity; I would appreciate any pointers.

@hersle hersle marked this pull request as draft October 29, 2024 13:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Substitute with fold=true does not preserve rationals
1 participant