-
-
Notifications
You must be signed in to change notification settings - Fork 60
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
Improve infinity and Precision #767
Conversation
@@ -325,11 +325,11 @@ class Gudermannian(Builtin): | |||
"Gudermannian[0]": "0", | |||
"Gudermannian[2*Pi*I]": "0", | |||
# FIXME: handling DirectedInfinity[-I] leads to problems | |||
# "Gudermannian[6/4 Pi I]": "DirectedInfinity[-I]", | |||
"Gudermannian[3 I / 2 Pi]": "DirectedInfinity[-I]", | |||
# Handled already |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment is not correct, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BTW, this is another reason to have a way to do arithmetic in an context-independent way: When rules are loaded, it makes a difference if we write Gudermannian[6 / 4 Pi I]-> repl
and Gudermannian[3 I / 2 Pi]-> repl
:
the first rule is never applied. Ideally, at loading time, the pattern should be brought to a canonical form.
This could be achieved by evaluating the rule. However, in our current framework, it is not possible, because the evaluation requires definitions that might not already be loaded. But most of the needed changes are just arithmetic evaluations, which could be perfectly done without an Evaluation object.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed the commented lines now. I am going to merge this when CI finishes.
LGTM - thanks for doing this. There is one small comment regarding possibly crud from before. |
This would be the simplest part of #766, including tests and changes in
Infinity
andPrecision
. Some of the new tests are commented / marked as xfail because require the other changes.