Graphics Reference
In-Depth Information
11.4.1 Interval Arithmetic Examples
As an example of an interval arithmetic computation, consider the evaluation of
x (6
x ) for x
=[
1, 3
]
:
x (6
x )
=[
1, 3
]
(
[
6, 6
]−[
1, 3
]
)
=[
1, 3
][
3, 5
]=[
3, 15
]
.
In this case, the true range of the expression for the given value of x is
[
5, 9
]
, which is
contained in the interval
(as it must be). This example also illustrates the main
weakness with interval arithmetic: the resulting intervals are often much larger than
necessary. In complex nested expressions, this “error explosion” can quickly cause
intervals to become unusable. The problem, known as the dependency problem , is that
each time a variable occurs in an expression it is treated as a new variable, indepen-
dent from earlier occurrences. However, in the earlier example the subexpressions
to the multiplication, x and 6
[
3, 15
]
x , are both dependent on x . The multiplication has
no knowledge of this fact and thus the computation suffers from an unnecessary
widening of the resulting interval. For this reason, if a variable occurs more than once
in an expression the computed result may not tightly bound the true value range of
the expression.
In many cases, it is possible to avoid, or at least limit, the dependency problem by
rearranging an expression to eliminate dependencies. For example, for x
=[
3.0, 3.1
]
the expression
x ( x
f ( x )
=
1),
evaluates as f (
[
3.0, 3.1
]
)
=[
3.0, 3.1
]
/
[
2.0, 2.1
]=[
1.4, 1.6
]
. The equivalent expression
1 ( x
f ( x )
=
1
+
1),
[
]
=
+
[
]=
+
in which x only occurs once,
evaluates as f (
3.0, 3.1
)
1
1/
2.0, 2.1
1
[
0.476, 0.5
]=[
1.476, 1.5
]
, which is a tight bound. Similarly, the expressions
x
+
y
xy
g ( x , y )
=
and
h ( x , y )
=
x
y
x
+
y
can be tightly written as
2
1
g ( x , y )
=
1
and
h ( x , y )
=
1/ y .
1
x / y
1/ x
Search WWH ::




Custom Search