A temperature adaptive control method for insect protein preservation system
By calculating the asynchronous coefficient and conditional entropy in the insect protein storage library and adjusting the proportional gain coefficient of the PID controller, the problem of temperature adjustment lag in the insect protein preservation system is solved, the accuracy and response speed of temperature control are improved, and the Freshness preservation effect.
Patent Information
- Application Number
- CN202410256109.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-06
- Publication Date
- 2024-09-10
- Estimated Expiration
- 2044-03-06
AI Technical Summary
In the existing insect protein preservation system, due to factors such as the tightness of the storage warehouse, sensor accuracy, and control response, the temperature adjustment lags, the temperature error is amplified, and the effect of temperature adaptive regulation is reduced.
By obtaining the temperature data time series and distance between multiple locations in the insect protein storage warehouse and the air conditioning outlet, the asynchronous coefficient and conditional entropy are calculated, and the proportional gain coefficient of the PID controller is adjusted to improve the accuracy and response speed of temperature control.
It improves the consistency and rapid response capability of temperature control in the insect protein storage, reduces temperature errors, and enhances the temperature adaptive control effect of the fresh-keeping system.
Smart Images

Figure CN118011778B
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of temperature measurement, and in particular to a temperature self-adapting control method for an insect protein preservation system. Background Art
[0002] The insect protein preservation system is a technical system used to preserve and prolong the freshness of insect protein. Insect protein is considered to be a potential high-protein source, so maintaining its freshness is important for its application. The existing adaptive temperature control system is used to ensure that insect protein is kept within a suitable temperature range during production, storage, transportation and sales to prevent protein degradation and food safety issues.
[0003] Generally, insect protein that is preserved for a short period of time, such as in the retail and food service industries, is usually maintained at around 4 degrees Celsius. The adaptive temperature control system uses temperature sensors to monitor the temperature of the insect protein storage warehouse, and then automatically adjusts the operation of the temperature control system according to the set temperature range to ensure the stability of the warehouse temperature. However, factors such as the airtightness of the storage warehouse, sensor accuracy, and control response may cause temperature regulation to lag, thereby amplifying the temperature error problem and reducing the effect of the temperature adaptive regulation of the insect protein preservation system. Summary of the invention
[0004] The invention provides a temperature self-adapting control method for an insect protein preservation system to solve the existing problems.
[0005] The temperature adaptive control method of the insect protein preservation system of the present invention adopts the following technical scheme:
[0006] One embodiment of the present invention provides a temperature adaptive control method for an insect protein preservation system, the method comprising the following steps:
[0007] Obtaining a time series of temperature data corresponding to a plurality of different positions in an insect protein storage warehouse and an air outlet of an air conditioner, as well as the distance from each position to the air outlet of the air conditioner;
[0008] According to the difference between the temperature data time series sequences corresponding to any two positions and the distance from each position to the air outlet of the air conditioner, the asynchronous coefficient of the temperature data time series sequences corresponding to the any two positions is obtained; according to the asynchronous coefficient of the temperature data time series sequences corresponding to all positions, the synchronous compensation value is obtained;
[0009] According to the temperature data difference between the temperature data time series corresponding to the air outlet of the air conditioner and all positions, the conditional entropy is obtained; the default proportional gain coefficient of the PID controller is obtained, and the default proportional gain coefficient is adjusted according to the synchronous compensation value and the conditional entropy to obtain a new proportional gain coefficient;
[0010] The new proportional gain coefficient is input into the PID controller, and a control instruction is output; the control instruction is used to regulate the temperature in the insect protein storage.
[0011] Furthermore, the step of obtaining the asynchronous coefficient of the temperature data time series corresponding to any two positions according to the difference between the temperature data time series corresponding to any two positions and the distance from each position to the air outlet of the air conditioner includes the following specific steps:
[0012] Fourier transform is used to decompose the time series of temperature data corresponding to any position in the insect protein storage depot, and several sine waves of different frequencies and the phase value of each sine wave are obtained;
[0013] According to the magnitude of the frequency, all the sinusoidal waves decomposed from the temperature data time series corresponding to any two positions in the insect protein storage are divided into target sinusoidal waves and reference sinusoidal waves;
[0014] In the insect protein storage warehouse, the asynchronous coefficient of the temperature data time series sequence corresponding to any two positions is obtained according to the number of reference sine waves in all sine waves decomposed from the temperature data time series sequence corresponding to any two positions, the phase value of the target sine wave and the distance from each position to the air outlet of the air conditioner.
[0015] Furthermore, the method of dividing all the sinusoidal waves of the temperature data time series corresponding to any two positions in the insect protein storage into target sinusoidal waves and reference sinusoidal waves according to the magnitude of the frequency includes the following specific steps:
[0016] The time series of temperature data corresponding to any two positions in the insect protein storage are recorded as the first series and the second series respectively;
[0017] When any frequency corresponds to a sine wave decomposed by the first sequence and a sine wave decomposed by the second sequence at the same time, the sine wave decomposed by the first sequence and the sine wave decomposed by the second sequence are recorded as target sine waves;
[0018] When any frequency corresponds to only one sine wave decomposed by the first sequence or one sine wave decomposed by the second sequence, the one sine wave decomposed by the first sequence or one sine wave decomposed by the second sequence is recorded as a reference sine wave.
[0019] Furthermore, the number of reference sine waves in all sine waves decomposed according to the temperature data time series sequence corresponding to the arbitrary two positions, the phase value of the target sine wave, and the distance from each position to the air outlet of the air conditioner are used to obtain the asynchronous coefficient of the temperature data time series sequence corresponding to the arbitrary two positions, including the following specific steps:
[0020] Count the number of reference sine waves S in the sine wave decomposed from the temperature data time series corresponding to the ath position a , S a The product of the distance from the bth position to the air outlet of the air conditioner is recorded as the first product;
[0021] Count the number of reference sine waves S in the sine wave decomposed from the temperature data time series corresponding to the bth position b , S b The product of the distance from the ath position to the air outlet of the air conditioner is recorded as the second product;
[0022] Calculate the ratio of the first product to the second product, and record the absolute value of the difference between 1 and the ratio as the first difference;
[0023] Will minus The square of is recorded as the phase difference between the u-th target sine wave corresponding to the a-th position and the b-th position; where, is the phase value of the uth target sine wave in the sine wave decomposed from the temperature data time series sequence corresponding to the ath position, The phase value of the uth target sine wave in the sine wave decomposed from the temperature data time series sequence corresponding to the bth position;
[0024] The average of the phase differences of all target sine waves corresponding to the a-th position and the b-th position is recorded as the second difference;
[0025] The product of the first difference and the second difference is recorded as the asynchronous coefficient of the temperature data time series sequence corresponding to the a-th and b-th positions.
[0026] Furthermore, the step of obtaining the synchronization compensation value according to the asynchronous coefficient of the temperature data time series corresponding to all positions includes the following specific steps:
[0027] According to the asynchronous coefficients of the temperature data time series corresponding to all positions in the insect protein storage, an asynchronous matrix is constructed. Among them, γ 1,1 , γ 1,2 and γ 1,m are the non-synchronous coefficients of the temperature data time series corresponding to the first, second and mth positions, respectively, and γ 2,1 , γ 2,2 and γ 2,m are the non-synchronous coefficients of the temperature data time series corresponding to the second, first, second and mth positions, respectively, γ m,1 , γ m,2 and γ m,mare the nonsynchronous coefficients of the time series of temperature data corresponding to the mth position and the 1st, 2nd and mth positions, respectively, and m is the number of different positions in the insect protein storage depot;
[0028] The Schmidt orthogonalization method is used to perform operations to obtain the orthogonal matrix of the asynchronous matrix;
[0029] Use the principal component analysis method to calculate and obtain the variance value of the maximum principal component direction of the orthogonal matrix;
[0030] The variance value in the direction of the maximum principal component of the orthogonal matrix is recorded as the synchronization compensation value.
[0031] Furthermore, the conditional entropy is obtained according to the temperature data difference between the air outlet of the air conditioner and the temperature data time series corresponding to all positions, and the specific steps include the following:
[0032] In the time series of temperature data corresponding to any position in the insect protein storage warehouse and the air outlet of the air conditioner, a sequence consisting of the absolute values of the difference between two temperature data corresponding to all the same ordinal values is recorded as the error value sequence corresponding to the any position;
[0033] According to the size of the error value in the error value sequence corresponding to each position, a target error value sequence and a reference error value sequence are selected from the error value sequences corresponding to all positions;
[0034] According to the number of identical error values in the target error value sequence, the occurrence probability of each error value in the target error value sequence is obtained;
[0035] Obtaining the probability of occurrence of each error value in the reference error value sequence according to a method for obtaining the probability of occurrence of each error value in the target error value sequence;
[0036] According to the occurrence probability of each error value in the target error value sequence and the reference error value sequence, the conditional entropy is obtained.
[0037] Furthermore, the specific steps of selecting a target error value sequence and a reference error value sequence from the error value sequences corresponding to all positions according to the size of the error value in the error value sequence corresponding to each position include the following:
[0038] The mean of all error values in the error value sequence corresponding to each position is recorded as the average error value of each position;
[0039] Among all the positions in the insect protein storage, the error value sequence corresponding to the position with the maximum average error value is recorded as the target error value sequence, and the error value sequence corresponding to the position with the minimum average error value is recorded as the reference error value sequence.
[0040] Furthermore, the method of obtaining the occurrence probability of each error value in the target error value sequence according to the number of identical error values in the target error value sequence includes the following specific steps:
[0041] In the target error value sequence A, count the number of error values S that are the same as the tth error value in the target error value sequence A A,t , S A,t The ratio of the number of all error values in the target error value sequence A is recorded as the probability of occurrence of the tth error value in the target error value sequence A.
[0042] Furthermore, the conditional entropy is obtained according to the occurrence probability of each error value in the target error value sequence and the reference error value sequence, and the specific steps include the following:
[0043] According to the probability of occurrence of each error value in the target error value sequence A and the reference error value sequence B, the Bayesian theorem is used to calculate the probability of occurrence of the t-th error value in the target error value sequence A under the probability of occurrence of the t-th error value in the reference error value sequence B.
[0044] Will as well as The product of is recorded as the third product of the tth error value in the target error value sequence A and the reference error value sequence B; where, is the probability of occurrence of the tth error value in the target error value sequence A, is the probability of occurrence of the t-th error value in the reference error value sequence B, ln() is a logarithmic function with a natural constant as the base;
[0045] The sum of the third products of all error values in the target error value sequence A and the reference error value sequence B is calculated, and the negative value of the sum is recorded as the conditional entropy.
[0046] Furthermore, the step of obtaining a default proportional gain coefficient of the PID controller and adjusting the default proportional gain coefficient according to the synchronous compensation value and the conditional entropy to obtain a new proportional gain coefficient includes the following specific steps:
[0047] The default proportional gain coefficient of the PID controller is obtained by using the tuning method;
[0048] A normalized value of the product of the synchronization compensation value and the conditional entropy is calculated, and the product of the normalized value and the default proportional gain coefficient is recorded as a new proportional gain coefficient.
[0049] The beneficial effects of the technical solution of the present invention are:
[0050] In the embodiment of the present invention, the temperature data time series corresponding to multiple different positions in the insect protein storage warehouse and an air-conditioning outlet and the distance from each position to the air-conditioning outlet are obtained, thereby obtaining the asynchronous coefficient of the temperature data time series corresponding to any two positions, which is used to construct an asynchronous matrix, thereby obtaining a synchronous compensation value, and the synchronous compensation value is used for the subsequent adjustment of the proportional gain coefficient, which can ensure that the temperature adjustment at each position remains consistent, thereby improving the effect of temperature adaptive regulation. Then, the conditional entropy is obtained, which reflects the maximum transmission loss of temperature transfer during the temperature adjustment process, and is used to adjust the proportional gain coefficient, thereby reducing the adjustment lag problem existing in the temperature regulation process, and further improving the effect of temperature adaptive regulation. According to the synchronous compensation value and the conditional entropy, the default proportional gain coefficient of the PID controller is adjusted to obtain a new proportional gain coefficient, and the new proportional gain coefficient is input into the PID controller, and a control instruction is output, and the temperature in the insect protein storage warehouse is regulated using the control instruction. So far, the present invention improves the accuracy of the control instruction output by the PID controller through the adaptive proportional gain coefficient, so that when all positions in the storage room are disturbed and a temperature error occurs, it can return to a stable state more quickly, thereby improving the effect of temperature adaptive regulation of the insect protein preservation system. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0052] Figure 1 This is a flow chart of the steps of a temperature adaptive control method of an insect protein preservation system of the present invention;
[0053] Figure 2 The figure is a flow chart of obtaining control instructions in an embodiment of the present invention. DETAILED DESCRIPTION
[0054] In order to further explain the technical means and effects adopted by the present invention to achieve the predetermined invention purpose, the temperature adaptive control method of an insect protein preservation system proposed by the present invention, its specific implementation method, structure, characteristics and effects are described in detail as follows in combination with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.
[0055] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.
[0056] The specific scheme of the temperature adaptive control method of the insect protein preservation system provided by the present invention is described in detail below with reference to the accompanying drawings.
[0057] See also Figure 1 , which shows a flow chart of the steps of a temperature adaptive control method of an insect protein preservation system provided by an embodiment of the present invention, the method comprising the following steps:
[0058] Step S001: Obtain a time series sequence of temperature data corresponding to a plurality of different positions in an insect protein storage warehouse and an air-conditioning outlet, as well as a distance from each position to the air-conditioning outlet.
[0059] Taking any insect protein storage warehouse as an example, temperature sensors are installed at multiple different positions in the insect protein storage warehouse, and the temperature sensors are used to obtain temperature change data at various positions in the insect protein storage warehouse over a period of time, as well as real-time temperature data of the air outlet of the air conditioner in the insect protein storage warehouse.
[0060] It should be noted that: in this embodiment, the temperature control system uses air conditioning for cooling and heating, obtains the structural diagram of the insect protein storage warehouse and the position of the air outlet of the temperature control system, and installs a temperature sensor in the four directions of the southeast, northwest, and northeast of the insect protein storage warehouse respectively. This is used as an example for description. In other implementations, it can be set to other positions, which is not limited in this embodiment.
[0061] Thus, a time series of temperature data corresponding to a plurality of different positions in the insect protein storage warehouse and an air-conditioning outlet is obtained, as well as the distance from each position in the insect protein storage warehouse to the air-conditioning outlet.
[0062] It should be noted that if there are multiple air-conditioning outlets in the insect protein storage warehouse, the distance from each position to the air-conditioning outlet is the distance from each position to the nearest air-conditioning outlet. The temperature data time series sequence corresponding to the air-conditioning outlet is the temperature data time series sequence composed of the average temperature of all air-conditioning outlets at the same time. This is because the temperature in the storage warehouse should be kept constant, so all air-conditioning outlets should keep the temperature adjustment of the entire storage warehouse consistent.
[0063] Step S002: According to the difference between the temperature data time series sequences corresponding to any two positions and the distance from each position to the air outlet of the air conditioner, the asynchronous coefficient of the temperature data time series sequences corresponding to any two positions is obtained; according to the asynchronous coefficient of the temperature data time series sequences corresponding to all positions, the synchronization compensation value is obtained.
[0064] The temperature control system generally uses a PID controller to feedback and adjust the temperature of the storage warehouse, and adjusts the output based on the current state and error of the system to make the system stable and meet performance requirements. However, temperature control is not limited to a single location. In the storage room space, there is a loss problem in the transmission of the temperature control amount, and when there is no strict requirement for sealing, there is still a certain disturbance error in the storage room space, which causes the temperature control effect to have a lag at different locations, and the lag adjustment may cause the temperature to fluctuate greatly instead of maintaining a stable level. This fluctuation may cause the indoor temperature to rise or fall rapidly in a short period of time, which is extremely unfavorable for the preservation effect of insect protein.
[0065] Fourier transform is used to decompose the four ambient temperature change data to obtain all sine waves of each ambient temperature change data and the frequency and phase information of each sine wave of each ambient temperature change data, and the asynchronous coefficient between every two ambient temperature change data is calculated.
[0066] Specifically, Fourier transform is used to decompose the temperature data time series corresponding to any position in the insect protein storage depot to obtain a number of sine waves of different frequencies and the phase value of each sine wave.
[0067] According to the above method, a plurality of sine waves of different frequencies decomposed from the temperature data time series sequence corresponding to each position and the phase value of each sine wave are obtained.
[0068] It should be noted that Fourier transform is a well-known technology, and the specific method is not introduced here. Fourier transform can decompose a time domain signal into a spectrum composed of sine and cosine waves of different frequencies. According to the spectrum information, the frequency and phase value of each sine wave can be found. This is a well-known technology.
[0069] All the sine waves with the same frequency of the temperature change data of any two temperature sensors and the remaining sine waves with different frequencies of each ambient temperature change data are obtained.
[0070] Therefore, the temperature data time series corresponding to any two positions in the insect protein storage are recorded as the first sequence and the second sequence respectively.
[0071] When any frequency corresponds to a sine wave decomposed by the first sequence and a sine wave decomposed by the second sequence at the same time, the sine wave decomposed by the first sequence and the sine wave decomposed by the second sequence are recorded as target sine waves.
[0072] When any frequency corresponds to only one sine wave decomposed by the first sequence or one sine wave decomposed by the second sequence, the one sine wave decomposed by the first sequence or one sine wave decomposed by the second sequence is recorded as a reference sine wave.
[0073] Thus, all the sinusoidal waves decomposed from the first sequence and the second sequence are divided into target sinusoidal waves and reference sinusoidal waves respectively.
[0074] According to the above method, the target sine wave and the reference sine wave are obtained from all the sine waves decomposed from the time series of the temperature data corresponding to any two positions in the insect protein storage.
[0075] It is known that the sine wave of the temperature change data of each temperature sensor has a phase value, and the sine waves with the same frequency between two temperature sensors may also have different phases.
[0076] Take any two positions in the insect protein storage as an example, the two positions are the ath and bth positions respectively. According to the above operation, the target sine wave and the reference sine wave in all the sine waves decomposed by the temperature data time series sequence corresponding to the ath and bth positions can be known. It can be known that the calculation formula for the non-synchronous coefficient of the temperature data time series sequence corresponding to the ath and bth positions is:
[0077]
[0078] where γ a,b is the asynchronous coefficient of the temperature data time series corresponding to the a-th and b-th positions, D b is the distance from the bth position to the air outlet of the air conditioner, D a is the distance from the ath position to the air outlet of the air conditioner, S a is the number of reference sine waves in the sine wave decomposed from the temperature data time series corresponding to the ath position, S b is the number of reference sine waves in the sine wave decomposed from the temperature data timing sequence corresponding to the b-th position, N is the number of target sine waves in the sine wave decomposed from the temperature data timing sequence corresponding to the a-th position, and N is also the number of target sine waves in the sine wave decomposed from the temperature data timing sequence corresponding to the b-th position. is the phase value of the uth target sine wave in the sine wave decomposed from the temperature data time series sequence corresponding to the ath position, is the phase value of the u-th target sine wave in the sine wave decomposed from the temperature data time series sequence corresponding to the b-th position, and || is the absolute value function.
[0079] It should be noted that: in this embodiment, the order of all the sinusoidal waves decomposed into the temperature data time series is arranged from large to small according to the frequency of the sinusoidal waves. The closer it is to 1, the closer the distances from the a-th and b-th positions to the air outlet of the air conditioner are and the number of interfering sine waves is similar. Interfering sine waves are reference sine waves with no same frequency. The higher the synchronization weight of the temperature data time series corresponding to the a-th and b-th positions, The larger the value, the more out of sync. b ×S a is the first product, D a ×S b is the second product, The first difference. It represents the phase difference between the uth target sine wave corresponding to the ath position and the bth position, and reflects the phase difference between the sine waves of the same frequency in the sine waves decomposed from the temperature data timing sequence corresponding to the ath and bth positions. The second difference reflects the mean square error of the phase difference of all target sine waves of the same frequency in the sine waves decomposed from the temperature data timing sequence corresponding to the a-th and b-th positions. The larger the mean square error, the worse the synchronization between the temperature data timing sequence corresponding to the a-th and b-th positions. The larger the value is, the greater the asynchronous coefficient of the temperature data time series corresponding to the a-th and b-th positions is.
[0080] According to the above method, the asynchronous coefficient of the temperature data time series corresponding to any two positions in the insect protein storage warehouse is obtained.
[0081] Therefore, according to the asynchronous coefficients of the temperature data time series corresponding to all positions in the insect protein storage, an asynchronous matrix P is constructed. The asynchronous matrix P is as follows:
[0082]
[0083] where γ 1,1 , γ 1,2 and γ 1,m are the non-synchronous coefficients of the temperature data time series corresponding to the first, second and mth positions, respectively, and γ 2,1 , γ 2,2 and γ 2,m are the non-synchronous coefficients of the temperature data time series corresponding to the second, first, second and mth positions, respectively, γ m,1 , γ m,2 and γ m,m are the asynchronous coefficients of the temperature data time series corresponding to the mth and 1st, 2nd and mth positions respectively, and m is the number of different positions in the insect protein storage.
[0084] What needs to be explained is: γ 1,1 , γ 2,2 and γ m,m It is the asynchronous coefficient of the temperature data time series corresponding to the same position. The temperature data time series corresponding to the same position are exactly the same. According to the calculation method of the asynchronous coefficient, the result obtained is 0.
[0085] The Schmidt orthogonalization method is used to obtain the orthogonal matrix Q of the asynchronous matrix P. The Schmidt orthogonalization method is a well-known technique, and the specific method is not introduced here. The method can convert the column vectors of the original matrix into a set of orthogonal column vectors, thereby constructing an orthogonal matrix.
[0086] It should be noted that the orthogonal matrix represents a group of matrices that are orthogonally unrelated to the asynchronous matrix. The purpose of calculating the orthogonal matrix is to map the data characteristics of the temperature change data into the compensation requirements of the temperature control, and to use the unrelated orthogonal matrix to eliminate the nonlinear relationship between the temperature change data and the control logic of the PID controller. The orthogonal irrelevance of the asynchronous matrix represents the opposing synchronous compensation matrix. Therefore, the compensation amount used to compensate for the asynchronousness between sensors can be obtained from the orthogonal matrix of the asynchronous matrix.
[0087] The principal component analysis method is used to obtain the variance value of the orthogonal matrix Q in the direction of the maximum principal component, and the variance value of the orthogonal matrix Q in the direction of the maximum principal component is recorded as the synchronization compensation value E.
[0088] It should be noted that the principal component analysis method is a well-known technology, and the specific method will not be introduced here. The principal component analysis method can obtain the eigenvalue of the matrix and the eigenvector corresponding to the eigenvalue. The eigenvector is the direction of the principal component, and the eigenvalue represents the variance in this direction. Therefore, the maximum principal component direction is the maximum variance direction of the orthogonal matrix, which represents the direction with the maximum temperature control synchronization compensation between various locations in the storage. The maximum principal component direction of the orthogonal matrix has the maximum compensation demand between the ambient temperature change data, so the variance value obtained in this direction is obtained as the synchronization compensation value of the temperature control system.
[0089] Step S003: Obtain conditional entropy based on the temperature data difference between the air-conditioning outlet and the temperature data time series corresponding to all positions; obtain the default proportional gain coefficient of the PID controller, adjust the default proportional gain coefficient according to the synchronous compensation value and the conditional entropy, and obtain a new proportional gain coefficient.
[0090] By obtaining the error values at all times between the temperature value of each temperature sensor and the temperature value of the air outlet of the temperature control system, several groups of error sets can be obtained. The error sets are the transmission errors of the temperature adjustment amount of the temperature control system to each position. If the positions in different directions are regarded as independent adjustment targets, the greater the transmission loss, the faster the response is required to make the error return to a stable state quickly.
[0091] Therefore, in the time series of temperature data corresponding to each position in the insect protein storage warehouse and the air outlet of the air conditioner, the sequence composed of the absolute values of the difference between the two temperature data corresponding to all the same ordinal values is recorded as the error value sequence corresponding to each position.
[0092] The mean of all error values in the error value sequence corresponding to each position is recorded as the average error value of each position.
[0093] Among all the positions in the insect protein storage, the error value sequence corresponding to the position with the maximum average error value is recorded as the target error value sequence A, and the error value sequence corresponding to the position with the minimum average error value is recorded as the reference error value sequence B.
[0094] It should be noted that: if there are multiple maximum average error values or minimum average error values, the error value sequence corresponding to the position of the maximum average error value or the minimum average error value is arbitrarily selected for marking, that is, A and B are made unique.
[0095] Taking the tth error value in the target error value sequence A as an example, count the number of error values S in the target error value sequence A that are the same as the tth error value A,t , S A,t The ratio of the number of all error values in the target error value sequence A is recorded as the probability of occurrence of the tth error value in the target error value sequence A.
[0096] According to the above method, the occurrence probability of each error value in the target error value sequence A is obtained. According to the method for obtaining the occurrence probability of each error value in the target error value sequence A, the occurrence probability of each error value in the reference error value sequence B is obtained.
[0097] Get all error groups at the same time in A and B. One error group has two error values at the same time, and the two error values have a probability of occurrence in their respective sequences. The adjustment error must be transferred from the smaller error to the larger error. This real-time example uses the idea of reverse reasoning. Assuming that there is no transfer error between the various positions in the storage room, then according to the probability of occurrence of each error value in the target error value sequence A and the reference error value sequence B, the Bayesian theorem can be used to calculate the probability of occurrence of the t-th error value in the target error value sequence A under the probability of occurrence of the t-th error value in the reference error value sequence B. Among them, Bayes' theorem is a well-known technology, and the specific method will not be introduced here. Bayes' theorem is an important theorem in probability theory, which is used to calculate the probability of updating an event when some prior information is known.
[0098] Therefore, according to the occurrence probability of each error value in the target error value sequence A and the reference error value sequence B, the calculation formula of the conditional entropy can be obtained as follows:
[0099]
[0100] Where W is the conditional entropy, is the probability of occurrence of the t-th error value in the target error value sequence A under the probability of occurrence of the t-th error value in the reference error value sequence B, is the probability of occurrence of the tth error value in the target error value sequence A, is the probability of occurrence of the tth error value in the reference error value sequence B, M is the number of all error values in the target error value sequence A, M is also the number of all error values in the reference error value sequence B, and ln() is a logarithmic function with a natural constant as the base.
[0101] What needs to be explained is: is the conditional entropy, which reflects how much transmission loss is required to make all the error values in A appear when the error value in B appears. The larger the conditional entropy, the greater the transmission loss required to transfer the temperature from the sensor position with the smallest error to the sensor position with the largest error. This transmission loss is the maximum transmission loss in the storage room, that is, the conditional entropy W also represents the maximum transmission loss in the storage room. Among them, It is the third product of the tth error value in the target error value sequence A and the reference error value sequence B.
[0102] The proportional gain coefficient of the PID controller can control the control response speed of the temperature control system. The response speed of the temperature control system can be adjusted according to the synchronous compensation value E and the transmission loss, that is, the proportional gain coefficient of the PID controller can be adjusted.
[0103] The default proportional gain coefficient of the PID controller is obtained by tuning. The tuning method is a method for obtaining the parameters of the PID controller. This is a well-known technology and the specific method will not be introduced here. The PID controller is a very common and well-known type of controller used to control industrial processes, mechanical systems, and various other systems. PID stands for Proportional, Integral, and Derivative, which represent the three main parts of the controller.
[0104] It can be seen that the calculation formula of the new proportional gain coefficient is:
[0105] K ′ =sigmoid(E×W)×K
[0106] Where K ′ is the new proportional gain coefficient, E is the synchronization compensation value, W is the conditional entropy, K is the default proportional gain coefficient, sigmoid() is the sigmoid function, and the sigmoid function can use nonlinear transformation to constrain the problem of excessive regulation demand. Therefore, the sigmoid function is used to normalize the product of the synchronization compensation value and the conditional entropy to between 0 and 1, and the regulation coefficient between 0 and 1 is obtained, which is multiplied by the default proportional gain coefficient to obtain the new proportional gain coefficient.
[0107] Step S004: input the new proportional gain coefficient into the PID controller and output a control instruction; use the control instruction to regulate the temperature in the insect protein storage tank.
[0108] The new proportional gain coefficient can effectively compensate for the loss of temperature control quantity in the storage room, so that all positions in the storage room can return to a stable state more quickly when temperature errors occur due to disturbances.
[0109] The new proportional gain coefficient is input into the PID controller, and a control instruction is output. This is a well-known technology, and the specific method is not introduced here. The control instruction is used to control the temperature in the insect protein storage tank. The process of obtaining the control instruction is as follows: Figure 2 shown.
[0110] It should be noted that the control instruction is the temperature value that the insect protein storage tank is expected to reach at present, so the air conditioner is used for cooling or heating to make the temperature of the insect protein storage tank at present the expected temperature value. In this way, the temperature of the insect protein storage room is automatically adjusted to ensure the stability of the insect protein preservation system.
[0111] So far, the present invention is completed.
[0112] In summary, in an embodiment of the present invention, a time series of temperature data corresponding to a plurality of different positions in an insect protein storage warehouse and an air-conditioning outlet and the distance from each position to the air-conditioning outlet are obtained, thereby obtaining the asynchronous coefficient of the time series of temperature data corresponding to any two positions, and using it to construct an asynchronous matrix, thereby obtaining a synchronous compensation value, and then obtaining the conditional entropy, and adjusting the default proportional gain coefficient of the PID controller according to the synchronous compensation value and the conditional entropy to obtain a new proportional gain coefficient, and inputting the new proportional gain coefficient into the PID controller, outputting a control instruction, and using the control instruction to regulate the temperature in the insect protein storage warehouse. The present invention improves the accuracy of the control instruction output by the PID controller through an adaptive proportional gain coefficient, thereby improving the effect of temperature adaptive regulation of the insect protein preservation system.
[0113] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A temperature adaptive control method for an insect protein preservation system, characterized in that: The method comprises the following steps: Obtaining a time series of temperature data corresponding to a plurality of different positions in an insect protein storage warehouse and an air outlet of an air conditioner, as well as the distance from each position to the air outlet of the air conditioner; According to the difference between the temperature data time series sequences corresponding to any two positions and the distance from each position to the air outlet of the air conditioner, the asynchronous coefficient of the temperature data time series sequences corresponding to the any two positions is obtained; according to the asynchronous coefficient of the temperature data time series sequences corresponding to all positions, the synchronous compensation value is obtained; According to the temperature data difference between the temperature data time series corresponding to the air outlet of the air conditioner and all positions, the conditional entropy is obtained; the default proportional gain coefficient of the PID controller is obtained, and the default proportional gain coefficient is adjusted according to the synchronous compensation value and the conditional entropy to obtain a new proportional gain coefficient; The new proportional gain coefficient is input into the PID controller to output a control instruction; the temperature in the insect protein storage tank is regulated using the control instruction; The step of obtaining the synchronization compensation value according to the asynchronous coefficient of the temperature data time series corresponding to all positions includes the following specific steps: According to the asynchronous coefficients of the temperature data time series corresponding to all positions in the insect protein storage, an asynchronous matrix is constructed. Among them, γ 1,1 , γ 1,2 and γ 1,m are the non-synchronous coefficients of the temperature data time series corresponding to the first, second and mth positions, respectively, and γ 2,1 , γ 2,2 and γ 2,m are the non-synchronous coefficients of the temperature data time series corresponding to the second, first, second and mth positions, respectively, γ m,1 , γ m,2 and γ m,m are the nonsynchronous coefficients of the time series of temperature data corresponding to the mth position and the 1st, 2nd and mth positions, respectively, and m is the number of different positions in the insect protein storage depot; The Schmidt orthogonalization method is used to perform operations to obtain the orthogonal matrix of the asynchronous matrix; Use the principal component analysis method to calculate and obtain the variance value of the maximum principal component direction of the orthogonal matrix; The variance value in the direction of the maximum principal component of the orthogonal matrix is recorded as the synchronization compensation value; The step of obtaining a default proportional gain coefficient of the PID controller and adjusting the default proportional gain coefficient according to the synchronous compensation value and the conditional entropy to obtain a new proportional gain coefficient includes the following specific steps: The default proportional gain coefficient of the PID controller is obtained by using the tuning method; A normalized value of the product of the synchronization compensation value and the conditional entropy is calculated, and the product of the normalized value and the default proportional gain coefficient is recorded as a new proportional gain coefficient.
2. The temperature adaptive control method of the insect protein preservation system according to claim 1, characterized in that: The step of obtaining the asynchronous coefficient of the temperature data time series corresponding to any two positions according to the difference between the temperature data time series corresponding to any two positions and the distance from each position to the air outlet of the air conditioner comprises the following specific steps: Fourier transform is used to decompose the time series of temperature data corresponding to any position in the insect protein storage depot, and several sine waves of different frequencies and the phase value of each sine wave are obtained; According to the magnitude of the frequency, all the sinusoidal waves decomposed from the temperature data time series corresponding to any two positions in the insect protein storage are divided into target sinusoidal waves and reference sinusoidal waves; In the insect protein storage warehouse, the asynchronous coefficient of the temperature data time series sequence corresponding to any two positions is obtained according to the number of reference sine waves in all sine waves decomposed from the temperature data time series sequence corresponding to any two positions, the phase value of the target sine wave and the distance from each position to the air outlet of the air conditioner.
3. The temperature adaptive control method of the insect protein preservation system according to claim 2, characterized in that: The method of dividing all the sinusoidal waves of the temperature data time series corresponding to any two positions in the insect protein storage into target sinusoidal waves and reference sinusoidal waves according to the magnitude of the frequency includes the following specific steps: The time series of temperature data corresponding to any two positions in the insect protein storage are recorded as the first series and the second series respectively; When any frequency corresponds to a sine wave decomposed by the first sequence and a sine wave decomposed by the second sequence at the same time, the sine wave decomposed by the first sequence and the sine wave decomposed by the second sequence are recorded as target sine waves; When any frequency corresponds to only one sine wave decomposed by the first sequence or one sine wave decomposed by the second sequence, the one sine wave decomposed by the first sequence or one sine wave decomposed by the second sequence is recorded as a reference sine wave.
4. The temperature adaptive control method of the insect protein preservation system according to claim 2, characterized in that: The step of obtaining the asynchronous coefficient of the temperature data time series sequence corresponding to the arbitrary two positions according to the number of reference sine waves in all sine waves decomposed according to the temperature data time series sequence corresponding to the arbitrary two positions, the phase value of the target sine wave, and the distance from each position to the air outlet of the air conditioner includes the following specific steps: Count the number of reference sine waves S in the sine wave decomposed from the temperature data time series corresponding to the ath position a , S a The product of the distance from the bth position to the air outlet of the air conditioner is recorded as the first product; Count the number of reference sine waves S in the sine wave decomposed from the temperature data time series corresponding to the bth position b , S b The product of the distance from the ath position to the air outlet of the air conditioner is recorded as the second product; Calculate the ratio of the first product to the second product, and record the absolute value of the difference between 1 and the ratio as the first difference; Will minus The square of is recorded as the phase difference between the u-th target sine wave corresponding to the a-th position and the b-th position; where, is the phase value of the uth target sine wave in the sine wave decomposed from the temperature data time series sequence corresponding to the ath position, The phase value of the uth target sine wave in the sine wave decomposed from the temperature data time series sequence corresponding to the bth position; The average of the phase differences of all target sine waves corresponding to the a-th position and the b-th position is recorded as the second difference; The product of the first difference and the second difference is recorded as the asynchronous coefficient of the temperature data time series sequence corresponding to the a-th and b-th positions.
5. The temperature adaptive control method of the insect protein preservation system according to claim 1, characterized in that: The conditional entropy is obtained according to the temperature data difference between the air outlet of the air conditioner and the temperature data time series corresponding to all positions, and the specific steps include the following: In the time series of temperature data corresponding to any position in the insect protein storage warehouse and the air outlet of the air conditioner, a sequence consisting of the absolute values of the difference between two temperature data corresponding to all the same ordinal values is recorded as the error value sequence corresponding to the any position; According to the size of the error value in the error value sequence corresponding to each position, a target error value sequence and a reference error value sequence are selected from the error value sequences corresponding to all positions; According to the number of identical error values in the target error value sequence, the occurrence probability of each error value in the target error value sequence is obtained; Obtaining the probability of occurrence of each error value in the reference error value sequence according to a method for obtaining the probability of occurrence of each error value in the target error value sequence; According to the occurrence probability of each error value in the target error value sequence and the reference error value sequence, the conditional entropy is obtained.
6. The temperature adaptive control method of the insect protein preservation system according to claim 5, characterized in that: The specific steps of selecting a target error value sequence and a reference error value sequence from the error value sequences corresponding to all positions according to the size of the error values in the error value sequence corresponding to each position are as follows: The mean of all error values in the error value sequence corresponding to each position is recorded as the average error value of each position; Among all the positions in the insect protein storage, the error value sequence corresponding to the position with the maximum average error value is recorded as the target error value sequence, and the error value sequence corresponding to the position with the minimum average error value is recorded as the reference error value sequence.
7. The temperature adaptive control method of the insect protein preservation system according to claim 5, characterized in that: The specific steps of obtaining the occurrence probability of each error value in the target error value sequence according to the number of identical error values in the target error value sequence are as follows: In the target error value sequence A, count the number of error values S that are the same as the tth error value in the target error value sequence A A,t , S A,t The ratio of the number of all error values in the target error value sequence A is recorded as the probability of occurrence of the tth error value in the target error value sequence A.
8. The temperature adaptive control method of the insect protein preservation system according to claim 5, characterized in that: The specific steps of obtaining the conditional entropy according to the occurrence probability of each error value in the target error value sequence and the reference error value sequence are as follows: According to the probability of occurrence of each error value in the target error value sequence A and the reference error value sequence B, the Bayesian theorem is used to calculate the probability of occurrence of the t-th error value in the target error value sequence A under the probability of occurrence of the t-th error value in the reference error value sequence B. Will as well as The product of is recorded as the third product of the tth error value in the target error value sequence A and the reference error value sequence B; where, is the probability of occurrence of the tth error value in the target error value sequence A, is the probability of occurrence of the t-th error value in the reference error value sequence B, ln() is a logarithmic function with a natural constant as the base; The sum of the third products of all error values in the target error value sequence A and the reference error value sequence B is calculated, and the negative value of the sum is recorded as the conditional entropy.
