halg-core-0.6.0.0: Core types and functions of halg computational algebra suite.
Safe HaskellNone
LanguageHaskell2010

Algebra.Scalar

Synopsis

Documentation

newtype Scalar r Source #

Scalar r provides almost the same type-instances as r, but it can also behave as a Module over r itself.

Constructors

Scalar 

Fields

Instances

Instances details
RightModule Integer r => RightModule Integer (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(*.) :: Scalar r -> Integer -> Scalar r #

RightModule Natural r => RightModule Natural (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(*.) :: Scalar r -> Natural -> Scalar r #

Semiring r => RightModule r (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(*.) :: Scalar r -> r -> Scalar r #

LeftModule Integer r => LeftModule Integer (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(.*) :: Integer -> Scalar r -> Scalar r #

LeftModule Natural r => LeftModule Natural (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(.*) :: Natural -> Scalar r -> Scalar r #

Semiring r => LeftModule r (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(.*) :: r -> Scalar r -> Scalar r #

Enum r => Enum (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

succ :: Scalar r -> Scalar r #

pred :: Scalar r -> Scalar r #

toEnum :: Int -> Scalar r #

fromEnum :: Scalar r -> Int #

enumFrom :: Scalar r -> [Scalar r] #

enumFromThen :: Scalar r -> Scalar r -> [Scalar r] #

enumFromTo :: Scalar r -> Scalar r -> [Scalar r] #

enumFromThenTo :: Scalar r -> Scalar r -> Scalar r -> [Scalar r] #

Eq r => Eq (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(==) :: Scalar r -> Scalar r -> Bool #

(/=) :: Scalar r -> Scalar r -> Bool #

Fractional r => Fractional (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(/) :: Scalar r -> Scalar r -> Scalar r #

recip :: Scalar r -> Scalar r #

fromRational :: Rational -> Scalar r #

Integral r => Integral (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

quot :: Scalar r -> Scalar r -> Scalar r #

rem :: Scalar r -> Scalar r -> Scalar r #

div :: Scalar r -> Scalar r -> Scalar r #

mod :: Scalar r -> Scalar r -> Scalar r #

quotRem :: Scalar r -> Scalar r -> (Scalar r, Scalar r) #

divMod :: Scalar r -> Scalar r -> (Scalar r, Scalar r) #

toInteger :: Scalar r -> Integer #

Num r => Num (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(+) :: Scalar r -> Scalar r -> Scalar r #

(-) :: Scalar r -> Scalar r -> Scalar r #

(*) :: Scalar r -> Scalar r -> Scalar r #

negate :: Scalar r -> Scalar r #

abs :: Scalar r -> Scalar r #

signum :: Scalar r -> Scalar r #

fromInteger :: Integer -> Scalar r #

Ord r => Ord (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

compare :: Scalar r -> Scalar r -> Ordering #

(<) :: Scalar r -> Scalar r -> Bool #

(<=) :: Scalar r -> Scalar r -> Bool #

(>) :: Scalar r -> Scalar r -> Bool #

(>=) :: Scalar r -> Scalar r -> Bool #

max :: Scalar r -> Scalar r -> Scalar r #

min :: Scalar r -> Scalar r -> Scalar r #

Read r => Read (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Real r => Real (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

toRational :: Scalar r -> Rational #

Show r => Show (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

showsPrec :: Int -> Scalar r -> ShowS #

show :: Scalar r -> String #

showList :: [Scalar r] -> ShowS #

UnitNormalForm r => UnitNormalForm (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

splitUnit :: Scalar r -> (Scalar r, Scalar r) #

Ring r => Ring (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

fromInteger :: Integer -> Scalar r

Rig r => Rig (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

fromNatural :: Natural -> Scalar r #

DecidableUnits r => DecidableUnits (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

recipUnit :: Scalar r -> Maybe (Scalar r) #

isUnit :: Scalar r -> Bool #

(^?) :: Integral n => Scalar r -> n -> Maybe (Scalar r) #

DecidableAssociates r => DecidableAssociates (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

isAssociate :: Scalar r -> Scalar r -> Bool #

Unital r => Unital (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

one :: Scalar r #

pow :: Scalar r -> Natural -> Scalar r #

productWith :: Foldable f => (a -> Scalar r) -> f a -> Scalar r #

Division r => Division (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

recip :: Scalar r -> Scalar r #

(/) :: Scalar r -> Scalar r -> Scalar r #

(\\) :: Scalar r -> Scalar r -> Scalar r #

(^) :: Integral n => Scalar r -> n -> Scalar r

Commutative r => Commutative (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Semiring r => Semiring (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Multiplicative r => Multiplicative (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(*) :: Scalar r -> Scalar r -> Scalar r #

pow1p :: Scalar r -> Natural -> Scalar r #

productWith1 :: Foldable1 f => (a -> Scalar r) -> f a -> Scalar r #

Monoidal r => Monoidal (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

zero :: Scalar r #

sinnum :: Natural -> Scalar r -> Scalar r #

sumWith :: Foldable f => (a -> Scalar r) -> f a -> Scalar r #

Group r => Group (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(-) :: Scalar r -> Scalar r -> Scalar r #

negate :: Scalar r -> Scalar r #

subtract :: Scalar r -> Scalar r -> Scalar r #

times :: Integral n => n -> Scalar r -> Scalar r #

Additive r => Additive (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(+) :: Scalar r -> Scalar r -> Scalar r #

sinnum1p :: Natural -> Scalar r -> Scalar r #

sumWith1 :: Foldable1 f => (a -> Scalar r) -> f a -> Scalar r #

Abelian r => Abelian (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Normed r => Normed (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Associated Types

type Norm (Scalar r) Source #

Methods

norm :: Scalar r -> Norm (Scalar r) Source #

liftNorm :: Norm (Scalar r) -> Scalar r Source #

Semiring r => RightModule (Scalar r) (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(*.) :: Scalar r -> Scalar r -> Scalar r #

(Semiring r, Integral r) => RightModule (Scalar r) (Ratio r) Source # 
Instance details

Defined in Algebra.Instances

Methods

(*.) :: Ratio r -> Scalar r -> Ratio r #

Semiring r => LeftModule (Scalar r) (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

Methods

(.*) :: Scalar r -> Scalar r -> Scalar r #

(Semiring r, Integral r) => LeftModule (Scalar r) (Ratio r) Source # 
Instance details

Defined in Algebra.Instances

Methods

(.*) :: Scalar r -> Ratio r -> Ratio r #

type Norm (Scalar r) Source # 
Instance details

Defined in Algebra.Scalar

type Norm (Scalar r) = Norm r

(.*.) :: Module (Scalar r) m => r -> m -> m infixr 8 Source #