Keywords

1 Introduction

Nutrients present in soil play a vital role in plant growth. Deficiency as well as excess of these nutrients may impede the productivity. NPK, i.e., nitrogen (N), phosphorous (P), and potassium (K), represent the three most important nutrients in agriculture and are the prime ingredients in almost all fertilizers. Soil is the main source of nutrients for plant growth, and nitrogen is one of the most vital nutrients as it plays a fundamental role in the manufacture of chlorophyll in all plants and is an essential element of enzymatic proteins which catalyze and regulate the biological process responsible for plant growth. Soil spectral properties in the optical domain are related to soil minerals and organic compounds, water content, and soil particle size and structure [1]. Study and understanding of these relationships therefore can be of great significance for development of sensors to determine the quality of soil in terms of nutrients and other properties such as soil pH, salinity. Application of more amount of fertilizers (particularly urea) to soil in order to meet the demands of continually growing world population has led to nutrient imbalance not only in soil but has also caused air and water pollution. Nutrient management of soil is therefore a very critical part of sustainable agricultural practices [2]. Vis-NIR spectroscopy is very useful in measuring the mineral compositions of soil. Visible NIR region contains useful information about organic and inorganic materials present in the soil, and so the soil spectra obtained in this region can be used for soil mapping and monitoring and making inferences about soil quality and fertility. The soil total nitrogen (TN) content is an integral parameter that needs to be measured in precision agriculture. In [3], a portable soil TN detector was developed and a back-propagation neural network (BP-NN) estimation model was established using near-infrared reflectance spectroscopy with absorbance data at near-infrared wavelengths. The soil TN content correlation coefficient R2 of the BP-NN estimation model was 0.88, and the validation R2 was 0.75. In another work [4], a multispectral optical sensor was employed to measure the plant reflectance at four wavelengths, and these data were then used to develop an ANN-based model to predict the nitrogen concentration of leaves of cotton plants. Not only in agricultural fields, NIRS has been also used in dairy farming to monitor the milk quality of cow. In [5], NIRS spectroscopic sensing system has been used to monitor the three major constituents of milk, i.e., fat, protein, and lactose. The soil spectral signature method has also been employed in [6], to estimate the soil moisture content of bare soils from their spectral signatures in 400–2500 nm range. Statistical modeling such as convex envelope and ISER was used for analysis of the spectral signature. In [7], soil organic matter and available NPK were analyzed based on the near-infrared spectroscopy technology. The NIRS data were then analyzed using the least squares support vector machine model which employed the principal component analysis. Chemical fertilizer is added to soil to meet up the nutrients’ requirements of plants, but the uncontrolled addition of these substances can cause severe environmental hazards such as surface and ground water pollution and also affect the quality of the crop [8,9,10,11,12,13,14]. Therefore, a lot of attention has been focused in this area in the recent years, particularly in the area of precision agriculture and site-specific management procedures for obtaining localized on-the-go measurement of NPK in any soil.

2 Materials and Methods

2.1 Study Site and Sampling Design

Soil samples were collected from the turmeric and coconut fields of horticulture research center, Kamrup, on August 10, 2016 around 8:30 a.m. at temperature 23 °C and 65% humidity. Grid sampling method was used to extract the soil from a depth of 20 cm below the surface. All the samples were air-dried for about a week. The texture of the soil was found to be clay loam. The samples were then grinded and sieved through a 2-mm sieve.

2.2 Experimental Procedure

Figure 1 depicts the framework intended for the proposed work. The steps involved are as follows:

Fig. 1
figure 1

Optical structure of the proposed sensing scheme for estimation of nitrogen content

  • Acquire soil samples by an appropriate soil sampling method (grid sampling)

  • Illuminate the soil sample with a proper light source such that it corresponds to the vibrational frequencies of the bonds of the target ion (nitrogen)

  • Measurement of diffuse reflectance from the sample under study

  • Obtain spectral reflectance/absorbance data

  • Statistical analysis of soil spectral signature

  • Development of prediction mathematical models for measurement of target ion concentration in the soil sample based on the unique soil spectra obtained.

As shown in Fig. 1, the optical sensor probe consisted of set 7 LEDS in the range (Vis-NIR) for illuminating the soil sample, and the reflected light from the soil is then detected by set of phototransistors and IR photodetector. Based on these data, the diffuse reflectance is then measured and spectral signature is statistically analyzed to understand the variation in the reflectance based on the amount of nitrogen present in soil.

3 Analysis of Soil Spectral Signature for Nitrogen

To characterize the soil nitrogen content and thereafter obtain a unique spectral signature, it is important to determine the most responsive wavelength. Therefore, reflectance/absorbance data were obtained for seven different wavelengths in the Vis-NIR range. The sample was illuminated with light from seven LEDs sources ranging from UV to IR (380–850 nm) containing the visible and NIR wavelengths. In addition to these, a white LED was also employed. The light was made to fall on the sample at five different positions by rotating the sample holder (petri dish) by 72° each time. The diffused reflected light was then collected at each of the angles by the array of photodetectors. Let Vi be the incident voltage and VR the reflected voltage. Then the reflectance is given by:

$$ \rho = \frac{{V_{\text{R}} }}{{V_{\text{i}} }} $$
(1)

For our case, the reflected voltage is the mean of the voltages collected from five different positions of the sample. Now, the reflectance for the bare soil is given by:

Finally the normalized reflectance is calculated as:

$$ R = \frac{{\rho_{\text{WC}} }}{{\rho_{\text{NC}} }} = \frac{{V_{\text{RWC }} }}{{V_{\text{RNC }} }} $$
(2)
$$ {\text{i}} . {\text{e}} . , R = \frac{{{\text{Reflected}}\;{\text{voltage}}\;{\text{from}}\;{\text{the}}\;{\text{sample}}\;{\text{with}}\;{\text{chemical}}}}{{{\text{Reflected}}\;{\text{voltage}}\;{\text{from}}\;{\text{the}}\;{\text{bare}}\;{\text{sample}}\;{\text{without}}\;{\text{chemical}}}} $$
(3)

Thus, the normalized reflectance is the ratio of the reflected output voltage obtained from the sensor for sample with the target chemical to the reflected output voltage obtained from the sensor for bare sample. After obtaining the reflectance data from the sensor, the spectral signature of soil total nitrogen content is obtained and based on the unique spectral signature obtained, regression models have been built for prediction and performance analysis of the system.

4 Mathematical Modeling of Soil Nitrogen Content

For each soil sample, several experiments were carried out to obtain the soil spectral signature of soil nitrogen content (SNC). Optimization techniques have been used to obtain the best-fit parameters for the soil nitrogen content characteristics curve. The curve fitting method determines model parameters such that the mathematical function passes through most of the experimental and gives the best fit. Based on the analyses of the soil spectral signature obtained, two models were developed: (1) multilinear polynomial regression model(fourth and fifth orders) and (2) exponential regression model.

4.1 Soil Spectral Signature of Soil Nitrogen Content

Based on the reflectance data obtained in the region UV-Vis-NIR, the spectral signature was obtained and it was found to follow a unique pattern as shown in Fig. 2. Two multilinear regression models (of fourth and fifth orders) were estimated using curve fitting for analysis of the soil spectral signature as shown in Fig. 3. The fourth- and fifth-order estimated models obtained from the best-fitted curve are given by:

Fig. 2
figure 2

Soil spectral signature for varying amount of soil nitrogen

Fig. 3
figure 3

Measured and fitted graphs for soil spectral signature obtained for 1, 2, 4, 5 grams of nitrogen content in 20 grams of soil (solid lines show the measured data and the dotted lines show the predicted data)

$$ Y = - a_{5 } X^{5} + a_{4 } X^{4} - a_{3 } X^{3} + a_{2 } X^{2} - a_{1 } X + \varepsilon $$
(4)
$$ Y = - a_{4 } X^{4} + a_{3 } X^{3} - a_{2 } X^{2} + a_{1 } X - \varepsilon $$
(5)

The magnitude of coefficients of reflection (a5, a4, a3, a2, a1) followed a specific trend and correlation with the amount of nitrogen content in soil. So, a transformed quadratic regression model named as sum of square root of reflection coefficients (SSRC) was obtained for further statistical analysis as shown in Fig. 4. The transformed model besides reducing the complexities also aided in better analysis of the model parameters.

Fig. 4
figure 4

Signature of the transformed model employing the reflection coefficients

4.2 Exponential Regression Model for Infrared Source

From the experimental data analysis and the graphs, it is apparent that in the entire spectrum, the infrared sensor appeared to produce the best correlation with the soil total nitrogen content. So, a separate model was developed to characterize the soil nitrogen content as shown in Fig. 5. Curve fitting was employed, and the exponential regression model that gave the best fit is given by:

Fig. 5
figure 5

Exponential model for infrared signature of soil nitrogen content (solid lines show the measured data and dotted lines show the predicted data)

$$ Y = A\exp \left( { - bX} \right) $$
(6)

5 Results and Discussions

For the quantitatively assessing the performance of the various models expressed in Eqs. (4), (5), and (6), we have employed statistical measures such as correlation coefficient (r), coefficient of determination (R2), root mean square error (RMSE), and standard error of estimate (SEE). Moreover, each experiment was repeated under the same physical conditions several times to check the stability and reproducibility of the system. This is shown in Fig. 6.

Fig. 6
figure 6

Repeatability and stability of the developed sensing system for 200 and 50 mg/g of TN

The correlation coefficient for the various experiments was observed to be in the range of 0.95–0.99. The statistical measures of the developed models for several soil samples were calculated, a few of which is shown in the Table 1.

Table 1 Statistical measures for performance analysis of the simulated models

6 Conclusion

Soil samples with varying amount of nitrogen content were analyzed by the simple optical sensing system developed to obtain the reflectance measurements at six different wavelengths (380, 475, 510, 570, 650, 840 nm). The soil spectra obtained showed a unique signature, and two models SSRC and ERMIR were developed based on the experimental data obtained. The predicted/estimated data from the model were verified, and it was observed that fifth-order polynomial model (SSRC) yielded better results as the root mean square error (RMSE) and standard error of estimate (SEE) were very less and the coefficient of determination (R2) was found to be almost 1. All these proved the efficiency of the model to predict the soil nitrogen content accurately. Also it was observed that the best correlation of the obtained reflectance with the varying amount of nitrogen was exhibited in the infrared region. So, the ERMIR model was developed for estimating the nitrogen content based on the reflectance obtained only from the NIR sensor. The obtained results validate that the developed sensing system as well as the mathematical models is capable of being employed for estimation of total soil nitrogen content and can therefore be a very useful tool in variable rate fertilizer applicator for application in smart farming.