Ix94      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJK LMNOPQRSTUV W X Y Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s tuvwxyz{|}~overview of AERN-RnToRm non-portable (requires fenv.h) experimentalmik@konecny.aow.czP  addressing and modifying leaves portable experimentalmik@konecny.aow.cz3A representation of a binary tree with a hole that  can be efficiently filled. A path in a binary tree. ) It is used mainly in connection with BisectionTree.BisectionTree. @Assuming that bisection happens at default points as defined by  * and starts from the given root interval. @Lookup a subdomain of a function according to a bisection path. B Return the restrited function as well as a zipper that allows ? an efficient modification of the function on the looked up  subdomain. 3Modify a function in its subdomain as expressed by  the zipper.  hierarchical domain partitions portable experimentalmik@konecny.aow.czx+value splitter function - parameters are: : depth, domain of value, value, variable to split by, 4 point to split at; returns the two split values {1 The root of the tree often represents the whole R^n.  Each node splits the parent's space into two using K a specified variable (ie direction) and an optional splitting point. A By default, a split is taken at the point defined by the method  RA.bisect. :Apply a function to all values, thus creating a new tree. :Apply a function to all values, thus creating a new tree. KPerform a given action on all branches of a bisection tree, left to right. 1 (optionally now going below the given depth) KPerform a given action on all branches of a bisection tree, left to right. 1 (optionally now going below the given depth) JPerform a given action on all branches of a bisection tree, left to right 3 with the option of further branching the tree. 1 (optionally now going below the given depth) 9Ensure both trees have equal structure at the top level: = either they are all leaves or they all split at the same - direction with the same splitting point. *Also, unify the domains at the top level. <Ensure all the trees have equal structure at the top level: = either they are all leaves or they all split at the same - direction with the same splitting point. *Also, unify the domains at the top level. DCombine two bisection trees using a given value combining function. @ Where necessary, leaves are split so that the resulting tree' s structure I is the union of the two argument tree structures. Such splitting of = values in leaves is performed by the provided functions. Areturn all values in leafs (except those within some CE subtree) 3 as a list (from the leftmost to the rightmost) Areturn all values in leafs (except those within some CE subtree) 3 as a list (from the leftmost to the rightmost) Dlookup the smallest subtree whose domain covers the given rectangle depth of this node domain value estimate direction to split in point that the split is at %the half towards -Infty in split dir %the half towards +Infty in split dir CApply a function to all values, thus creating a list of new trees. #linear ordering on bisection trees &Update a value on a given sub-domain, . bisecting the tree if necessary to obtain / a better fit for the domain, but not below  a given depth limit. ?With multiple domain dimensions, split the domain according to  . wxyz{|}~{yzwx|}~;abstract zipping of domain partitions used for integration portable experimentalmik@konecny.aow.cz;Transform a bunch of bisection trees over the same domain  by  integrating" them in a very abstract sense. F The trees are unified in their splitting patterns in the process. ? By supplying certain parameters, this function can in fact F perform numerical integration of piece-wise polynomial functions. It can be also viewed as a zipping+folding$ operator over bisection trees that \ generates another bunch of bisection trees, synchronously traversing the original trees J from a certain point on a selected axis outwards in both directions,  carrying some data along. <Zip a list of bisection trees in synchrony but do something 2 else inside and not inside a given subdomain. GFurther splitting at default points will be done up to the given depth A in an attempt to separate the subdomain as well as possible. BIf the subdomain is not properly isolated by the splitting at the P maximum depth, splits are made at irregular points to ensure full isolation  of the subdomain. 3concise names for default function representations non-portable (requires fenv.h) experimentalmik@konecny.aow.cz4(internal) polynomial datatype and simple functions portable experimentalmik@konecny.aow.czDEChebyshev polynomials expressed as associative lists power -> coeff F1Convert a polynomial to a string representation, " using the ordinary x^n basis. GVChebyshev polynomials expressed as lists of integer coefficients for powers 0,1,2... H2conversion of one Chebyshev term to the X^n basis LEA polynomial represented by its coefficients it the Chebyshev basis. 8The polynomials are never to be used outside the domain [-1,1]^n. GAll operations are rounded in such a way that the resulting polynomial  is a point-wise upper or lower bound of the exact result. P4Inspect all terms of the polynomial and return the ' degree of the highest degree term. R make a basic x) polynomial for a given variable number U@conversion of polynomials from Chebyshev basis to the X^n basis E(not exact - suffering from rounding in the coefficient conversions) DEFGHIJKLMNOPQRSTUVLJMNEOPQRSTIFUHDG 0polynoms in the Chebyshev basis of the 1st kind portable experimentalmik@konecny.aow.czJKLVLKVJ 9(internal) elementary functions applied to polynomials portable experimentalmik@konecny.aow.czk2Approximate the pointwise cosine of a polynomial 4 by another polynomial from below and from above  using the tau method  as described in [Mason & Handscomb 2003, p 62]. l7Approximate the pointwise square root of a polynomial 6 by another polynomial from below and from above. m7Approximate the pointwise exponential of a polynomial 6 by another polynomial from below and from above. n[Approximate the pointwise integer power of a polynomial by another polynomial from above. o=Approximate the pointwise natural logarithm of a polynomial 6 by another polynomial from below and from above. p0Approximate the pointwise sine of a polynomial 5 by another polynomial from below and from above. %Assuming the polynomial range is [-pi2, pi2]. q0Approximate the pointwise sine of a polynomial 5 by another polynomial from below and from above. %Assuming the polynomial range is [-pi2, pi2]. s=Approximate the pointwise natural logarithm of a polynomial 6 by another polynomial from below and from above. klmnopqrs lmnopqrsk 5(internal) field operations applied to polynomials portable experimentalmik@konecny.aow.czWBmultiply a polynomial by a scalar rounding downwards and upwards XQConvert a polynomial to a lower-order one that is dominated by (resp. dominates) " it closely on the domain [-1,1]. ZKmultiply a polynomial by a scalar interval rounding downwards and upwards WXYZYXWZ,(internal) integration of polynomials etc portable experimentalmik@konecny.aow.cztDApproximate from below and from above the integral of a polynomial. ;Based on the following formulas for Chebyshev polynomials:   \int T_n(x)dx = . T_{n+1}(x)/2(n+1) - T_{n-1}(x)/2(n-1)   \int T_1(x)dx =  T_2(x)/4 + 1/4  \int T_0(x)dx =  T_1(x) uBmeasure the volume between a polynomial and the zero axis on [-1,1]^n v8Differentiate a polynomial using one of its variables. tuvtuv %(internal) evaluation of polynomials portable experimentalmik@konecny.aow.cz[PEvaluate a polynomial at a point, consistently rounding upwards and downwards. `6Evaluate a polynomial at a real number approximation aNSubstitute several variables in a polynomial with real number approximations, $ rounding downwards and upwards. b*Compose two polynomials, rounding upwards - provided the second polynomial maps [-1,1] into [-1,1]. [\]^_`ab[\]^_`ab 5(internal) bounds of single and multiple polynomials portable experimentalmik@konecny.aow.czc A version of h  using a cubic approximation. dPApproximate from below and from above the pointwise maximum of two polynomials e.Find an upper bound on a polynomial over the  unit domain [-1,1]^n. f;Find a close upper bound on an affine polynomial over the  unit domain [-1,1]^n. g=Find a close upper bound on a quadratic polynomial over the  unit domain [-1,1]^n. h@Approximate the function max(0,p(x)) by a polynomial from below  and from above. i2Multiply a thin enclosure by a non-thin enclosure j(Safely multiply a polynomial by itself. cdefghijefgdhcij8class abstracting imprecise function arithmetic on [-1,1]^n portable experimentalmik@konecny.aow.cz-FCheck internal consistency of the function and report problem if any.  Construct a constant function. Construct an affine function. "Multiply a function by a scalar, ) rounding downwards and upwards. 6Multiply a function by an approximation of a scalar, ) rounding downwards and upwards. 6Multiply a function by an approximation of a scalar,  rounding downwards. 6Multiply a function by an approximation of a scalar,  rounding upwards. ,Get the degree of this particular function. 6If the function is a polynomial, this function should  return its degree. 0Decrease the degree of function approximation, 2 rounding pointwise downwards and upwards. MDecrease the degree of function approximation, rounding pointwise downwards. KDecrease the degree of function approximation, rounding pointwise upwards. GApproximate the integral of p (with 0 at 0) from below and from above. 9Approximate the integral of p (with 0 at 0) from below. 9Approximate the integral of p (with 0 at 0) from above. 'Measure the volume between a function . and the zero hyperplane on the domain [-1,1]^n. )Find an upper bound of the function over [-1,1]^n. (Find a lower bound of the function over [-1,1]^n. @Approximate the function max(0,p(x)) from below and from above. Approximate the function 1/ p(x) from below and from above. Approximate the function 1/p(x) from below. Approximate the function 1/p(x) from above. GApproximate the function max(p_1(x),p_2(x)) from below and from above. 8Approximate the function max(p_1(x),p_2(x)) from below. 8Approximate the function max(p_1(x),p_2(x)) from above. GApproximate the function min(p_1(x),p_2(x)) from below and from above. 8Approximate the function min(p_1(x),p_2(x)) from below. 8Approximate the function min(p_1(x),p_2(x)) from above.  Approximate  sqrt(p(x)) from below and from above.  Approximate  exp(p(x)) from below and from above.  Approximate  log(p(x)) from below and from above.  Approximate  sin(p(x)) from below and from above, . assuming the range of p is within [-pi2,pi2].  Approximate  cos(p(x)) from below and from above, . assuming the range of p is within [-pi2,pi2].   Approximate  atan(p(x)) from below and from above.  5Evaluate at a point, rounding upwards and downwards.  )Evaluate at a point, rounding downwards.  )Evaluate at a point, rounding downwards.  =Safely evaluate at a point using a real number approximation + for both the point and the result. 1Partially evaluate at a lower-dimensional point 1 given using a real number approximation. F Approximate the resulting function from below and from above. 1Partially evaluate at a lower-dimensional point 1 given using a real number approximation. 7 Approximate the resulting function from below. 1Partially evaluate at a lower-dimensional point 1 given using a real number approximation. 7 Approximate the resulting function from above. 6Compose two functions, rounding upwards and downwards  provided each f_v ranges within the domain [-1,1]. *Compose two functions, rounding downwards  provided each f_v ranges within the domain [-1,1]. (Compose two functions, rounding upwards  provided each f_v ranges within the domain [-1,1]. 1Convert from the interval type to the base type. B (The types are determined by the given example function.) 2Convert from the base type to the interval type. B (The types are determined by the given example function.) 18     8+arbitrary precision function enclosures on [-1,1]^n portable experimentalmik@konecny.aow.cz 9:;<=>?@ABC ?=;BC>:A@<9)class abstracting function enclosures on [-1,1]^n portable experimentalmik@konecny.aow.cz&This class extends  by: ? assuming that the domain of the function enclosures is always [-1,1]^n for some n; 8 allowing the construction of basic function enclosures ( where the domain has to be known. ';A function enclosure with no information about the function' s values. (9Construct a constant enclosure for a tuple of functions. )7Construct the exact enclosure of an affine function on [-1,1]^n. *IFind close upper and lower bounds of the volume of the entire enclosure. N A negative volume means that the enclosure is certainly inconsistent. JExplicitly specify the variables to identify the dimension of the domain. +KIntersect two enclosures and measure the global improvement as one number. (Use RA.intersectMeasureImprovement defined in module Data.Number.ER.Real.Approx B to measure the improvement using a function enclosure.) JExplicitly specify the variables to identify the dimension of the domain. ,Safely integrate a [-1,1] ^n -> R^m function enclosure E with some initial condition (origin and function at origin). &'()*+,&'()*+, enclosures translated from [-1,1]^n to another domain portable experimentalmik@konecny.aow.cz2%Datatype translating enclosures from [-1,1]^n to any compact  interval in R^n with non-empty interior ; using a bunch of linear maps, one for each dimension. 4the interval being mapped 5The canonical translation of 8 any compact non-empty and non-singleton interval in R " to and from the unit interval [-1,1]. 3This structure holds the two coefficients for both  linear mappings. -./01234567 2017534/6-.,classes abstracting function approximations portable experimentalmik@konecny.aow.cz=A class of types that approximate first-order real functions   R^n -> R^m3 using some type of graph enclosures. The domains @ of the functions can be neither specified nor investigated ! by operations in this class. This class extends % so that we could perform point-wise ! operations on the functions. This class is associated with: % two real number types (instances of () for working with parts of the function's domain and range; 3 a type of boxes indexed by variables (instance of ) for working with  parts of the function' s domain. This class extends  by: G making the domain of the function enclosure available for inspection; 8 allowing the construction of basic function enclosures , where the domain has to be specified. 4Recursively perform a number of bisections and then # glue the bits back together. This way we can ensure that 5 a piece-wise enclosure has a partition that goes " to at least the given depth. ;A function enclosure with no information about the function' s values. 9Construct a constant enclosure for a tuple of functions. 8Construct the exact enclosure for a projection function  (ie a variable). -Return the domain of the function enclosure. DSplit the domain into two halves, yoelding two function enclosures. 5Merge function enclosures with neighbouring domains. Safely integrate a  R^n -> R^m function enclosure E with some initial condition (origin and function at origin). Safely integrate a R -> R^m function enclosure. Safely integrate a  R^n -> R^m function enclosure ? intersecting it with a prior enclosure for the result. >The prior enclosure could contains one of more initial value. Safely integrate a R -> R^m function enclosure ? intersecting it with a prior enclosure for the result. >The prior enclosure could contains one of more initial value. 7Check internal consistency and report problem if any. @Get the internal degree of quality (usually polynomial degree)  of the approximation. ASet an upper bound on the degree of this function approximation. :This reduces the degree immediately if necessary and also @ affects all operations performed with this value later. 7Get the current uppend bound on the degree associated + with this function approximation. 8Give a close upper bound of the precision of the range 6 at the best approximated point in the domain. 6Find some upper and lower bounds of the function over [-1,1]^n. 8Combine several functions with the same domain into one tuple function. 0Reveal how many functions are bundled together. &Modify a tuple of functions in a way : that does not treat the tuple elements uniformly. IFind close upper and lower bounds of the volume of the entire enclosure. N A negative volume means that the enclosure is certainly inconsistent. BMultiply a function approximation by a real number approximation. HIntersect one enclosure by another but only on a box within its domain. KIntersect two enclosures and measure the global improvement as one number. (Use  defined in module Data.Number.ER.Real.Approx B to measure the improvement using a function enclosure.) *Evaluate the function at the given point. >Fix some variables in the function to the given exact values. /A simple and limited composition of functions. NIt is primarily intended to be used for precomposition with affine functions.    =arbitrary precision piece-wise-something function enclosures portable experimentalmik@konecny.aow.cz*Arbitrary precision piece-wise something 2 (eg linear, polynomial, rational) enclosures  of functions R^n->R^m. 7The type of approximation within segments is specified  by an instance of . 8The piece-wise construction defines another instance of . 2separate approximations per domain-box hyper-edge portable experimentalmik@konecny.aow.cz"=Use some function approximation type and for each domain box E keep a structure of function approximations of this type indexed E by the hyper-edge structure. For each hyper-edge of the domain, 3 the approximation has this edge as its domain. 'E.g. for a 2D square domain there are: ( one approximation for the whole square + four 1D approximations, one for each edge > eight 0D approximations, one for each endpoint of each edge  !""! .a list of approximations over the same domain portable experimentalmik@konecny.aow.cz%=A tuple of function approximations allowing one to get from  functions R^n->R to a function  R^n -> R^m. #$%%$#'definitions useful for testing in ghci non-portable (requires fenv.h) experimentalmik@konecny.aow.cz$ !"#$%&'()*+,-./0123456789:;<=>?@ !"#$%&'()*+,-./0123456789::;<<=>14"?@ABCBDEDFGHIJKLMNMOOPQRSTUVWXYYZ[\]^_`abc d e f g h i j k l m n o p q r s t u v w x y z { | } ~   &>2)"     54 !"#$%&'()*+,-./0123456789:;<=>?@ABCAERN-RnToRm-0.4Data.Number.ER.RnToRm.Approx%Data.Number.ER.RnToRm.Approx.DomEdges"Data.Number.ER.RnToRm.Approx.Tuple$Data.Number.ER.RnToRm.UnitDom.Approx&Data.Number.ER.RnToRm.Approx.DomTransl"Data.Number.ER.RnToRm.UnitDom.Base-Data.Number.ER.RnToRm.UnitDom.Approx.Interval9Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.Basic3Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom9Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.Field8Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.Eval:Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.Bounds>Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.Elementary?Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.Integration#Data.Number.ER.RnToRm.BisectionTree/Data.Number.ER.RnToRm.BisectionTree.Integration&Data.Number.ER.RnToRm.Approx.PieceWise!Data.Number.ER.RnToRm.DefaultRepr(Data.Number.ER.RnToRm.BisectionTree.PathData.Number.ER.RnToRmAERN-Real-0.9.6.1Data.Number.ER.Real.ApproxData.Number.ER.Real.DomainBox!Data.Number.ER.RnToRm.TestingDefs ERFnApprox ERFnDomApproxbisectUnbisectDepth bottomApproxconstprojdombisectunBisect integrateintegrateUnaryintegrateMeasureImprovement integrateMeasureImprovementUnarycheck domra2ranra ranra2domra getDegree setMaxDegree getMaxDegreegetBestPrecisiongetRangeApproxtuple getTupleSize applyTupleFnvolumescalepartialIntersectintersectMeasureImprovementeval partialEval composeThin erfnEdgeserfnMainVolumeERFnDomEdgesApprox erfnTuple ERFnTupleERUnitFnApproxaffinedtrToUnitSlopedtrToUnitConstdtrFromUnitSlopeERFnDomTranslApproxerfnUnitApprox DomTransldtrDomdtrFromUnitConst erfnDomTransl ERUnitFnBaseerfnCoeffGranularity erfnContext erfnUpper erfnMaxDegree ERFnIntervalERFnIntervalAny ERFnContext erfnLowerNeg erfnGlobalchebyXCoeffsLists chplTermOrderchplShow chebyXCoeffs termXterms chplNormaliseTermKey ERChebPolychplConstTermKeychplIsConstTermKey chplTermArity chplGetDegree chplConstchplVarchplNormaliseUpchplNormaliseDown chebToXBasis chplCoeffs chplScalechplReduceDegree chplAffinechplScaleApproxchplEval chplEvalUp chplEvalDownchebyEvalTsRoundDownUpchebyEvalTsExactchplEvalApproxchplPartialEvalApprox chplComposechplNonnegCubicchplMaxchplUpperBoundAffinechplUpperBoundAffineCornerschplUpperBoundQuadr chplNonnegchplThinTimesEncl chplSquare chplRecipchplSqrtchplExpchplPowchplLogchplSine chplCosinesincosTaylorAuxchplAtan chplIntegratechplVolumeAboveZerochplDifferentiateDepth ValueSplitterNodeLeaf BisectionTreeisLeafsplit mapWithDom mapLeavesdoBistrdoMap doMapLeaves removeVarssync2syncMany combineWith collectValuescollectDomValueslookupSubtreeDom ValueCombiner bistrDepthbistrDombistrValbistrDirbistrPtbistrLObistrHI zipFromOriginzipOnSubdomain ERFnPiecewiseFAPUFAPDFAPTFAPEFAPWPFAFnZipper BisecTreePathpath2domlookupSubdomain updateFnZ$Data.Number.ER.Real.DomainBox.IntMapBoxVarIDshowVar defaultVarnewVarIDlookupfindWithDefaultzipWithDefaultSecondzipWithDefaultzipWith foldWithKeyfoldfilterelemskeys unionWithunion notMembermemberdelete insertWithinsert fromAscList toAscListfromListtoList singletonunaryisNoinfonoinfo differenceintersectionWith mapWithKeymapDomainBoxMappableclassifyPosition bestSplitunify compatible DomainIntBox DomainBox VariableID bisectDomainBTP_LBTP_RBTP_HFnZ_HFnZ_LFnZ_RmapMultiLeavescompare updateVal errorModule chplCheck chplGetVarschplGetGranularitychplSetMinGranularitychplSetGranularity boundsAddErr chplRecipDn chplRecipUpchplReduceDegreeDownchplReduceDegreeUp chplScaleDown chplScaleUp chplMaxUpchplMin chplMaxDn chplMinDn chplMinUp scaleApproxscaleApproxDown scaleApproxUp reduceDegreereduceDegreeDownreduceDegreeUp integrateDown integrateUpvolumeAboveZero upperBound lowerBoundnonnegrecip recipDownrecipUpmaxmaxDownmaxUpminminDownminUpsqrtexplogsincosatanevalDownevalUp evalApproxpartialEvalApproxpartialEvalApproxDownpartialEvalApproxUpcompose composeDown composeUp raEndpointsraFromEndpointsgetGranularitysetMinGranularitysetGranularityERApprox ERIntApproxfapeUConst13InitPtfn2fn1 fapeUConst1 fapeUConst13 fapeMultiVarfapeUX1 fapeConstUfapeUX0 fapeConst01 fapuConst1 fapdConst1 fapdConstU fapdConst01fapd04X0fapd13X0fapd12X1fapdUX0fapdUX1 fapeConst1fape13X0fape12X1 fapeTestMult fapeTestPEvalfapwUUX0fapwUUX1fapwUX0fapwUX1 fapwUConst1 fapwUConst13fapwUConst13InitPt testIntegrE testIntegrPxxLRfn3