Safe Haskell | None |
---|---|

Language | Haskell2010 |

Metric structure

- class Metric a b where
- class Normed a b where
- class (AdditiveUnital a, AdditiveGroup a, MultiplicativeUnital a) => Signed a where
- class AdditiveGroup a => Epsilon a where
- (≈) :: Epsilon a => a -> a -> Bool

# Metric

class Normed a b where Source #

Normed is a current wart on the NumHask api, causing all sorts of runaway constraint boiler-plate.

class (AdditiveUnital a, AdditiveGroup a, MultiplicativeUnital a) => Signed a where Source #

abs and signnum are warts on the standard `Num`

class, and are separated here to provide a cleaner structure.

class AdditiveGroup a => Epsilon a where Source #

This should probably be split off into some sort of alternative Equality logic, but to what end?