In hoc signo vinces (Was: Revamping the numeric classes)

Jerzy Karczmarczuk
Fri, 09 Feb 2001 10:52:39 +0000

Marcin 'Qrczak' Kowalczyk wrote:

> JK> Now, signum and abs seem to be quite distincts beasts. Signum seem
> JK> to require Ord (and a generic zero...).
> Signum doesn't require Ord.
>     signum z = z / abs z
> for complex numbers.

Thank you, I know. And I ignore it. Calling "signum" the result of
a vector normalization (on the gauss plane in this case) is something
I don't really appreciate, and I wonder why this definition infiltrated
the prelude. Just because it conforms to the "normal" definition of
signum for reals?

Again, a violation of the orthogonality principle. Needing division
just to define signum. And of course a completely different approach
do define the signum of integers. Or of polynomials...

Jerzy Karczmarczuk