# Accurate Determination of Geographical Origin of Tea Based on Terahertz Spectroscopy
## 3 Classification Model  
In the proposed combination method, SVM is used to establish the classifiers of the four types of green tea. The SVM method is based on Vapnik-Chervonenkis theory and structural risk minimization principle, which is based on statistical learning theory; this method can be applied by using limited information of samples to determine an ideal compromise between model complexity and learning ability, and to achieve optimum generalization [22]. SVM is characterized by strong theoretical and mathematical bases and is not prone to local minimum problems. Learning a small sample also provides a strong generalization ability [23; 24]. In short, SVM application reduces the dependence on the quantity of samples. Considering the training samples \(x_{i}\), \(y_{i}\), \(i=1,\,\ldots,\,n;y_{i}\in\{-1,1\}\) with \(x_{i}\) as the \(i\)-th sample of the input model and \(y_{i}\) as the symbol, we derived the hyperplane equation of separation as follows:  
\[\Omega x+b=0,\,\omega\in R^{n},\,b\in R \tag{2}\]  
where \(\omega\) is a normal vector of the hyperplane, \(b\) is a constant of the hyperplane, and \(d\) is the \(d\)-dimensional space. The GA derives from computer simulation research on biological systems. It is a tool used for random overall searching and optimization developed on the basis of simulations of natural biological evolution, [PERSON]'s evolution theory, and [PERSON]'s heredity theory. It is an efficient, parallel, and comprehensive searching method that automatically obtains and accumulates knowledge of a searching space through a searching process which is controlled to determine optimum solutions through self-adaptation. GA is used in the proposed combination method to optimize the parameters. The selection of penalty factor c and kernel parameter g directly influence the identification results of the SVM model, so the parameters should be optimized accordingly. A flowchart of the GA-SVM algorithm is provided in Figure 4. The detailed steps of GA for the selection of SVM parameters are as follows:  
1 Produce a set of SVM parameters at random and obtain a certain coding scheme to encode each parameter of the SVM to create the initial group. 2 Calculate the error function and affirm its adaptation. If the error is large, adaptation is small. 3 Select several individuals with the best adaptation and directly pass them to the next generation. 4 Use crossed, variant, and other genetic operators to manage the group of the current generation and produce the group of the next generation. Figure 3: (**a**) The time domain signals of reference (pure PE pellet) and a Maofeng sample; (**b**) the absorption of maofeng sample at 0.2–1 THz; and (**c**) the refractive index of Maofeng sample at 0.2–1.2 THz. Repeat Step 2 and continuously evolve the group of the SVM parameters affirmed initially until the training objectives are satisfied. Principal component analysis (PCA) is mainly utilized to reduce data dimensions and remove overlapping information [25]. A small number of new variables can be created by converting the original spectral variables into linear combinations of the original variables; the new variables can maximize the presentation of the data structure and desirable features of the original variables without losing essential information. The set of original data can apply the first k principal components to replace the approximation when the contribution rate of the accumulative variance of the currently-stated k principal component is sufficiently large (85%, usually). The THz spectrum between 0.2 and 1.0 THz of tea samples was selected as a feature for identification. PCA was performed to reduce the dimensionality of original THz spectroscopic data and extract the features of said data. After performing PCA, the first three principal components were extracted from the THz spectra data of 160 reference samples. The first three principal components were those three whose cumulative contribution rates were the largest.