Presentation is loading. Please wait.

Presentation is loading. Please wait.

Algebraic numbers I Based on Burnikel, Fleischer, Mehlhorn, Schirra article: A Strong and Easily Computable Separation Bound for Arithmetic Expressions.

Similar presentations


Presentation on theme: "Algebraic numbers I Based on Burnikel, Fleischer, Mehlhorn, Schirra article: A Strong and Easily Computable Separation Bound for Arithmetic Expressions."— Presentation transcript:

1 Algebraic numbers I Based on Burnikel, Fleischer, Mehlhorn, Schirra article: A Strong and Easily Computable Separation Bound for Arithmetic Expressions Involving Radicals. Algorithmica 27: 87-99 (2000)

2 Timeline 1.Introduction and Definitions. 2.Theorems and it proofs. 3.Applications. 4.[Expressions involving divisions]. 5.[More tight results]. 6.[Comparison to previous works].

3 Introduction – The Problem. The evaluation of a test in a computer program frequently amounts to determining the sign of an arithmetic expression, e.g., If p, q, and r are points in the plane, then Determines whether p is at least as close to r as q.

4 Introduction (cont.) While using finite data types, one is prone to get errors. In The Question: 'Is the expression's value bigger than 0, equal to 0 or less then 0 ?'. Because of precision problems with finite data types the above question may lead to wrong answers if the expression's value is very close to 0.

5 Definition – Separation bound. Definition: Sep(E) – separation bound of expression E: For an expression E having value ξ = val(E), a separation bound sep(E) is a positive real number with the property that: ξ ≠ 0 →|ξ| ≥ sep(E). Thus, |ξ| < sep(E) → ξ = 0.

6 Introduction (cont.) A more robust way to ask and answer this question (about the sign of E) is: Find sep(E). Compute an approximation A of ξ, with | A - ξ | < sep(E)/2, by evaluating E with float with sufficient mantissa length. If |A| ≥ sep(E)/2 that ξ has the same sign as A. else ξ = 0.

7 So The Problem is to find easy computable separation bound!

8 Definitions E – expression, with value ξ. We can look at E as a directed acyclic graph (dag) whose source nodes are labeled by integers and whose internal nodes are labeled by operators like +, -, *, / and. E is division-free if it contains no /.

9 DAG Example.

10 Recursive definition of U(E),L(E). E = U(E)/L(E); U(E),L(E) are division-free.

11 Definitions u(E), l(E) – nonnegative real numbers. The numbers u(E) and l (E) are bounds on the absolute values of U(E) and L(E) respectively, obtained by replacing every subtraction in E by an addition. Note that u(U(E)) = u(E) and u(L(E)) = l (E) and l (E) = 1, for division-free expressions. Note that U(E) and L(E) works on DAG, and u(E) and l (E) on integers.

12 Recursive definition of u(E), l(E)

13 Definition - Algebraic Number. Definition: The number ξ = val(E) is algebraic, i.e., there is a polynomial pєZ(X), such that p(ξ) = 0. Definition: Among the polynomials in Z(X) having root ξ there exists a unique irreducible polynomial m ξ, called the minimal polynomial of ξ.

14 Algebraic Number (cont.) Definition : The degree of ξ, deg(ξ) is the degree of the minimal polynomial of ξ, m ξ. Definition: If E involves r radical nodes of indices k 1, …,k r. Than define: And D(E) ≥ deg(ξ).

15 Symmetric Functions. Definition: Let p be a polynomial in t 1 ;..t n ; with coefficients in R, R is a commutative ring with unity. p symmetric if for any permutation π, we have:

16 Elementary Symmetric functions. Definition : Let elementary symmetric functions (ESF) in t 1,…,t n.

17 THEOREM 1 – Symmetric Function. Let R be a commutative ring with unity. Than for any p, symmetric polynomial in t 1,..t n. with coefficients in R, there exist a unique polynomial q with coefficients in R such that:

18 Proof. By induction on the number n of variables and on the total degree m of p. For n = 1, Suppose for n-1 variables, and prove it by induction on m = deg(ξ). Suppose m ≠ 0 and that for all degrees < m it performs.

19 Let define: Then by induction on n exist q’ such that: And σ 1 …σ n-1 are ESF in t 1..t n-1. And deg(q) ≤ m. Define: The total degree of p 1 is at most m. Since It follows that t n divides p 1.

20 Let p 2 such that Since p 1 is symmetric (by its definition) For all possible permutations. Therefore p 1 is divisible by t 1,…,t n. So it is divisible by their product (suppose that t i is algebraic independent). Then there exist p 3 such that:

21 Note that deg(p 3 ) = deg(p 1 ) – n ≤ m-n < m. By induction on m exist q 3 such that: And finally we get: And we can define q:

22 THEOREM 2. Let p a and p b, be polynomials with integral coefficients. Then for every operation in {+, -,*}, the has integral coefficients as well.

23 Proof. We use the Theorem 1 on the polynomial: it is symmetric in α 1,…α n and in β 1,…,β m. (By definition of f ). Since f symmetric in β 1,…,β m there is a polynomial g such that:

24 Proof (cont.) And since g is symmetric in α 1,…α n, We can apply the theorem once more. We get h such that: We have, by definition of p a and p b and of ESF. By assumption, a i and b j all are integral, so h is a polynomial in X with integral coefficients. Hence f(X) = p A op B (X) has integral coefficients.

25 THEOREM 3. There exists a polynomial such that For all roots e i of p E (X).

26 Proof. We use induction on the structure of E. 1.If E is an integer constant a, then use polynomial p E (X) = X – a. 2.If E = A op B. op in {+,-.*} Then by induction exist p A (X) and p B (X).

27 And the roots is val(A) and val(B). Than we define p E (X) = p A op B (X). By Theorem 2, p A op B (X) has int. coefficients, and val(E) = val(A) op val(B) is root of p A op B (X) by definition. By induction: |α| ≤ u(A) and |β| ≤ u(B). If op={+,-}, than the roots are bounded by: If op=*, Than:

28 If E =, than we set where ζ k is a (complex) primitive k-th root of unity. In this case which concludes the induction step and thus finishes the proof.

29 THEOREM 4 – Separation Bound. If E is a division-free expression, whose value val(E) = ξ is nonzero, then

30 Proof. The upper bound is obvious. Let’s proof it for the lower bound. In the last theorem we constructed a polynomial with root val(E) = ξ. Since every integral polynomial having root ξ, is divided by the minimal polynomial Both polynomials have leading coefficient 1, and the roots of, are among the roots of.

31 And for some indices we have Since it is minimal polynomial all. And bounded by u(E). Without loss of generality. Since have integral coefficients, (And for all polynomials)

32 Weaker lower bound. Let E be a division-free expression with value ξ ≠ 0. Then: And this happens because D(E) > deg(ξ).

33 Expressions involving divisions Let E be an expression whose value ξ is nonzero. Than, To prove it, apply the bounds of Theorem 4 on U(E) and L(E). Each radical operation of index k i in E generates at most two radical operations of index k i, each of which may appear in U(E) as well as in L(E).

34 The reason is: And we have And val(E) = val(U(E))/val(L(E)), and u(U(E)) = u(E) and u(L(E)) = l(E).

35 Cont. And finally we have:

36 Applications – Find Sign of E. As above, by finding approximation A. An error bound ∆ is initialized to some positive value, ∆ = 1. And an find an approximation À of ξ, | ξ - À | ≤ ∆ using float point with arbitrary- length mantissa. if |À|> ∆, the sign of ξ is equal to sign of À else, |À| ≤ ∆ and hence | ξ | ≤ 2∆. if 2∆ ≤ sep(E), we have ξ = 0. else half ∆ and repeat.

37 Bit bound. The worst case complexity of the alg. is determined by the separation bound. We need log(1/sep(E)) iterations for computation of À. We call log(1/sep(E)) bit bound. If ξ≠0 we need only log(ξ) precisions. And hence “easy sign tests” are much faster than the worst case.

38 Find Sign of E – Other way. Compute an interval I ε of length  such that 0 <  < sep(E) and I ε contains E. If 0 is inside I ε, the value of E is smaller than sep(E) and hence E is zero. Otherwise, the sign of E is equal to the sign of the numbers in I ε.

39 Actual Computation of Separation Bounds. Theorem 4 cannot be applied directly, since it evolves quantities u(E) and l (E), that are in general nonrational algebraic numbers. In article they give two methods to compute slightly weaker separation bounds.

40 Actual Computation of Separation Bounds (cont.) 1.Computing with floating point numbers with rounding toward larger values. 2.Maintaining integral logarithms of u(E) and l(E).

41 Use of floating point. Use of IEEE standard 754, result exactly rounded according to the chosen rounding mode. But changing the rounding mode is expensive on some systems. As an alternative one can simply evaluate u(E) and l(E) in double precision floating point arithmetic and multiply each intermediate result by. Underflow does not occur here since we always have u(E) > 1 whenever u(E) is nonzero. In case of overflow, the resulting value of u(E) will be infinity, which is a correct (but meaningless) bound.

42 Integral logarithms. Recursively compute integers: As define in table:

43 Cont. The recursive rules for u’(E) and l’(E) do not evolve radical operations. Hence rounding errors are not an issue for computing u’(E) and l’(E).

44 More tight results. In 2001, the same authors published article and they improved their result. They reached new separation bound: The way they do it, is based on new definition of: u(E) and l(E).

45 The start point was to change transformation rules. Instead of use the last rule, use: For building division free expression of E 1 and E 2.

46 New definition of u(E) and l(E).

47 More tight results. In our case the alg. bit-bound is linear in D(E) for division free expressions. And quadratic for expressions that include divisions. Chee Yap and Chen Li in 2000 found a new separation bound, that is linear for expressions that include divisions too.

48 Comparison with Previous Work In order to check the practical use of their separation bound. The authors implemented the algorithm that use Integral logarithms approach. And compared it with bounds based on the previous results of Canny and Mignotte. The authors proved that Canny’s polynomial system bounds are always weaker than their.

49 The Test. The check was based on next test: Let v be the Voronoi vertex having minimal distance to sites s 1, s 2, and s 3 and let s be another site. Is s inside the Voronoi circle of v, i.e., is it nearer to v than the sites s 1, s 2, s 3 ? In the implementation of the incircle test we need compare the squared distance of the sites s 1, s 2, and s 3 to v with the squared distance of s to v.

50 Result of comparison separation bounds for incircle test. The sites s i can be defined by points or by lines. For example ppl p – mean that v defined by 2 points and line and we test point.


Download ppt "Algebraic numbers I Based on Burnikel, Fleischer, Mehlhorn, Schirra article: A Strong and Easily Computable Separation Bound for Arithmetic Expressions."

Similar presentations


Ads by Google