-
Notifications
You must be signed in to change notification settings - Fork 52
Add complex number support to sqrt
#461
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
General comments since I see you start working on ufuncs that have a branch cut 🙂
|
@leofang Re: defn branch cut. I can move to the list of specification definitions. Re: same branch cuts. Currently, I am approaching this on a case-by-case basis. For However, one possible idea I entertained is that for functions having branch cuts (apart from fcns with unanimous conventions, such as If we find that, for all practical purposes, array libraries all adhere to the same branch cuts, we could move from provisional to non-provisional in a later revision of the standard. |
This still needs the refactoring and marking of branch cut as provisional. I don't see any concerns with getting it merged. |
Updated to include a warning documenting that the choice of branch cut is under provisional status and moved the definition of a branch cut to the list of specification definitions. This PR should be ready for final review. |
Updated the PR by adding a discussion concerning branch cuts to design topics and linking back to the document from This PR should be ready for another review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The page on branch cuts looks good to me.
The page for the sqrt
docs shows that the content there needs some refactoring. The description of parameters and returns is not visible above the fold. So we're obscuring the main info with details that very few people will care about. Can we please move all the special cases to a Notes
section below Parameters
and Returns
?
Moving special cases to somewhere else can be done, but this should be in a follow-up PR and apply to all relevant functions in the specification, as this is generally applicable throughout the specification. |
Created an issue for reorganizing documentation content (see gh-518). The tentative plan is to reorganize content in one fell swoop, rather than begin reorganizing content in a piecemeal fashion beginning with this PR. As such, as this PR has been discussed in consortium meetings and no objections have been raised concerning the branch cut here or elsewhere, will merge. As this PR contains the design topic on branch cuts, by merging this PR, we'll unblock other PRs which need to refer to this document. Any further changes can be addressed in follow-up PRs. |
This PR
sqrt
by documenting special cases. By convention, the square root has a single branch cut, which is defined as the real interval(-infinity, 0)
.