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

factor of rational numbers : StackOverflowError #1110

Open
WimKlim opened this issue Jun 5, 2023 · 4 comments
Open

factor of rational numbers : StackOverflowError #1110

WimKlim opened this issue Jun 5, 2023 · 4 comments

Comments

@WimKlim
Copy link

WimKlim commented Jun 5, 2023

I get (Julia version v1.9.0 Windows 64-Bit, Hecke version 0.18.14) :

julia> factor(12//35)
ERROR: StackOverflowError:
Stacktrace:
[1] factor(a::Rational{Int64}; b::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ Hecke xxx.julia\packages\Hecke\ttSxw\src\Misc\Integer.jl:712
[2] factor(a::Rational{Int64})
@ Hecke xxx.julia\packages\Hecke\ttSxw\src\Misc\Integer.jl:712
[3] factor(x::Rational{Int64})
@ Hecke xxx.julia\packages\Hecke\ttSxw\src\Hecke.jl:239--- the last 3 lines are repeated 26660 more times ---

@fieker
Copy link
Collaborator

fieker commented Jun 5, 2023 via email

@WimKlim
Copy link
Author

WimKlim commented Jun 5, 2023

Thanks, factor(QQ(12//35), ZZ) works and is what I expect (ZZ (with negative exponents)) .
The Nemo version is 0.34.4 .

@fieker
Copy link
Collaborator

fieker commented Jun 5, 2023 via email

@thofma
Copy link
Owner

thofma commented Jun 5, 2023

We are missing the factor(x::Rational) = factor(QQ(x)) fallback and similar for the two-argument version.

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

No branches or pull requests

3 participants