algebra-4.3.1: Constructive abstract algebra

Safe HaskellSafe
LanguageHaskell98

Numeric.Field.Fraction

Synopsis

Documentation

data Fraction d Source #

Fraction field k(D) of GCDDomain domain D.

Instances

GCDDomain d => RightModule Integer (Fraction d) Source # 

Methods

(*.) :: Fraction d -> Integer -> Fraction d Source #

GCDDomain d => RightModule Natural (Fraction d) Source # 

Methods

(*.) :: Fraction d -> Natural -> Fraction d Source #

GCDDomain d => LeftModule Integer (Fraction d) Source # 

Methods

(.*) :: Integer -> Fraction d -> Fraction d Source #

GCDDomain d => LeftModule Natural (Fraction d) Source # 

Methods

(.*) :: Natural -> Fraction d -> Fraction d Source #

(Eq d, GCDDomain d) => Eq (Fraction d) Source # 

Methods

(==) :: Fraction d -> Fraction d -> Bool #

(/=) :: Fraction d -> Fraction d -> Bool #

(Ord d, GCDDomain d) => Ord (Fraction d) Source # 

Methods

compare :: Fraction d -> Fraction d -> Ordering #

(<) :: Fraction d -> Fraction d -> Bool #

(<=) :: Fraction d -> Fraction d -> Bool #

(>) :: Fraction d -> Fraction d -> Bool #

(>=) :: Fraction d -> Fraction d -> Bool #

max :: Fraction d -> Fraction d -> Fraction d #

min :: Fraction d -> Fraction d -> Fraction d #

(Eq d, Show d, Unital d) => Show (Fraction d) Source # 

Methods

showsPrec :: Int -> Fraction d -> ShowS #

show :: Fraction d -> String #

showList :: [Fraction d] -> ShowS #

GCDDomain d => Abelian (Fraction d) Source # 
GCDDomain d => Additive (Fraction d) Source # 

Methods

(+) :: Fraction d -> Fraction d -> Fraction d Source #

sinnum1p :: Natural -> Fraction d -> Fraction d Source #

sumWith1 :: Foldable1 f => (a -> Fraction d) -> f a -> Fraction d Source #

GCDDomain d => Monoidal (Fraction d) Source # 

Methods

zero :: Fraction d Source #

sinnum :: Natural -> Fraction d -> Fraction d Source #

sumWith :: Foldable f => (a -> Fraction d) -> f a -> Fraction d Source #

GCDDomain d => Semiring (Fraction d) Source # 
GCDDomain d => Multiplicative (Fraction d) Source # 

Methods

(*) :: Fraction d -> Fraction d -> Fraction d Source #

pow1p :: Fraction d -> Natural -> Fraction d Source #

productWith1 :: Foldable1 f => (a -> Fraction d) -> f a -> Fraction d Source #

GCDDomain d => Group (Fraction d) Source # 
GCDDomain d => Unital (Fraction d) Source # 

Methods

one :: Fraction d Source #

pow :: Fraction d -> Natural -> Fraction d Source #

productWith :: Foldable f => (a -> Fraction d) -> f a -> Fraction d Source #

GCDDomain d => Division (Fraction d) Source # 
GCDDomain d => Commutative (Fraction d) Source # 
GCDDomain d => DecidableAssociates (Fraction d) Source # 
GCDDomain d => DecidableUnits (Fraction d) Source # 
GCDDomain d => DecidableZero (Fraction d) Source # 

Methods

isZero :: Fraction d -> Bool Source #

GCDDomain d => Rig (Fraction d) Source # 
(Characteristic d, GCDDomain d) => Characteristic (Fraction d) Source # 

Methods

char :: proxy (Fraction d) -> Natural Source #

GCDDomain d => Ring (Fraction d) Source # 
GCDDomain d => ZeroProductSemiring (Fraction d) Source # 
GCDDomain d => UnitNormalForm (Fraction d) Source # 

Methods

splitUnit :: Fraction d -> (Fraction d, Fraction d) Source #

GCDDomain d => Euclidean (Fraction d) Source # 
GCDDomain d => PID (Fraction d) Source # 

Methods

egcd :: Fraction d -> Fraction d -> (Fraction d, Fraction d, Fraction d) Source #

GCDDomain d => UFD (Fraction d) Source # 
GCDDomain d => GCDDomain (Fraction d) Source # 
GCDDomain d => IntegralDomain (Fraction d) Source # 

type Ratio = Fraction Source #

Convenient synonym for Fraction.

(%) :: GCDDomain d => d -> d -> Fraction d infixl 7 Source #