Function reference · Complex
csgn
Returns the complex sign used by Nerdamer's branch-sensitive simplification rules.
csgn returns 1 when the real part is positive and -1 when the real part is negative. If the real part is zero, it uses the sign of the imaginary part. Zero returns 0.
When the sign cannot be determined symbolically, Nerdamer keeps csgn(...) unevaluated. The same operation is available directly as nerdamer.csgn(...).
Examples
These examples use Nerdamer Notation.
Use the sign of a positive real part.
csgn(3+2*i) // → 1
Use the sign of a negative real part.
csgn(-3+2*i) // → -1
Keep an unresolved symbolic complex sign.
csgn(x+2*i)Interfaces
The same operation is available through the interfaces below.
Nerdamer Notation
Use this form inside input passed to nerdamer(...).
csgn(arg1)
