Optimal Regulation Method of Greenhouse Light Environment considering Photosynthetic Rate Model Error

Due to the complexity of photosynthesis of greenhouse crops, there are inevitable errors between the established photosynthetic rate model and the actual value, which makes it dicult to guarantee the optimality and even feasibility of the optimal regulation of greenhouse light environment based on the original photosynthetic rate model. To solve these problems, this paper proposes an optimal regulation method of greenhouse light environment considering the error of photosynthetic rate model. e main contributions of this method are as follows: rstly, the photosynthetic rate model is established by using the error compensation extreme learning machine method to reduce the error between the model output and the actual value. en, the model output is introduced into the optimal regulation problem of greenhouse light environment to form the optimal regulation model of greenhouse light environment after error compensation, and the constrained adaptive particle swarm optimization algorithm is used to solve the optimal regulation model, which ensures the rapid convergence of optimization results, makes the optimization results closer to the actual optimal values, and improves the reliability of optimal regulation of greenhouse light environment. Finally, the eectiveness of the proposed optimal regulation method is veried by experiments. e simulation results also show that the proposed optimal regulation method can give a reasonable light intensity setting value in time under dierent temperature, humidity, and CO2 conditions inside greenhouse, meet the needs of photosynthesis of actual greenhouse crops, and make the growth of greenhouse crops ecient and stable.


Introduction
Crop photosynthesis refers to the biochemical process of converting CO 2 and water into the organic matter and realizing the material accumulation under certain light intensity [1,2]. Light is one of the main conditions of photosynthesis, and weak light will reduce the net photosynthetic rate of crop leaves, a ect the synthesis and accumulation of crop photosynthetic products, and then a ect the owering, pollination, and fruit setting of solanaceous crops (e.g., tomato, eggplant, etc.). Eventually, the yield and quality of crops will decline. Due to the in uence of greenhouse structure, covering materials, solar incidence angle, haze, rain, and snow weather, the light intensity in the conventional greenhouse is only 40%∼70% of that in the eld, which limits the photosynthetic capacity of crops and is di cult to meet the needs of crop growth and development, thereby a ecting the yield and quality of crops [3][4][5]. erefore, determining a reasonable optimal regulation strategy of light environment for improving the photosynthetic rate of greenhouse crops is of great signi cance to promote the growth and yield of greenhouse crops. e basis of optimal regulation of greenhouse light environment is the prediction model of photosynthetic rate. In recent years, relevant scholars have established physiological models of photosynthesis [6,7]. However, most of the inputs to the model are destructively measured physiological parameters, such as quantum e ciency and mitochondrial respiration rate. Under the existing technical conditions, it is di cult to measure them accurately. At the same time, the daily and seasonal changes of greenhouse environment are great, and the demand of crops for environment is time-varying. erefore, the model is not suitable for direct application to the optimal regulation of greenhouse light environment. In view of this, some researchers have studied data-based photosynthetic rate models [8][9][10][11][12][13][14][15], which take the main environmental factors affecting photosynthesis as input variables. e model has the advantages of simple structure and convenient analysis and has been widely used in the crop photosynthesis simulation. However, crop photosynthesis is affected by many environmental factors in greenhouse; due to the disturbance and uncertainty of the greenhouse environment, it is difficult to establish a databased photosynthetic rate model that accurately reflects the actual photosynthetic process, and there are inevitable errors between the model output and the actual value. erefore, the light saturation point obtained from the optimal regulation of greenhouse light environment based on the original photosynthetic rate model will deviate from the actual optimal value and may even be infeasible, which is difficult to meet the actual needs of optimal regulation of greenhouse light environment. In addition, in solving the optimal regulation problem of greenhouse light environment, relevant scholars widely adopted intelligent optimization algorithms such as genetic algorithm (GA) and particle swarm optimization (PSO) algorithm to solve the optimal regulation problem of greenhouse light environment [16][17][18], and the light saturation point is obtained with maximizing the photosynthetic rate as the goal, which can be used to guide the regulation of greenhouse light environment. However, due to the complexity of the objective function in the optimal regulation problem, there are some problems such as poor convergence and low accuracy when using the standard intelligent optimization algorithm, resulting in the unsatisfactory regulation effect.
To address the above problems existing in the optimal regulation methods of greenhouse light environment, this paper proposes an optimal regulation method of greenhouse light environment considering the error of photosynthetic rate model. is method firstly proposes a photosynthetic rate modeling method based on error compensation extreme learning machine, in which a new learning algorithm, also known as extreme learning machine (ELM), is used to establish the initial photosynthetic rate model so as to overcome the problems of slow training speed and easy to fall into local optimum of traditional data modeling algorithms. And then, aiming at the problem that it is difficult to describe the error of photosynthetic rate model, considering the successful application of Gaussian mixture model (GMM) technology in the model correction of complex system, GMM is adopted to describe the error mean and error variance of photosynthetic rate model, and the error compensation of photosynthetic rate model is realized by using the error mean. en, the photosynthetic rate model after error compensation is introduced into the established optimal regulation model of greenhouse light environment to form the optimal regulation model of greenhouse light environment after error compensation, which makes the optimal regulation results closer to the actual optimal values. Moreover, aiming at the shortcomings of standard particle swarm optimization (PSO) algorithm in solving this optimal regulation model, an adaptive particle swarm optimization (APSO) algorithm is used to solve the optimal regulation model to improve the efficiency of solving the optimal regulation problem of greenhouse light environment. Finally, the simulation is carried out by using the relevant data of tomato growth in a solar greenhouse to verify the reliability and the effectiveness of the proposed modeling method and optimal regulation method.
In order to further show the highlights of this paper, referring to these literatures [19][20][21][22][23], the innovations and main contributions of this paper are listed as follows: (i) e optimal regulation method of greenhouse light environment considering the photosynthetic rate model error is proposed, which makes the optimal regulation result closer to the actual optimal value and improves the reliability of optimal regulation of greenhouse light environment. (ii) An error compensation ELM modeling method is proposed to establish the photosynthetic rate model for reducing the error between the initial photosynthetic rate model and the actual value. (iii) e optimal regulation model of greenhouse light environment after error compensation is formed by introducing the established photosynthetic rate model, which is solved by APSO algorithm to improve the convergence speed and accuracy of the solution. (iv) e relevant data of tomato growth process in a solar greenhouse are used to prove the effectiveness of the proposed optimal regulation method of greenhouse light environment. e rest of the paper is organized as follows. In Section 2, the optimal regulation problem of greenhouse light environment is described. In Section 3, the optimal regulation method of greenhouse light environment considering the photosynthetic rate model error is proposed. In Section 4, the example verification and result analysis are given. Lastly, the paper is summarized.

Optimal Regulation Problem of Greenhouse
Light Environment e intelligent optimal regulation of greenhouse light environment (as shown in Figure 1) can make the light environment in the greenhouse always suitable for crop growth [24], which plays an important role in improving the yield and benefit of greenhouse crops.
As can be seen from Figure 1, the system first collects the environmental information of the greenhouse in real time, including temperature, humidity, CO 2 concentration, and light intensity, and then inputs the collected environmental information into the optimal regulation of greenhouse light environment to obtain the light saturation point under the corresponding environmental conditions. By calculating the difference between the light saturation point and the current light intensity value, the supplementary light lamps are adjusted to make the light intensity in the greenhouse reach the light saturation point, thereby realizing the intelligent regulation of greenhouse light environment.
It can also be seen from the above figure that in the intelligent optimal regulation system of greenhouse light environment, the description of the optimal regulation problem of greenhouse light environment is the most important part. erefore, this section first gives the objective function and constraints of the problem and then gives the mathematical model of the problem.

Objective Function of the Optimal Regulation Problem of Greenhouse Light Environment.
Because the optimal regulation of greenhouse light environment is to make the light environment in the best state according to the actual growth needs of crops, and the crop growth is a process of metabolism and material accumulation through photosynthesis, therefore, as an index to measure the photosynthetic capacity, the photosynthetic rate can directly reflect the total growth capacity of crops and can be used to evaluate the light intensity. erefore, this paper takes the maximization of photosynthetic rate in the crop growth process as the objective function of the optimal regulation of greenhouse light environment.

Constraints of the Optimal Regulation Problem of
Greenhouse Light Environment. Temperature, humidity, CO 2 concentration, and light intensity in the greenhouse will affect the photosynthesis of crops. At the same time, these environment factors interact with each other and have strong dynamic changes under the influence of external climate conditions and the operation state of regulation equipment, resulting in significant changes in photosynthetic rate. erefore, in order to realize the optimal regulation of greenhouse light environment, it is necessary to meet a certain range of temperature, humidity, CO 2 concentration, and light intensity, as well as the relationship between various environment factors, which is the key constraint to obtain the optimal light intensity setting value for maximizing photosynthetic rate.

Optimal Regulation Model of Greenhouse Light
Environment. As mentioned above, maximizing the photosynthetic rate is taken as the objective function, and the upper and lower limits of environmental factors and the relationship between various environmental factors are taken as the inequality constraints. And temperature, humidity, CO 2 concentration, and light intensity that have a great impact on the photosynthetic rate are taken as decision variables; the optimal regulation model of greenhouse light environment is established as follows: where the definitions and units of relevant symbols in (1) are given in the Nomenclature.

Optimal Regulation of Greenhouse Light Environment considering Photosynthetic Rate Model Error
Owing to the complexity of crop photosynthetic process and the influence of the disturbance and uncertainty of greenhouse environment, it is difficult to establish a photosynthetic rate model that accurately reflects the actual photosynthesis process, and there are inevitably some errors in the model, which presents a great challenge to the optimal regulation of greenhouse light environment based on the original photosynthetic rate model. To address this problem, this paper proposes a framework of the optimal regulation method of greenhouse light environment considering photosynthetic rate model error, as shown in Figure 2. e method consists of the photosynthetic rate model established by error compensation ELM and the optimal regulation of greenhouse light environment after error compensation. Firstly, aiming at the problem of error between photosynthetic rate model and the actual value, an error compensation ELM modeling method is proposed to establish the photosynthetic rate model. In this method, Gaussian mixture model (GMM) is used to estimate the error of the initial photosynthetic rate model established by  Mathematical Problems in Engineering extreme learning machine (ELM), and the outputs of the two models are superimposed as the output of the final photosynthetic rate model, which realizes the error compensation of the initial photosynthetic rate model and improves the prediction accuracy of the model. en, the photosynthetic rate model after error compensation is introduced into the optimal regulation problem of greenhouse light environment in (1) to form the optimal regulation model of greenhouse light environment after error compensation. And the adaptive particle swarm optimization (APSO) algorithm is used to solve the optimal regulation model after error compensation, and the light saturation point under the condition of maximizing photosynthetic rate is obtained to guide the optimal regulation of greenhouse light environment.

Photosynthetic Rate Model Established by Error Compensation ELM.
In order to improve the prediction accuracy of photosynthetic rate model and ensure the optimality and feasibility of optimal regulation of greenhouse light environment based on this model, an error compensation ELM modeling method is proposed to establish photosynthetic rate model.

Extreme Learning Machine (ELM).
Aiming at the problems of slow training speed and easy to fall into local optimum in traditional data-driven modeling methods (e.g., neural network learning algorithm), Huang et al. propose a new learning algorithm, namely, extreme learning machine (ELM) algorithm [25], as shown in Figure 3. ELM is a single hidden layer feedforward network with three-layer structure; the main feature of the algorithm is to randomly generate hidden layer learning parameters, transform the training process into the solution of linear equations, and then obtain the least squares solution of the minimum norm according to Moore-Penrose's generalized inverse matrix theory [26][27][28]. Because the whole training process does not need iteration, it has fast training speed and strong generalization ability.
Assuming that there are G samples . , t iM ] T represents the M-dimensional output vector of the ith sample, the output of the single hidden layer feedforward neural network with L hidden layer nodes is represented as follows [29]: where a k � [a k1 , a k2 , . . . , a kN ] T and b k are hidden layer learning parameters, β k � [β k1 , β k2 , . . . , β kM ] T is the weight matrix connecting the kth hidden layer node and the output node, and G(a k , b k , u i ) is the output function of the kth hidden layer node. Equation (2) is written in the matrix form, as Hβ � T, From the perspective of optimization, ELM algorithm is to search the optimal output weight by minimizing the training error and outputting the weight norm, and the optimization problem is expressed as follows:  . . .

Output nodes
Randomly generated (a i ,b i ) β obtained by optimisation where c is the regularization parameter and e i is the training error. e solution of (3) is transformed into a dual optimization problem, and the estimated value of the output weight is expressed as follows:

Error Compensation of ELM Model by Using GMM.
Due to the complexity of photosynthetic process of greenhouse crops, the prediction results of photosynthetic rate model established only by ELM algorithm are not ideal.
In order to reduce the error between the model output and the actual value, it is of positive significance to describe the error characteristics of the established model [30,31]. In view of the advantages of Gaussian mixture model (GMM) in the model correction of complex system [32], based on the initial photosynthetic rate model established by ELM algorithm, this paper uses GMM to describe the error mean and error variance of the model and uses the error mean to compensate the error of the model. e input vector of the initial model and the prediction error of the corresponding model are taken as the inputs of GMM, which are expressed as follows: where X e− represents the vector composed of environmental factors including temperature, humidity, CO 2 concentration, and light intensity, e � y actual − y, y is the prediction value of the initial photosynthetic rate model, y actual is the actual value of photosynthetic rate, and the error mean μ e/x e− and error variance e/x e− under the condition X e− can be obtained by the following derivation. e probability distribution function of model error [33,34] is expressed as follows: where P(X) is the joint probability density distribution of GMM, P(e/X e− ) is the probability distribution of model error under X e− , 0 ≤ α j ≤ 1, α j is the probability of the jth sample generated by the single Gaussian model, m is the number of single Gaussian models, N(μ j , Σ j ) is the probability density distribution of the jth single Gaussian model, and μ j and Σ j are the mean vector and covariance matrix of the jth single Gaussian model, respectively. According to X � [X e− , e] T , μ and Σ are expressed as follows [35]: So, the inverse of can be obtained as en, the quadratic form of the exponent in the Gaussian distribution is expressed as follows [36]: e left-hand side of (8) can be expanded as follows: Since (8) is equal to (9), the formula can be obtained as follows: Because X e− X e− X e− e eX e− ee According to the definition of matrix inversion, the formula can be obtained as follows: Mathematical Problems in Engineering By substituting (12) into (10), we can get where μ e/X e− and e/X e− are the error mean and error covariance of e under X e− , μ e/X e− represents the deviation of model prediction, and e/X e− indicates the reliability of model prediction results.
Since the deviation is the deviation between the prediction value of the model and the actual value, the error of the initial ELM model can be compensated directly with the conditional error mean μ e/X e− (as shown in Figure 4), which is expressed as follows: where y ′ is the output of photosynthetic rate model after error compensation, y is the prediction value of the initial ELM model, and μ e/X e− is the error estimation value based on GMM.

Optimal Regulation of Greenhouse Light Environment after Error
Compensation. e photosynthetic rate model established by the above error compensation ELM is substituted into (1) to form the optimal regulation model of greenhouse light environment after error compensation. According to the characteristics of the optimal regulation model, the adaptive particle swarm optimization algorithm (APSO) is used to solve the optimal regulation model, to realize the optimal regulation of greenhouse light environment after error compensation, and to improve the reliability of optimal regulation of greenhouse light environment.

Optimal Regulation Model of Greenhouse Light Environment after Error
Compensation. Based on the above description, the flowchart of establishing the optimal regulation model of greenhouse light environment after error compensation is shown in Figure 5. e specific steps are as follows: Step 1. Collect data. e collected data includes input data and output data, the input data is the information of environmental factors including temperature, humidity, CO 2 concentration, and light intensity in the greenhouse, and the output data is the measured value of photosynthetic rate under corresponding environmental conditions.
Step 2. Establish the initial photosynthetic rate model by ELM algorithm and obtain the prediction value of the initial model.
Step 3. Realize the error compensation of the initial photosynthetic rate model based on GMM, and by using the collected data and the data generated by the initial photosynthetic rate model, the number of single Gaussian models is determined by the Bayesian criterion [37], and the parameters of GMM are estimated by expectation maximization (EM) algorithm [38], to realize the training of GMM model for error estimation, and realize the error compensation of photosynthetic rate model by superimposing the output of initial model with the output of error estimation model.
Step 4. e output of photosynthetic rate model after error compensation is replaced by the objective function of equation (1) to form the optimal regulation model of greenhouse light environment after error compensation, which is used for the subsequent optimization solution to ensure the reliability of the optimal regulation of greenhouse light environment.

Solution of the Optimal Regulation Model after Error
Compensation. As the optimal regulation model of greenhouse light environment after error compensation is a typical nonlinear optimization problem with constraints, the method to solve this kind of optimization problem provides a theoretical basis for solving the optimal regulation problem of greenhouse light environment after error compensation. Adaptive particle swarm optimization (APSO) algorithm is a new global optimization intelligent algorithm, which has the advantages of less parameters, low computational complexity, and good convergence. It can better meet the actual needs, especially when the objective function and constraints are complex. At present, APSO algorithm has been successfully applied to solve many complex engineering optimization problems and achieved remarkable results. erefore, this paper uses APSO algorithm to solve the optimization problem of greenhouse light environment after error compensation. Based on the standard particle swarm optimization (PSO) algorithm, APSO algorithm improves its convergence speed and stability by adjusting the inertia weight, and the mathematical expression of the standard PSO algorithm [39] is as follows: where the meanings of variables in equations (15) and (16) are shown in the Nomenclature. e inertia weight ω can balance the global and local search ability of PSO algorithm, determine the impact of the previous iteration speed on the current iteration speed, and has a decisive impact on the convergence performance of the whole algorithm. However, the search of PSO algorithm is a nonlinear and complex process, and the linear change may not achieve an accurate balance between the local search and global search. Meanwhile, taking the photosynthetic rate as the fitness function in this paper, the inertia weight is adaptively adjusted according to the current fitness value of particles, to improve the optimization efficiency of the algorithm and avoid the problem of premature convergence, and find the light intensity setting value that maximizes the photosynthetic rate. erefore, the inertia weight is adjusted nonlinearly and dynamically in this paper, which is expressed as follows: where ω max and ω min are the maximum value and minimum value of ω, respectively, they are generally set to 0.9 and 0.4, respectively, f is the current fitness value of particle, and f avg and f min are the current average fitness value and minimum fitness value of all particles, respectively. As can be seen from (17), when the fitness value of the particle is higher than the average fitness value, ω of the corresponding particle is larger, so the particle is retained. On the contrary, when the fitness value is lower than the average fitness value, ω of the corresponding particle is smaller, which makes the particle closer to a better search space, to guarantee the diversity of particles. And the inertia weight is adaptively adjusted according to the fitness value of particles, which improves the convergence speed and accuracy of solving the optimal regulation problem of greenhouse light environment after error compensation. Accordingly, the flowchart of solving the optimal regulation model of greenhouse light environment after error compensation by APSO algorithm is shown in Figure 6.
As can be seen from Figure 6, the optimal photosynthetic rate and corresponding light saturation point under different combination conditions of temperature, humidity, and CO 2 concentration can be obtained through the optimization solution, to obtain the dynamic regulation target of greenhouse light environment and provide the quantitative guidance for the control of greenhouse light environment.

Example Verification and Result Analysis
In order to verify the effectiveness of the proposed optimal regulation method, the relevant data of the actual growth of tomato in a solar greenhouse of Northeast China is taken as an example to design the optimal regulation of light environment, and the corresponding model prediction results and optimal regulation results are analyzed.

Data Collection.
In order to provide the data for establishing the photosynthetic rate model based on error compensation ELM, it is necessary to collect the information of environmental factors including temperature, humidity, CO 2 concentration and light intensity, and the corresponding photosynthetic rate from the actual growth process of greenhouse tomato. e information of environmental factors is collected in real time by the environmental sensor node hanging 0.1 m above the growth point of tomato plant. e node is connected by twelve integrated sensors of temperature, humidity, and light intensity (S-THL-02, Jshine Tech, Beijing, China) and six CO 2 sensors (GSS-COZIP, GSS, Cumbernauld, UK), and the specific distribution of these sensors is shown in Figure 7.

Mathematical Problems in Engineering
In Figure 7, P i represents the ith (i � 1, 2, . . . , 12) integrated sensor of temperature, humidity, and light intensity, and C j represents the jth (j � 1, 2, . . . , 6) CO 2 sensor. en, the information of various environmental factors is transmitted to the data management center through the wireless gateway.
e measured values of photosynthetic rate corresponding to environmental conditions are obtained through the following experiment, and the specific experimental areas and methods are as follows: e experiment is carried out in an east-west-oriented solar greenhouse (latitude 41.8 o N, longitude 123.4 o E), which is in the experimental base of Shenyang Agricultural University; the greenhouse is 60 m long and 8 m wide. e heights of the northern wall and northern roof are 2.6 m and 4 m, respectively, the wall is a multistorey composite structure, the profile of the greenhouse is shown in Figure 8, and the south roof is covered by a single layer of 0.00012 m thick polyethylene film. e experimental tomato variety is "Liaoyuan Duoli," which is sown in 50-hole seeding tray on September 4, 2020. e tomato seedlings are transplanted when the plant height is about 15 cm and the stem diameter is 0.4 cm. After transplantation, the tomato plants are cultivated in soil ridge, with ridge width of 0.4 m and ridge spacing of 0.6 m. A total of 46 rows are cultivated, and the spacing of transplanted tomato plants is 0.35 m. e transplantation is completed on October 17, 2020. After successful transplantation, 270 tomato plants with stable growth are randomly selected as the test samples, and the fourth leaf without shadow is selected from the top to the bottom of the plant as the test leaf.
As the strong sunlight and high temperature at noon will enhance transpiration, resulting in the closure of many stomata of plants and the reduction of carbon dioxide supply, the corresponding photosynthesis will be affected.
is period is called the lunch break of plants [40]. In order to avoid the influence of lunch break on the measured values of photosynthetic rate, the photosynthetic rate of leaves is measured by a portable photosynthetic instrument (LI-6400XT, LI-COR, Lincoln, NE, USA) between 9:00-11:30 and 14:30-17:30 every day during the test.
During the measurement, different environmental control modules of the photosynthetic instrument are used to set the microclimate environmental conditions, and the set values of various environmental factors are shown in Table 1.
As can be seen from Table 1, there are six temperature gradients, five humidity gradients, five CO 2 concentration and six light intensity gradients, forming 900 groups combination conditions of temperature, humidity, CO 2 concentration, and light intensity. Under each combination condition, the photosynthetic rate is measured three times, and a total of 2700 groups of data are obtained. en, the repeated measured data are averaged to obtain 900 groups of data.

Photosynthetic Rate Model Verification.
Due to the different dimensions between environmental factors and photosynthetic rate, considering its impact on the convergence and complexity of photosynthetic rate modeling, it is necessary to deal with the collected data of environmental factors and photosynthetic rate before modeling. Firstly, the 3 σ criterion [41] is used to eliminate the abnormal data, and then the data is normalized to overcome the influence of different dimensions between variables, which is expressed as follows: where the meanings of symbols in (18) are shown in Table 2, and after normalization U i ′ ∈ [0, 1]. After data processing, 885 groups of data of temperature, humidity, CO 2 concentration, light intensity, and corresponding photosynthetic rate are obtained. Based on these data, the initial photosynthetic rate model is constructed by ELM. In order to realize the error compensation of GMM for  Figure 6: Flowchart of solving optimal regulation of greenhouse light environment after error compensation by APSO algorithm. 8 Mathematical Problems in Engineering the initial photosynthetic rate model, 700 groups of data are generated by using the processed data and the constructed initial photosynthetic rate model, of which 560 groups are used as the training samples to complete the error estimation of the initial photosynthetic rate model, and then the photosynthetic rate model after error compensation is established. e remaining 140 groups are used as the test samples. In order to further verify the performance of the photosynthetic rate model established by this method, the traditional data models (BP and SVM) and ELM model without error compensation are used to predict the test samples, and the prediction results are compared. e results are shown in Figure 9.
As can be seen from Figure 9, compared with BP model, SVM model, and ELM model, the prediction results of error compensation ELM model are closer to the actual values, and the model has a good effect on the prediction of photosynthetic rate. In order to further illustrate the good performance of the model, root mean square error (RMSE), mean absolute error (MAE), and correlation coefficient (CC) are used to evaluate the performance of these models. ese indexes are calculated by the following equations, and the results of these models are shown in Table 3.
And the physical meanings and units of the symbols in the above equations appear in the Nomenclature.
It can be seen from Table 3 that the RMSE of error compensation ELM model is smaller, and compared with the   other three models, it is reduced by at least 50%. Moreover, MAE is relatively small, and the correlation coefficient (CC) between the actual value and the prediction value is relatively high. erefore, the error compensation ELM model is obviously superior to other models in terms of these performance indexes, which greatly improves the accuracy of  Light intensity μ mol m − 2 s − 1 h j (x) ≤ 0 e jth inequality constraint among multiple environmental factors m Number of inequality constraints x i min Lower limit of ith environmental factor in greenhouse x i max Upper limit of ith environmental factor in greenhouse k Number of iterations V id (k) Velocity of the ith particle on the d-dimensional component of the kth iteration(i � 1, 2, · · · , n, d � 1, 2, · · · , N, k � 1, 2, · · · , k max ) X id (k) Position of the ith particle on the d-dimensional component of the kth iteration g best,i (k) Individual optimal solution of the kth iteration g best (k) Global optimal solution of the kth iteration c 1 , c 2 Learning factors r 1 , r 2 Random numbers with uniform distribution on [0, 1] ω Inertia weight U i Value before the normalization of the ith variable

Optimal Regulation Results.
On the premise of establishing the photosynthetic rate model after error compensation, the light intensity during tomato growth is optimized at regular intervals. erefore, it is necessary to use APSO to solve the optimal regulation model of greenhouse light environment after error compensation so as to obtain the light saturation point under the optimal photosynthetic rate. e relevant parameters of APSO algorithm are set as follows: the population size n is 100, the maximum number of iterations k max � 100, the learning factor c 1 � c 2 � 1.8, and the inertia weight ω max � 1.0, ω min � 0.3. In order to verify the solution performance of APSO algorithm, PSO algorithm is also used to solve the optimal regulation model of greenhouse light environment after error compensation, and the corresponding evolutionary iterative process of the two intelligent optimization algorithms under one random combination condition of temperature, humidity, and CO 2 concentration is shown in Figure 10.
As can be seen from Figure 10, when solving the optimal regulation model of greenhouse light environment after error compensation, the standard PSO algorithm needs 40 iterations to converge, and the algorithm is easy to fall into local optimum. On the other hand, the APSO algorithm only needs 25 iterations to converge, and it has faster convergence speed and higher convergence accuracy. erefore, APSO algorithm has high solution speed and accuracy in solving the optimal regulation model of greenhouse light environment after error compensation.
In order to verify the rationality and effectiveness of the solution results obtained by the optimal regulation model after error compensation, APSO algorithm is used to solve the optimal regulation model of greenhouse light environment before and after error compensation under all combination conditions of temperature, humidity, and CO 2 concentration, and the optimization calculation results are shown in Figure 11.
It can be seen from Figure 11, by solving the optimal regulation model of greenhouse light environment before and after error compensation, the light saturation point under different environmental combination conditions is obtained, which provides the quantitative guidance for the regulation of greenhouse light environment. Meanwhile, compared with the optimal regulation model before error compensation, the optimal photosynthetic rate obtained by solving the optimal regulation model after error compensation is higher. In order to further illustrate the reliability of the optimal regulation results after error compensation, the light environment in the greenhouse is adjusted according to the light saturation point before and after error compensation, and the actual value of photosynthetic rate is obtained. Since six temperature gradients are set in this paper, the optimization results under six combination conditions with different temperatures are listed and compared with the actual values, and the comparison results are shown in Table 4.
As can be seen from Table 4, with the increase of temperature, the optimal photosynthetic rate and light saturation point increase, but when the temperature is too high, the optimal photosynthetic rate will decrease. is is because the temperature is too high, the light respiration and dark respiration of crops are enhanced, so the photosynthetic rate is inhibited. is is consistent with the response rule of environmental factors to the photosynthetic rate, indicating the effectiveness of the optimal regulation results. Moreover, the photosynthetic rate obtained by the proposed optimal regulation method of greenhouse light environment is closer to the actual value, and compared with the optimal regulation method before error compensation, the optimal regulation performance after error compensation is improved more. For example, for the result of number 1 in Table 4, the optimal photosynthetic rate is increased from 17.4278 (μ mol m − 2 s − 1 ) to 18.0795 (μ mol m − 2 s − 1 ). e above results verify the effectiveness and superiority of the    Table 4: Comparison results between the actual values and the optimization results obtained by solving the optimal regulation models before and after error compensation.