8000 Add complex number support to `log` by kgryte · Pull Request #514 · data-apis/array-api · GitHub
[go: up one dir, main page]

Skip to content

Add complex number support to log #514

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

Merged
merged 5 commits into from
Dec 13, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix equation
Co-authored-by: Aaron Meurer <asmeurer@gmail.com>
  • Loading branch information
kgryte and asmeurer authored Dec 1, 2022
commit d0a8ec501712ad7adfb270be60506b333668028c
2 changes: 1 addition & 1 deletion spec/API_specification/array_api/elementwise_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -933,7 +933,7 @@ def log(x: array, /) -> array:
- If ``a`` is ``NaN`` and ``b`` is ``NaN``, the result is ``NaN + NaN j``.

.. note::
The natural logarithm of a complex number :math:`z` with polar coordinates :math:`(r,\theta)` equals :math:`\ln r + (θ+ 2n\pi)j` with principal value :math:`\ln r + \theta j`.
The natural logarithm of a complex number :math:`z` with polar coordinates :math:`(r,\theta)` equals :math:`\ln r + (\theta + 2n\pi)j` with principal value :math:`\ln r + \theta j`.

.. note::
For complex floating-point operands, ``log(conj(x))`` must equal ``conj(log(x))``.
Expand Down
0