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 mark.dickinson
Recipients docs@python, mark.dickinson, rhettinger
Date 2020-07-08.18:51:22
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1594234282.87.0.273102613267.issue41245@roundup.psfhosted.org>
In-reply-to
Content
Yes, that looks like the right part of the sqrt code.

For the acos docstring, "continuous from below" implies that for any complex number z that lies exactly _on_ the branch cut, acos(z) is close to acos(w) for a nearby value w just _below_ the branch cut. But that's demonstrably not true: see the change of sign in the real part below:

>>> acos(complex(2.3, -1e-10))  # value just "below" the branch cut
(4.828045495852677e-11+1.475044781241425j)
>>> acos(complex(2.3, 0.0))  # nearby value exactly _on_ the branch cut
-1.475044781241425j

In effect, for a branch cut along the real axis, the sign of the zero in the imaginary part of the argument allows us to be continuous from both sides at once.
History
Date User Action Args
2020-07-08 18:51:22mark.dickinsonsetrecipients: + mark.dickinson, rhettinger, docs@python
2020-07-08 18:51:22mark.dickinsonsetmessageid: <1594234282.87.0.273102613267.issue41245@roundup.psfhosted.org>
2020-07-08 18:51:22mark.dickinsonlinkissue41245 messages
2020-07-08 18:51:22mark.dickinsoncreate