next up previous contents
Next: Example 3 Up: Examples Previous: Example 1   Contents

Example 2

The problem we want to solve has been presented in section,15.1.1.

The IntervalGradient procedure is:

INTERVAL_MATRIX IntervalGradient (int l1,int l2,INTERVAL_VECTOR & in)
INTERVAL x,y,teta;
    if(l2==1){Grad(1,1)=2*x;return Grad;}
    if(l2==2){Grad(1,2)=2*y;return Grad;}
    if(l2==3){Grad(1,3)=0;return Grad;}
    if(l2==1){Grad(2,1)=2.0*x-20.0+8.0*Cos(teta);return Grad;}
    if(l2==2){Grad(2,2)=2.0*y+8.0*Sin(teta);return Grad;}
      return Grad;}
      return Grad;}
    if(l2==2){Grad(3,2)=2.0*y-20.0+4.0*Sin(teta)+4.0*Cos(teta);return Grad;}
      return Grad;
We may use the same main program as in the previous example (the name of this program is

Let's assume that we set epsilonf to 0 and epsilon to 0.01 while looking at all the solutions (Stop=0), using the maximum equation ordering and setting Dist to 0.1. The algorithm provide the following solutions after using 55 boxes:

...99845,5.00165]~~~~y=[4.99845,5.00146]~~~\theta =[-0.000536641,0]

We notice that all of the roots are contained in the solution intervals.

If we use the maximum middle-point equation ordering the algorithm provide the same solution intervals.

With epsilonf=0.001, epsilon=0 the algorithm still find exactly the root with 55 boxes and a computation time of 7010ms. Here Moore test may have failed as the solution in $\theta$ is 0, which correspond exactly to split point in the bisection process: it may be useful to break the symmetry in the test domain.

Using the single bisection mode and setting the flag Single_Bisection to 2 enable to reduce the number of boxes to 33 and the computation time to 3580ms for epsilonf=0.00001.

Note that we may improve the efficiency of the procedure by using simplification procedures such as the 2B (section 2.17) and the 3B method. In that case for epsilonf=1e-6, epsilon=1e-6 the number of boxes will have been reduced to 7. Note that the solution [5,5,0] is still not guaranteed. But using a search space of $[-\pi,\pi+1]$ for $\theta$ allow the Moore test to guarantee both solutions.

next up previous contents
Next: Example 3 Up: Examples Previous: Example 1   Contents
Jean-Pierre Merlet 2012-12-20