Estimation of Solar Radiation for Tomato Water Requirement Calculation in Chinese-Style Solar Greenhouses Based on Least Mean Squares Filter

The area covered by Chinese-style solar greenhouses (CSGs) has been increasing rapidly. However, only a few pyranometers, which are fundamental for solar radiation sensing, have been installed inside CSGs. The lack of solar radiation sensing will bring negative effects in greenhouse cultivation such as over irrigation or under irrigation, and unnecessary power consumption. We aim to provide accurate and low-cost solar radiation estimation methods that are urgently needed. In this paper, a method of estimation of solar radiation inside CSGs based on a least mean squares (LMS) filter is proposed. The water required for tomato growth was also calculated based on the estimated solar radiation. Then, we compared the accuracy of this method to methods based on knowledge of astronomy and geometry for both solar radiation estimation and tomato water requirement. The results showed that the fitting function of estimation data based on the LMS filter and data collected from sensors inside the greenhouse was y = 0.7634x + 50.58, with the evaluation parameters of R2 = 0.8384, rRMSE = 23.1%, RMSE = 37.6 Wm−2, and MAE = 25.4 Wm−2. The fitting function of the water requirement calculated according to the proposed method and data collected from sensors inside the greenhouse was y = 0.8550x + 99.10 with the evaluation parameters of R2 = 0.9123, rRMSE = 8.8%, RMSE = 40.4 mL plant−1, and MAE = 31.5 mL plant−1. The results also indicate that this method is more effective. Additionally, its accuracy decreases as cloud cover increases. The performance is due to the LMS filter’s low pass characteristic that smooth the fluctuations. Furthermore, the LMS filter can be easily implemented on low cost processors. Therefore, the adoption of the proposed method is useful to improve the solar radiation sensing in CSGs with more accuracy and less expense.


Introduction
Since being introduced in the 1930s, the Chinese-style solar greenhouse (CSG) has gradually grown in Chinese agriculture. The greenhouse vegetable industry accounts for 20% of the total vegetable production area in China, but it produces 35% of the output and 60% of the economic value in 2013 [1]. In 2013, the CSG cultivation area amounted to 612,000 ha [2]. CSGs extend the crop growing season in the cold areas in China between 34° and 41° N, where the temperature falls below −20 °C at night. CSG cultivation requires little auxiliary heating equipment; the consumption of energy and emissions of carbon dioxide are considerably reduced.

Experimental Site and Measurement Methods
We conducted this study in an east-west-oriented CSG in Shenyang, China (41°48′ N, 123°24′ E, 42 m a.s.l.). The greenhouse was 60 m long and 12 m wide. The height of the north wall and north roof were 3 m and 5.5 m, respectively. The south roof was covered by a single layer of 0.00012 m thick polyethylene film.
The cultivation area inside the greenhouse was 55 m long from east to west and 10 m wide. Tomatoes were grown with row spacing of 1 m, within-row spacing of 0.33 m, and plant density of 4 plants·m −2 . Tomatoes were grown in substrate and irrigated using a drip irrigation system. The tomatoes were sown on 5 August 2017. Then, the transplant was performed on 1 September 2017 and the cultivation finished on 27 December 2017. We conducted this study using Hout data collected from outer weather station and indoor pyranometers (Hs) from 1-26 December 2017. It was cold and nature ventilation was rare during the experimental days.
Six temperature sensors (SHT10, Sensirion, Zurich, Switzerland) and three pyranometers (MP200, Apogee Instruments, Logan, UT, USA) were installed in the experimental greenhouse. The temperature sensors were hung 1.5 m above the ground and pyranometers were placed horizontally at different heights above the ground (1.5, 2, and 2.5 m) according to the growth condition of the tomatoes. The placement of indoor sensors is shown in Figure S1.
The temperature sample interval was 15 min and the mean of the temperature recorded by the six installed sensors was considered the temperature inside the greenhouse. The sample interval of solar radiation was 15 min [40] and the mean of three installed pyranometers was taken as the true Hi value.

Experimental Site and Measurement Methods
We conducted this study in an east-west-oriented CSG in Shenyang, China (41 • 48 N, 123 • 24 E, 42 m a.s.l.). The greenhouse was 60 m long and 12 m wide. The height of the north wall and north roof were 3 m and 5.5 m, respectively. The south roof was covered by a single layer of 0.00012 m thick polyethylene film.
The cultivation area inside the greenhouse was 55 m long from east to west and 10 m wide. Tomatoes were grown with row spacing of 1 m, within-row spacing of 0.33 m, and plant density of 4 plants·m −2 . Tomatoes were grown in substrate and irrigated using a drip irrigation system. The tomatoes were sown on 5 August 2017. Then, the transplant was performed on 1 September 2017 and the cultivation finished on 27 December 2017. We conducted this study using H out data collected from outer weather station and indoor pyranometers (H s ) from 1-26 December 2017. It was cold and nature ventilation was rare during the experimental days.
Six temperature sensors (SHT10, Sensirion, Zurich, Switzerland) and three pyranometers (MP200, Apogee Instruments, Logan, UT, USA) were installed in the experimental greenhouse. The temperature sensors were hung 1.5 m above the ground and pyranometers were placed horizontally at different heights above the ground (1.5, 2, and 2.5 m) according to the growth condition of the tomatoes. The placement of indoor sensors is shown in Figure S1.
The temperature sample interval was 15 min and the mean of the temperature recorded by the six installed sensors was considered the temperature inside the greenhouse. The sample interval of solar radiation was 15 min [40] and the mean of three installed pyranometers was taken as the true H i value.

Evaluation Parameters
As evaluation parameters, we adopted the coefficient of determination (R 2 ), percent error (PE), root mean square error (RMSE), relative root mean square error (rRMSE), and mean absolute error (MAE), and these parameters were calculated according to Equations (1)-(5), respectively [22,23,40]. In our study, R 2 , RMSE, rRMSE, and MAE were firstly used for comparisons between the estimated solar radiation and measured solar radiation. Additionally, they were also used to compare the daily water requirements of tomatoes calculated by estimated data and sensor data. RE was used to compare the error rates of water requirements. where y e is the estimated value, y m is measured value, y m_mean is the mean of y m , and n is the number of samples.

Classic Methods of Estimating H i
Two methods have mainly been used for estimating H i . Method 1 is based on knowledge of astronomy and geometry according to the following procedure: Step 1: Calculate H 0 using Equation (6) [12]: where G sc is solar constant, G sc = 1367 Wm −2 , φ is the latitude of the location and n day is the day number of the year, counted from 1 January, and δ and ω s are the daily solar declination and sunset hour angle, respectively [22]: Step 2: Calculate K t according to H o and H out via Equation (9) [22]: Sensors 2020, 20, 155 5 of 18 Step 3: Decompose H out into H b and H d according to K t [8,13] using Equation (10): Step 4: Calculate H c via Equation (11) [15,17]: where τ b is film transmittance to H b and τ d is film transmittance to H d . The values of τ b and τ d are 0.88 and 0.65 in the experimental greenhouse, respectively. Method 2 [19] is based on Equation (12): Method 2 is simpler than Method 1, but as shown in Figure S2, the mean and variance τ g of the experimental greenhouse was different from that in another study [19], so Method 1 was adopted in this study for comparison.
In both methods above, film transmittance and global transmittance are constant, but this does not reflect the reality. Some studies proved global transmittance changed with the incidence angle of the sun [24,25] and film transmittance changed due to aging and deposition [26]. So, estimating solar radiation merely according to fixed transmittance is not reliable and is prone to error.

Tomato Water Requirement Calculation
Carmassi's equation was dedicated to calculating the water requirement of tomatoes according to only two meteorological parameters: solar radiation and temperature. Carmassi's equation is calculated as follows: Step 1: Calculate leaf area index (LAI) according to Equation (13) [33]: where a, b, c, and d are regression constants, a = 0.335, b = 4.803, c = 755.3, and d = 134.7; GDD is tomato growing degree days; T avg is indoor daily average temperature, • C; Start_day presents the sowing date and Stop_day presents the date when cultivation ends. Something to be pointed out is that GDD is taken as dimensionless in LAI's computation. The GDD values are shown in Figure S3, and the values of GDD on 1 and 26 December were 1252 and 1340, respectively.
Step 2: Calculate extinction factor k according to Equation (14) [33]: where H up and H down are solar radiation above and below the canopy, respectively; H up and H down were measured using two pyranometers placed horizontally at 2.5 and 1.5 m above the ground. During the experimental days, k was 0.69.
Step 3: Calculate the water requirement of tomatoes according to Equation (15) [33]: where A = 0.946, B = 0.188, λ* is the latent heat of vaporization (2.45 MJ kg −1 ), and R i is the energy intercepted by canopy (MJ m −2 day −1 ). R i is calculated as [33]: where T s is the sample interval, and T start and T stop are start time and stop time of water requirement calculation, respectively. T start was confirmed by the time when H s first rose above 10 Wm −2 and T stop was confirmed by the time when the H s first fell to 0 Wm −2 . On sunny days during the experiment, T start was 08:00 and T stop was 16:00.

LMS Filter
According to the filter refresh algorithm, some kinds of adaptive filters can be used [41], such as the least mean squares (LMS) filter [35], recursive least squares (RLS) filter [42], least mean p-norm (LMP) filter [43], normalized LMP (NLMP) filter [44], least mean absolute deviation (LMAD) filter [44], and normalized LMAD (NLMAD) filter [44]. The basic diagram of adaptive filter is shown in Figure  S4. Among these, the LMS filter's resource consumption is low, making it suitable for applications in resource-constrained systems such as microcontrollers, which have only smaller RAM and run at a lower speed [45]. So, we only focused on the LMS filter's performance.
The LMS filter updates its filter coefficients according to least mean squares algorithm; computation proceeds according to Equations (17)- (19) [36]: w(n + 1) = w(n) + 2µe(n)x(n) (19) where µ is the convergence factor of LMS filter, and w(n + 1) is the filter coefficient in the next iteration. µ, which is related to convergence speed and approximate precision, is an important factor in the LMS filter. In addition, a smaller value of µ leads to higher approximate precision and lower convergence speed, and vice versa. The LMS filter is fully analyzed according to Equations (20)- (22) [37,38]: where R dx = E[d(n)x(n)] is the cross correlation matrix of the input and desired signals, is the autocorrelation matrix of the input signal, and R xx is at least a positive semi-definite matrix, so a normalized orthogonal matrix Q sets up Equation (21) [37,38]: where the modal matrix Q is orthonormal. The columns of Q, which are the eigenvectors of R xx , are mutually orthogonal and normalized. Notice that Q −1 = Q T , Λ is the spectral matrix and all its Sensors 2020, 20, 155 7 of 18 elements are zero except for the main diagonal, whose elements are the set of eigenvalues of R xx , which are presented as, λ 1 , λ 2 , λ 3 , . . . , λ L . According to Equation (22), Λ has the following form [37,38]: The eigenvalues of R xx are all real and greater or equal to zero, and µ can be calculated according to [37,38]: where λ max is the maximum eigenvalue of R xx . A tightly-constrained equation about µ is [37,38]: where tr(R xx ) is the trace of R xx . And tr(R xx ) is calculated as [37,38]: where L is the number of taps of the LMS filter. Equations (24) and (25) prove that the upper bound of µ is the power of the input signal, which can be calculated easily in applications.

DFT and FFT
DFT is a fundamental tool in signal processing applications, and FFT [46] is the fast algorithm of DFT. The characteristics in the frequency domain of the interested signals are obtained by DFT and FFT. DFT is calculated according to [46]: (26) where X(k) is the frequency domain values of time series x(n), N is the calculation length, and both n and k range from 0 to N − 1.

Filter Pass Band Characteristic
The pass band characteristic of a filter is the response effect of the amplitude-frequency characteristic of a filter to the signal of a different frequency. It can be calculated using Equation (26). Filters are classified as high pass, low pass, band pass, notch, and all pass according to the band characteristics. For example, a low pass filter passes low-frequency components and attenuates high-frequency components, so the output signal is always smoother than the input signal.

Proposal Methods and Evaluation Procedures
We focused on estimating H i using H out recorded from a weather station, which is basic equipment in many growing areas in China.
The flow chart of data processing is shown in Figure 2. Firstly, H out and H s were obtained from a weather station and the sensors inside the greenhouse. H c was calculated according Equations (6)- (11). Secondly, H out and H c were used as the x(n) and d(n) input signals for the LMS filter, respectively; therefore, the output signal of the LMS filter was the estimation of H i and is presented as H f . The required water volume for tomato, according to H c , H f , and H s , which are presented as V c , V f , and V s , respectively, were calculated via Equations (13)-(16).

Filter Pass Band Characteristic
The pass band characteristic of a filter is the response effect of the amplitude-frequency characteristic of a filter to the signal of a different frequency. It can be calculated using Equation (26). Filters are classified as high pass, low pass, band pass, notch, and all pass according to the band characteristics. For example, a low pass filter passes low-frequency components and attenuates high-frequency components, so the output signal is always smoother than the input signal.

Proposal Methods and Evaluation Procedures
We focused on estimating Hi using Hout recorded from a weather station, which is basic equipment in many growing areas in China.
The flow chart of data processing is shown in Figure 2. Firstly, Hout and Hs were obtained from a weather station and the sensors inside the greenhouse. Hc was calculated according Equations (6)- (11). Secondly, Hout and Hc were used as the x(n) and d(n) input signals for the LMS filter, respectively; therefore, the output signal of the LMS filter was the estimation of Hi and is presented as Hf. The required water volume for tomato, according to Hc, Hf, and Hs, which are presented as Vc, Vf, and Vs, respectively, were calculated via Equations (13)-(16). The performance of curve fitting, including Hf-Hs and Hc-Hs, were evaluated to analyze each solar radiation estimation method. The performance of curve fitting, including Vf-Vs. and Vc-Vs, were evaluated to analyze water requirement according to each solar radiation estimation method. Both of the evaluations were based on the equations proposed in Section 2.1.3. All data in this study were processed and all figures were drawn using Python 3.7 (Python Software Foundation, Wilmington, DE, USA). The data of Hs and Hout is available in Data file S1 and Data file S2 respectively. And the program is available in Program file S1.

Determination of μ and L
The length (L) of the LMS filter varies in different applications and ordinary lengths are 8, 9, 64, and 128, but the sample interval in greenhouse applications always ranges from 1 min to 1 h or Evaluation Evaluation Figure 2. Flow chart of solar radiation estimation, water requirement calculation, and corresponding evaluations in this study. LMS = least mean squares.
The performance of curve fitting, including H f -H s and H c -H s , were evaluated to analyze each solar radiation estimation method. The performance of curve fitting, including V f -V s . and V c -V s , were evaluated to analyze water requirement according to each solar radiation estimation method. Both of the evaluations were based on the equations proposed in Section 2.1.3. All data in this study were processed and all figures were drawn using Python 3.7 (Python Software Foundation, Wilmington, DE, USA). The data of H s and H out is available in Data file S1 and Data file S2 respectively. And the program is available in Program file S1.

Determination of µ and L
The length (L) of the LMS filter varies in different applications and ordinary lengths are 8, 9, 64, and 128, but the sample interval in greenhouse applications always ranges from 1 min to 1 h or more. Given a sample interval of 15 min, L = 128, introduces a time delay at more than 24 h, so a smaller number of taps is preferred. In this study, L was 9.
According to Equations (24) and (25), the upper bound of µ was computed. In experimental days, the maximum of E[x 2 (n)] was 145. To avoid computational overflow in the program, each value of H out was multiplied by 0.01. So, the upper bound of µ was 0.0007.
In the range of 10 −5 to 5 × 10 −4 , six values were chosen for evaluation to determine the exact value of µ. According to the procedure proposed in Section 2.6, H f and H c were computed according Sensors 2020, 20, 155 9 of 18 to H out collected between 07:00 and 17:00 on experimental days. Then, the performance was evaluated; notably, in the three taps of the left shift of H f for compensation of computational delay. In the latter parts of this study, the length and direction of shift were constant unless otherwise mentioned.
As shown in Table 1, the distribution of evaluation parameters showed a single peak, and R 2 , RMSE, rRMSE, and MAE reached their minimum when µ was 5 × 10 −5 ; so, in this study, µ was determined.  Figure 3. Two days were sunny, 11 and 12 December. In Figure 3c, the curve of H s fluctuated obviously near its peak value, whereas the curve of H f , which tended to have a half-wave sinusoidal shape, was smooth. In other words, the fluctuation range of H f was very narrow near noon. The fluctuations of H out and H c ranged between H s and H f . We observed quick changes in the curves of H out and H c near their peak value at about 11:00 each day and the quick changes were introduced by a metal bar installed nearby the weather station. So, the weather station measurements were temporarily disturbed by the shadow of the bar. In contrast, the curve of H f proved to be immune to this temporary disturbance.

Tomato Water Requirement
According to Equation (16), Ri was computed using Hc, Hf, and Hs, which are presented as Rc, Rf, and Rs, respectively. Tstart values were 08:15, 08:00, 08:00, 08:00, 11:00, 10 (27) and (28), respectively, are also shown in Table 2. The weather was partly cloudy on 5 and 10 December. According to the curves of H out , H c , H f , and H s in Figure 3b, as the cloud cover increased after 14:00 on 5 December, the curves of H out , H c , and H s fluctuated considerably, and these fluctuations made the curves rougher than the H f curve. The overall trend of the curves was H f > H c > H s during this time. The fluctuations of the curves of H out , H c , and H s on 10 December were more obvious than on 5 December. However, the H f curve was smoother than the other curves and fluctuation range was narrow on 10 December. In addition, the shape of H f on both days distorted gradually.
The day was overcast on 2 and 8 December. Due to the lower outer solar radiation in the morning on these days, the blanket was rolled up later than usual. So a distinguishing rising edge, after which H s curve was close to the H c and H f curves, rapidly appeared on the H s curve in Figure 3a. The operation of the blanket resulted in a T start at 11:00 and 10:00 on 2 and 8 December, respectively. According to the H out , H c , H f , and H s curves in Figure 3c, as the cloud cover increased after 13:00 on 2 December, the curves of H out , H c , and H s fluctuated obviously, making the curves rougher than the H f curve. The fluctuations of H out , H c , and H s curves on 8 December proved to be more obvious than on 2 December. However, the curve of H f was smoother than other curves and the fluctuation range was narrow on 8 December. The shapes of H f on both days were distorted and were no longer half-wave sinusoidal.

Tomato Water Requirement
According to Equation (16) (15) as shown in Table 2. The PE of V f -V s . and V c -V s , presented as PE fs and PE cs , respectively, calculated via Equations (27) and (28), respectively, are also shown in Table 2. The data on 11 and 12 December in Table 2 show that V s . < V f < V c and PE fs < PE cs . The PE fs values on both days were smaller than 2% but the values of PE cs tended to be more than 7%. The data show PE fs < PE cs on 5 December and PE fs > PE cs on 10 December. The difference in PE fs and PE cs was 5.6% on 5 December and 1.2% on 10 December. The data on 2 and 8 December show that PE fs = PE cs . Figure 4a and the fitting function of H f and H s was y = 0.7634x + 50.58. The scatter plot of H c and H f is shown in Figure 4b and the fitting function was y = 0.9376x + 33.04. The latter analysis focuses on the performance of each method under sunny conditions, which dominated during the experimental period.

Overall Performance of Estimation of Hi
The scatter plot of Hf and Hs is shown in Figure 4a and the fitting function of Hf and Hs was y = 0.7634x + 50.58. The scatter plot of Hc and Hf is shown in Figure 4b and the fitting function was y = 0.9376x + 33.04. The latter analysis focuses on the performance of each method under sunny conditions, which dominated during the experimental period. In Figure 4a,b, when some points of Hf increased above 30 Wm −2 , Hs was nearly 0 Wm −2 . These larger values are mainly attributed to the postponed blanket operations. Differences of Hs and estimated values including Hf and Hc appeared to be large because Hf and Hc had reached higher values when Hs was still near 0 Wm −2 .
In Figure 4a, as Hs rose above 200 Wm −2 , the number of points of Hf < Hs also increased gradually. When Hs rose above 300 Wm −2 , the number of points of Hf < Hs was greater than the number of points of Hf > Hs. The details of the curves during 10:00-14:00 on 11 and 12 December indicates as Hs rose above 200 Wm −2 , the increasing speed rose so the curve of Hs gradually stayed above the curve of Hf. Hence, the increasing number of points of Hf < Hs in Figure 3c contributed to the increasing rising speed of Hs. The peaks in the Hs curve on these two days in Figure 4a reached more than 300 Wm −2 ; so, when Hs > 300 Wm −2 , the number of points of Hf < Hs dominated. Oscillation was observed when Hs rose above 200 Wm −2 , so some Hf > Hs points were introduced.
In contrast, in Figure 4b, the number of points of Hc < Hs changed within a small variation range, and Hs stayed above Hc only near its peak value. When Hs rose above 250 Wm −2 (Figure 4b), some points of Hc < Hs occurred due to the disturbance caused by the metal bar near the outer weather station.
In summary, the overall trend in Figure 4a was Hc > Hf > Hs when Hs < 200 Wm −2 , and Hc > Hs > Hf when Hs > 200 Wm −2 . According to Figure 4a-c, the fluctuation range of Hf was the smallest among the four curves.
The pass band characteristics of LMS filters in Section 3.2 are shown in Figure 5. And the FFTs of Hout in Section 3.2 are also shown in this figure. The pass band characteristics of LMS filters in these six days were all low pass. The low pass characteristic made Hf smoother than Hout, which In Figure 4a In Figure 4a, as H s rose above 200 Wm −2 , the number of points of H f < H s also increased gradually. When H s rose above 300 Wm −2 , the number of points of H f < H s was greater than the number of points of H f > H s . The details of the curves during 10:00-14:00 on 11 and 12 December indicates as H s rose above 200 Wm −2 , the increasing speed rose so the curve of H s gradually stayed above the curve of H f . Hence, the increasing number of points of H f < H s in Figure 3c contributed to the increasing rising speed of H s . The peaks in the H s curve on these two days in Figure 4a reached more than 300 Wm −2 ; so, when H s > 300 Wm −2 , the number of points of H f < H s dominated. Oscillation was observed when H s rose above 200 Wm −2 , so some H f > H s points were introduced.
In contrast, in Figure 4b, the number of points of H c < H s changed within a small variation range, and H s stayed above H c only near its peak value. When H s rose above 250 Wm −2 (Figure 4b), some points of H c < H s occurred due to the disturbance caused by the metal bar near the outer weather station.
In summary, the overall trend in Figure 4a Figure 4a,b, the fluctuation range of H f was the smallest among the four curves.
The pass band characteristics of LMS filters in Section 3.2 are shown in Figure 5. And the FFTs of H out in Section 3.2 are also shown in this figure. The pass band characteristics of LMS filters in these six days were all low pass. The low pass characteristic made H f smoother than H out , which was the smoothest among H out , H c , and H s . The low pass characteristic also made the LMS filter immune to temporary disturbances, which were common in many greenhouse applications. was the smoothest among Hout, Hc, and Hs. The low pass characteristic also made the LMS filter immune to temporary disturbances, which were common in many greenhouse applications.
We found the LMS filter is not applicable if research focuses on the fluctuations in solar radiation due to its low pass characteristic.

Overall Performance of Tomato Water Requirement Calculation
According to the procedure in Section 3.2.2, we calculated the Vc, Vf, and Vs. of each day during the experimental period, as shown in Figure 6. The overall trend of these three values was the same: they all increased when cloud cover decreased. Vf was close to Vs. when cloud cover was lower, and to Vc when cloud cover was higher. The scatter plots of Vf-Vs. and Vc-Vs. are shown in Figure 7, and the fitting functions of Vf-Vs. and Vc-Vs. are y = 0.8470x + 102.2 and y = 0.9656x + 74.6, respectively. As shown in Figure 7, Vf was We found the LMS filter is not applicable if research focuses on the fluctuations in solar radiation due to its low pass characteristic.

Overall Performance of Tomato Water Requirement Calculation
According to the procedure in Section 3.2.2, we calculated the V c , V f , and V s . of each day during the experimental period, as shown in Figure 6. The overall trend of these three values was the same: they all increased when cloud cover decreased. V f was close to V s . when cloud cover was lower, and to V c when cloud cover was higher.
Sensors 2020, 20, x FOR PEER REVIEW 11 of 18 was the smoothest among Hout, Hc, and Hs. The low pass characteristic also made the LMS filter immune to temporary disturbances, which were common in many greenhouse applications. We found the LMS filter is not applicable if research focuses on the fluctuations in solar radiation due to its low pass characteristic.

Overall Performance of Tomato Water Requirement Calculation
According to the procedure in Section 3.2.2, we calculated the Vc, Vf, and Vs. of each day during the experimental period, as shown in Figure 6. The overall trend of these three values was the same: they all increased when cloud cover decreased. Vf was close to Vs. when cloud cover was lower, and to Vc when cloud cover was higher. The scatter plots of Vf-Vs. and Vc-Vs. are shown in Figure 7, and the fitting functions of Vf-Vs. and Vc-Vs. are y = 0.8470x + 102.2 and y = 0.9656x + 74.6, respectively. As shown in Figure 7, Vf was The scatter plots of V f -V s . and V c -V s . are shown in Figure 7, and the fitting functions of V f -V s . and V c -V s . are y = 0.8470x + 102.2 and y = 0.9656x + 74.6, respectively. As shown in Figure 7, V f was close to V c when V s . < 400 mL and V f was close to V s . when V s . > 400 mL. The difference between V f Sensors 2020, 20, 155 13 of 18 and V s . decreased as V s . increased but, conversely, the trend in the difference between V c and V s . was not the same as V f -V s . When V s . rose above 600 mL plant −1 , the values of V f and V s . were almost the same; when V s . dropped below 400 mL plant −1 , the values of V f and V c were almost the same.
Sensors 2020, 20, x FOR PEER REVIEW 12 of 18 close to Vc when Vs. < 400 mL and Vf was close to Vs. when Vs. > 400 mL. The difference between Vf and Vs. decreased as Vs. increased but, conversely, the trend in the difference between Vc and Vs. was not the same as Vf-Vs. When Vs. rose above 600 mL plant −1 , the values of Vf and Vs. were almost the same; when Vs. dropped below 400 mL plant −1 , the values of Vf and Vc were almost the same. PEfs, PEcs, and Kt are shown in Figure 8. We found an opposite trend between PEs and Kt. The lowest value of PEfs was lower than that of PEcs. Among 2,8,14,22, and 24 December, in which Kt was greater than 40%, PEfs was close to PEcs and PEfs < PEcs on other days. Among 1, 2, 11, and 12 December, PEfs was almost 0.

Discussions
The four evaluation parameters of Hf-Hs and Hc-Hs on days in Section 3.2 were computed according to Equations (1) and (3)-(5), as shown in Table 3. Studies proved that estimation of solar radiation in hourly intervals was good enough if rRMSE ranged from 34% to 41% [16,47,48], so conclusions can be drawn as follows. Under sunny conditions, the estimation of Hf-Hs was more accurate than Hc-Hs and both of the methods were good enough on 11 and 12 December. Under partly cloudy conditions, the estimations of Hf-Hs and Hc-Hs were all good enough, with rRMSE in both cases below 41% on 5 December. Due to the rRMSE of Hf-Hs being above 41%, only the estimation of Hc-Hs was good enough on 10 December. Under overcast conditions, the estimations of Hf-Hs and Hc-Hs were all poor, with rRMSE above 41% on 2 December and rRMSE of Hf-Hs above 41%. Only estimation of Hc-Hs was acceptable on 8 December. PE fs , PE cs , and K t are shown in Figure 8. We found an opposite trend between PEs and K t . The lowest value of PE fs was lower than that of PE cs . Among 2,8,14,22,and 24 December, in which K t was greater than 40%, PE fs was close to PE cs and PE fs < PE cs on other days. Among 1, 2, 11, and 12 December, PE fs was almost 0.  PEfs, PEcs, and Kt are shown in Figure 8. We found an opposite trend between PEs and Kt. The lowest value of PEfs was lower than that of PEcs. Among 2,8,14,22,and 24 December, in which Kt was greater than 40%, PEfs was close to PEcs and PEfs < PEcs on other days. Among 1, 2, 11, and 12 December, PEfs was almost 0.

Discussions
The four evaluation parameters of Hf-Hs and Hc-Hs on days in Section 3.2 were computed according to Equations (1) and (3)-(5), as shown in Table 3. Studies proved that estimation of solar radiation in hourly intervals was good enough if rRMSE ranged from 34% to 41% [16,47,48], so conclusions can be drawn as follows. Under sunny conditions, the estimation of Hf-Hs was more accurate than Hc-Hs and both of the methods were good enough on 11 and 12 December. Under partly cloudy conditions, the estimations of Hf-Hs and Hc-Hs were all good enough, with rRMSE in both cases below 41% on 5 December. Due to the rRMSE of Hf-Hs being above 41%, only the estimation of Hc-Hs was good enough on 10 December. Under overcast conditions, the estimations of Hf-Hs and Hc-Hs were all poor, with rRMSE above 41% on 2 December and rRMSE of Hf-Hs above 41%. Only estimation of Hc-Hs was acceptable on 8 December.

Discussions
The four evaluation parameters of H f -H s and H c -H s on days in Section 3.2 were computed according to Equations (1) and (3)-(5), as shown in Table 3. Studies proved that estimation of solar radiation in hourly intervals was good enough if rRMSE ranged from 34% to 41% [16,47,48] [47][48][49]. Additionally, the decreasing of estimation accuracy lies in the increasing portion of diffuse solar radiation, which is always measured at a lower accuracy [48]. Since outer solar radiation is decomposed into beam and diffuse parts in our study, estimation accuracy is also affected if cloud cover increases. However, with the LMS filter being introduced, estimation accuracy of ours is affected less than in other methods because of the LMS filter's low pass characteristic. In contrast, the estimation accuracy of H c -H s proved to be the best on partly cloudy days, the worst on sunny days, and medium on overcast days. In the study of Huang et al. (2019) and Tong et al. (2017) the fluctuation of H i tends to be larger at noon [14,25], and the same trend was found in our study. It is a common phenomenon that large fluctuations appear in the data on a sunny noon, but to our knowledge the mechanism of this phenomenon needs further analysis.
The evaluation parameters of H f -H s , H c -H s , V f -V s . and V c -V s . during experimental days computed according to Equations (1) and (3)-(5) are shown in Table 4. The results indicate that estimation of H f -H s was more accurate than H c -H s , so the proposed method proves to be more accurate than astronomy and geometry method [16,17]. Additionally, rRMSE of H f -H s is within the range between 34% and 41% [16,48], so this method is acceptable in solar radiation estimation. In the study of , the evaluation parameters of solar radiation estimation proved to be R 2 = 0.71, RMSE = 68.34 Wm −2 , and rRMSE = 30.54% in contrast [16]. Moreover, film transmittances are still important factors in our method and their values are not constant in applications, therefore, the accuracy of our model is affected by transmittances variations. In the studies of Gueymard and Myers (2008), data filtering is considered as an important factor to improve solar radiation sensing accuracy [50]. In our study, the LMS filter performs low pass filtering and the operation of Equation (16) is also low pass filtering. So, the calculation of V f performs a two-stage low pass filtering and the evaluation parameters of V f -V s . tend to be even better. The results of our study show the impacts introduced by fluctuations, especially in cloudy and overcast weather conditions. The results of our study have also proved the importance of filtering in both solar radiation estimation and water requirement calculation.
However, the following points need to be fully improved. Firstly, the accuracy of the model is affected by cloud cover. For better performance, the new methods in the measure/estimate diffuse of solar radiation with more accuracy are to be developed. Secondly, real-time transmittance computation should be an important part of the model for better accuracy. Thirdly, we conduct research supposing the CSG is at east-west orientation with no incline. However, some CSGs are built with an incline due to terrain restrictions. Finally, long term analysis is to be conducted for better use of our model.
In our study, with no indoor sensors needed, the cost of solar radiation sensing is little. In the literature of Villarrubia et al. (2017), the cost of an irrigation system is acceptable when cost amounts to 100€/250 m 2 [51]. Therefore, our research reduces the expense of solar radiation sensing and is contributing to the promotion of precision agriculture in CSGs.

Conclusions
In this study, solar radiation inside a CSG was estimated based on an LMS filter, and then the tomato water requirement was calculated according to the estimation data. The performance of both solar radiation estimation and water requirement calculation were compared to the corresponding methods based on knowledge of astronomy and geometry.
The results showed that the fitting function of estimation data based on the LMS filter and data collected from sensors inside the greenhouse was y = 0.7634x + 50.58, with the evaluation parameters of R 2 = 0.8384, rRMSE = 23.1%, RMSE = 37.6 Wm −2 , and MAE = 25.4 Wm −2 . The fitting function of the water requirement calculated according to the proposed method and data collected from sensors inside the greenhouse was y = 0.8550x + 99.10 with the evaluation parameters of R 2 = 0.9123, rRMSE = 8.8%, RMSE = 40.4 mL plant −1 , and MAE = 31.5 mL plant −1 .
The low pass characteristic of the LMS filter leads to the following two results. First, the performance of the proposed method is more accurate than that of the contrastive method. Second, the proposed method performs well on sunny days but performs worse on party cloudy and overcast days. In addition, LMS is easy to be performed in microcontrollers. Therefore, the method is proved to be efficient and low cost in both solar radiation estimation and tomato water requirement calculation. However, it is not applicable if focusing on the fluctuations of solar radiation inside a greenhouse.
Supplementary Materials: The following are available online at http://www.mdpi.com/1424-8220/20/1/155/s1, Figure S1: Diagram of sensor placement inside the greenhouse, Figure S2: Daily average greenhouse global transmittance (τg) calculated from data from exterior and interior inside sensors and the overall average value of τg during experiment, Figure S3: Growing degree days (GDD) during experimental days, Figure S4: Basic diagram of adaptive filter. Data file S1: Indoor solar radiation and temperature data file, values_in_copy.xlsx, Data file S2: Outside solar radiation data file, values_out_12.xlsx. Program file S1: LMS function and outcome display program file, lmsRev3.py.