Nemo.jl icon indicating copy to clipboard operation
Nemo.jl copied to clipboard

Add conversion QQFieldElem -> Float64 / ComplexF64, and perhaps more generally all Real / Complex subtypes

Open fingolfin opened this issue 5 months ago • 2 comments

Right now I have to do this:

julia> x = sqrt(QQBar(2))
Root 1.41421 of x^2 - 2

julia> RR = ArbField(64);

julia> Float64(RR(x))
1.4142135623730951

It would be nice if I could just do Float64(x), alas:

julia> Float64(x)
ERROR: MethodError: no method matching Float64(::QQBarFieldElem)

fingolfin avatar Jan 31 '24 14:01 fingolfin