## 2 Methods
### Support Vector Machine and Regression  
The SVM is one of the well-known machine learning techniques and has the advantage of its generalizing ability and having the optimal global solution, due to the fact that it uses the principle of minimizing the structural risk (maximum margin), unlike the neural network which adopts the empirical risk minimization principle (minimize residual) [21; 22].  
The SVM is also suitable for complex systems and has robust performance when processing corrupted data. The SVM is a classifier that maximizes the margin, the distance between support vectors. A support vector is a data element closest to the hyperplane in multidimensional space. The SVM generates hyperplanes in high density or spaces with infinite dimensions in which data analyses such as classification or regression can be conducted [22]. The excellent separation is achieved by the hyperplane that is the longest distance from the closest training data point of a class, since the larger the margin, the lower the generalization error of the classifier [23; 24; 25].  
Let \(w\) be a normal vector, \(y_{i}\) is a variable that indicates the group to which \(x\) belongs by 1 and \(-\)1, and \(b\) is the distance from the point where \(x\) is projected to \(w\). In this case, the hyperplane satisfying \(w\cdot x-b\geq 1\) (when \(y_{i}=1\)) or \(w\cdot x-b\leq-1\) (when \(y_{i}=-1\)) is the line passing through the support vector [22]. Since there is no other data between these distances (hard margin), the following constraints and object function are expressed.  
\[\arg\min_{(w,b)}\lVert w\rVert \tag{6}\]  
\[subject\ to\ y_{i}(w\cdot x-b)\geq 1 \tag{7}\]The objective function is a problem of finding the norm of the normal vector, which is a problem of finding the square root. The Lagrange multiplier can be used to find the saddle point as in the following and this is solved by partial differential equations [22]. The SVM permits soft margins that allow some classification error to avoid over-fitting. A misclassification tolerance term \(\xi_{i}\) is added to the objective function ([21], Chapter 8).  
\[\underset{(w,b)}{min}\|w\|^{2}+C\sum_{i=1}^{n}\xi_{i} \tag{8}\]  
\[subject\text{ to }y_{i}(w\!:\!x-b)\geq 1-\xi_{i} \tag{9}\]  
The SVM uses a kernel trick that replaces the calculation of the inner product of the vector with the kernel function to reflect the nonlinearity [23]. Linear classification was performed at the modified high dimension, but nonlinear classification was performed in the original space. There were Linear, polynomial, and radial basis kernel function, and this study used a radial basis function. The support vector regression, which is a regression model using SVM, can be expressed as below using the soft margin. \(\Gamma\) is the cost function [25].  
\[f(x)=C\!\!\sum_{i=0}^{l}\Gamma(f(x_{i}-y_{i}))+\|w\|^{2} \tag{10}\]  
The partial differential is \(w=\sum_{i=0}^{l}(\alpha_{i}\!-\!\alpha_{i}^{*})\Phi(x_{i})\). As a consequence, the \(f(x)\) is \(\sum_{i=0}^{l}(\alpha_{i}-\alpha_{i}^{*})(\Phi(x_{i})\!\cdot\!\Phi(x))+b\). The dot product of \((\Phi(x_{i})\!\cdot\!\Phi(x))\) can be replaced by the kernel function, and it is as in the following [23]. This study used a radial basis kernel function as used in Wu [26] for traffic data.  
\[f(x)=\sum_{i=0}^{l}(\alpha_{i}-\alpha_{i}^{*})k(x_{i},x_{i})+b \tag{11}\]