Research on the Effects of Drying Temperature on Nitrogen Detection of Different Soil Types by Near Infrared Sensors

Soil is a complicated system whose components and mechanisms are complex and difficult to be fully excavated and comprehended. Nitrogen is the key parameter supporting plant growth and development, and is the material basis of plant growth as well. An accurate grasp of soil nitrogen information is the premise of scientific fertilization in precision agriculture, where near infrared sensors are widely used for rapid detection of nutrients in soil. However, soil texture, soil moisture content and drying temperature all affect soil nitrogen detection using near infrared sensors. In order to investigate the effects of drying temperature on the nitrogen detection in black soil, loess and calcium soil, three kinds of soils were detected by near infrared sensors after 25 °C placement (ambient temperature), 50 °C drying (medium temperature), 80 °C drying (medium-high temperature) and 95 °C drying (high temperature). The successive projections algorithm based on multiple linear regression (SPA-MLR), partial least squares (PLS) and competitive adaptive reweighted squares (CARS) were used to model and analyze the spectral information of different soil types. The predictive abilities were assessed using the prediction correlation coefficients (RP), the root mean squared error of prediction (RMSEP), and the residual predictive deviation (RPD). The results showed that the loess (RP = 0.9721, RMSEP = 0.067 g/kg, RPD = 4.34) and calcium soil (RP = 0.9588, RMSEP = 0.094 g/kg, RPD = 3.89) obtained the best prediction accuracy after 95 °C drying. The detection results of black soil (RP = 0.9486, RMSEP = 0.22 g/kg, RPD = 2.82) after 80 °C drying were the optimum. In conclusion, drying temperature does have an obvious influence on the detection of soil nitrogen by near infrared sensors, and the suitable drying temperature for different soil types was of great significance in enhancing the detection accuracy.


Introduction
Soil, which provides nutrients in the process of plant growth, is the foundation and plays an important role in agriculture. Thus, it is of great importance to obtain soil nutrient elements such as soil nitrogen quickly and accurately for precision fertilization and agricultural production [1,2]. Many conventional soil analytical techniques such as Dumas combustion are often complex, with multi-component interactions [3]. At present, near infrared sensors (NIR) have been successfully applied to the fields of agriculture, food, medicine, petroleum and chemistry, and are one of the most important analytical methods, indispensable in qualitative and quantitative analysis [4,5]. In recent years, many scholars have used near infrared sensors to detect soil nitrogen and improved the detection accuracy in the aspects of soil pretreatments, spectral data processing, characteristic band selection and algorithm optimization. comes from the Greater Khingan region, whose pH value is neutral to slightly alkaline. Loess comes from Xi'an, Shanxi province, whose soil properties are loose and porous. Calcium soil with the features of loose and poor structure is from Jinan, Shandong province. The soil sample preparation process was as follows. First, the soil samples were sieved with a 40 mesh sieve (0.425 mm) and grinded; in addition, the urea solutions with different concentrations were prepared. Second, different nitrogen concentration gradients for three kinds of soils were prepared, that were, loess (0.09-0.93 g/kg, 0.1 g/kg per gradient), calcium soil (0.32-1.17 g/kg, 0.1 g/kg per gradient), black soil (0.46-2.15 g/kg, 0.2 g/kg per gradient). Meanwhile, the three kinds of soils without urea added were set as references. There were 16 samples for each concentration, and each soil type contained 11 nitrogen gradients. Third, the experiments were carried out in four groups, each group containing three soil types. Black soil, loess and calcium soil were dried after 50 °C for 24 h (group I), 80 °C for 18 h (group II) and 95 °C for 12 h (group III) respectively. Other soil samples were dried and then placed at 25 °C for 12 days (group IV).

Spectrometric Determination
The portable near infrared optical instrument is from Isuzu Optics Corp (Shanghai, China). It is an interferometer instrument which is reflective with two integrated tungsten halogen lamps. The instrument collects spectral information in the range of 900-1700 nm, whose optical resolution is 10 nm and the signal-noise ratio is 5000:1 in a 1 s scan; the size is 120 × 85 × 54 mm and the weight is 900 g. The soil detection platform is shown in Figure 1. When the spectrum of soil were measured, the samples were placed on the light source window, which avoided the phenomenon of light leakage since the size of the soil sample is larger than that of the light source window. Before performing the spectroscopic measurement, the instrument should be preheated for 15 min and be prepared with blackboard and whiteboard correction operation. In order to maintain the integrity of the original soil spectra and the rapidity of the detection process, the spectral acquisition parameter is set up as 400 points, and the spectrum is obtained by averaging three scans.

Data Analysis
Near infrared light is an electromagnetic wave between the infrared and visible light whose wavelength range is from 780 nm to 2526 nm [30]. The spectral information originates from the vibration of the O-H, C-H and N-H groups, which can reflect the variety of organic matter in the characteristic signal of the spectral region [31]. According to Lambert absorption law [32], the spectral characteristics would change as material composition or structure changes. However, at the same time, it can also be affected by the soil surface texture, density and uneven distribution of internal components, which is very difficult for all the redundant information of the spectral data to be eliminated, such as the overlap. Therefore, in order to achieve the purpose of qualitative or When the spectrum of soil were measured, the samples were placed on the light source window, which avoided the phenomenon of light leakage since the size of the soil sample is larger than that of the light source window. Before performing the spectroscopic measurement, the instrument should be preheated for 15 min and be prepared with blackboard and whiteboard correction operation. In order to maintain the integrity of the original soil spectra and the rapidity of the detection process, the spectral acquisition parameter is set up as 400 points, and the spectrum is obtained by averaging three scans.

Data Analysis
Near infrared light is an electromagnetic wave between the infrared and visible light whose wavelength range is from 780 nm to 2526 nm [30]. The spectral information originates from the vibration of the O-H, C-H and N-H groups, which can reflect the variety of organic matter in the characteristic signal of the spectral region [31]. According to Lambert absorption law [32], the spectral characteristics would change as material composition or structure changes. However, at the same time, it can also be affected by the soil surface texture, density and uneven distribution of internal components, which is very difficult for all the redundant information of the spectral data to be eliminated, such as the overlap. Therefore, in order to achieve the purpose of qualitative or quantitative analysis of complex mixtures, it is necessary to extract and analyze the weak chemical information by chemometrics method in the spectral analysis. In this paper, the original spectra were preprocessed by Savitzky-Golay (S-G) smoothing. Then three modeling methods were used to model and analyze the spectral information. The SPXY method [33] was used to divide the three soil samples into two groups according to the proportion of 2:1, among which 118 soil samples (N1) were calibrated and 58 soil samples (N2) were validated at different temperatures and different soils. All data analysis was based on MATAB R2014a (The Math-Works, Natick, MA, USA).

Spectral Preprocessing Method
Savitzky-Golay (S-G) smoothing [34], also known as polynomial smoothing, uses the weighted average method to quantize the data in the moving window by polynomial least squares fitting as well as emphasizing the central role of the center point. The formula of average wavelengths after S-G smoothing is where H is the normalization factor, hi is the smoothing coefficient and H = ∑ +W I=−W h i . The measured value multiplied by the smoothing coefficient minimizes the smoothing influence on the useful information. In the experiment, the S-G was used to remove the background noise of the instrument and the noise of the spectrum.

SPXY Method
SPXY, the method of choosing the calibration sample, was put forward on the basis of KS methods by Galvao et al. [35]. The basic principle is that spectrum and concentration variables are considered at the same time to calculate the distance of the samples, the distance formula is as follows: In the formula, d x (i, j) is based on spectral characteristic parameters for the calculation of the distance between the samples, while d y (i, j) is based on concentration characteristic parameters for the calculation of the distance between the samples-which makes the sample in spectrum space and concentration space have the same weightiness-divided by their corresponding maximum standardizing, respectively. z is spectral space.

Partial Least Squares Method
Partial least squares regression (PLSR) is one of the most widely used methods for quantitative correction in chemometrics. In the PLS model, the principal components of the matrix X and the matrix Y are decomposed in order to extract the most comprehensive variables with respect to the dependent variables and maximize the correlation between the principal component and the concentration, which overcomes the negative effects of the multiple correlation of variables and further improves the reliability of the model [36]. In this paper, the whole band spectral data are used as independent variable X, and the nitrogen content are considered as the dependent variable Y. The minimum cross validation is used to verify the root mean square error cross validation (RMSECV) to determine the optimum number of principal factors.

Successive Projections Algorithm-Multiple Linear Regression (SPA-MLR)
Araujo et al. [37] first proposed the selection of spectral variables by means of the successive projections algorithm (SPA). Soares [38] used SPA for cross-classification analysis. The SPA, a forward variable selection method, uses vector projection analysis to find the variable group with minimal redundancy information to effectively eliminate the collinear, singular and instable variables in the spectra. Since it reduces the number of variables used in the model and lowers the complexity of the model, the collinear between the vectors is minimized. The multiple liner regression (MLR) adopts the least squares method to estimate the coefficient matrix, resulting in the samples whose numbers are more than the number of spectral variables. Extracting feature wavelength modeling based on SPA-MLR has significance in actual detection because of the useful information for mining spectral data with latent variables [39].

Competitive Adaptive Weighting Method (CARS)
The competitive adaptive weighted algorithm method, imitating the evolution of "survival of the fittest" principle, phases out of the invariable wavelength [40]. It uses Monte Carlo sampling or random sampling method to select a part of the sample from the calibration set samples for PLS modeling and repeats this process for hundreds of iterations. In the process of wavelength variable selection, the adaptive weighted sampling method is used to preserve the wavelength variable with the absolute value of PLS regression coefficient, and the wavelength invariable with small absolute value of regression coefficient is removed. In order to obtain a series of wavelength variable subsets, each subset of wavelength variables is modeled by cross validation, and the optimal wavelength variable subset is selected according to the RMSECV value [41].

Model Evaluation Index
In this experiment, the modeling effect is evaluated by the correlation coefficient R, the root mean square error (RMSE) and the residual predictive deviation (RPD). The correlation coefficient R reflects the level of intimacy between variables, root mean square error (RMSE) reflects the accuracy of the model, and RPD reflects the prediction ability of the model. The higher the R and RPD and the lower the RMSE, the better the performance of the prediction model. In this paper, R c and R p represent the correlation coefficient of calibration set and prediction set, respectively, and RMSEC and RMSEP represent the root mean square error of the calibration set and prediction set respectively. Besides this, RPD was suggested to be at least 3 for agriculture applications; 2 < RPD < 3 indicates a model with a good prediction ability; 1.4 < RPD < 2 is an intermediate model needing some improvement; and the RPD < 1.4 indicates a poor prediction ability of the model [42].

Temperature and Soil Reflectance
In this experiment, the spectral information of three kinds of soil samples at four temperatures were collected. According to Figure 2, the abscissa of the curve is the wavelength and the ordinate of the curve is the average spectral reflectance. Figure 2A-D shows the near infrared reflectance curves of the four soils after 50 • C, 80 • C, 95 • C drying and 25 • C placement respectively. First, the near infrared spectra of different soils vary from each other, but the overall trends are similar. The physical properties, chemical properties and soil colors would have certain influence on the absorption of near infrared spectra [43], which results in the differences of spectral curves.
Second, the temperature does affect reflectance strength. The reflectance of the black soil spectral curve at 25 • C placement is significantly lower than other temperatures. The reason is that the water in the soil cannot be completely dried when soil was placed at 25 • C and the water absorption of near-infrared spectroscopy is very sensitive. The loess spectral curves are less affected by temperature because the loess are relatively loose, and porous, thus the water content in loess are easy to evaporate while drying.  Third, the spectral absorption characteristics of those three soils are different. There is an obvious decrease trend in the band 1385 nm among the black soil, loess and calcium soil, which is caused by the vibration of O-H [44]. However, different soils have different characteristic bands. It is suggested in Figure 2a that the spectral reflectance of black soil decreases gradually at 1470 nm with the increase of nitrogen concentration of soil. Figure 2h shows that the spectral reflectance of loess decreases weakly near the band 1160 nm and Figure 2i displays that calcium soil has a spectral absorption at band 1145 nm when the drying temperature is 95 • C. Those mentioned above might be the characteristic bands of soil total nitrogen in different kinds of soils.

SPA-MLR Model
The maximum number of selected variables was set up to 30, and the wavelength variables were selected from the 400 spectral variables based on the minimum error, which are shown in Table 1. Figure 3 presents the SPA wavelength number of loess, calcium soil and black soil, where Figure 3A-D represents the variable number of SPA after soil 50 • C, 80 • C, 95 • C drying and 25 • C placement respectively. It is indicated that although the variable numbers and bands differed in the same soil at different temperatures after the variable selection, the characteristic bands are similar when the temperatures varied small. The variable numbers and bands for different soils on the same drying temperature are not the same, suggesting that both soil type and drying temperature have a great influence on wavelength variables selected by SPA-MLR. The prediction results of SPA-MLR are shown in Table 2 and Figure 4. Both loess (R P = 0.9758, RMSEP = 0.07 g/kg, RPD = 4.35) and calcium soil (R P = 0.9517, RMSEP = 0.103 g/kg, RPD = 3.24) obtain the best detection effect after 95 • C drying, while black soil has a better detection effect after 50 • C (R P = 0.9486, RMSEP = 0.22 g/kg, RPD = 2.82) and 80 • C(R P = 0.9373, RMSEP = 0.234 g/kg, RPD = 2.55) drying, and the three kinds of soils have the worst effect when soils were placed in the 25 • C environment.    On the one hand, the reason might be that medium and high temperature could stimulate the activity of soil urease and remove fully water in soil [45]. Meanwhile, soil water content was preserved little when soils were placed at 25 • C during the long time. Compared with O-H bond, the N-H bond exists mostly in multiple frequency or combination frequency, which was relatively weak in soil spectra and affects the extraction of soil nitrogen information [46].
On the other hand, the information of physical and chemical properties, including iron oxides, particle size distribution and surface roughness vary dramatically in different soils, which reduce or even obscure the spectral effect of nitrogen in soil [43]. Among them, loess mainly contains SiO 2 , Al 2 O 3 and CaO with the properties of being loose and porous, and calcium soil mainly consisted of CaCO 3 . Both loess and calcium soil have few O-H bonds when they were dried, which interferes with the NIR spectrum to a small extent [47].
Hence, the prediction accuracy of loess and calcium soil was the optimum among three kinds of soils. However, the black soil obtains relatively low prediction accuracy because the abundant organic matter and humus in black soil have a strong absorption in NIR, resulting in adverse interference for nitrogen detection [48]. Figure 4 indicates that black soil nitrogen detection ranges from 0.93 g/kg to 1.87 g/kg, and the detection of nitrogen in loess is concentrated in the vicinity of 0.47 g/kg, while the soil nitrogen calcium concentrates from 0.47 g/kg to 0.93 g/kg when soils were placed at 25 • C, which largely deviates from the true values of the nitrogen in soil. The reason might be that the water content in soil was relatively higher when it was placed at 25 • C than when drying at other medium and high temperatures, which affects the extraction of soil nitrogen information [49].
On the one hand, the reason might be that medium and high temperature could stimulate the activity of soil urease and remove fully water in soil [45]. Meanwhile, soil water content was preserved little when soils were placed at 25 °C during the long time. Compared with O-H bond, the N-H bond exists mostly in multiple frequency or combination frequency, which was relatively weak in soil spectra and affects the extraction of soil nitrogen information [46].
On the other hand, the information of physical and chemical properties, including iron oxides, particle size distribution and surface roughness vary dramatically in different soils, which reduce or even obscure the spectral effect of nitrogen in soil [43]. Among them, loess mainly contains SiO2, Al2O3 and CaO with the properties of being loose and porous, and calcium soil mainly consisted of CaCO3. Both loess and calcium soil have few O-H bonds when they were dried, which interferes with the NIR spectrum to a small extent [47].
Hence, the prediction accuracy of loess and calcium soil was the optimum among three kinds of soils. However, the black soil obtains relatively low prediction accuracy because the abundant organic matter and humus in black soil have a strong absorption in NIR, resulting in adverse interference for nitrogen detection [48]. Figure 4 indicates that black soil nitrogen detection ranges from 0.93 g/kg to 1.87 g/kg, and the detection of nitrogen in loess is concentrated in the vicinity of 0.47 g/kg, while the soil nitrogen calcium concentrates from 0.47 g/kg to 0.93 g/kg when soils were placed at 25 °C, which largely deviates from the true values of the nitrogen in soil. The reason might be that the water content in soil was relatively higher when it was placed at 25 °C than when drying at other medium and high temperatures, which affects the extraction of soil nitrogen information [49].

PLS Method Model
The prediction results of PLS are shown in Table 3 and Figure 5. The detection accuracy from high to low is loess, calcium soil and black soil, in that order. Moreover, both loess (RP = 0.9721, RMSEP = 0.067 g/kg, RPD = 4.34) and calcium soil (RP = 0.9588, RMSEP = 0.094 g/kg, RPD = 3.89) have the best detection accuracy after 95 °C drying. However, the black soil (RP = 0.9216, RMSEP = 0.228 g/kg, RPD = 2.72) after 50 °C drying achieves the best detection accuracy of black soil. Moreover, the results of PLS and SPA-MLR are similar, which indicates that medium and high temperatures are helpful for the soil nitrogen detection and the reasons have been discussed in Section 3.2.1.

PLS Method Model
The prediction results of PLS are shown in Table 3 and Figure 5. The detection accuracy from high to low is loess, calcium soil and black soil, in that order. Moreover, both loess (R P = 0.9721, RMSEP = 0.067 g/kg, RPD = 4.34) and calcium soil (R P = 0.9588, RMSEP = 0.094 g/kg, RPD = 3.89) have the best detection accuracy after 95 • C drying. However, the black soil (R P = 0.9216, RMSEP = 0.228 g/kg, RPD = 2.72) after 50 • C drying achieves the best detection accuracy of black soil. Moreover, the results of PLS and SPA-MLR are similar, which indicates that medium and high temperatures are helpful for the soil nitrogen detection and the reasons have been discussed in Section 3.2.1.

PLS Method Model
The prediction results of PLS are shown in Table 3 and Figure 5. The detection accuracy from high to low is loess, calcium soil and black soil, in that order. Moreover, both loess (RP = 0.9721, RMSEP = 0.067 g/kg, RPD = 4.34) and calcium soil (RP = 0.9588, RMSEP = 0.094 g/kg, RPD = 3.89) have the best detection accuracy after 95 °C drying. However, the black soil (RP = 0.9216, RMSEP = 0.228 g/kg, RPD = 2.72) after 50 °C drying achieves the best detection accuracy of black soil. Moreover, the results of PLS and SPA-MLR are similar, which indicates that medium and high temperatures are helpful for the soil nitrogen detection and the reasons have been discussed in Section 3.2.1.

CARS Model Methods
The setting times of the CARS variable selection was 500, and the variable selection process are shown in Figure 6.  Table 4. After the selection, the number of variables and bands differ in the same soil at different drying temperatures and the number of variables and bands in different soil types on the same drying temperature vary from each other as well, indicating that both soil type and soil drying temperature have a great influence on wavelength variables selected by CARS.

CARS Model Methods
The setting times of the CARS variable selection was 500, and the variable selection process are shown in Figure 6.  Table 4. After the selection, the number of variables and bands differ in the same soil at different drying temperatures and the number of variables and bands in different soil types on the same drying temperature vary from each other as well, indicating that both soil type and soil drying temperature have a great influence on wavelength variables selected by CARS.   The prediction results of the CARS are shown in Figure 7 and Table 5. The results of nitrogen prediction of loess (R P = 0.9612, RMSEP = 0.079 g/kg, RPD = 3.92) and calcium soil (R P = 0.9472, RMSEP = 0.112 g/kg, RPD = 3.07) are the best after 95 • C drying. While the black nitrogen prediction was best after 80 • C drying. Also, the three kinds of soils have the worst effects when soils were placed at 25 • C. The results are similar to the SPA-MLR and PLS, which indicates that medium and high temperatures are beneficial to soil nitrogen detection and the reasons have been discussed in Section 3.2.1. The prediction results of the CARS are shown in Figure 7 and Table 5. The results of nitrogen prediction of loess (RP = 0.9612, RMSEP = 0.079 g/kg, RPD = 3.92) and calcium soil (RP = 0.9472, RMSEP = 0.112 g/kg, RPD = 3.07) are the best after 95 °C drying. While the black nitrogen prediction was best after 80 °C drying. Also, the three kinds of soils have the worst effects when soils were placed at 25 °C. The results are similar to the SPA-MLR and PLS, which indicates that medium and high temperatures are beneficial to soil nitrogen detection and the reasons have been discussed in Section 3.2.1.        This indicated that urease in soil was activated and the water content was easier to fully evaporate under medium and high drying temperatures, thus the detection effects were obviously better. However, the information of physical and chemical properties including iron oxides and particle size distribution were different in soil [43], which caused the different detection results when different soils were dried at the same temperature. Moreover, the prediction effects of black soil in 50 °C, 85 °C and 90 °C were worse than that of the loess and the calcium soil, but the results were better than those of other soils when soils were placed at 25 °C, which not only indicated that the physicochemical properties of the black soil caused the difference of the results, but also suggested that the little water preserved in the drying process had the least influence on the nitrogen detection in black soil than other soils. This indicated that urease in soil was activated and the water content was easier to fully evaporate under medium and high drying temperatures, thus the detection effects were obviously better. However, the information of physical and chemical properties including iron oxides and particle size distribution were different in soil [43], which caused the different detection results when different soils were dried at the same temperature. Moreover, the prediction effects of black soil in 50 • C, 85 • C and 90 • C were worse than that of the loess and the calcium soil, but the results were better than those of other soils when soils were placed at 25 • C, which not only indicated that the physicochemical properties of the black soil caused the difference of the results, but also suggested that the little water preserved in the drying process had the least influence on the nitrogen detection in black soil than other soils. Second, different algorithms had different effects on soil nitrogen detection based on the same temperature. The overall detection effect ranking from better to worse was SPA-MLR, PLS and CARS, and the prediction accuracy of SPA-MLR and PLS was similar. The reason might be that SPA-MLR could efficiently eliminate redundant variables, which made the results more accurate and the detection precision higher [39]. The comprehensive variables extracted by PLS performed well in summarizing the information of independent variables, explaining dependent variables and eliminating noise interference in the system, which effectively handled the variables multiple correlation problem [42]. In the CARS, it was difficult to find the best or optimal value of the noise threshold and select the randomness of the characteristic variables, which leaded to the poor prediction results [41]. Figure 9 shows the prediction effects of soils under different drying temperatures using different algorithms. Second, different algorithms had different effects on soil nitrogen detection based on the same temperature. The overall detection effect ranking from better to worse was SPA-MLR, PLS and CARS, and the prediction accuracy of SPA-MLR and PLS was similar. The reason might be that SPA-MLR could efficiently eliminate redundant variables, which made the results more accurate and the detection precision higher [39]. The comprehensive variables extracted by PLS performed well in summarizing the information of independent variables, explaining dependent variables and eliminating noise interference in the system, which effectively handled the variables multiple correlation problem [42]. In the CARS, it was difficult to find the best or optimal value of the noise threshold and select the randomness of the characteristic variables, which leaded to the poor prediction results [41]. Figure 9 shows the prediction effects of soils under different drying temperatures using different algorithms.  As can be seen from the Figure 9, no matter which algorithm was used, the prediction accuracy of black soil was better when the drying temperatures ranged from 50 • C to 80 • C. While the detection accuracy of loess and calcium soil nitrogen obtained better results when the temperatures were in the range of 80 • C to 90 • C.

Conclusions
In this paper, three kinds of soils were used to investigate the effects of drying temperature on soil nitrogen detection using near infrared sensors. The NIR spectra of different soils varied greatly and the spectra of the same soil type changed greatly under different drying temperatures.
The main conclusions are as follows: (1) The drying temperature does have an influence on soil nitrogen detection by near infrared sensors and the suitable drying temperatures for different soils were different, which indicated that it was necessary to find the suitable drying temperature for different soil types to enhance the detection accuracy; (2) the drying temperatures ranged from 50 • C to 80 • C for black soil nitrogen detection accuracy were better than other temperatures, while the loess and calcium soil nitrogen detection had better results when the drying temperature was 95 • C. The O-H bonds of water in soil might be the main factor influencing the prediction accuracy when soils were placed at 25 • C. Besides this, the suitable drying temperatures for more soil types should be further researched; (3) the SPA-MLR and PLS models obtained a better prediction effect for soils, while CARS performed worse. In conclusion, drying temperature had an obvious influence on the detection of soil nitrogen by near infrared sensors, and the suitable drying temperature for different soil types was of great significance in enhancing the detection accuracy.