- package:numeric-prelude
x -| y == max 0 (x-y)
The default implementation is not efficient, because it compares the
values and then subtracts, again, if safe.
max 0 (x-y) is
more elegant and efficient but not possible in the general case, since
x-y may already yield a negative number.
Construct a complex number with negated imaginary part.
An experimental alternative hierarchy of numeric type classes
The package provides an experimental alternative hierarchy of numeric
type classes. The type classes are more oriented at mathematical
structures and their methods come with laws that the instances must
fulfill.