Documentation moved.
This entry is documented with its primary interface. Open the documentation →
Function
src/index.ts:1207nerdamer.arg
nerdamer.arg(x: ExpressionInput): ExpressionReturns the principal argument of a complex expression.
Details
Nerdamer deliberately follows the WolframAlpha convention arg(0) = 0, matching the zero-angle choice in toPolarFormArray(). In contrast, SymPy returns nan for arg(0), and NIST DLMF §4.2 leaves the argument of zero undefined because zero has no direction. See https://dlmf.nist.gov/4.2.
Parameters
| Name | Type | Description |
|---|---|---|
x | ExpressionInput | The expression whose principal argument is requested |
Returns
Expression — The principal argument, or zero when x is zero
