AERN-Real-0.9.5: arbitrary precision interval arithmetic for approximating exact real numbers

Portabilityportable
Stabilityexperimental
Maintainermik@konecny.aow.cz

Data.Number.ER.Real.DomainBox

Description

Abstractions of the Box datatype, often used to represent sections of multi-dimensional function domains.

To be imported qualified, usually with prefix DBox.

VariableID(..) and DomainBox are usually imported separately and not qualified.

Synopsis

Documentation

class Ord varid => VariableID varid whereSource

A class abstracting a type of variable identifiers for axes in function domains, polynomials etc.

Methods

newVarID :: Set varid -> varidSource

defaultVar :: varidSource

showVar :: varid -> StringSource

Instances

class VariableID varid => DomainBox box varid ira | box -> varid ira, varid ira -> box whereSource

A class abstracting a type of many-dimensional points or intervals.

Methods

noinfo :: boxSource

isNoinfo :: box -> BoolSource

unary :: ira -> boxSource

constructor using defaultVar

singleton :: varid -> ira -> boxSource

toList :: box -> [(varid, ira)]Source

fromList :: [(varid, ira)] -> boxSource

toAscList :: box -> [(varid, ira)]Source

fromAscList :: [(varid, ira)] -> boxSource

toMap :: box -> Map varid iraSource

fromMap :: Map varid ira -> boxSource

insert :: varid -> ira -> box -> boxSource

insertWith :: (ira -> ira -> ira) -> varid -> ira -> box -> boxSource

delete :: varid -> box -> boxSource

member :: varid -> box -> BoolSource

notMember :: varid -> box -> BoolSource

union :: box -> box -> boxSource

unionWith :: (ira -> ira -> ira) -> box -> box -> boxSource

keys :: box -> [varid]Source

elems :: box -> [ira]Source

map :: (ira -> ira) -> box -> boxSource

fold :: (ira -> a -> a) -> a -> box -> aSource

foldWithKey :: (varid -> ira -> a -> a) -> a -> box -> aSource

zipWith :: (ira -> ira -> a) -> box -> box -> [(varid, a)]Source

intersectionWith :: (ira -> ira -> ira) -> box -> box -> boxSource

findWithDefault :: ira -> varid -> box -> iraSource

lookupSource

Arguments

:: String

identification of caller location to use in error messages

-> varid 
-> box 
-> ira 

Pick the extents of a single variable in a domain box. If there is no information for this variable, assume the variable ranges over the whole real line.

Instances

Show ira => DomainBox (Box ira) VarID ira 

class DomainBox box varid ira => DomainIntBox box varid ira | box -> varid ira, varid ira -> box whereSource

A class abstracting a type of many-dimensional intervals.

Methods

compatible :: box -> box -> BoolSource

Check whether the two domains specify the same interval for each variable that they share.

unifySource

Arguments

:: String

identification of caller location to use in error messages

-> box 
-> box 
-> box 

Assuming that two domains are compatible, take the most information from both of the domains about the ranges of variables.

bestSplit :: box -> (varid, ira)Source

Find the variable with the largest interval and return it together with the default splitting point in its domain.

classifyPositionSource

Arguments

:: box

domain d1

-> box

domain d2

-> (Bool, Bool, Bool, Bool)

Answers to these (mutually exclusive) questions:

  • is d1 outside and not touching d2?
  • is d1 outside and touching d2?
  • is d1 intersecting and not inside d2?
  • is d1 inside d2?

Instances

ERIntApprox ira => DomainIntBox (Box ira) VarID ira