This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author tim.peters
Recipients mark.dickinson, martin.panter, ned.deily, rhettinger, serhiy.storchaka, steven.daprano, tim.peters, vstinner
Date 2016-09-02.02:07:31
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1472782051.38.0.731172031082.issue27761@psf.upfronthosting.co.za>
In-reply-to
Content
BTW, add this other way of writing a native-precision Newton step to see that it's much worse (numerically) than writing it in the "guess + small_correction" form used in roots.py.  Mathematically they're identical, but numerically they behave differently:


def native2(x, n):
    g = x**(1.0/n)
    if g**n == x:
        return g
    return ((n-1)*g + x/g**(n-1)) / n
History
Date User Action Args
2016-09-02 02:07:31tim.peterssetrecipients: + tim.peters, rhettinger, mark.dickinson, vstinner, ned.deily, steven.daprano, martin.panter, serhiy.storchaka
2016-09-02 02:07:31tim.peterssetmessageid: <1472782051.38.0.731172031082.issue27761@psf.upfronthosting.co.za>
2016-09-02 02:07:31tim.peterslinkissue27761 messages
2016-09-02 02:07:31tim.peterscreate