AngouriMath

Navigation

← Back to list of members

PullArccotan​(AngouriMath.​Entity.​Number.​Complex,​AngouriMath.​Entity@)

 Method (no overloads)

Summary

arccotan(x) here is arctan(1/x), with range (-pi/2, pi/2] — not
the textbook (0, pi).
So the complement is pi/2 - arctan(x) for a
non-negative argument and -pi/2 - arctan(x) for a negative one.

Remarks

This read pi/2 - arctan(x) for every argument, which is the textbook identity and
is wrong on every negative one: arccotan(-1) came back as 3/4 * pi where the function's own value is -pi/4, so Simplify(System.Int32) and EvalNumerical disagreed about a closed-form constant. Measured at the three
arguments that settle a range: arccotan(1) is 0.785…, arccotan(-1) is -0.785… and arccotan(0) is 1.570…, so the range is
(-pi/2, pi/2] and the function is odd away from zero.
The docstring it replaces claimed to take "the same reading of it the simplification
rule for arctan(x) + arccotan(x) already takes". That rule answers pi/2 for a non-negative argument and -pi/2 for a negative one
(#887) — so the
two readings were opposite, and the comment asserting they agreed is what let it stand.

























Angouri © 2019-2023 · Project's repo · Site's repo · Octicons · Transparency · 4378 pages online