<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">On Thu, Aug 30, 2018 at 5:11 AM Jonathan Fine <<a href="mailto:jfine2358@gmail.com">jfine2358@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Neil<br>
<br>
We wrote<br>
<br>
>> This gives the same results as Python's Fraction, except for your<br>
>> example [6]. There, it gives the Fraction(0) you ask for.<br>
>><br>
>> If the smart mathematicians and computer scientists that wrote gp/pari<br>
>> get the same answers, it suggests to me that improvement would be<br>
>> hard.<br>
<br>
> That's because these are just floating point numbers. These are not being<br>
> processed symbolically. Wolfram Alpha gives all three roots, including the<br>
> real root.<br>
<br>
I've not used Wolfram Alpha, nor I think have many people on this<br>
list. Please copy and paste the input and output from Alpha, so we can<br>
see for ourselves (and so there's a record on this list).<br></blockquote><div><br></div><div>It's online for everyone to use: <a href="http://www.wolframalpha.com/input/?i=(-1)+%5E+(1%2F3">http://www.wolframalpha.com/input/?i=(-1)+%5E+(1%2F3</a>)</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
If anyone has time and ready access, it would help to know what<br>
<a href="https://www.sympy.org/en/index.html" rel="noreferrer" target="_blank">https://www.sympy.org/en/index.html</a> does with this.<br>
<br>
Perhaps your innocent request conceals a request for symbolic handling<br>
of simple algebraic numbers.<br></blockquote><div><br></div><div>Well, rational numbers. Although an algebraic number type would be interesting. And, the way I see it, Fraction is the type corresponding to the field of rational numbers.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
-- <br>
best regards<br>
<br>
Jonathan<br>
</blockquote></div></div>