synthesizer-llvm-1.1.0.1: Efficient signal processing using runtime compilation

Safe HaskellNone
LanguageHaskell98

Synthesizer.LLVM.Complex

Contents

Synopsis

Documentation

data T a #

Complex numbers are an algebraic type.

Instances
Functor T 
Instance details

Defined in Number.Complex

Methods

fmap :: (a -> b) -> T a -> T b #

(<$) :: a -> T b -> T a #

C T 
Instance details

Defined in Number.Complex

Methods

zero :: C a => T a #

(<+>) :: C a => T a -> T a -> T a #

(*>) :: C a => a -> T a -> T a #

Sqr a b => Sqr a (T b) 
Instance details

Defined in Number.Complex

Methods

normSqr :: T b -> a #

(C a, Sqr a b) => C a (T b) 
Instance details

Defined in Number.Complex

Methods

norm :: T b -> a #

(Ord a, C a v) => C a (T v) 
Instance details

Defined in Number.Complex

Methods

norm :: T v -> a #

(C a, C a v) => C a (T v) 
Instance details

Defined in Number.Complex

Methods

norm :: T v -> a #

(Show v, C v, C v, C a v) => C a (T v) 
Instance details

Defined in Number.Complex

Methods

toScalar :: T v -> a #

toMaybeScalar :: T v -> Maybe a #

fromScalar :: a -> T v #

C a b => C a (T b) 
Instance details

Defined in Number.Complex

C a b => C a (T b)

The '(*>)' method can't replace scale because it requires the Algebra.Module constraint

Instance details

Defined in Number.Complex

Methods

(*>) :: a -> T b -> T b #

Eq a => Eq (T a) 
Instance details

Defined in Number.Complex

Methods

(==) :: T a -> T a -> Bool #

(/=) :: T a -> T a -> Bool #

(Floating a, Eq a) => Fractional (T a) 
Instance details

Defined in Number.Complex

Methods

(/) :: T a -> T a -> T a #

recip :: T a -> T a #

fromRational :: Rational -> T a #

(Floating a, Eq a) => Num (T a) 
Instance details

Defined in Number.Complex

Methods

(+) :: T a -> T a -> T a #

(-) :: T a -> T a -> T a #

(*) :: T a -> T a -> T a #

negate :: T a -> T a #

abs :: T a -> T a #

signum :: T a -> T a #

fromInteger :: Integer -> T a #

Read a => Read (T a) 
Instance details

Defined in Number.Complex

Methods

readsPrec :: Int -> ReadS (T a) #

readList :: ReadS [T a] #

readPrec :: ReadPrec (T a) #

readListPrec :: ReadPrec [T a] #

Show a => Show (T a) 
Instance details

Defined in Number.Complex

Methods

showsPrec :: Int -> T a -> ShowS #

show :: T a -> String #

showList :: [T a] -> ShowS #

Arbitrary a => Arbitrary (T a) 
Instance details

Defined in Number.Complex

Methods

arbitrary :: Gen (T a) #

shrink :: T a -> [T a] #

Storable a => Storable (T a) 
Instance details

Defined in Number.Complex

Methods

sizeOf :: T a -> Int #

alignment :: T a -> Int #

peekElemOff :: Ptr (T a) -> Int -> IO (T a) #

pokeElemOff :: Ptr (T a) -> Int -> T a -> IO () #

peekByteOff :: Ptr b -> Int -> IO (T a) #

pokeByteOff :: Ptr b -> Int -> T a -> IO () #

peek :: Ptr (T a) -> IO (T a) #

poke :: Ptr (T a) -> T a -> IO () #

(C a, C a, C a, Power a) => C (T a) 
Instance details

Defined in Number.Complex

Methods

pi :: T a #

exp :: T a -> T a #

log :: T a -> T a #

logBase :: T a -> T a -> T a #

(**) :: T a -> T a -> T a #

sin :: T a -> T a #

cos :: T a -> T a #

tan :: T a -> T a #

asin :: T a -> T a #

acos :: T a -> T a #

atan :: T a -> T a #

sinh :: T a -> T a #

cosh :: T a -> T a #

tanh :: T a -> T a #

asinh :: T a -> T a #

acosh :: T a -> T a #

atanh :: T a -> T a #

(C a, C a, Power a) => C (T a) 
Instance details

Defined in Number.Complex

Methods

sqrt :: T a -> T a #

root :: Integer -> T a -> T a #

(^/) :: T a -> Rational -> T a #

C a => C (T a) 
Instance details

Defined in Number.Complex

Methods

(/) :: T a -> T a -> T a #

recip :: T a -> T a #

fromRational' :: Rational -> T a #

(^-) :: T a -> Integer -> T a #

(C a, C a, C a) => C (T a) 
Instance details

Defined in Number.Complex

Methods

abs :: T a -> T a #

signum :: T a -> T a #

(Ord a, C a, C a) => C (T a) 
Instance details

Defined in Number.Complex

Methods

extendedGCD :: T a -> T a -> (T a, (T a, T a)) #

gcd :: T a -> T a -> T a #

lcm :: T a -> T a -> T a #

(Ord a, C a) => C (T a) 
Instance details

Defined in Number.Complex

Methods

isUnit :: T a -> Bool #

stdAssociate :: T a -> T a #

stdUnit :: T a -> T a #

stdUnitInv :: T a -> T a #

C a => C (T a) 
Instance details

Defined in Number.Complex

Methods

div :: T a -> T a -> T a #

mod :: T a -> T a -> T a #

divMod :: T a -> T a -> (T a, T a) #

C a => C (T a) 
Instance details

Defined in Number.Complex

Methods

(*) :: T a -> T a -> T a #

one :: T a #

fromInteger :: Integer -> T a #

(^) :: T a -> Integer -> T a #

C a => C (T a) 
Instance details

Defined in Number.Complex

Methods

isZero :: T a -> Bool #

C a => C (T a) 
Instance details

Defined in Number.Complex

Methods

zero :: T a #

(+) :: T a -> T a -> T a #

(-) :: T a -> T a -> T a #

negate :: T a -> T a #

C a => C (T a) 
Instance details

Defined in Number.Complex

Methods

compare :: T a -> T a -> Ordering #

C a => C (T a) 
Instance details

Defined in Synthesizer.LLVM.Complex

Methods

pack :: T a -> Struct (T a)

unpack :: Struct (T a) -> T a

C l => C (T l) 
Instance details

Defined in Synthesizer.LLVM.Complex

Associated Types

type Struct (T l) :: Type

Methods

load :: Value (Ptr (Struct (T l))) -> CodeGenFunction r (T l)

store :: T l -> Value (Ptr (Struct (T l))) -> CodeGenFunction r ()

decompose :: Value (Struct (T l)) -> CodeGenFunction r (T l)

compose :: T l -> CodeGenFunction r (Value (Struct (T l)))

C a => C (T a) 
Instance details

Defined in Synthesizer.LLVM.Complex

Associated Types

type Repr (T a) :: Type

Methods

cons :: T a -> T0 (T a)

undef :: T0 (T a)

zero :: T0 (T a)

phi :: BasicBlock -> T0 (T a) -> CodeGenFunction r (T0 (T a))

addPhi :: BasicBlock -> T0 (T a) -> T0 (T a) -> CodeGenFunction r ()

Phi a => Phi (T a) 
Instance details

Defined in Synthesizer.LLVM.Complex

Methods

phi :: BasicBlock -> T a -> CodeGenFunction r (T a)

addPhi :: BasicBlock -> T a -> T a -> CodeGenFunction r ()

Undefined a => Undefined (T a) 
Instance details

Defined in Synthesizer.LLVM.Complex

Methods

undef :: T a

Flatten a => Flatten (T a) 
Instance details

Defined in LLVM.DSL.Value

Associated Types

type Registers (T a) :: Type #

Methods

flattenCode :: T a -> Compute r (Registers (T a)) #

unfoldCode :: T0 (Registers (T a)) -> T a #

Aggregate ae al => Aggregate (T ae) (T al) 
Instance details

Defined in LLVM.DSL.Expression

Associated Types

type MultiValuesOf (T ae) :: Type

type ExpressionsOf (T al) :: Type

Methods

bundle :: T ae -> CodeGenFunction r (T al)

dissect :: T al -> T ae

type Struct (T l) 
Instance details

Defined in Synthesizer.LLVM.Complex

type Struct (T l) = Struct (Struct l)
type Repr (T a) 
Instance details

Defined in Synthesizer.LLVM.Complex

type Repr (T a) = T (Repr a)
type ExpressionsOf (T al) 
Instance details

Defined in LLVM.DSL.Expression

type ExpressionsOf (T al) = T (ExpressionsOf al)
type MultiValuesOf (T ae) 
Instance details

Defined in LLVM.DSL.Expression

type MultiValuesOf (T ae) = T (MultiValuesOf ae)
type Registers (T a) 
Instance details

Defined in LLVM.DSL.Value

type Registers (T a) = T (Registers a)

type Struct a = Struct (a, (a, ())) Source #

(+:) :: a -> a -> T a infix 6 #

Construct a complex number from real and imaginary part.

cis :: C a => a -> T a #

cis t is a complex value with magnitude 1 and phase t (modulo 2*pi).

scale :: C a => a -> T a -> T a #

Scale a complex number by a real number.

constOf :: IsConst a => T a -> ConstValue (Struct a) Source #

unfold :: Value (Struct a) -> T (T (Value a)) Source #

Orphan instances

C a => C (T a) Source # 
Instance details

Methods

pack :: T a -> Struct (T a)

unpack :: Struct (T a) -> T a

C l => C (T l) Source # 
Instance details

Associated Types

type Struct (T l) :: Type

Methods

load :: Value (Ptr (Struct (T l))) -> CodeGenFunction r (T l)

store :: T l -> Value (Ptr (Struct (T l))) -> CodeGenFunction r ()

decompose :: Value (Struct (T l)) -> CodeGenFunction r (T l)

compose :: T l -> CodeGenFunction r (Value (Struct (T l)))

C a => C (T a) Source # 
Instance details

Associated Types

type Repr (T a) :: Type

Methods

cons :: T a -> T0 (T a)

undef :: T0 (T a)

zero :: T0 (T a)

phi :: BasicBlock -> T0 (T a) -> CodeGenFunction r (T0 (T a))

addPhi :: BasicBlock -> T0 (T a) -> T0 (T a) -> CodeGenFunction r ()

Phi a => Phi (T a) Source # 
Instance details

Methods

phi :: BasicBlock -> T a -> CodeGenFunction r (T a)

addPhi :: BasicBlock -> T a -> T a -> CodeGenFunction r ()

Undefined a => Undefined (T a) Source # 
Instance details

Methods

undef :: T a