## 3 Algorithm
Calculate the likelihood ratio estimates for all orthants of the target class \(q=1,2,\ldots,Q_{1}\) and obtain the training set \(\{\mathbf{x}^{(q)},L^{(q)}\}\). 2. Renumber the orthants \(W^{(q)}\) in accordance with the decrease in the likelihood ratio estimates \(L^{(1)}\geq L^{(2)}\geq\cdots\geq L^{(Q_{1})}\). 3. For points of the set \(W^{(1)}\), determine the values of the functions \[U(\mathbf{x})^{(1)}=P_{1}^{(1)}\] (5) is the probability of a sample point of class \(\omega_{1}\) in the orthant \(W^{(1)}\), and \[V(\mathbf{x})^{(1)}=P_{2}^{(1)}\] (6)  
is the probability of a sample point of class \(\omega_{2}\) in the orthant \(W^{(1)}\). Determine for points from the set \(W^{(2)}\backslash W^{(1)}\) the values of the functions \(U(\mathbf{x})^{(2)}\) and \(V(\mathbf{x})^{(2)}\), where \(U(\mathbf{x})^{(2)}\) is the probability, which is defined as the ratio of the number of points of class \(\omega_{1}\) from the set \(W^{(1)}\cup W^{(2)}\) to the number of all points \(Q_{1}\) of the training sample of the class \(\omega_{1}\); \(V(\mathbf{x})^{(2)}\) is the probability equal to the ratio of the number of points of class \(\omega_{2}\) from the set \(W^{(1)}\cup W^{(2)}\) to the number of points \(Q_{2}\) of the class of the training sample \(\omega_{2}\). Determine for points from the set \(W^{(3)}\backslash(W^{(1)}\cup W^{(2)})\) the values of the probabilities \(U(\mathbf{x})^{(3)}\) and \(V(\mathbf{x})^{(3)}\), which are calculated from the set \(W^{(1)}\cup W^{(2)}\cup W^{(3)}\). Next, in the same way, calculate the values \(U(\mathbf{x})^{(n)}\) and \(V(\mathbf{x})^{(n)}\) on the sets of points of the feature space in accordance with the orthant numbering specified in Step 2. Assign the value \(U(\mathbf{x})=V(\mathbf{x})=1\) to other points of the feature space. Thus, a system of nested sets is constructed on the space of features for the training sample. The system defines two functions related to each other by a monotonic dependence \(U(V)\), where \(U=U(\mathbf{x})\) is the probability of the successful classification of objects of class \(\omega_{1}\) and \(V=V(\mathbf{x})\) is the probability of erroneous classification of objects of class \(\omega_{2}\). From the values of the functions \(U(\mathbf{x})\) and \(V(\mathbf{x})\) for any given values of the thresholds \(\alpha\) and \(\beta\), we can calculate the decision rule of classification: \(\mathbf{x}\in\omega_{1}\) if \(V(\mathbf{x})\leq\alpha\) and \(\mathbf{x}\in\omega_{2}\) if \(V(\mathbf{x})>\alpha\) or \(\mathbf{x}\in\omega_{1}\) if \(U(\mathbf{x})\leq\beta\) and \(\mathbf{x}\in\omega_{2}\) if \(U(\mathbf{x})>\beta\). The resulting decision rules can be represented as logical functions of features. These solutions explain the classification rule in terms of the problem domain. The logic function calculation algorithm consists of the following steps:  
1. Select points \(\mathbf{x}^{(q)}\) of the target class \(\omega_{1}\), for which the probability of misclassification of objects of class \(\omega_{2}\) as objects of class \(\omega_{1}\), \(V(\mathbf{x})\leq\alpha\) (to select points, a similar condition \(U(\mathbf{x})\leq\beta\)) can be used). 2. Construct the membership matrix \((M_{pq})\). The rows of the matrix denote the orthants \(W^{(p)}\), with vertices at points \(\mathbf{x}^{(p)}\) selected in the previous step, and the columns of the matrix denote the points of the target class \(\mathbf{x}^{(q)}\). Matrix element \(m_{pq}=1\), if point \(\mathbf{x}^{(q)}\) of the class \(\omega_{1}\) belongs to the orthant with index \(p\), and \(m_{pq}=0\) otherwise. The belonging of a point in the feature space to the orthant \(W^{(p)}\) is determined by the conjunction: \(\mathbf{x}\in W^{(p)}\) if \(x_{i}\leq x_{i}^{(p)}\) for all \(i=1,2,\ldots,I\). The set of rows of the matrix corresponds to the disjunction of the conjunctions. 3. Determine a subset of the minimum number of orthants that contains all points of the target class selected in Step 1.