-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Documentation about "Conversion from rational to floating-point" #56726
Comments
nsajko
added
docs
This change adds or pertains to documentation
maths
Mathematical functions
rationals
The Rational type and values thereof
labels
Dec 1, 2024
I think it was a mistake introduced by #45220: -with the exception of the two cases b == 0 and a == 0 && b < 0:
+with the exception of the two cases `a==0 && b==0` and `a==0 && b < 0`. we may add some doctests as example: julia> a, b = 0, 0
(0, 0)
julia> float(a//b)
ERROR: ArgumentError: invalid rational: zero(Int64)//zero(Int64)
Stacktrace:
...
julia> a/b
NaN
julia> a, b = 0, -1
(0, -1)
julia> float(a//b), a/b
(0.0, -0.0) |
giordano
pushed a commit
that referenced
this issue
Dec 18, 2024
Fixes #56726 added the changes that were suggested. fixing the mistake. --------- Co-authored-by: Max Horn <[email protected]> Co-authored-by: Chengyu Han <[email protected]>
KristofferC
pushed a commit
that referenced
this issue
Jan 2, 2025
Fixes #56726 added the changes that were suggested. fixing the mistake. --------- Co-authored-by: Max Horn <[email protected]> Co-authored-by: Chengyu Han <[email protected]> (cherry picked from commit fc9e7c4)
KristofferC
pushed a commit
that referenced
this issue
Jan 2, 2025
Fixes #56726 added the changes that were suggested. fixing the mistake. --------- Co-authored-by: Max Horn <[email protected]> Co-authored-by: Chengyu Han <[email protected]> (cherry picked from commit fc9e7c4)
stevengj
pushed a commit
that referenced
this issue
Jan 2, 2025
Fixes #56726 added the changes that were suggested. fixing the mistake. --------- Co-authored-by: Max Horn <[email protected]> Co-authored-by: Chengyu Han <[email protected]>
KristofferC
pushed a commit
that referenced
this issue
Jan 13, 2025
Fixes #56726 added the changes that were suggested. fixing the mistake. --------- Co-authored-by: Max Horn <[email protected]> Co-authored-by: Chengyu Han <[email protected]> (cherry picked from commit fc9e7c4)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The docs state:
https://docs.julialang.org/en/v1/manual/complex-and-rational-numbers/
I do not understand the first case (
b == 0
), because:The text was updated successfully, but these errors were encountered: