Nemocas / AbstractAlgebra.jl

Generic abstract algebra functionality in pure Julia (no C dependencies)
https://nemocas.github.io/AbstractAlgebra.jl/dev/index.html
Other
163 stars 63 forks source link

cannot multiply elements in polynomial ring over a field of fractions #1710

Closed matthias314 closed 4 months ago

matthias314 commented 4 months ago

I would expect the following to work:

julia> R, x = polynomial_ring(QQ, :x)
(Univariate polynomial ring in x over rationals, x)

julia> F = total_ring_of_fractions(R)
Total ring of fractions of R

julia> S, y = polynomial_ring(F, :y)
(Univariate polynomial ring in y over F, y)

julia> 2*y*y
2*y^2

julia> y*y
ERROR: MethodError: Cannot `convert` an object of type AbstractAlgebra.Generic.TotFrac{AbstractAlgebra.Generic.Poly{Rational{BigInt}}} to an object of type AbstractAlgebra.Generic.Poly{Rational{BigInt}}

I'm using AbstractAlgebra v0.41.5. The same error occurs with Nemo v0.45.1.

joschmitt commented 4 months ago

Thanks for the report. Should be fixed with #1711.