You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
evalf seems to convert the argument to Float64 and then extend its precision. I would expect evalf to behave like the last command in the example below. Is my expectation incorrect?
julia> Sym(2.45).evalf(70)
2.450000000000000177635683940025046467781066894531250000000000000000000
julia> BigFloat(2.45, 200) # turn a Float64 into a BigFloat
2.45000000000000017763568394002504646778106689453125
julia> BigFloat("2.45", 200) # parse "2.45" as a BigFloat
2.4500000000000000000000000000000000000000000000000000000000005
I was going to suggest sympify("2.45") to avoid the conversion to a float within julia before SymPy has a chance to do something, but this has the same issue. Scanning the docs, I see you can use Float passing a string (similar to the big constructor):
evalf
seems to convert the argument to Float64 and then extend its precision. I would expectevalf
to behave like the last command in the example below. Is my expectation incorrect?This is with [24249f21] SymPy v1.0.28.
Probably related to #369.
The text was updated successfully, but these errors were encountered: