Research on Real-Time Robust Optimization of Perishable Supply-Chain Systems Based on Digital Twins

Aiming at the real-time robust optimization problem of perishable supply-chain systems in complex environments, a real-time robust optimization scheme based on supply-chain digital twins is proposed. Firstly, based on the quantitative logical relationship between production and sales of single-chain series supply-chain system products, the state space equation of the supply-chain system with logical characteristics, structural characteristics, and quantitative characteristics was constructed, and twin data were introduced to construct the digital twins of supply chains based on the state-space equation. Secondly, the perishable supply-chain system in complex environments was regarded as an uncertain closed-loop system from the perspective of the state space equation, and then a robust H∞ controller design strategy was proposed, and the supply-chain digital twins was used to update and correct the relevant parameters of the supply-chain system in real-time, to implement the real-time robust optimization based on the supply-chain digital twins. Finally, the simulation experiment was carried out with a cake supply-chain production as an example. The experimental results show that the real-time updating of relevant parameters through the digital twins can help enterprise managers to formulate reasonable management plans, effectively avoid the shortage problem of enterprises in the cake supply-chain system, and reduce the maximum inventory movement standard deviation of each link by 12.65%, 6.50%, and 14.87%, and the maximum production movement standard deviation by 70.21%, 56.84%, and 45.19%.


Introduction
The supply-chain system is a cascade system composed of multiple links, and its upstream and downstream enterprises are committed to selling products to consumers at the lowest operating costs and the fastest speed. With the trend of globalization, more and more enterprises and researchers pay attention to the management and optimization of the supply-chain system, especially from the perspective of production-storage-sales [1][2][3][4][5], the supply-chain system to optimize management. In the modern supply-chain system, the operating environment of the supply-chain system is complex, and the challenges it faces include many aspects such as natural disasters [6,7], public health [8][9][10], and wars [11][12][13].These will lead to changes in the market environments, causing market demand fluctuations.Especially in recent years, the emergence of crises such as coronavirus disease 2019 and the Russian-Ukrainian war put the world supply-chain system in a state of extreme complexity, high uncertainty, and disruption. Companies may suffer significant financial losses if they are unable to quickly and effectively respond to changes in the market environments and adapt to the complex supply chain system environments.For example, the COVID-19 outbreak at the start of 2020 made many fresh products unmarketable, resulting in a wide spectrum of product damage and expiry and a significant waste of resources and economic damages. This shows that especially for the supply-chain system of perishable products, if the product is unsellable or transportation is interrupted due to changes in the complex market environments, it will cause product waste and cause huge economic losses. This also makes the managers aware that traditional supply-chain management techniques are no longer adequate to manage the complex market environments. Instead, effective management techniques are urgently required to assist enterprises in managing the complex market environments and developing a reasonable production-storage-sales strategy to increase the robustness and anti-disturbance capability of the supply-chain system.
The control of the supply-chain system is a management method that combines the logical relationship of the number of purchases, sales, and inventory of each link in the complete supply-chain system, combines the structural characteristics, constructs the dynamic model of the supply-chain system in the case of considering the cycle, and reasonably designs the control method based on the dynamic model, to achieve the ideal state of production, demand, shipment, inventory, and other parameters. At the same time, due to the suddenness and unpredictability of the sudden state, it is also necessary for the real-time optimization management of the supply-chain system. According to the realtime operation of the supply-chain system, a reasonable production-storage-sales scheme is formulated, and the digital twin technology can well meet the demand of real-time optimization. The digital twin technology is used to build digital twins of the supply chain, and then the digital twins is used to realize the real-time connection between the physical entities of the supply chain and the virtual simulation environment, so as to realize the real-time robust optimization of the supply-chain system. The existing research closely related to this paper mainly focuses on three aspects: the application research of automation control theory in supply-chain system, the application research of robust H ∞ state feedback control, and the application of digital twin technology in supply-chain management.
With the development of the automotive control theory, more and more scholars are also focusing on the cross-field application of automation technology, including the application in the field of supply-chain management. At present, the research on the application of automation technology in the field of supply chain management mainly focuses on two aspects.

•
Application of frontier automated intelligent algorithms to manage and optimize the supply-chain system [14][15][16][17]. The research in this aspect is to create an objective optimization function based on the supply-chain system, solve it using an intelligent algorithm, and provide a management and optimization strategy for the supply-chain system. The advantage of this research is that it can help the supply-chain system to achieve multi-objective optimization, but the disadvantage is that the optimal solution is often a range solution, which cannot give business managers clear and accurate production, purchase, and shipment strategies. At the same time, it requires relatively high model accuracy, which makes it necessary to set a lot of assumptions in the model construction process. • Application of automation control theory for supply-chain system management and optimization [18][19][20][21]. This research is based on the existing supply-chain production and marketing model, taking inventory and operation costs as the controlled objects and constructing a supply-chain system model with reasonable assumptions, and then applying control theory ideas to optimize the management of the supply-chain system based on the model. Compared with the intelligent algorithmic solutions, the control theoretic can help managers to develop clear and accurate production-storageshipment strategies that do not require high model accuracy.
Due to the unique advantages of control philosophy in supply-chain management, more and more scholars and business managers have conducted related research. Simon [22], a an American scholar, was the first to apply the idea of control systems to inventory management. He viewed the inventory optimization problem as a control system and applied the Laplace transform to convert the differential equation into the transfer function of the control system. Vladimir et al. [23] considered the optimization problem of a failure-prone manufacturing system with uncertainty in demand and inventory levels, and designed a controller based on adaptive control for the online estimation and optimal control of a supply-chain inventory system in the presence of unknown demand and inaccurate inventory. Bartoszewicz et al. [24] used sliding mode control to optimize the management of manufacturers' inventories with storage constraints for manufacturers' inventory management under different demands. Achamrah et al. [25] used the genetic algorithm and deep reinforcement learning to solve the inventory path problem with transit and substitution under dynamic and stochastic demand. Such literature addresses the problem of demand uncertainty in complex environments from a control perspective, but ignores the fact that complex environments can cause not only changes in demand but also changes in the structural parameters of the supply-chain system, which is not considered in this literature. This is one of the motivations for this paper. Of course, some scholars have also focused on the study of supply-chain inventory management with parameter uncertainty. Chen et al. [26] studied the optimization of supply-chain product renewal based on a multi-period model and fuzzy control in an uncertain environment, addressing the problem of how to satisfy uncertain market demand in the case of manufacturer product improvement. David et al. [27] studied the design of a multi-configuration logistics network with capacity constraints under perturbations and parameter uncertainties using a pharmaceutical supply chain as an example of a retailer in direct contact with consumers. However, such literature does not take into account the problem of product self-loss and production conformity in the case of multiple cycles and does not study perishable supplychain systems that are subject to environmental impacts, which is another motivation for this paper.
H ∞ robust control has a better control impact for uncertain systems in complicated contexts when compared to other automated control approaches. The main purpose of H ∞ robust control is to address the issue of uncertainty disturbance of the controlled object. By designing H ∞ robust control, it is possible to improve the stability and quality robustness of the system, which makes H ∞ robust control a widely used model for solving the problems of an unknown control system. Indri et al. [28] applied of robust H ∞ control to the industrial robotic arm to solve the tracking problem of the robotic arm under the action of unknown disturbances. Xu et al. [29] studied the quadrotor UAV flight problem inside a culvert, and used robust H ∞ control based on the state observer for dynamic planning of UAV flight state inside a culvert. Wang et al. [30] used the H ∞ robust control strategy to solve the wind turbine hydraulic pitch system control problem, which greatly reduced the system error of wind turbines. In addition to the above industrial applications, H ∞ robust control has also been applied in the field of supply-chain inventory management, but the current research in the field of supply-chain inventory management mainly focuses on solving the bullwhip effects problem [31][32][33], and there is no research related to the application of perishable supply-chain systems in complex environments. This is the third research motivation for this paper. Although H ∞ robust control can successfully solve the uncertain system control problem under unknown environments, the fluctuation range of unknown parameters is frequently determined by using data statistics or expert experience, which cannot be dynamically changed in real-time with time and environmental changes, while the digital twin model can obtain the relevant parameter data in real-time based on physical entities, and then dynamically update the simulation.
The concept of the digital twin was first proposed by professor Grieves [34] in 2003 at the university of Michigan in the United States, and it was first used in the aerospace and defense sectors, considerably enhancing their growth and production. Since then, several industries have adopted and developed digital twin technology. Initially, the digital twin model followed the three-dimensional model proposed by professor Grieves [34] for model building, until 2019, when Tao Fei et al. [35] proposed a five-dimensional digital twin model, which introduced data and services into the model and greatly enriched the model structure and extended the application area of digital twin technology. Through the continuous discussion of the concept and definition of the digital twin, it is clear that the objects it applies to different fields are different, among which digital twins refers to whole physical entities and their digital drives [36]. At present, the applications of digital twin technology in supply-chain systems are mostly focused on product design [37], shop floor monitoring and forecasting [38], and product line management [39]. However, the applicability to multi-cascade supply-chain systems has not been thoroughly studied, which is the final research objective for this article. Considering the current technology, there are two main problems: the construction of virtual entities is relatively complex [40] and data collection between multiple enterprises is relatively difficult [41]. However, if we build the digital twin using a dynamic equation, it can accurately reflect the logical, structural, and quantitative characteristics of the supply-chain system, avoiding the mentioned problems. It can also be used to obtain real-time access to the operational state of supply-chain system and to carry out robust real-time supply-chain optimization.
Based on the above analysis, this paper designs the H ∞ robust controller for perishable supply-chain systems in complex environments and builds the digital supply-chain twins to obtain unknown parameters in real-time to achieve the dynamic robust optimization of the supply-chain system. The goal of this work is to resolve the control problem of perishable supply-chain inventory systems under the fluctuation of market demand caused by complex environments, and supply-chain uncertainty. It can also help the supply-chain system to adapt to the complex market environments and meet unknown demands, while reducing the impact of demand fluctuation and parameter changes on the operating cost of the supply-chain system. The rest of this paper is organized as follows. Section 2 builds supply-chain digital twins based on the supply-chain state-space equation by digital twin technology. We design a robust H ∞ controller of the supply-chain system in complex environments and illustrate the real-time robust optimization principle based on the supply-chain digital twins in Section 3. Section 4 discusses simulation and comparison experiments based on the cake supply-chain system. We make conclusions and discuss future possibilities in Section 5.

Supply-Chain Digital Twins
The supply-chain system is a complex network system made up of multi-level links, and because of its structural complexity, high level of unpredictability, and high operating expenses, researchers and business managers have faced several challenges while designing and validating algorithms. Firstly, if algorithm verification is carried out in the real supplychain system, a lot of resources will be wasted. Secondly, because the operating parameters of supply-chain system are frequently influenced by environmental factors, setting them beforehand based on simulation results will result in an inaccurate description of the supplychain system and inaccurate experimental results. Finally, owing to the unexpectedness and unpredictability of emergencies, there will be some uncertainty in the algorithm's verification if the pertinent data from the supply-chain system cannot be obtained in real-time.
To solve the previous issues, this paper builds digital twins for real-time data transmission to better monitor the operating status of the supply-chain system in complex environments, and then uses real-time data to correct unknown parameters in real-time, allowing for the development of more reasonable production plans can be made that are more reasonable for a variety of operating conditions and environments for perishable supply-chain systems in complex environments. This lowers inventory costs and increases the enterprise's robustness and anti-disruption capabilities, while it can also meet market demand. The supply-chain digital twinning process is shown in Figure 1.
From Figure 1, we can see that the process of supply-chain digital twinning in this paper is divided into two steps: creating the state-space equation of supply-chain system, which includes structural and parametric properties, and creating its digital twins using the state-space equation.

Dynamics Equation of Perishable Supply-Chain System
We base our analysis on a single-chain tandem supply-chain system, the structure of which is shown in Figure 2. In a single-chain tandem supply-chain system, only the last producer needs to sell directly to the market. At the same time, in most cases, all parts of the supply-chain system are replenished according to a certain production cycle. According to the definition of single-chain tandem supply-chain system and the schematic diagram of Figure 2, it can be equated as shown in Figure 3. As shown in Figure 3, manufacturer-01 creates components for transfer to manufacture-02, manufacture-02 creates components for transfer to downstream producers, and producern creates finished items for sale. In order to model and analyze the single-chain tandem supply-chain system more accurately, so as to be closer to the operation state of each link of the supply-chain system in the real environment, the following assumptions need to be made. Assumption 1. This paper considers the situation that the supply-chain system is a single chain. Only the last-link manufacturer directly outputs products to the market. Other links do not export goods to the outside market, only produce product parts for transmission, and only transmit within the supply-chain system.

Assumption 2.
In this paper, we consider the production replenishment time point of the supplychain inventory system is kT, where k = 0, 1, 2, . . . , n, T represents the production planning cycle. In most cases, the production planning cycle is day, so this paper uses k to represent kT. Assumption 3. The manufacturer's production is influenced by various factors such as production capacity and production equipment, and it cannot guarantee that all the parts produced are qualified. In this paper, we set the production rate in a single cycle T as δ, and then we obtain (1)

Assumption 4.
The product under consideration is perishable, and there is a self-loss of inventory at each stage of the production process due to the product itself or storage conditions, and assume that the self-loss rate of the supply-chain inventory system is ρ for a single cycle T, then we can obtain According to the internal linkage of each link in the sales route of the supply chain system and the logical relationship between production and sales of the products sold as shown in Figure 3, the most important inventory quantity of each link of the supply-chain system is taken as the controlled object, and the inventory relationship of each link of the supply-chain system can be obtained by equivalence and simplification based on the above assumptions, as shown in Figure 4.  Figure 4. Equivalent diagram of single-chain tandem supply-chain system.
Where u i denotes the planned production of the ith manufacturer; x i represents the parts inventory of the ith manufacturer; δ i indicates the production pass rate parameter of the ith manufacturer in the supply chain system; ρ i means the inventory self-loss rate of the ith manufacturer in the supply-chain system; d denotes the fixed market demand.
Firstly, based on the above assumptions and considering the logical relationship between the parameters of the single-chain tandem supply-chain system, the inventory relationship between the producers in each link of the supply-chain system in Figure 4 can be expressed as follows.
Secondly, based on Figure 4, the relationship between the inventory of each link of the supply-chain system, considering the production quantity, inventory quantity, and market demand, which are the most important concerns of enterprise managers, we let where x(k) denotes the set of inventory of each producer in the supply chain system at time k. u(k) represents the production quantity of each producer in the supply-chain system at time k. d(k) indicates the fixed market demand in the supply-chain system at time k.
In summary, the state-space equation for a single-chain tandem perishable supplychain system with n producer links can be built as where y(k) ∈ R n denotes the measurable output of the supply-chain system, A ∈ R n×n , B ∈ R n×n , C ∈ R n×n are known constant matrices, respectively, and C is the unit matrix. We suppose that the (A,B) matrix is controllable and the (A,C) matrix is observable. For the constructed dynamic equation of the single-chain tandem perishable supply chain system, the following remarks are needed. Remark 1. The value range of the inventory level of each link in the supply-chain system is x j (k) m j , where m j represents the maximum storage capacity of the warehouse in the j link. Of course, when the inventory is x j (k) < 0, it means that the link is currently in a short shortage state, which is also existing and reasonable for the real supply-chain system.

Remark 2.
The production of manufacturer has a certain range of values, which is 0 < u 1 (k) u max and the u max represents the maximum production capacity of the manufacturer.

Remark 3.
The fixed market demand faced by the supply-chain system is known to the upstream and downstream enterprises and is relatively stable, and the changes in market demand affecting the supply-chain are mainly caused by demand fluctuations.
We set the market demand fluctuation ω(k) at time k based on the dynamic equation of the single-chain tandem perishable supply-chain system. We know that although the market demand fluctuation directly acts on the last producer, due to the bullwhip effects and the cascade effect of the single-chain supply-chain system, the market demand fluctuation will gradually affect the upstream producers in the supply chain against the direction of product flow. We let the impact matrix of market demand fluctuation ω(k) on the supplychain system be D 1 ∈ R n , then the state-space equation of the supply-chain system with demand fluctuation can be obtained as shown in Equation (7).
To reflect the change of inventory costs in the supply-chain system, here we introduce the inventory costs parameter z(k) at the time k. The inventory cost z(k) of the supply-chain inventory system is closely related to the inventory quantity in each link of the supply chain. In this paper, let the matrix of inventory cost and inventory quantity related parameters be C 1 ∈ R 1×n ; then, the state-space expression of the single-chain tandem perishable supply-chain system with inventory cost can be obtained as follows.

Supply-Chain Digital Twins Based on State-Space Equation
The digital twins of the supply chain established in this paper need to achieve the information transfer between the physical and virtual entities of the supply chain and their real-time interaction, and play a role in the whole process of robust optimization, so the digital twins built in this paper are shown in Figure 5, which mainly consists of the real physical environment, the virtual simulation environment, and the data transfer environment. The real physical environment consists of the physical entity layer, the data acquisition layer, and the production decision layer. The virtual simulation environment and the data transfer environment include the algorithm processing layer and the data transfer layer.
The real-world physical environment, the computer-generated simulation environment, and the data-dump layer are defined as follows from Figure 5.

•
The physical entity layer is a perishable supply-chain system, which consists of several segments that produce perishable products, each of which includes production, storage, and sales components. During the operation of the supply-chain system, different types of data are generated, including supply-chain parameters, production data, and product storage data, which are transmitted to the data acquisition layer. • The data acquisition layer is the medium through which the digital twins collects data, mainly the operational data of the supply-chain system, including production data and store data, and the external data of the supply-chain system, including weather, average temperature, and market demand. • The production decision layer will create the best production plan based on market demand and the production plan generated by the algorithm processing layer, and then issue the production order to the terminal equipment to guarantee the supplychain system runs normally. • The algorithm processing layer, which is the central component of the supply-chain digital twins, directly sets the production strategy for each link in the system. To assist businesses in creating the best production plan, it first builds the supply-chain state-space equation based on data from the data receiving layer and then updates the operation state and pertinent supply-chain system parameters with the real-time transmitted data. • The data transfer layer is mainly composed of data storage and data transmission, which realizes the efficient transfer of data between each link of the supply-chain system, and stores and recalls these data in real-time through a combination of cloud and local terminals.  By the supply-chain digital twins, we can realize the supply-chain system to link with the virtual simulation environment through the twin data in real-time to achieve better control effects, optimize the simulation results in the virtual environment, and help the enterprises in each link of the supply-chain system to make better production plans.

Analysis and Methods
The different operating environments of the supply-chain system are reflected in the state-space equation of the supply-chain system, which can be represented by different system parameters.The different operating environments of the supply-chain system are reflected in the state-space equation of the supply-chain system, which can be represented by different system parameters, and then the uncertain supply-chain system state-space equation can be used to describe the supply-chain system in a complex environments.
After describing the supply-chain system in complex environments by using the uncertain state-space equation, we propose the design theorem of a robust H ∞ controller for an uncertain system, and then design the robust H ∞ controller to meet the performance requirements, and finally use the supply-chain digital twins to obtain the unknown parameters of the supply chain system in the current environment in real-time to achieve the real-time robust optimization of the supply-chain system.

Model Analysis of Perishable Supply-Chain System in Complex Environments
The challenges that the modern supply-chain system faces emerge from a variety of sources, and the environment in which it operates is very complex. In particular, for the perishable supply-chain system, the unique characteristics of the items would create huge economic loss if the supply chain system was unable to address the issues and adapt to the complicated operational environments.Therefore, there is a pressing need to address the issue of how to improve the robustness of supply-chain system while coping with the complicated and ever-changing operational environments. Due to the complexity of the market and operating environments, the operation state of the supply-chain system will also change, which is reflected in the constructed state-space equation of the supplychain system and can be expressed as the change of relevant parameters.We need to make some remarks about the perishable supply-chain system's parameter changes in this paper because of the complex environments.

Remark 4.
The dynamic model of the perishable supply-chain system is mainly characterized by two changes in parameters: internally, the self-loss rate ρ and the production conformity rate δ. Externally, it is mainly reflected in the changes in market demand fluctuation ω.
The following assumptions on the influences on the supply-chain system need to be established in order to study the supply-chain system in the complex environments.
Assumption 5. The matrix D 1 of the impact of demand volatility on the supply-chain system and the parameter C 1 of the correlation between the supply-chain inventory quantity and inventory costs do not change under complex environments. Assumption 6. In complex environments, the fixed market demand of the supply-chain system does not change, but the change in market demand is mainly caused by the fluctuation of demand. Figure 6 shows the operation diagram of the supply-chain system under complex environments, where the complex environments are mainly reflected in the weather, average temperature, production conditions, and unexpected events during the operation cycle T. These parts will directly cause changes in the relevant parameters of the supply-chain system and market demand. The supply-chain system will exhibit different operating parameters in different environments, which often makes the management of the supply-chain system more difficult for enterprise managers.   According to Figure 6 and Equation (6), some parameters of the perishable supplychain system are different under different environmental conditions, which can be described by the state-space equation as follows.
Because the fixed market demand is known and constant, we set the controller into two parts: the u 1 part is used to achieve robust H ∞ state feedback control, and the u 2 part is used to balance the fixed market demand in the market. Then we can obtain Combining Equations (9)-(11), we can obtain the dynamic equation of supply-chain inventory model with state feedback control in a complex environment.
For the constructed system (12), the system (12) is considered as an uncertain supplychain system since each cycle T of the supply-chain system leads to uncertainty in parameters A and B under different operating environments. For the uncertain closed-loop supply-chain system (12), the following remarks are also required.

Remark 5.
In the uncertain closed-loop supply-chain system (12), A i ,B i is the uncertainty parameter matrix of the system and satisfies whereĀ andB are the initial values of the system parameters, A * and B * are the change matrices caused by the complex environmental changes, and we let Here, H, E 1 , E 2 are matrices of known proper dimensions, and H, E 1 , E 2 are related to the operating environment of the supply-chain system and its own operation. G is an unknown real matrix function and satisfies G T G I.

Remark 6.
From the uncertainty matrix of the system A i ,B i determined by the self-loss rate parameter ρ and the transport loss rate parameter δ, respectively. It can be seen that the parameters A i ,B i have a certain range of values.

Robust H ∞ Controller Design
In this part, we design the robust H ∞ controller for perishable supply-chain system in complex environments based on the supply-chain system state-space Equation (12), which aims to help the supply-chain system to effectively adapt to the complex market environments, achieve the required operational demand, reduce the impact of demand fluctuations on the supply chain inventory costs, and improve the robustness of the supply-chain system in complex environments. The controller u 1 (k) is designed by H ∞ state feedback so that the uncertain closed-loop supply-chain system (12) satisfies the following requirements.

•
When the demand perturbation ω(k) = 0, the uncertain closed-loop supply-chain inventory system (12) is capable of satisfying robust asymptotic stability. • When the demand fluctuation ω(k) = 0, the uncertain closed-loop supply-chain system (12) should satisfy the H ∞ performance parameter γ, which can be equated to the transfer function of ω(k) → z(k) in the system G wz , then G wz is satisfied where γ is the H ∞ performance sub-optimization parameter of the system.
The design of the H ∞ controller based on the state-space equation of the supply-chain system for uncertain supply-chain system in complex environments is shown in Figure 7, where the fixed market demand is obtained directly from the market survey, and the H ∞ state feedback controller u 1 (k) is designed to make the uncertain closed-loop perishable supply chain system (12) satisfy requirement 1 and requirement 2. From Figure 7, the control matrix of H ∞ state feedback controller u 1 (k) is K, and then

Supply Chain System
By combining Equations (12), (13) and (16), we can obtain and then from the Equation (17), the z(z) can be written as where A b =Ā +BK, E = E 1 + E 2 K. Futhermore, with Equation (18), we can equate requirement 2 to Next, it is required that we introduce Lemma 1 in order to be able to develop controllers that fulfill the robust H ∞ performance of perishable supply-chain systems in complicated environments. Lemma 1 ([42]). For the closed-loop system transfer function G(z) = C(zI − A) −1 B, where A is the stable matrix, then the necessary and sufficient condition for G(z) ∞ < 1 is Riccati inequality and there exists a positive definite solution X = X T , which makes B T XB < I.
Based on Lemma 1, we propose the Theorem 1.

Theorem 1. The transfer function of the closed-loop system is G
If there is a positive definite matrix P = P T , which means the matrix inequality satisfies then the closed-loop system is robustly stable and meets G(z) ∞ < γ.
The proof of Theorem 1 proceeds as follows.
Proof. According to Lemma 1, a sufficient condition for G(z) ∞ < 1 is Riccati's inequality as shown in Equation (12). Then, for H ∞ performance γ-suboptimization objective, that is, G(z) ∞ < γ, use B γ = γ −1 B instead of the matrix B in Lemma 1. In addition, taking A = A + A 1 , then we can obtain Theorem 1 is true and the proof is complete by organizing Equation (22).
According to Theorem 1, for the uncertain closed-loop supply-chain system (12), this paper proposes Theorem 2.

Theorem 2. The transfer function for the uncertain closed-loop supply-chain inventory system
is a stable matrix for all permissible uncertain parameters. If there exists a scalar parameter α > 0 and a positive definite matrix P = P T , for all supply-chain inventory systems in complex environments, the following two conditions are satisfied simultaneously, where Then the uncertain closed-loop supply-chain inventory system (12) is robust and stable and satisfies G(z) ∞ < γ. Then, the feedback control law is Next, we will prove Theorem 2.
Proof. We set L = P + PD 1 MD T 1 P, where M = (γ 2 I − D T 1 PD 1 ) −1 , and since P is known to be a positive definite symmetric matrix, we can obtain that both L and M are symmetric matrices. Then, the A b + HGE stability matrix is substituted into Lemma 1, the Equation (20) can be transformed into Because of the state feedback control for the uncertain closed-loop supply chain system (12), it contains the corresponding uncertain parameters. Then we set the existing parameter matrices W 1 , W 2 , and scalar parameters α > 0, and W 1 , W 2 are defined as where F is the symmetric matrix. By Equation (26) we obtain According to Equation (27), we have Substituting Equation (28) into Equation (25), the Equation (25) can be translated as We set F as then, by substituting Equation (30) into Equation (29), we can obtain where J = L + αLH(I − αH T LH) −1 H T L T , then we find J is a symmetric matrix. From the description of G T G I in Remark 5, then from Equation (31) we obtain Since we need to solve for the state feedback parameter matrix K that satisfies the system control conditions, we organize the Equation (33) by In summary, according to the Equations (21), (33) and (34), the can be obtained. According to Theorem 1, we know that the uncertain closed-loop supply chain inventory system (12) is robust and stable as long as there exists a positive definite symmetric matrix P such that satisfies the condition. Then, we have By the condition 1 in Theorem 1, we can find that the size of the H ∞ performance γ parameter is equivalent to the size of the positive semidefinite part of the symmetric positive definite matrix P. That is, if we minimize the H ∞ performance γ parameter, it is equivalent to minimizing the positive semidefinite part of the symmetric positive definite matrix P. Therefore, if we want to make the symmetric positive definite matrix P as small as possible to improve the performance of H ∞ , we need to satisfy max{ f (K)} as small as possible. Function f (K) can be expressed as then, we can find only when K = −Q −1 N, function f (K) obtains the maximum value. In this situation Therefore Theorem 2 holds, and the proof is over.
In conclusion, this paper uses Theorem 2 to create a state feedback controller for an uncertain closed-loop supply-chain system (12) in complex environments. The goal is to achieve the H ∞ performance γ-suboptimization objective of a perishable supply-chain system in complex environments with unknown parameters within a specific range.

Real-Time Robust Optimization Principles
Perishable supply-chain systems in complex environments are influenced by many factors, making it impossible for enterprise managers to make reasonable and accurate production plans. The supply-chain digital twins can interact with the real supply-chain system in real-time, and obtain the operation status and environment status of the supplychain system in real-time, and simulate it in the virtual simulation space, so as to help enterprise managers to make the optimal production plan and help enterprises adapt to the complex market environments. The working principle of the real-time robust optimization of supply-chain system based on digital twins is shown in Figure 8 below. The real-time robust optimization system based on the digital twins of the supply-chain system consists of a physical environment and a virtual environment, of which the physical environment and the virtual environment have been described above. From Figure 8, it can be seen that the robust optimization principle based on the digital twins of the supply-chain system is divided into two main parts. One of them is to use the acquisition sensors to collect the operational state data of the supply-chain system in the physical environment, to construct the dynamic equation of the uncertain supply-chain inventory system, update the unknown parameter data, and correct the inventory quantity of each link of the supply-chain system in real-time for better design of robust controllers. Secondly, using the collected real-time data to simulate in the virtual space, the optimal control inputs are analyzed in real-time to help the enterprise managers to formulate the most reasonable production plans and issue the corresponding instructions through the decision-making level to realize the production scheduling of the supply-chain system.

Supply Chain System
Production Link  By using the digital twin for real-time robust optimization of the supply-chain system in complex environments, the supply-chain system, the twin data, and the virtual simulation entity are connected as a whole, and the production plan of the supply-chain system in the complex environments can be optimized in real-time, as shown in Figure 9.  According to Figure 9, we can obtain the real-time robust optimization based on the supply-chain digital twins, and it can be divided into the following steps:

1.
We construct the supply-chain digital twins by combining our supply chain state-space equation of the uncertain supply chain with digital twin technology; 2.
The use of relevant sensors are used to collect twin data, including supply chain operation, status, and environmental conditions; 3.
Based on the twin data collected in real-time, the parameters of the supply-chain system under the virtual simulation environment are updated and corrected, mainly including the real-time inventory quantity and unknown parameters A and B of the supply-chain enterprises; 4.
The modified parameters are used for virtual simulation to develop the optimal production decision; 5.
The optimal production decision is transmitted to the company manager through the data transmission layer.
From the above steps, it can be seen that the most critical step for real-time robust optimization of the supply-chain digital twins is step 3, which can make real-time corrections to the relevant parameters in the simulation environment to ensure that better production decisions can be obtained. According to the Equation (16), the controller input is related to the current enterprise inventory x and the state feedback control matrix K, so the supplychain digital twins are used to make corrections from these two aspects. In this paper, we take advantage of the real-time data acquisition feature of the supply-chain digital twin to determine the parameters E 1 and E 2 in real-time. In this paper, the parameters E 1 and E 2 are corrected in real-time by taking advantage of the real-time data acquisition feature of the supply-chain digital twins, and let the corrected parameters beẼ 1 andẼ 2 .
In summary, we can obtain the dynamic equation of the supply-chain system after the correction using the supply-chain digital twins as

Simulation and Comparative Analysis
To verify the real-time robust optimization of perishable supply-chain system by constructing the digital twins of the supply-chain, this paper conducts a comparative simulation study based on the production and sale of a cake in the market, which contains multiple upstream producers, and its processing flow is shown in Figure 10. From the initial production of fresh milk at the cow production base to the downstream milk processor to produce raw dairy products, the raw dairy products are sent to the downstream cream processing manufacturer to produce cream, and finally the cream is made into cake products by the cake processor for sale. The structure is in line with the single-chain chain supplychain system marketing model, and the processed products are also a type of perishable product, which is fully consistent with the needs of this paper to study the object of perishable supply-chain system. Based on a cake processing process, to verify the applicability and superiority of the proposed method, two kinds of simulation experiments are conducted for the cake supply-chain system: traditional robust optimization based on the state-space equation and real-time robust optimization based on the digital twins of the supply-chain. Firstly, we obtain the relevant parameters of the cake supply chain system and construct the statespace equation of the supply-chain system. Secondly, we determine the variation range of the unknown parameters and give the performance parameter γ according to the previous experience, and use the Theorem 2 proposed in this paper to find out the state feedback matrix H ∞ control of the supply-chain system under different simulation situations. Finally, using the inventory quantity as the control index, we analyze the trend of inventory quantity and inventory costs of the supply-chain system under complex environments.
From Figure 10, we can see that the upstream processors of the cake are 3, that is, we take n = 3 in this paper. By analyzing the production-sales-storage data and making reasonable data assumptions about the cake supply-chain system, we can obtain the initial parameters of the three-stage supply-chain system model of the cake as follows: It is known that the robust sub-optimization parameter γ = 1.20 of the cake supplychain system is taken in this paper, and the range of variation of the relevant parameters of the three-level supply-chain system can be obtained through previous investigations and expert experience as follows: According to Theorem 2, the matrix inequality (41) can be constructed, and the proof procedure is shown in Appendix A. By solving inequality (41), we can obtain the state feedback control law K for uncertain perishable supply-chain systems in complex environments.
In this paper, we take γ = 1.20, α = 0.1, and use the LMI toolbox to solve matrix inequality (41), and we can obtain the state feedback matrix K as A robust H ∞ controller for a perishable supply-chain system in a complex environments is designed using the solved state feedback matrix K, and a conventional robust optimization simulation experiment based on the state-space equation of the uncertain supply-chain is conducted with the following initial parameters According to the above experimental conditions, the comparison of the change of inventory levels, production levels, and inventory costs of each link of the cake supply chain system under the two simulation conditions is shown in Figure 11, Figure 12, and Figure 13, respectively. By analyzing Figure 11, we can find that the simulation process can update the relevant parameters in real-time due to the existence of the supply chain digital twins, which can develop a more reasonable production strategy compared with the traditional robust optimization, and greatly reduce the inventory fluctuation in each link of the cake supplychain system. When the supply-chain system is stable, the inventory quantity of each link of the supply-chain system will gradually converge to 0, maintaining the dynamic stability of production and sales, ensuring market demand, and reducing the inventory costs of the enterprise caused by inventory. Through Figure 12, we can also find that the real-time robust optimization based on the digital twins of the supply-chain can help companies develop smoother production strategies, while the production strategies developed by the traditional robust optimization are more volatile. Since the inventory cost of each link of the cake supply-chain system is proportional to the inventory quantity, we can find that the trend of the change curve of inventory costs are the same as the trend of the change of inventory quantity in Figure 13.
In order to better reflect the fluctuation trend of inventory quantity and production quantity of different links of the supply-chain system under different simulation conditions, this paper introduces the moving standard deviation index, where the moving standard deviation is defined as the standard deviation of each sampling point in the operation of the supply chain system to obtain the moving standard deviation. According to the definition, the moving standard deviation of inventory and the moving standard deviation of production for each link of the cake supply-chain system under two simulation conditions can be calculated as shown in Figures 14 and 15.  From the analysis of Figure 14, we can see that compared with the traditional robust optimization, the real-time robust optimization based on the supply chain digital twins can reduce inventory fluctuation, reduce the production storage pressure and avoid the waste of resources in the enterprise. Similarly, Figure 15 reflects that with the help of realtime updating of the parameters of the supply-chain digital twins, the virtual simulation environment can formulate more reasonable production strategies based on the operation status of the supply-chain system, reduce the number of production fluctuations, and reduce the waste of resources and cost increase caused by the production.
In summary, in order to reflect the effectiveness and superiority of real-time robust optimization based on the supply-chain digital twins, a comprehensive comparison of the simulation results in two different cases is presented in Table 1.

Conclusions
In this paper, a solution based on supply-chain digital twins is proposed for the realtime robust optimization of a perishable supply-chain system in complex environments. The state-space of the supply-chain system is constructed based on the logical relationship of its operation, and the digital twin technology is used to build the supply-chain digital twins. The experimental results show that, compared with the traditional robust optimization, the real-time robust optimization solution based on supply-chain digital twins can update the relevant parameters in real-time based on the twin data generated from the operation state of the supply-chain system, which can help enterprises to formulate more appropriate production-storage-sales strategies to meet the market demand while reducing the enterprise's inventory, reducing the waste of resources, and effectively help perishable supply chain system enterprises to adapt to the complex, volatile, and fluctuating market environments.
This paper provides a theoretical basis and feasible means for the managers of perishable supply-chain system enterprises to cope with the complex market environments. However, there are still some research deficiencies in this paper. The research on the supplychain system does not consider the time-lag problem when the products are shipped, and further research can be conducted by introducing time-lag parameters. In addition, this paper considers that the supply-chain inventory system model is mainly linear, but there are many nonlinear factors in the real environment, so we can add relevant nonlinear relationships for further research in the future. Data Availability Statement: This article does not use public data. All data is provided by enterprises and cannot be shared.

Conflicts of Interest:
The authors declare no conflict of interest.

Appendix A
In order to be able to prove Equation (41) in the main text, the following lemma needs to be introduced. Lemma A1 ( [43]). For an uncertain closed-loop system as shown in Equation (A1), if there exists a state feedback u(k) = Kx(k) and a reversible symmetric positive definite matrix P ∈ R n×n , the following inequalities hold simultaneously: x(k + 1) = (A c + HGE c )x(k) + B 1 ω(k) y(k) = Cx(k) (A1) (1)S < 0 (2)S 11 < 0, S 22 − S T 12 S −1 11 S 12 < 0 (3)S 22 < 0, S 11 − S 12 S −1 22 S T 12 < 0 According to the Lemmas A1 and A2, the proof of Equation (41) is as follows: From Lemma A1 it follows that Then we can get