Comparative Analysis of Deterministic and Nondeterministic Decision Tree Complexity. Global Approach Mikhail Moshkov
Research Institute for Applied Mathematics and Cybernetics of Nizhni Novgorod State University 10, Uljanova St., Nizhni Novgorod, 603005, Russia Abstract
We study the relationships between the complexity of a task description and the minimal complexity of deterministic and nondeterministic decision trees solving this task. We investigate decision trees assuming a global approach i.e. arbitrary checks from a given check system can be used for constructing decision trees.
Introduction Decision trees are widely used in dierent elds related to problem solving and knowledge representation. Decision trees over nite check systems are studied in such elds as test theory [3, 6, 7], theory of information systems and of rough sets [11, 15], theory of questionnaires [12], theory of decision tables [4], machine learning [14], and searching theory [1, 16]. Decision trees over in nite check systems have not been intensively investigated, with the exception of linear and algebraic decision trees [2, 5, 6] and some their generalizations [8]. Linear and algebraic decision trees are often used in computational geometry [13]. Furthermore in [9, 10] the time complexity of decision trees over arbitrary check systems is considered. This paper deals with comparative analysis of three parameters of tasks over arbitrary ( nite or in nite) check system: the complexity of a task description, the minimal complexity of a decision tree solving this task deterministically, and the minimal complexity of a decision tree solving this task nondeterministically. We consider a global approach to investigation of decision trees i.e. arbitrary checks from check system can be used for constructing decision trees. This work was supported by State Committee on Higher Education of Russian Federation. Part of this work was done when author visited Institute of Mathematics at Warsaw University
1 Basic De nitions and Results 1.1 Decision Trees
Let ! = f0; 1; 2; : : :g, Ek = f0; 1; : : : ; k ? 1g, k 2, and A be a nonempty set and let F be a nonempty set of functions from A into Ek . Functions from F will be called checks, and the pair U = (A; F ) will be called a check system. By F will be denoted the set of all nite words over the alphabet F , including the empty word . A vertex in a nite directed tree is called a root, if it is the only vertex which is not the terminal vertex of any edge. A tree, which has such a vertex, will be called a nite directed tree with root. The tree vertices, which are initial vertices of no edge, will be called terminal vertices. The tree vertices, which are neither the root nor terminal, will be called working vertices. A complete path in a nite directed tree with root is any sequence = v0; d0; : : : ; vm ; dm; vm+1 of vertices and edges of the tree such that v0 is the root, vm+1 is a terminal vertex, and vi is the initial and vi+1 is the terminal vertex of the edge di for i = 0; : : : ; m. A decision tree over the check system U is a marked nite directed tree with root, which has at least two vertices and the following properties: a) the root and the edges starting in the root are assigned nothing; b) each working vertex is assigned a check from the set F ; c) each edge starting in a working vertex is assigned a number from Ek ; d) each terminal vertex is assigned a number from !. A decision tree is deterministic i it satis es the following conditions: a) the root is initial vertex of exactly one edge; b) edges starting in a working vertex are assigned pairwise dierent numbers. The set of all decision trees over U will be denoted by DT (U ). Assume ? 2 DT (U ). Further let C (?) be the set of all checks, which are assigned to working vertices of ?, and P (?) be the set of all complete paths in ?. Let = v0 ; d0; : : : ; vm ; dm; vm+1 be a complete path in ?. We denote by ( ) the number assigned to the vertex vm+1 . Now we de ne a word '( ) from F and a subset A( ) of the set A, associated with , in the following way: if m = 0, then '( ) = and A( ) = A. Let m > 0, and let the check fj be assigned to the vertex vj and let j be the number assigned to the edge dj , j = 1; : : : ; m. Then '( ) = f1 : : : fm and A( ) = fa : a 2 A; f1(a) = 1 ; : : : ; fm(a) = m g. Let S ( ) = ff1(x) = 1 ; : : : ; fm(x) = m g for m > 0.
1.2 Tasks
The set of all nonempty nite subsets of the set ! will be denoted by P (!). A task over U is any (n + 1)-tuple z = (; f1 ; : : : ; fn), where n 2 ! n f0g; : Ekn ! P (!) and f1; : : : ; fn 2 F . Let C (z) = ff1 ; : : : ; fng. The task z may be interpreted as a task of searching for at least one number from the set z(a) = (f1 (a); : : : ; fn(a)) for an arbitrary a 2 A. Dierent problems of pattern recognition, discrete optimization, fault diagnostics, and computational geometry can be represented in such form. We denote by T (U ) the set of all tasks over the check system U . Let z 2 T (U ) and ? 2 DT (U ). We say that the tree ? solves the task z nondeterministically if the following conditions are satis ed: S a) 2P (?) A( ) = A; b) if a 2 A( ) then ( ) 2 z(a) for any a 2 A and 2 P (?).
The tree ? solves the task z deterministically if ? is a deterministic decision tree which solves z nondeterministically.
1.3 Complexity Measures
A complexity measure over U is any map : F ! !. The complexity measure is called limited if it has the following properties: (a) (12 ) (1 ) + (2) for any 1 ; 2 2 F ; (b) (1 23 ) (1 3) for any 1; 2 ; 3 2 F ; (c) for any 2 F the inequality () l() holds, where l() is the length of . We extend a given complexity measure onto the set DT (U ) by
(?) = maxf ('( )) : 2 P (?)g for any ? 2 DT (U ). The value (?) will be called the complexity of a decision tree ?. Now we give some examples of complexity measures. Let w : F ! ! n f0g. We de ne the function w : F ! ! by w () = 0 if = and w () = Pmi=1 w(fi) if = f1 : : : fm . The function w is a limited complexity measure over U and it is called a weighted depth. If w 1 then the function w is called the depth and is denoted by h. Let be a complexity measure over U and z = (; f1; : : : ; fn) 2 T (U ). The value i (z ) = (f1 : : : fn ) will be called the complexity of the task z description. We denote U by Ud (z) the minimal complexity of a decision tree ? 2 DT (U ) which solves the task z deterministically. We denote by Ua (z) the minimal complexity of a decision tree ? 2 DT (U ) which solves the task z nondeterministically.
1.4 Global Types of T-Pairs
A pair (U; ), where U is a check system and is a complexity measure over U , will be called a test-pair (or, t-pair, in short). If is a limited complexity measure then t-pair (U; ) will be called a limited t-pair. Let (U; ) be a t-pair. We have three parameters Ui (z), Ud (z) and Ua (z) for any task z 2 T (U ), and we shall investigate the relationships between any two such parameters for tasks from T (U ). Let us consider, for example, the parameters Ui (z) and Ud (z). Let n 2 !. We shall study relations Ui (z) n =) Ud (z) u true for any z 2 T (U ). The minimal value of u is most interesting for us. This value (if exists) is equal to UUdi (n) = maxf Ud (z) : z 2 T (U ); Ui (z) ng: Also we shall study relations Ui (z) n =) Ud (z) l. In this case the maximal value of l is most interesting for us. This value (if exists) is equal to
LdiU (n) = minf Ud (z) : z 2 T (U ); Ui (z) ng: The two functions UUdi and LdiU describe how the behavior of the parameter
d U (z )
depends on the behavior of the parameter Ui (z). There are 18 similar functions for all ordered pairs of parameters Ui (z), Ud (z) and Ua (z). These 18 functions well describe the relationships among the considered parameters. It will be very interesting to point out 18-tuples of these functions for all t-pairs as well as for all limited t-pairs. But this is a very dicult problem. In this paper instead of functions we shall study types of functions. With any function we
shall associate its type from the set f; ; ; ; g. For example, if a function has in nite domain, and it is bounded above than its type is equal to . Thus we shall enumerate 18-tuples of types of functions. These tuples will be represented in tables called the global types of t-pairs. Now we give de nitions of mentioned above notions. Let b; c 2 fi; d; ag. We de ne partial functions UUbc : ! ! ! and LbcU : ! ! ! by UUbc (n) = maxf Ub (z) : z 2 T (U ); Uc (z) ng; LbcU (n) = minf Ub (z) : z 2 T (U ); Uc (z) ng for any n 2 ! . If the value UUbc (n) is de ned then it is an unimprovable upper bound on the values Ub (z) for tasks z 2 T (U ) satisfying Uc (z) n. If the value LbcU (n) is de ned then it is an unimprovable lower bound on the values Ub (z) for tasks z 2 T (U ) satisfying Uc (z) n. Let g be a function from a subset of ! and into !. We denote by Dom(g) the domain of g. Let Dom+(g) = fn : n 2 Dom(g); g(n) ng and Dom?(g) = fn : n 2 Dom(g); g(n) ng. Now we de ne the value typ(g) 2 f; ; ; ; g called the type of g. If Dom(g) is an in nite set and g is a bounded above function then typ(g) = . If Dom(g) is an in nite set, Dom+(g) is a nite set, and g is an unbounded above function then typ(g) = . If both sets Dom+(g) and Dom?(g) are in nite then typ(g) = . If Dom(g) is an in nite set and Dom?(g) is a nite set then typ(g) = . If Dom(g) is a nite set then typ(g) = . We denote by typg (U; ) a table with three rows and three columns, in which rows from top to bottom and columns from the left to the right are labelled by indices i; d; a; and the pair typ(LbcU ) typ(UUbc ) is on the intersection of the row with index b 2 fi; d; ag and the column with index c 2 fi; d; ag. The table typg (U; ) will be called the global type of t-pair (U; ).
1.5 Basic Results
The main problem investigated in this paper is to nd all global types of t-pairs as well as of limited t-pairs. The solution of this problem describes all possible (in terms of functions UUbc ; LbcU types, b; c 2 fi; d; ag) relationships among the task description complexity, the task solving complexity by deterministic decision trees, and the task solving complexity by nondeterministic decision trees. Now we de ne seven tables: i d a i d a i d a i i
i
T1 = d T2 = d T3 = d
a a a
i
T4 = di a
d
a i d T = i
5 d
a
a i d
i
T6 = d
a
i d a i
T7 = d
a
a
Theorem 1 The relation typg (U; ) 2 fT1; T2 ; T3; T4; T5 ; T6; T7g holds for any t-pair (U; ). For any i 2 f1; 2; 3; 4; 5; 6; 7g there exists a t-pair (U; ) such that typg (U; ) = Ti .
Theorem 2 The relation typg (U; ) 2 fT2 ; T3; T4; T5 ; T6; T7g holds for any limited tpair (U; ). For any i 2 f2; 3; 4; 5; 6; 7g there exists a limited t-pair (U; h) such that typg (U; h) = Ti .
ExampleP1 Let n 2 ! nf0g and U (n) = (Rn; Ln), where R is the set of all real numbers, Ln = fr( ni=1 aixi + an+1 ) : ai 2 R; 1 i n + 1g, r : R ! f0; 1g and r(a) = 0 i a < 0 for any a 2 R. Using results from [8] one can prove that typg (U (n); h) = T3. Seven similar examples with full proofs are included in Section 3 (Lemmas 7 - 13).
2 Possible Global Upper Types of T-Pairs Let (U; ) be a t-pair. We denote by typgu(U; ) a table with three rows and three columns, in which rows from top to bottom and columns from the left to the right are labelled by indices i; d; a and the value typ(UUbc ) is on the intersection of the row with index b 2 fi; d; ag and the column with index c 2 fi; d; ag. The table typgu(U; ) will be called the global upper type of t-pair (U; ). In this section all possible global upper types of t-pairs are enumerated. Now we de ne seven tables: i d a i d a i d a i d a t1 = di t2 = di t3 = di t4 = di
a a a a
i t5 = di
a
d
a i d a i d a t = i t = i
6 d 7 d
a a Proposition 1 The relation typgu(U; ) 2 ft1; t2 ; t3; t4 ; t5; t6; t7 g holds for any t-pair (U; ). Proposition 2 The relation typgu(U; ) 2 ft2 ; t3; t4 ; t5; t6; t7 g holds for any limited tpair (U; ). First we prove some auxiliary statements. Lemma 1 Let (U; ) be a t-pair and z 2 T (U ). Then the inequalities Ua (z) Ud (z) i U (z ) hold. Proof. Let z = (; f1 ; : : : ; fn). It is not dicult to construct a decision tree ?0 2 DT (U ) solving the task z deterministically by sequential nding values of the checks f1 ; : : : ; fn. Evidently, (?0) = Ui (z). Therefore Ud (z) Ui (z). If a decision tree ? 2 DT (U ) solves the task z deterministically then the decision tree ? solves the task z nondeterministically. Therefore Ua (z) Ud (z). 2 Let (U; ) be a t-pair, n 2 ! and b; c 2 fi; d; ag. A notation UUbc (n) = 1 means that the set f Ub (z) : z 2 T (U ); Uc (z) ng is in nite. Evidently, if UUbc (n) = 1 then UUbc (n + 1) = 1. It is not dicult to prove the next statement.
Lemma 2 Let (U; ) be a t-pair and b; c 2 fi; d; ag. Then a) if there exists n 2 ! such that UUbc (n) = 1 then typ(UUbc ) = ; b) if there is no n 2 ! such that UUbc (n) = 1 then Dom(UUbc ) = fn : n 2 !; n n0 g, where n0 = minf Uc (z) : z 2 T (U )g. Let (U; ) be a t-pair and b; c; e; f 2 fi; d; ag. A notation UUbc / UUef means that for any n 2 ! the following statements hold: a) if the value UUbc (n) is de ned then either UUef (n) = 1 or the value UUef (n) is de ned and the inequality UUbc (n) UUef (n) holds; b) if UUbc (n) = 1 then UUef (n) = 1. Let us assume is a linear order on the set f; ; ; ; g and . Lemma 3 Let (U; ) be a t-pair. Then typ(UUbi ) typ(UUbd ) typ(UUba ) and typ(UUab ) typ(UUdb ) typ(UUib ) for any b 2 fi; d; ag. Proof. From the de nition of the functions UUbc ; b; c 2 fi; d; ag, and from Lemma 1 it follows that UUbi / UUbd / UUba and UUab / UUdb / UUib for any b 2 fi; d; ag. Using these relations and Lemma 2 we obtain the statement of the lemma. 2
Lemma 4 Let (U; ) be a t-pair and b; c 2 fi; d; ag. Then a) typ(UUbc ) = i the function Ub is bounded above on the set T (U ); b) if the function Ub is unbounded above on T (U ) then typ(UUbb ) = . Proof. The statement a) of Lemma is obvious. b) Let the function Ub be unbounded above on T (U ). One can show that in this case the equality UUbb (n) = n holds for in nitely many n 2 !. Therefore typ(UUbb ) = . 2 Corollary 1 Let (U; ) be a t-pair and b 2 fi; d; ag. Then typ(UUbb ) 2 f; g. Lemma 5 Let (U; ) be a t-pair and typ(UUii ) =6 . Then typ(UUid ) = typ(UUia ) = . Proof. Using Lemma 4 we have that the function Ui is unbounded above on T (U ). Let m 2 !. Then there exists a task z = (; f1; : : : ; fn) 2 T (U ) such that Ui (z) m. Let us consider a task z0 = ( 0 ; f1; : : : ; fn), where 0 f0g. It is clear that Ui (z0 ) m.
Let ? be a decision tree which consists of the root, the terminal vertex labelled by 0 and the edge connecting these two vertices. One can show that the tree ? solves the task z0 deterministically. Therefore Ua (z0 ) Ud (z0 ) (?) = (). Taking into account that m is an arbitrary number from ! we have that UUid ( ()) = 1 and UUia ( ()) = 1. Using Lemma 2 we obtain typ(UUid ) = typ(UUia ) = . 2
Lemma 6 Let (U; ) be a t-pair. Then typ(UUai ) 2 f; g. Proof. Let U = (A; F ) and f : A ! Ek for any f 2 F . Using Lemma 3 and Corollary 1 we have that typ(UUai ) 2 f; ; g. Assume that typ(UUai ) = . Then there exists m 2 ! n f0g such that UUai (n) < n for any n 2 !; n > m. We prove by induction on n that for any task z 2 T (U ), if Ui (z) n then Ua (z) m0 , where m0 = maxfm; ()g. From Lemma 1 we obtain that under the condition n m the considered statement holds. Let it holds for some n; n m. We show that this statement holds for n + 1 too. Let z 2 T (U ) and Ui (z) n + 1. Since n + 1 > m then we obtain Ua (z) n. Let ? 2 DT (U ); (?) = Ua (z) and ? solves the task z nondeterministically. Assume
that in ? there exists a complete path in which there are no working vertices. In this case a decision tree, which consists of the root, the terminal vertex labelled by ( ) and the edge connecting these two vertices, solves the task z nondeterministically. Therefore Ua (z) () m0 . Assume now that each complete path in the decision tree ? contains a working vertex. Let 2 P (?); = v0 ; d0; : : : ; vp; dp; vp+1 and let a check fi be assigned to the vertex vi and let i be a number assigned to the edge di; i = 1; : : : ; p. Let us consider a task z = ( ; f1; : : : ; fp), where (1; : : : ; p) = f ( )g and () = f ( ) + 1g for any p-tuple 2 Ekp such that 6= (1; : : : ; p). It is clear that Ui (z ) n. Using the inductive hypothesis we obtain that there exists a decision tree ? 2 DT (U ) which has the following properties: ? solves the task z nondeterministically and (? ) m0 . Let A( ) 6= ;. We denote by ?~ a tree obtained from ? by removal all vertices and edges which satisfy the following condition: there is no a complete path 0 in ? which contains this vertex or edge and for which ( 0) = ( ). Let f : 2 P (?); A( ) 6= ;g = f1; : : : ; r g. Let us identify the roots of the trees ?~ 1 ; : : : ; ?~ r . We denote by G the obtained tree. It is not dicult to show that G 2 DT (U ); (G) m0 and the decision tree G solves the task z nondeterministically. Thus the considered statement holds. Using Lemma 4 we have that typ(UUai ) = . The obtained contradiction shows that typ(UUai ) 2 f; g. 2 Proof of Proposition 1. Let (U; ) be a t-pair. Using Corollary 1 we have typ(UUii ) 2 f; g. Using Corollary 1 and Lemma 3 we obtain typ(UUdi ) 2 f; ; g. From Lemma 6 it follows that typ(UUai ) 2 f; g. a) Let typ(UUii ) = . Using Lemmas 3 and 4 we have typgu(U; ) = t1 . b) Let typ(UUii ) = and typ(UUdi ) = . Using Lemmas 3, 4 and 5 we obtain typgu(U; ) = t2 . c) Let typ(UUii ) = and typ(UUdi ) = . Using Lemma 5 we have that typ(UUid ) = typ(UUia ) = . Hence from Lemmas 3 and 6 we obtain that typ(UUai ) = . From this equality and from Lemma 4 it follows that typ(UUad ) = typ(UUaa ) = . Using the equality typ(UUdi ) = , Lemma 3 and Corollary 1 we have typ(UUdd ) = . From the equalities typ(UUdd ) = , typ(UUaa ) = and from Lemmas 2 and 4 it follows that typ(UUda ) = . Thus typgu(U; ) = t3 . d) Let typ(UUii ) = typ(UUdi ) = and typ(UUai ) = . Using Lemma 5 we have typ(UUid ) = typ(UUia ) = . From Lemma 4 it follows that typ(UUad ) = typ(UUaa ) = . Using Lemma 3 and Corollary 1 we obtain typ(UUdd ) = . Hence taking also into account typ(UUaa ) = , and Lemmas 2 and 4 we obtain that typ(UUda ) = . Thus typgu(U; ) = t4 . e) Let typ(UUii ) = typ(UUdi ) = typ(UUai ) = . Using Lemma 5 we have typ(UUid ) = typ(UUia ) = . From Lemma 3 and Corollary 1 we obtain typ(UUdd ) = typ(UUad ) = typ(UUaa ) = . Using Lemma 3 we have typ(UUda ) 2 f ; ; g. Therefore typgu(U; ) 2 ft5 ; t6; t7g. 2 Proof of Proposition 2. Let (U; ) be a limited t-pair. Taking into account that the complexity measure has the property (c) and using Lemma 4 we have typ(UUii ) 6= . Therefore typgu(U; ) 6= t1. From this relation and Proposition 1 it follows that the statement of Proposition 2 holds. 2
3 Realizable Global Upper Types of T-Pairs In this section all realizable global upper types of t-pairs are enumerated.
Proposition 3 For any i 2 f1; 2; 3; 4; 5; 6; 7g there exists a t-pair (U; ) such that typgu(U; ) = ti :
Proposition 4 For any i 2 f2; 3; 4; 5; 6; 7g there exists a limited t-pair (U; h) such that typgu(U; h) = ti: Let us prove some auxiliary statements. Let us de ne a t-pair (U1 ; ) as follows: U1 = (!; F1), where F1 = ff g and f 0, and 0.
Lemma 7 typgu(U1 ; ) = t1 . Proof. Using Lemma 4 we have that typ(UUii ) = . From this equality and from 1
Proposition 1 it follows that typgu(U1 ; ) = t1 . 2 Let us de ne a t-pair (U2; h) as follows: U2 = (!; F2), where F2 = F1 .
Lemma 8 typgu(U2 ; h) = t2 . Proof. It is not dicult to show that hdU (z) = 0 for any task z 2 T (U2). It is clear 2
that the function hiU2 is unbounded above on T (U2 ). Using Lemma 4 we have that typ(UUii2h) = and typ(UUdd2h) = . From these equalities and from Proposition 1 it follows that typgu(U2 ; h) = t2. 2 Let us de ne a t-pair (U3 ; h) as follows: U3 = (!; F3), where F3 = fli : i 2 ! n f0gg and for any i 2 ! n f0g; j 2 !, if j i then li(j ) = 0, and if j > i then li(j ) = 1.
Lemma 9 typgu(U3 ; h) = t3 . Proof. Using Corollary 1 and Lemma 3 we obtain typ(UUdi h) 2 f; ; g. We prove that typ(UUdi h) = 6 . Let n 2 ! n f0g; z = (; li ; : : : ; lim ) 2 T (U3) and m n. Using 3
3
1
"dichotomous" approach to construction of decision trees it is not dicult to prove that hdU3 (z) 1 + log2 n. Taking into account that z is an arbitrary task over U3 such that hiU3 (z) n we have UUdi3h(n) 1 + log2 n. Therefore typ(UUdi3h) 6= . Now we prove that typ(UUdi3h) = . Assume the contrary: typ(UUdi3h) = . Using Lemma 4 we obtain that there exists a number p 2 ! such that hdU3 (z) p for any task z 2 T (U3 ). Therefore there exists a number r 2 ! n f0g satis es the following condition: for any task z 2 T (U3 ) there exists a decision tree ? 2 DT (U3) which solves the task z deterministically and has at most r terminal vertices. Let us consider a task z0 = (; l1; : : : ; lr ) from T (U3 ), where : E2r ! P (!) and (1 ) \ (2 ) = ; for any 1 ; 2 2 E2r such that 1 6= 2 . Let ? be an arbitrary decision tree over U3, which solves the task z0 deterministically. It is not dicult to show that the tree ? must have at least r + 1 terminal vertices. We obtain a contradiction. Therefore typ(UUdi3h) = . From this equality and from Proposition 1 it follows that typgu(U3 ; h) = t3 . 2 Let us de ne a t-pair (U4 ; h) as follows: U4 = (!; F4), where F4 is the set of all possible maps f : ! ! E2.
Lemma 10 typgu(U4; h) = t4 .
Proof. We prove that typ(UUai h) = . Let z 2 T (U4), ? be a decision tree over U4 which solves the task z deterministically, and 2 P (?). Let us denote by f the check from F4 which has the following property: f (a) = 1 i a 2 A( ) for any a 2 !. We 4
denote by ? a decision tree over U4 which consists of the root v0 , the working vertex v1 labelled by f , the terminal vertex v2 labelled by ( ), the edge d0 connecting v0 and v1, and the edge d1 labelled by 1 and connecting v1 and v2. Let us identify the roots of the trees ? ; 2 P (?). We denote by G the obtained tree. It is not dicult to show that G 2 DT (U4); h(G) = 1 and the decision tree G solves the task z nondeterministically. Thus haU4 (z) 1 for any task z 2 T (U4 ). From here and from Lemma 4 it follows that typ(UUai4h) = . Let us prove that typ(UUdi4h) = . Using Lemmas 2 and 3 and Corollary 1 we have that Dom(UUdi4h) = ! n f0g. Let n 2 ! and n 1. It is not dicult to show that there exist f1; : : : ; fn 2 F4 which have the following property: for any 1 ; : : : ; n 2 E2 the system of equations ff1 (x) = 1 ; : : : ; fn(x) = ng is compatible on !. Let us consider a task z = (; f1 ; : : : ; fn) where : E2n ! P (!) and (1 ) \ (2 ) = ; for any 1 ; 2 2 E2n such that 1 6= 2 . It is clear that hiU4 (z) = n. Let ? be a decision tree over U4 which solves the task z deterministically and for which h(?) = hdU4 (z). It is clear that the decision tree ? must have at least 2n terminal vertices. Therefore h(?) n and hdU4 (z) n. Thus UUdi4 h(n) n. Using Lemma 1 we have UUdi4 h(n) = n. Taking into account that n is an arbitrary number from ! n f0g, we obtain that typ(UUdi4h) = . From this equality, equality typ(UUai4h) = and Proposition 1 it follows that typgu(U4 ; h) = t4. 2 Let us de ne a t-pair (U5 ; h) as follows: U5 = (!; F5), where F5 = ffi : i 2 ! n f0gg and for any i 2 ! n f0g; j 2 !, if i = j then fi(j ) = 1, and if i 6= j then fi(j ) = 0.
Lemma 11 typgu(U5; h) = t5 . Proof. Let z 2 T (U5 ). We shall show that hdU (z) = haU (z). Let ? be a decision 5
5
tree over U5 which solves the task z nondeterministically and for which h(?) = haU5 (z). Let be a complete path in the tree ? such that 0 2 A( ). If in the complete path there are no working vertices then, as it is not dicult to show, hdU5 (z) = haU5 (z) = 0. Let us assume we have m > 0 working vertices in the path and S ( ) = ffi1 (x) = 1 ; : : : ; fim (x) = m g. Since 0 2 A( ) then 1 = : : : = m = 0. It is clear that for any p 2 A( ) the relation ( ) 2 z(p) holds. Let us describe a decision tree ?1 over U5 which solves the task z deterministically and for which h(?1) m. For an arbitrary p 2 ! the decision tree ?1 nds the values fi1 (p); : : : ; fim (p). If fi1 (p) = : : : = fim (p) = 0 then we have p 2 A( ) and, hence, the task z is solved since we know that ( ) 2 z(p). Let for some j 2 f1; : : : ; mg the equality fij (p) = 1 holds. Then we have p = ij and, hence, the task z is solved too since we know all the set z(p). It is clear that h(?) m. Therefore h(?1 ) haU5 (z) and hdU5 (z) haU5 (z). By Lemma 1 we have that hdU5 (z) haU5 (z) and, hence, hdU5 (z) = haU5 (z). From this equality it follows that there is no n 2 ! for which UUda5 h(n) = 1. Using Lemma 2 we have that Dom(UUda5 h) = fn : n 2 !; n n0 g for some n0 2 ! and UUda5 h(n) n for any n 2 Dom(UUda5 h). Let n 2 Dom(UUda5h) and n 1. We shall show that UUda5 h(n) = n. Let z = (; f1; : : : ; fn) be a task from T (U5) for which (1 ) \ (2 ) = ; for any 1 ; 2 2 E2n such
that 1 6= 2 . Let ? be a decision tree over U5 which solves the task z nondeterministically and for which h(?) = haU5 (z). Let be a complete path in the tree ? such that 0 2 A( ). It is clear that in the complete path there is at least one working vertex. Let S ( ) = ffi1 (x) = 1 ; : : : ; fim (x) = m g. Since 0 2 A( ) then 1 = : : : = m = 0. It is clear that i 62 A( ) for any i 2 f1; : : : ; ng. Therefore for any i 2 f1; : : : ; ng the equation fi (x) = 0 is contained in the system S ( ). Consequently, h(?) n and haU5 (z) n. It is clear that hiU5 (z) = n. Using Lemma 1 we have that haU5 (z) = n and hdU5 (z) = n. Therefore UUda5h(n) n and, as proved above, UUda5 h(n) = n. Taking into account that n is an arbitrary number from ! such that n max(n0 ; 1) we have that Dom?(UUda5 h) and Dom+(UUda5h) are in nite sets and typ(UUda5h) = . Using Proposition 1 we obtain typgu(U5; h) = t5 . 2 Let us de ne a t-pair (U6 ; h) as follows: U6 = (!; F6), where F6 = F5 [ G6; G6 = fg2i+1 : i 2 !g and for any i 2 !; j 2 !, if j 2 f2i + 1; 2i + 2g then g2i+1(j ) = 1, and if j 62 f2i + 1; 2i + 2g then g2i+1(j ) = 0.
Lemma 12 typgu(U6; h) = t6 . Proof. Let z 2 T (U6). We shall show that hdU (z) haU (z)+1. Let ? be a decision tree 6
6
over U6 which solves the task z nondeterministically and for which h(?) = haU6 (z). Let be a complete path in the tree ? such that 0 2 A( ). If in the complete path there are no working vertices then, as it is not dicult to show, hdU6 (z) = haU6 (z) = 0. Let there are m > 0 working vertices in the path and S ( ) = fq1(x) = 1 ; : : : ; qm (x) = mg where qi 2 F6 ; 1 i m. Since 0 2 A( ) then 1 = : : : = m = 0. It is clear that for any p 2 A( ) the inclusion ( ) 2 z(p) holds. Let us describe a decision tree ?1 over U6 which solves the task z deterministically and for which h(?1) m + 1. For an arbitrary p 2 ! the decision tree ?1 nds the values q1 (p); : : : ; qm (p). If q1 (p) = : : : = qm (p) = 0 then we have p 2 A( ) and, hence, the task z is solved since we know that ( ) 2 z(p). Let for some j 2 f1; : : : ; mg the equality qj (p) = 1 holds. If qj = fi for some i 2 ! n f0g then we have p = i and, hence, the task z is solved too since we know all the set z(p). Let qj = g2i+1 for some i 2 !. Then we obtain that p 2 f2i + 1; 2i + 2g and we nd the value f2i+1 (p). If f2i+1(p) = 1 then p = 2i + 1, and if f2i+1 (p) = 0 then p = 2i + 2. In this cases the task z is solved too. It is clear that h(?) m. Therefore h(?1 ) haU6 (z) + 1 and hdU6 (z) haU6 (z) + 1. From this inequality it follows that there is no n 2 ! for which UUda6h(n) = 1. Using Lemma 2 we have that Dom(UUda6 ) = fn : n 2 !; n n0 g for some n0 2 !. Let n 2 Dom(UUda6h) and n 1. We shall show that UUda6h(n) n + 1. Let z = (; g1; f1; f2 ; : : :, g2n?1, f2n?1; f2n) be a task from T (U6) such that (1 ) \ (2 ) = ; for any 1 ; 2 2 E23n; 1 6= 2 . It is not dicult to show that haU6 (z) n. Let us prove that hdU6 (z) n + 1. Let ? be a decision tree over U6 which solves the task z deterministically and for which h(?) = hdU6 (z). Let be a complete path in the tree ? such that 0 2 A( ). It is clear that in the complete path there is at least one working vertex. Let S ( ) = fq1 (x) = 1; : : : ; qm (x) = m g, where qi 2 F6; 1 i m. Since 0 2 A( ) then 1 = : : : = m = 0. It is clear that i 62 A( ) for any i 2 f1; : : : ; 2ng. Therefore the equation g2i?1 (x) = 0 or both equations f2i?1 (x) = 0 and f2i (x) = 0 must belong to the system S ( ) for any i 2 f1; : : : ; ng. If the number of working vertices in the path is greater than n then the considered statement holds. Let the number of working vertices in the path is equal to n. Then S ( ) = fg1(x) = 0; : : : ; g2n?1(x) = 0g. Let v be the last working vertex in the path and let the check g2i?1 be assigned to the
vertex v. Let us consider the complete path 0 in the tree ? such that 2i ? 1 2 A( 0). Since ? is a deterministic decision tree then the path 0 contains the vertex v. Assume that in the path 0 there are exactly n working vertices. Then S ( 0) = fg21?1(x) = 0; : : : ; g2(i?1)?1 (x) = 0; g2i?1(x) = 1; g2(i+1)?1(x) = 0; : : : ; g2n?1(x) = 0g and A( 0) = f2i ? 1; 2ig, but this is impossible since z(2i ? 1) \ z(2i) = ;. Consequently, in the path 0 there are at least n+1 working vertices and h(?) n+1. Therefore hdU6 (z) n+1 and UUda6 h(n) n + 1. Taking into account that n is an arbitrary number from ! such that n max(n0; 1), we have that Dom?(UUda6 h) is a nite set and Dom+(UUda6 h) is an in nite set. Consequently, typ(UUda6h) = . Using Proposition 1 we obtain typgu(U6 ; h) = t6 . 2 Let us de ne a t-pair (U7; h) as follows: U7 = (Z; F7), where Z is the set of all integers, F7 = G7 [ L7 , G7 = ffi : i 2 ! n f0gg and L7 = fli : i 2 ! n f0gg. For any i 2 ! n f0g; j 2 Z, if j = ?i then fi(j ) = 1, and if j 6= ?i then fi(j ) = 0. For any i 2 ! n f0g; j 2 Z, if j i then li(j ) = 0, and if j > i then li(j ) = 1. Lemma 13 typgu(U7; h) = t7 . Proof. We prove typ(UUda7h) = . Let n 2 ! n f0g and zn = (n; l1; : : : ; ln) is the task from T (U7) where : E2n ! P (!) and (1 ) \ (2 ) = ; for any 1 ; 2 2 E2n such that 1 6= 2 . It is not dicult to show that for any compatible on Z system of equations fl1(x) = 1; : : : ; ln(x) = n g; where 1 ; : : : ; n 2 E2, there exists a subsystem, which has the same set of solutions and which contains at most two equations. Using this fact it is not dicult to show that haU7 (zn ) 2. Let us prove that there is no m 2 ! such that hdU7 (zn) m for any n 2 ! n f0g. Assume the contrary. Then there exists a number t 2 ! n f0g satisfying the following condition: for any n 2 ! n f0g there exists a decision tree ? 2 DT (U7) which solves the task zn deterministically and has at most t terminal vertices. Let us consider a task zt . Let ? be an arbitrary decision tree over U7 which solves the task zt deterministically. It is not dicult to show that the tree ? must have at least t + 1 terminal vertices. We obtain a contradiction. Thus haU7 (zn) 2 for any n 2 ! nf0g and there is no m 2 ! such that hdU7 (zn ) m for any n 2 ! n f0g. Therefore UUda7 h(2) = 1. Using Lemma 2 we obtain typ(UUda7h) = . We prove the function haU7 is unbounded above on the set T (U7). Assume the contrary. Then there exists m 2 ! such that haU7 (z) m for any z 2 T (U7 ). Let z = (; f1; : : : ; fm+1) be a task from T (U7 ) for which (1 ) \ (2 ) = ; for any 1 ; 2 2 E2m+1 such that 1 6= 2 . Let ? be a decision tree over U7 which solves the task z nondeterministically and for which h(?) = haU7 (z). Let be a complete path in the tree ? such that 0 2 A( ). It is clear that in the complete path there is at least one working vertex. Let S ( ) = fq1 (x) = 1 ; : : : ; qt(x) = t g, where q1; : : : ; qt 2 F7. Since 0 2 A( ) then 1 = : : : = t = 0. It is clear that i 62 A( ) for any i 2 f?1; : : : ; ?m ? 1g. Therefore for any i 2 f1; : : : ; m + 1g the equation fi(x) = 0 is contained in the system S ( ). Consequently, h(?) m + 1 and haU5 (z) m + 1. We obtain a contradiction. Thus the function haU7 is unbounded above on the set T (U7 ). Using Lemma 4 we have typ(UUaa7h) = . Hence and from the equality typ(UUda7h) = , and Proposition 1 it follows that typgu(U7 ; h) = t7. 2 Proof of Proposition 3. The statement of the proposition follows from Lemmas 7 13. 2 Proof of Proposition 4. The statement of the proposition follows from Lemmas 8 13. 2
4 Auxiliary Statements We shall prove some auxiliary statements which will help us to analyze the relationships between global upper types and global types of t-pairs. Let X be a nonempty set, f : X ! ! and g : X ! !. We de ne partial functions fg U : ! ! ! and Lgf : ! ! ! as follows: if n 2 ! then
U fg (n) = maxff (x) : x 2 X; g(x) ng; Lgf (n) = minfg(x) : x 2 X; f (x) ng: The notation U fg (n) = 1 means that ff (x) : x 2 X; g(x) ng is an in nite set. Evidently if U fg (n) = 1 then U fg (n + 1) = 1. It is not dicult to prove
Lemma 14 The following statements hold: a) If there exists n 2 ! such that U fg (n) = 1 then typ(U fg ) = . b) If there is no n 2 ! such that U fg (n) = 1 then Dom(U fg ) = fn : n 2 !; n ng g where ng = minfg(x) : x 2 X g. c) If the function f is bounded above on X then typ(Lgf ) = . d) If the function f is unbounded above on X then Dom(Lgf ) = !. Lemma 15 The following statements hold: a) typ(U fg ) = i typ(Lgf ) = . b) typ(U fg ) = i typ(Lgf ) = . Proof. a) Let typ(U fg ) = . Using Lemma 14 one can prove that the function f is bounded above on X and typ(Lgf ) = . Let typ(Lgf ) = . From Lemma 14 one can prove that the function f is bounded above on X and typ(U fg ) = . b) Let typ(U fg ) = . By Lemma 14 we have the function f is unbounded above on X and there exists m 2 ! such that U fg (m) = 1. Therefore Dom(Lgf ) = ! and Lgf (n) m for any n 2 !. Consequently typ(Lgf ) = . Let typ(Lgf ) = . Using Lemma 14 we have that Dom(Lgf ) = ! and there exists m 2 ! such that Lgf (n) m for any n 2 !. Therefore U fg (m) = 1 and typ(U fg ) = . 2 Lemma 16 Let typ(U fg ) =6 and typ(U fg ) =6 . Then a) jDom? (U fg )j < 1 i jDom+ (Lgf )j < 1. b) jDom+ (U fg )j < 1 i jDom? (Lgf )j < 1. Proof. Using Lemmas 14 and 15 we have that Dom(U fg ) = fn : n 2 !; n ng g and Dom(Lgf ) = !, where ng = minfg(x) : x 2 X g. a) Let jDom?(U fg )j < 1. Then there exists m 2 !; m ng ; such that U fg (n) > n for any n 2 !; n m. Let n m. Then there exists an element x0 2 X such that g(x0) n and f (x0) n + 1. Therefore Lgf (n + 1) n. Consequently Lgf (n) < n for any n 2 !; n m + 1, and jDom+(Lgf )j < 1. Let jDom+(Lgf )j < 1. Then there exists m 2 ! such that Lgf (n) < n for any n 2 !; n m. Let n 2 ! and n m. Then there exists an element x0 2 X such that g(x0) n ? 1 and f (x0) n. Therefore U fg (n ? 1) n. Consequently U fg (n) > n for any n 2 !; n m ? 1, and jDom?(U fg )j < 1. b) Let jDom+(U fg )j < 1. Then there exists m 2 !; m ng , such that U fg (n) < n for any n 2 !; n m. Let n m. Then for any element x 2 X such that g(x) n the
inequality f (x) < n holds. Therefore for any element x 2 X such that f (x) n the inequality g(x) > n holds. Consequently Lgf (n) > n and jDom?(Lgf )j < 1. Let jDom?(Lgf )j < 1. Then there exists m 2 ! such that Lgf (n) > n for any n 2 !; n m. Let n 2 ! and n max(m; ng ). Then for any element x 2 X such that f (x) n the inequality g(x) > n holds. Therefore for any element x 2 X such that g(x) n the inequality f (x) < n holds. Consequently U fg (n) < n and jDom+(U fg )j < 1. 2
Lemma 17 The following statements hold: a) typ(U fg ) = i typ(Lgf ) = . b) typ(U fg ) = i typ(Lgf ) = . c) typ(U fg ) = i typ(Lgf ) = . Proof. a) Let typ(U fg ) = . Using Lemma 15 we have that Dom(Lgf ) is an in nite set. From Lemma 16 it follows that jDom?(Lgf )j < 1. Therefore typ(Lgf ) = . Let typ(Lgf ) = . Using Lemma 15 we have that Dom(U fg ) is an in nite set and the function U fg is unbounded above. From Lemma 16 it follows that jDom+(U fg )j < 1. Therefore typ(U fg ) = . b) Let U fg = . Using Lemma 16 we have that typ(Lgf ) = . Let typ(Lgf ) = . From Lemma 15 we have that typ(U fg ) = 6 and typ(U fg ) =6 . From here and from Lemma 16 it follows that typ(U fg ) = . c) Using Lemma 15 and statements a), b) of Lemma 17 we have that typ(U fg ) = i typ(Lgf ) = . 2 Let us de ne a function : f; ; ; ; g ! f; ; ; ; g as follows: () = ; ( ) = ; ( ) = ; () = ; () = .
Proposition 5 Let X be a nonempty set, f : X ! !; g : X ! !; U fg (n) = maxff (x) : x 2 X; g(x) ng and Lgf (n) = minfg(x) : x 2 X; f (x) ng for any n 2 !. Then typ(Lgf ) = (typ(U fg )). Proof. The statement of the proposition follows from Lemmas 15 and 17. 2
5 Proofs of Theorems 1 and 2 Using Proposition 5 we obtain the following statement.
Proposition 6 Let (U; ) be a t-pair and b; c 2 fi; d; ag. Then typ(LcbU ) = (typ(UUbc )): Proof of Theorem 1. The statement of the theorem follows from Propositions 1, 3 and 6. 2
Proof of Theorem 2. The statement of the theorem follows from Propositions 2, 4 and 6. 2
Acknowledgement
I am greatly indebted to Professor Andrzej Skowron for constructive criticism on an earlier version of this paper.
References [1] R. Ahlswede and I. Wegener, Suchprobleme, B.G.Teubner, Stuttgart, 1979. [2] M. Ben-0r, Lower bounds for algebraic computation trees, Proc. 15th ACM Annual Symp. on Theory of Comput., pp. 80-86 (May 1983). [3] I. A. Chegis and S. V. Yablonskii, Logical methods for electric circuits control, Trudy MI AN SSSR, 51, 270-360 (1958) (in Russian). [4] E. Humby, Programs from Decision Tables, Macdonald, London and American Elsevier, New York, 1973. [5] F. Meyer auf der Heide, A polynomial linear search algorithm for the n-dimensional knapsack problem, J. ACM, 31(3), 668-676 (1984). [6] M. Ju. Moshkov, On the conditional tests, Dokl. Akad. Nauk SSSR, 265(3), 550552 (1982) (in Russian). [7] M. Ju. Moshkov, Conditional tests, in Problemy Cyberneticy, Edited by S. V. Yablonskii, 40, Nauka, Moscow, 131-170 (1983) (in Russian). [8] M. Ju. Moshkov, Decision trees with quasilinear checks, Trudy IM SO RAN, 27, 108-141 (1994) (in Russian). [9] M. Moshkov, Optimization problems for decision trees, Fundamenta Informaticae, 21(4), 391-401 (1994). [10] M. Ju. Moshkov, Decision Trees. Theory and Applications, Nizhni Novgorod State University, Niznhi Novgorod, 1994 (in Russian). [11] Z. Pawlak, Rough Sets - Theoretical Aspects of Reasoning about Data, Kluwer Academic Publishers, Dodrecht, Boston, London, 1991. [12] C. F. Picard, Theorie des Questionnaires, Gauthier-Villars, Paris, 1965. [13] F. P. Preparata and M. I. Shamos, Computational Geometry: An Introduction, Springer-Verlag, 1985. [14] J. R. Quinlan, Induction of decision trees, Machine Learning, 1(1), 81-106 (1986). [15] A. Skowron and C. Rauszer, The discernibility matrices and functions in information systems, in Intelligent Decision Support. Handbook of Applications and Advances of the Rough Set Theory, Edited by R. Slowinski, Kluwer Academic Publishers, Dodrecht, Boston, London, 331-362 (1992). [16] V. P. Tarasova, Method of Opponent Strategy in Problems of Optimal Search, Moscow State University, Moscow, 1988 (in Russian).