next up previous contents index
Next: PartiallyOrderedType Up: OrderedArithmeticType Previous: abs   Contents   Index


sign


Usage

sign x


Signature

sign: % $\to$ MachineInteger


Parameter Type Description
x % an element of the type


Returns

Returns $1$ if $x > 0$, $0$ if $x = 0$ and $-1$ if $x < 0$.



Manuel Bronstein 2004-06-28