# Modeling Human Encounter Situation Awareness Results Using Support Vector Machine Models
## 2 Materials and Methods
### Classification Model
#### 2.4.1 Support Vector Machine  
The support vector machine is a model that finds hyperplanes that efficiently classify a given data [30]. Support vector machines have been reported to perform well in generalization because they aim to minimize training errors [31]. The method for selecting a hyperplane in a support vector machine is to find the hyperplane as the optimal solution, where the margin of the distance of the class data is maximized. The definitions of data input into the model are \(D=\left\{(x_{1},y_{1}),(x_{2},y_{2}),\cdots(x_{i},y_{i}),y_{i}\in\left\{-1,1 \right\}.\right.\) The equation defining the hyperplane classifying classes according to the label is \(w\cdot x_{i}+b=0\). Here, \(w\) is the gradient of the hyperplane, \(x\) is the location of the data on the hyperplane, and \(b\) is the bias. The separation hyperplane of the two classes of data is defined as \(w\cdot x_{i}+b\geq+1\) (for \(y_{i}=+1\)) and \(w\cdot x_{i}+b\leq-1\)(for \(y_{i}=-1\)). Equation (21) is derived by combining the two equations as constraint terms.  
\[y_{i}(w\cdot x_{i}+b)\geq 1 \tag{21}\]  
The data points on the separation hyperplane of each class are called support vectors. They are defined as \(w\cdot x_{i}+b=\pm 1\). The margin is the distance (\(2/\|w\|_{2}\)) between the two  
Figure 3: Illustration of examples of the survey questionnaire. (**a**) The calculation results of OS’s Bearing 000\({}^{\circ}\), TS’s Aspect 340\({}^{\circ}\)DCPA 1.1 miles, TCPA10.8 min, (**b**) OS’s Bearing 355\({}^{\circ}\), TS’s Aspect 015\({}^{\circ}\)DCPA 0.6 miles, TCPA10.8 min, and (**c**) OS’s Bearing 000\({}^{\circ}\), TS’s Aspect 355\({}^{\circ}\)DCPA 0.3 miles, TCPA10.8 min.  
support vectors. The support vector machine model is guided to Equation (22), which minimizes the reciprocal of the distance, in that it is a model that maximizes the margin.  
\[max\;Margin=min\frac{1}{2}\|w\|_{2} \tag{22}\]  
Equations (21) and (22) are only available when they are entirely linearly separable. Therefore, Equations (23) and (24) are derived by adding terms that allow errors (\(\xi_{i}\)).  
\[max\;Margin=\text{minimize}\frac{1}{2}\|w\|_{2}^{2}+C\sum_{i=1}^{n}\xi_{i} \tag{23}\]  
\[y_{i}(w\cdot x_{i}+b)\geq 1-\xi_{i},i=1,2,\ldots,n \tag{24}\]  
Here, \(\xi_{i}\) is an error, and \(C\) is a regulatory term that regulates the error. The lower the regulation, the more training errors are allowed so that underfitting can occur. In contrast, the higher the regulation, the more overfitting can occur because training errors are not allowed.  
Kernel transformations that map predictors to higher dimensions are used to model boundaries that can be constructed non-linearly. The kernel includes linear, polynomial (\(d^{th},d\geq 2\)), and Gaussian kernel. Equations (25)-(27) define linear, polynomial, and Gaussian kernels.  
\[K\langle x_{1},x_{2}\rangle=\langle x_{1},x_{2}\rangle \tag{25}\]  
\[K\langle x_{1},x_{2}\rangle=\left(a\langle x_{1},x_{2}\rangle+b\right)^{d} \tag{26}\]  
\[K\langle x_{1},x_{2}\rangle=\exp\left(\frac{-\|x_{1}-x_{2}\|_{2}^{2}}{2\sigma ^{2}}\right) \tag{27}\]