Comparison between Capacitive and Microstructured Optical Fiber Soil Moisture Sensors

: Soil moisture content has always been an important parameter to control because it is a deterministic factor for site-speciﬁc irrigation, seeding, transplanting, and compaction detection. In this work, a discrete sensor that is based on a SnO 2 –FP (Fabry-P é rot) cavity is presented and characterized in real soil conditions. As far as authors know, it is the ﬁrst time that a microstructured optical ﬁber is used for real soil moisture measurements. Its performance is compared with a commercial capacitive soil moisture sensor in two different soil scenarios for two weeks. The optical sensor shows a great agreement with capacitive sensor’s response and gravimetric measurements, as well as a fast and reversible response; moreover, the interrogation technique allows for several sensors to be potentially multiplexed, which offers the possibility of local measurements instead of volumetric: it constitutes a great tool for real soil moisture monitoring.


Introduction
Soil moisture plays a key role in the hydrological cycle by controlling processes, such as evapotranspiration, runoff, and recharge of aquifers, just to mention some of them [1][2][3]. Therefore, soil water content data are very useful for the application and evaluation of hydrological models that yield to irrigation programming and optimization [4]. Hydrological models are essential tools for estimating water resources and floods in the current situation, as well as in relation to different scenarios of global climate change and/or under different land uses [5].
Several methodologies have been developed to determinate soil moisture, both in the field and in the laboratory: gravimetric measurements, optical spectroscopy, continuous wave acoustics, electric resistance blocks, tensiometers, and neutron probes, among others [6][7][8][9]. Recently, the use of capacitive sensors has increased [10], since they offer a good cost-benefit in relationship when compared to other devices, like the ones that are based on reflectometry in the time domain, which was considered as one of the most accurate methods for estimating the water content of soils so far [11,12].

Materials and Methods
A Decagon 10HS capacitive sensor (Meter Group Inc., Pullman, WA, USA) was used as reference for the soil moisture measurements. This capacitive device is a frequency domain reflectometry (FDR) based electrical sensor. Its operation principle consists of measuring the dielectric constant or permittivity of the soil to calculate its humidity content. It performs soil moisture measurements within a big volume of soil (~6.5 dm 3 ) with great moisture range and it is designed for any soil composition.
Its measurements have been compared with an optical fiber Fabry-Pérot interferometer that was fabricated by splicing a single mode fiber (SMF) to a cleaved four-bridge MOF, as shown in [19]. As shown in [19], the MOF-FP optical fiber core was used as the substrate in a SnO 2 coating-DC-Sputter Appl. Sci. 2018, 8,1499 3 of 12 deposition process. SnO 2 can be deposited on the walls of the air holes of the short section of the MOF as well as on the top of the sensor head due to the particular structure of the MOF that is used. SnO 2 coating is highly sensitive to humidity changes of the surrounding environment [30].
The interaction between SnO 2 and H 2 O molecules is due to the phenomena called physisorption by means of the adsorption/desorption of these molecules [31]. The molecules of water interact just with the surface of the deposited SnO 2 thin film.
The MOF cavity length determines the periodicity of the sensor optical spectrum interference obtained following (1). Where ∆λ: optical spectrum wavelength spacing, λ: working wavelength, n: refractive index, and d: MOF cavity length [32].
In this particular case, the MOF length used was~700 µm showing an interference period of 1.24 nm, as Figure 1a shows (after a 10 min SnO 2 deposition).
Appl. Sci. 2018, 8, x FOR PEER REVIEW 3 of 12 deposition process. SnO2 can be deposited on the walls of the air holes of the short section of the MOF as well as on the top of the sensor head due to the particular structure of the MOF that is used. SnO2 coating is highly sensitive to humidity changes of the surrounding environment [30]. The interaction between SnO2 and H2O molecules is due to the phenomena called physisorption by means of the adsorption/desorption of these molecules [31]. The molecules of water interact just with the surface of the deposited SnO2 thin film.
The MOF cavity length determines the periodicity of the sensor optical spectrum interference obtained following (1). Where Δλ: optical spectrum wavelength spacing, λ: working wavelength, n: refractive index, and d: MOF cavity length [32].
In this particular case, the MOF length used was ~700 μm showing an interference period of 1.24 nm, as Figure 1a shows (after a 10 min SnO2 deposition). As it can be inferred, the sensing head is very fragile and, moreover, dust inside the MOF holes and in contact with the SnO2 deposition could lead to measurement errors. In order to avoid this scenario, a protective cap was developed: it consists of a polyvinylchloride (PVC) tube with four arrays of drilled holes (1 mm of diameter) each 5 mm and a cap in one of its ends enabling the access of the optical fiber. Figure 2 shows the real pictures of the protective cap and the final sensor installed inside the cap. This PVC protection prevents the optical sensor from any damage during installation as well as undesired elements polluting the sensing material, creating a cavity inside the tube permeable to humidity, so that it can be measured.
The influence of the protective cap was verified before the installation in the soil in order to verify the correct behavior of the sensing head. The protected sensing head was inserted in a climatic chamber where humidity ranges from 20% to 90% were applied at constant temperature of 25 °C. Results are shown in Figure 3. As it can be inferred, the sensing head is very fragile and, moreover, dust inside the MOF holes and in contact with the SnO 2 deposition could lead to measurement errors. In order to avoid this scenario, a protective cap was developed: it consists of a polyvinylchloride (PVC) tube with four arrays of drilled holes (1 mm of diameter) each 5 mm and a cap in one of its ends enabling the access of the optical fiber. Figure 2 shows the real pictures of the protective cap and the final sensor installed inside the cap. deposition process. SnO2 can be deposited on the walls of the air holes of the short section of the MOF as well as on the top of the sensor head due to the particular structure of the MOF that is used. SnO2 coating is highly sensitive to humidity changes of the surrounding environment [30]. The interaction between SnO2 and H2O molecules is due to the phenomena called physisorption by means of the adsorption/desorption of these molecules [31]. The molecules of water interact just with the surface of the deposited SnO2 thin film.
The MOF cavity length determines the periodicity of the sensor optical spectrum interference obtained following (1). Where Δλ: optical spectrum wavelength spacing, λ: working wavelength, n: refractive index, and d: MOF cavity length [32].
In this particular case, the MOF length used was ~700 μm showing an interference period of 1.24 nm, as Figure 1a shows (after a 10 min SnO2 deposition). As it can be inferred, the sensing head is very fragile and, moreover, dust inside the MOF holes and in contact with the SnO2 deposition could lead to measurement errors. In order to avoid this scenario, a protective cap was developed: it consists of a polyvinylchloride (PVC) tube with four arrays of drilled holes (1 mm of diameter) each 5 mm and a cap in one of its ends enabling the access of the optical fiber. Figure 2 shows the real pictures of the protective cap and the final sensor installed inside the cap. This PVC protection prevents the optical sensor from any damage during installation as well as undesired elements polluting the sensing material, creating a cavity inside the tube permeable to humidity, so that it can be measured.
The influence of the protective cap was verified before the installation in the soil in order to verify the correct behavior of the sensing head. The protected sensing head was inserted in a climatic chamber where humidity ranges from 20% to 90% were applied at constant temperature of 25 °C. Results are shown in Figure 3. This PVC protection prevents the optical sensor from any damage during installation as well as undesired elements polluting the sensing material, creating a cavity inside the tube permeable to humidity, so that it can be measured. The influence of the protective cap was verified before the installation in the soil in order to verify the correct behavior of the sensing head. The protected sensing head was inserted in a climatic chamber where humidity ranges from 20% to 90% were applied at constant temperature of 25 • C. Results are shown in Figure 3. These results show a correct performance of the sensing head towards humidity changes, but with a reduction of its sensitivity in comparison with the case where no protective cap is employed. The delay of the sensors in relation with the climatic chamber is due to the small hysteresis effect induced by the tube. This performance can be improved by optimizing the sputtering deposition time or through the design of a three-dimensional (3D) printed protective cap to achieve optimal results, as shown in [19].
A commercial FBG (sensitivity of 10 p.m./°C) was also monitored at the same time in order to measure the temperature variations inside the soil sample and compensate the optical sensor's deviations. Temperature variations affect directly on a FP cavity as they modify the cavity length due to the thermal expansion of the silica. These variations produce a wavelength shift or analogously a FFT phase shift. Once known the variation of temperature through the FBG and the sensitivity of the MOF sensing head to temperature variations it can be directly compensated by subtracting the wavelength shift-FFT phase shift to the MOF's results.
A commercial interrogator equipment for FBGs based sensors (SM125, SMARTEC, Lugano, Switzerland) was used to illuminate the network and also to analyze the spectra of the signals reflected from the sensors. The interrogating equipment has a sampling frequency of 1 Hz [33], four different channels, and is remotely controlled through a MATLAB software (MathWorks, Natick, MA, USA) that also executes a FFT real time analysis. This analysis consists of tracking the FFT phase corresponding to the FFT module main component located at 0.8 nm −1 , as shown in in Figure 1b. The main advantage of this technique is the negligible influence of noise (high frequency components) and signal amplitude undesired variations. Moreover, choosing correctly the MOF lengths, several FP sensors could be multiplexed within a single optical interrogators channel through common optical couplers, as it has been demonstrated by authors in [34,35]. The three sensors where buried in the soil, as Figure 4 illustrates. These results show a correct performance of the sensing head towards humidity changes, but with a reduction of its sensitivity in comparison with the case where no protective cap is employed. The delay of the sensors in relation with the climatic chamber is due to the small hysteresis effect induced by the tube. This performance can be improved by optimizing the sputtering deposition time or through the design of a three-dimensional (3D) printed protective cap to achieve optimal results, as shown in [19].
A commercial FBG (sensitivity of 10 p.m./ • C) was also monitored at the same time in order to measure the temperature variations inside the soil sample and compensate the optical sensor's deviations. Temperature variations affect directly on a FP cavity as they modify the cavity length due to the thermal expansion of the silica. These variations produce a wavelength shift or analogously a FFT phase shift. Once known the variation of temperature through the FBG and the sensitivity of the MOF sensing head to temperature variations it can be directly compensated by subtracting the wavelength shift-FFT phase shift to the MOF's results.
A commercial interrogator equipment for FBGs based sensors (SM125, SMARTEC, Lugano, Switzerland) was used to illuminate the network and also to analyze the spectra of the signals reflected from the sensors. The interrogating equipment has a sampling frequency of 1 Hz [33], four different channels, and is remotely controlled through a MATLAB software (MathWorks, Natick, MA, USA) that also executes a FFT real time analysis. This analysis consists of tracking the FFT phase corresponding to the FFT module main component located at 0.8 nm −1 , as shown in in Figure 1b. The main advantage of this technique is the negligible influence of noise (high frequency components) and signal amplitude undesired variations. Moreover, choosing correctly the MOF lengths, several FP sensors could be multiplexed within a single optical interrogators channel through common optical couplers, as it has been demonstrated by authors in [34,35]. The three sensors where buried in the soil, as Figure 4 illustrates.  The optical sensors were placed at the same radial distance from the soil center as the capacitive sensor and buried ~10 cm deep (trying to be at the mid depth of the capacitive sensor). In this study, two different types of soil were tested in order to check the performance of the optical sensor in comparison with the capacitive one. The first porous media was a silica sand specified for use in pool filters, water purification, and sports fields. The soil texture was defined as sand [36], 100% sand. The second one was a mix of 50% weight of the silica sand and 50% weight of a contrasting natural soil texture classified as clay loam, 28% sand, 36% silt, and 36% clay [36].

Results
Different measurements were performed to compare the behavior of capacitive sensors against optical fiber sensors with the two types of soil samples that are described above. Moreover, gravimetric measurements were also performed to verify the results. Temperature variations affect directly on optical fiber sensors and therefore it was also monitored by a FBG.

Temperature Monitoring and Compensation
As it was previously mentioned, MOF-FP optical sensor is affected by temperature variations, leading to crosstalk between temperature and relative humidity measurements. Figure 5 shows the response of the MOF-FP sensor (calibration) towards temperature showing a linear response with sensitivity of 0.00377π rad/°C. The optical sensors were placed at the same radial distance from the soil center as the capacitive sensor and buried~10 cm deep (trying to be at the mid depth of the capacitive sensor). In this study, two different types of soil were tested in order to check the performance of the optical sensor in comparison with the capacitive one. The first porous media was a silica sand specified for use in pool filters, water purification, and sports fields. The soil texture was defined as sand [36], 100% sand. The second one was a mix of 50% weight of the silica sand and 50% weight of a contrasting natural soil texture classified as clay loam, 28% sand, 36% silt, and 36% clay [36].

Results
Different measurements were performed to compare the behavior of capacitive sensors against optical fiber sensors with the two types of soil samples that are described above. Moreover, gravimetric measurements were also performed to verify the results. Temperature variations affect directly on optical fiber sensors and therefore it was also monitored by a FBG.

Temperature Monitoring and Compensation
As it was previously mentioned, MOF-FP optical sensor is affected by temperature variations, leading to crosstalk between temperature and relative humidity measurements. Figure 5 shows the response of the MOF-FP sensor (calibration) towards temperature showing a linear response with sensitivity of 0.00377π rad/ • C. To avoid this undesirable crosstalk a commercial FBG (sensitivity of 10 p.m./°C) was also buried in contact to the MOF-FP sensor and simultaneously monitored. This temperature reference showed the behavior illustrated in Figure 6 Measurements shown were taken during a week. As can be noticed in Figure 6, the FBG optical interrogator has a wavelength resolution of 5 p.m., which means a temperature resolution of 0.5 °C. Results shown in Figure 6 show a good agreement between the dynamics of humidity and temperature. Temperature shows oscillations of 2 °C depending on the time of the day. During day hours temperature rises and when sun sets (soil sample was at direct exposition of sun light) it decreases ~2 °C. Humidity results follows the same trend showing great variations (decreasing humidity) during the day and slower ones at night. These variations agree temporarily with temperature, showing bigger slopes during sunshine hours.
With a temperature reference and being the sensitivity of the optical sensor to temperature variations known, its influence can be cancelled. Thus, the FFT phase shift induced by temperature variations (deduced through the FBG sensor) can be directly subtracted to the MOF-FP sensor's results. This compensation can be made either in real time or by post processing. In this study, it was directly implemented in the acquisition software. Results that are shown in Figures 7-9 are already temperature compensated ones. To avoid this undesirable crosstalk a commercial FBG (sensitivity of 10 p.m./ • C) was also buried in contact to the MOF-FP sensor and simultaneously monitored. This temperature reference showed the behavior illustrated in Figure 6 Measurements shown were taken during a week. As can be noticed in Figure 6, the FBG optical interrogator has a wavelength resolution of 5 p.m., which means a temperature resolution of 0.5 • C. To avoid this undesirable crosstalk a commercial FBG (sensitivity of 10 p.m./°C) was also buried in contact to the MOF-FP sensor and simultaneously monitored. This temperature reference showed the behavior illustrated in Figure 6 Measurements shown were taken during a week. As can be noticed in Figure 6, the FBG optical interrogator has a wavelength resolution of 5 p.m., which means a temperature resolution of 0.5 °C. Results shown in Figure 6 show a good agreement between the dynamics of humidity and temperature. Temperature shows oscillations of 2 °C depending on the time of the day. During day hours temperature rises and when sun sets (soil sample was at direct exposition of sun light) it decreases ~2 °C. Humidity results follows the same trend showing great variations (decreasing humidity) during the day and slower ones at night. These variations agree temporarily with temperature, showing bigger slopes during sunshine hours.
With a temperature reference and being the sensitivity of the optical sensor to temperature variations known, its influence can be cancelled. Thus, the FFT phase shift induced by temperature variations (deduced through the FBG sensor) can be directly subtracted to the MOF-FP sensor's results. This compensation can be made either in real time or by post processing. In this study, it was directly implemented in the acquisition software. Results that are shown in Figures 7-9 are already temperature compensated ones. Results shown in Figure 6 show a good agreement between the dynamics of humidity and temperature. Temperature shows oscillations of 2 • C depending on the time of the day. During day hours temperature rises and when sun sets (soil sample was at direct exposition of sun light) it decreases 2 • C. Humidity results follows the same trend showing great variations (decreasing humidity) during the day and slower ones at night. These variations agree temporarily with temperature, showing bigger slopes during sunshine hours.
With a temperature reference and being the sensitivity of the optical sensor to temperature variations known, its influence can be cancelled. Thus, the FFT phase shift induced by temperature variations (deduced through the FBG sensor) can be directly subtracted to the MOF-FP sensor's results. This compensation can be made either in real time or by post processing. In this study, it was directly implemented in the acquisition software. Results that are shown in Figures 7-9 are already temperature compensated ones. volume of soil while on the other hand, capacitive sensors need a significant soil volume (as it will be described) to work properly. After the sensor's installation, water was carefully added to the soil until saturation (water dropping at the bottom of the sample-Relative humidity = 100%). All of the sensors were monitored every 10 min during ~14 days uninterruptedly showing the results shown in Figure 7. After ~12 days for Soil1 and ~9 days for Soil2, humidity was raised again until saturation to check the sensor's reversibility and adaptability to changing environments. As can be seen in Figure 7, there is a discrepancy in terms of kinetics between both sensors. The optical sensing head measures the humidity directly in contact with it while capacitive sensors integrate the moisture in a volume of soil. As previously commented, due to the size, the principle of operation of each sensor, and their burial depth, the optical sensor is able to measure localized humidity variations, and therefore it measures moisture variations before the capacitive sensor.

Point Measurements
Point measurements were also performed in both soils to check and compare the precision of the sensors. For this kind of measurements, the results of both capacitive and optical sensors were compared with gravimetric measurements.
Soil samples of ~3 L were prepared for the test. The measuring initial point is with soil totally dried by an oven to get a ~0% humidity. At each sample, 300 mL of water were added to the soil until saturation was achieved. For the gravimetric measurements at each sample, just after performing the measures with both capacitive and optical sensors, a sample of soil was taken in a cylinder with a volume of 100.14 cm 3 , weighed, dried in the oven, and weighed again to check the real weight of water (difference in weight before and after the drying process) and as a consequence the humidity contained in the sample. Results that are shown in Figures 8 and 9 illustrate the regression slopes for both experiments showing R 2 = 0.988 for the capacitive sensor and R 2 = 0.978 for the optical sensor in Soil1 and R 2 = 0.956 and R 2 = 0.949 respectively in Soil2.
Each value was measured five times with a lapse time of 30 s between measurements and the mean value is represented in Figures 8 and 9. The maximum error of the measured samples was 9% and the minimum 2%, being the mean error of point measurements of 4%.  An important aspect to comment is the difficulty to perform accurate gravimetric measurements. The operation principle of this technique is to take a known volumetric sample of wet soil, weigh it, dry the sample in the oven and weigh again to analyze the water weight evaporated. To perform accurate measurements the volume and compaction of the soil sample are critical. Although the volume is not a problem, to maintain the same compaction during the drying process of the soil is not obvious and it requires complex techniques and devices. This difficulty led to small discrepancies, as can be seen in Figures 8 and 9.

Discussion
Results shown in Section 3 in overall show an agreement between capacitive sensors, MOF-FP optical sensors, and gravimetric measurements in (two) different types of soil.
One of the main differences between capacitive and optical results can be seen in Figure 5. There, it can be noticed differences in the time response to humidity changes between both sensors. It is due to two important factors: devices size and type of measurements. On the one hand, capacitive sensors that are used in this study have dimensions of 14.5 cm × 3.3 cm × 0.7 cm and they give us volumetric  An important aspect to comment is the difficulty to perform accurate gravimetric measurements. The operation principle of this technique is to take a known volumetric sample of wet soil, weigh it, dry the sample in the oven and weigh again to analyze the water weight evaporated. To perform accurate measurements the volume and compaction of the soil sample are critical. Although the volume is not a problem, to maintain the same compaction during the drying process of the soil is not obvious and it requires complex techniques and devices. This difficulty led to small discrepancies, as can be seen in Figures 8 and 9.

Discussion
Results shown in Section 3 in overall show an agreement between capacitive sensors, MOF-FP optical sensors, and gravimetric measurements in (two) different types of soil.
One of the main differences between capacitive and optical results can be seen in Figure 5. There, it can be noticed differences in the time response to humidity changes between both sensors. It is due to two important factors: devices size and type of measurements. On the one hand, capacitive sensors

Dynamic Measurements
Long term measurements were performed in order to check the viability of the MOF-FP sensor. For this aim, the MOF-FP sensor was buried in the soil at~5 cm deep, whereas the capacitive sensor was at~20 cm, as it has been shown in Figure 4a. This difference must be underlined as it will affect directly on the results and it is produced due to the size difference of the sensors. On the one hand, MOF-FP sensor presents reduced dimensions, allowing for the moisture measurement within a small volume of soil while on the other hand, capacitive sensors need a significant soil volume (as it will be described) to work properly. After the sensor's installation, water was carefully added to the soil until saturation (water dropping at the bottom of the sample-Relative humidity = 100%). All of the sensors were monitored every 10 min during~14 days uninterruptedly showing the results shown in Figure 7. After~12 days for Soil1 and~9 days for Soil2, humidity was raised again until saturation to check the sensor's reversibility and adaptability to changing environments.
As can be seen in Figure 7, there is a discrepancy in terms of kinetics between both sensors. The optical sensing head measures the humidity directly in contact with it while capacitive sensors integrate the moisture in a volume of soil. As previously commented, due to the size, the principle of operation of each sensor, and their burial depth, the optical sensor is able to measure localized humidity variations, and therefore it measures moisture variations before the capacitive sensor.

Point Measurements
Point measurements were also performed in both soils to check and compare the precision of the sensors. For this kind of measurements, the results of both capacitive and optical sensors were compared with gravimetric measurements.
Soil samples of~3 L were prepared for the test. The measuring initial point is with soil totally dried by an oven to get a~0% humidity. At each sample, 300 mL of water were added to the soil until saturation was achieved. For the gravimetric measurements at each sample, just after performing the measures with both capacitive and optical sensors, a sample of soil was taken in a cylinder with a volume of 100.14 cm 3 , weighed, dried in the oven, and weighed again to check the real weight of water (difference in weight before and after the drying process) and as a consequence the humidity contained in the sample. Results that are shown in Figures 8 and 9 illustrate the regression slopes for both experiments showing R 2 = 0.988 for the capacitive sensor and R 2 = 0.978 for the optical sensor in Soil1 and R 2 = 0.956 and R 2 = 0.949 respectively in Soil2.
Each value was measured five times with a lapse time of 30 s between measurements and the mean value is represented in Figures 8 and 9. The maximum error of the measured samples was 9% and the minimum 2%, being the mean error of point measurements of 4%.
An important aspect to comment is the difficulty to perform accurate gravimetric measurements. The operation principle of this technique is to take a known volumetric sample of wet soil, weigh it, dry the sample in the oven and weigh again to analyze the water weight evaporated. To perform accurate measurements the volume and compaction of the soil sample are critical. Although the volume is not a problem, to maintain the same compaction during the drying process of the soil is not obvious and it requires complex techniques and devices. This difficulty led to small discrepancies, as can be seen in Figures 8 and 9.

Discussion
Results shown in Section 3 in overall show an agreement between capacitive sensors, MOF-FP optical sensors, and gravimetric measurements in (two) different types of soil.
One of the main differences between capacitive and optical results can be seen in Figure 5. There, it can be noticed differences in the time response to humidity changes between both sensors. It is due to two important factors: devices size and type of measurements. On the one hand, capacitive sensors that are used in this study have dimensions of 14.5 cm × 3.3 cm × 0.7 cm and they give us volumetric measurements by measuring the dielectric constant of the soil, as shown in Figure 10. On the other hand, MOF-FP based sensors have very reduced dimensions (0.7 mm × 125 µm) without the protective cap. This cap is a cylinder 4 cm long having 0.8 cm of radius. The sensing head measures the humidity that is directly in contact with it. Therefore, it can be concluded that capacitive sensors are field sensors in opposition to point optical sensors. Due to this difference, the optical sensor is very sensitive to point humidity changes very close to the sensing head while capacitive measures all of the humidity comprised around it, being less sensitive to local variations.  Table 1 shows the measured errors between optical-capacitive sensors and optical sensorgravimetric measurements. As previously commented, gravimetric measurements present great variations due to the employed technique and its variability depending on the measuring conditions. Therefore, the errors measured between optical or capacitive sensors and gravimetric in some points (i.e., in Figure 9b) at 63% RH in gravimetric measurements) are higher than expected, as can be seen in the case of the maximum error between optical sensor and gravimetric measurement. Another difference shown in the results from capacitive and optical sensors in Figures 6 and 7 is a measuring error when humidity is close to 0%. This is due to the different nature of the sensors. On the one hand, capacitive sensors measure the dielectric constant of the soil and therefore the content of water in soil: moisture. On the other hand, optical sensors measure refractive index variations that are produced by the presence of soil moisture. Relative humidity can be described, as follows: where Pw is the water vapor pressure and Pws is the water vapor pressure in saturation and it is a function of temperature [28]. The term humidity usually makes reference to the presence of water in gaseous form, but it is often used to refer to expressions that are related to water vapor characteristics and in the field of measurement, there are various terms associated with such water vapor measurements. In addition, the term moisture is frequently interchanged with humidity even though the actual definition of moisture refers to the water in liquid form that may be present in solid materials [37]. Since humidity is a measure of water in gaseous state present in the environment, water vapor found in a gas mixture behaves in accordance with the gas laws and the amount of pressure it exerts equates to the partial pressure of the water vapor components in the gas mixture, as defined by Dalton's law [37].
To set a reference between capacitive sensors and optical sensors when the soil is saturated, the air in holes inside the soil (and therefore the cavity created by the optical sensor) is saturated too, and as a conclusion, both of the sensors show 100% of humidity and relative humidity, respectively.
As can be seen in Figures 8 and 9, both of the sensors work similarly in high humidity scenarios. The difference arises when the soil approaches to 0% humidity. Due to the nature of the optical sensor and its operation principle measuring the water present in air it becomes impossible to reach 0% of relative humidity while capacitive sensor can reach such low values. As a conclusion, the optical sensor is not suitable for environments of very low humidity (under 15%).  Table 1 shows the measured errors between optical-capacitive sensors and optical sensor-gravimetric measurements. As previously commented, gravimetric measurements present great variations due to the employed technique and its variability depending on the measuring conditions. Therefore, the errors measured between optical or capacitive sensors and gravimetric in some points (i.e., in Figure 9b) at 63% RH in gravimetric measurements) are higher than expected, as can be seen in the case of the maximum error between optical sensor and gravimetric measurement. Another difference shown in the results from capacitive and optical sensors in Figures 6 and 7 is a measuring error when humidity is close to 0%. This is due to the different nature of the sensors. On the one hand, capacitive sensors measure the dielectric constant of the soil and therefore the content of water in soil: moisture. On the other hand, optical sensors measure refractive index variations that are produced by the presence of soil moisture. Relative humidity can be described, as follows: where Pw is the water vapor pressure and Pws is the water vapor pressure in saturation and it is a function of temperature [28]. The term humidity usually makes reference to the presence of water in gaseous form, but it is often used to refer to expressions that are related to water vapor characteristics and in the field of measurement, there are various terms associated with such water vapor measurements. In addition, the term moisture is frequently interchanged with humidity even though the actual definition of moisture refers to the water in liquid form that may be present in solid materials [37]. Since humidity is a measure of water in gaseous state present in the environment, water vapor found in a gas mixture behaves in accordance with the gas laws and the amount of pressure it exerts equates to the partial pressure of the water vapor components in the gas mixture, as defined by Dalton's law [37].
To set a reference between capacitive sensors and optical sensors when the soil is saturated, the air in holes inside the soil (and therefore the cavity created by the optical sensor) is saturated too, and as a conclusion, both of the sensors show 100% of humidity and relative humidity, respectively.
As can be seen in Figures 8 and 9, both of the sensors work similarly in high humidity scenarios. The difference arises when the soil approaches to 0% humidity. Due to the nature of the optical sensor and its operation principle measuring the water present in air it becomes impossible to reach 0% of relative humidity while capacitive sensor can reach such low values. As a conclusion, the optical sensor is not suitable for environments of very low humidity (under 15%).
Additionally, as can be noticed in Figure 8, both of the graphs present different x-axe length. This is due to the fact that, Soil2, as a result of its composition, is able to retain more water than Soil1, and therefore, an additional 300 mL was needed to reach the saturation stage.
The last difference in the results can be seen in the X axis of Figure 7a,b. Figure 7a shows the results of the natural evaporation process in indoor conditions. As it can be seen, there is a very slow kinetic and humidity decreased~30% in 12 days. To accelerate this process, for Soil2 measurements (Figure 7), two heating fans where placed close to the sample. Temperature variations were compensated as explained before. A significant difference can be seen as the humidity decreased~60% in 9 days.
An important aspect to comment is the difficulty to perform accurate gravimetric measurements as they are very dependent on the experiment conditions. It has been demonstrated that the optical sensor can be used as a reference to measure moisture above 15%, avoiding imprecise gravimetric measurements. As previously commented, below this level, optical sensor decreases its sensitivity due to its measuring working principle.
As commented in Section 3.3, soil temperature close to the optical sensor location has been monitored. Results shown in Figure 6 show a good agreement between the dynamics of humidity and temperature. Temperature shows oscillations of 2 • C depending on the time of the day. During day hours temperature rises and when sun sets (soil sample was at direct exposition of sun light) it decreases 2 • C. Humidity results follows the same trend, showing great variations (decreasing humidity) during the day and slower ones at night. These variations agree temporarily with temperature, showing bigger slopes during sunshine hours.

Conclusions
In this study, a fiber optical sensor based in a microstructured optical fiber has been proposed and demonstrated for first time for soil moisture measurements. The optical sensing head is based on a Fabry-Pérot cavity made of a microstructured optical fiber with a SnO 2 sputtering thin film acting as sensitive layer and it was temperature and humidity characterized in a climatic chamber before its installation in soil. A comparison between a commercial capacitive FDR and the optical sensor has been carried out in two different types of soils during two weeks. The optical interrogation of the MOF-FP sensing head was carried out through the FFT technique, which avoids noise and amplitude variations' influence and enables multiplex several sensors within a single optical interrogator's channel. Results show a good agreement between capacitive and optical measurements in the range 15-100% humidity and also match with gravimetric analysis. For humidity below 15%, the optical sensor's sensitivity decreases significantly. Soil moisture can be measured with MOF-FP sensors with the advantages that they offer in comparison with traditional capacitive sensors: immunity to temperature variations (compensated), point measurements (against field measurements), and high multiplexing capability.
These particular characteristics lead to a new set of local applications that capacitive sensors are unable to attend, such as monitoring the soil moisture distribution (radial distance) in a local irrigation point performing measurements each centimeter. Moreover, due to the versatility of the sensing heads to be customized depending on the target application, different sensing heads with different purposes (such as dissolved pollutants, volatile organic compounds, solid or dissolved ferromagnetic elements can be detected by the correctly selection of the deposited chemical agent) can be multiplexed within the same optical interrogator, reducing the relative economic cost of the system and leading to complex real time (also high sampling rate applications) multiparameter monitoring schemes.