Mathematical Modeling of Production Processes of Discrete Machine-Building Enterprises Based on the Interaction of Simulation Systems and Operational Planning Systems

Analysis of production systems (PS) of discrete multi-nomenclature machine-building enterprises is a complex task, its solution is necessary to support decision-making during technical reequipment, modernization or technological preparation of production. The paper shows a concept of joint use of operational scheduling systems and simulation modeling systems to improve the efficiency and adequacy of PS analysis. The problem of determining the deviation of the planned state of the PS from the simulated state and evaluating the level of stability and stability of the PS behaviour on its basis is considered. It is revealed that the proposed approach allows us to more adequately determine the timing of the production program, assess the stability of the PS behaviour when using various planning logics and algorithms, and choose the best one for subsequent use in a real PS.


Introduction
Discrete multi-nomenclature machine-building enterprises are subject to periodic changes in the product range and production program. It has a significant impact on balancing the workload of workplaces and often requires making appropriate adjustments to the technological and organizational solutions used. A machine-building enterprise is a complex organizational and technical system and such decisions should be made reasonably on the basis of the results of a comprehensive analysis of performance indicators in the implementation of a promising production program. To a greater extent, the tasks of engineering today are relevant for discrete multi-nomenclature production, which is more susceptible to changes in the nomenclature, production program and the influence of other factors [1][2][3].
Solving the problems of analysis of the production system (PS) in the context of assessing the sufficiency of production capacities for the implementation of the production program of output, justifications for making changes to the PS, justification of investments, implementation of diversification projects, as well as risk assessments of such projects, are impossible without calculating and modeling the implementation of the production program with a given degree of detail, taking into account both the configuration and composition of production capacities, and planning and management algorithms [4].
One of the ways to solve the problem of analyzing and modeling the PS work of is to create its digital twin, as evidenced by a large number of publications in this field [5][6][7][8][9][10][11].

Modeling and analysis of production systems of discrete machine-building enterprises
From point of view of accurate planning of work at machine-building enterprises, systems of classes APS (Advanced Planning & Scheduling Systems) and MES (Manufacturing Execution Systems) are of interest. Such operational planning systems have a wide range of capabilities: assessment of the implementation of the production plan, drawing up detailed plans for the operation of equipment, performance analysis, dispatching of products. When developing production schedules in systems of this class, computational methods are used: methods of combinatorial optimization, theory of schedules, heuristic methods, which determine the logic of production management. Work schedules can be used to assess changes in the time of work load factors, the overall efficiency of OEE equipment (Overall Equipment Efficiency), production cycles of manufacturing products, etc. [2,7,11].
At the same time, a significant limitation of the calculation methods is the lack of the possibility of accounting for random events (equipment failures, supply failures, the occurrence of defects, etc.), the ability to work with indistinctly specified information in the form of value intervals, etc. Thus, the PS in systems of the MES/APS class is considered as a stable closed system, in which the occurrence of any event affecting the execution of the production program is set by a schedule.
However, practice shows that the PS of discrete multi-nomenclature machine-building enterprises are characterized by instability of the processes of management and transformation of the material flow. Therefore, the use of systems based only on calculation methods, including systems of the MES/ASP class, for the analysis of PS of multi-nomenclature machinebuilding enterprises does not provide the required reliability of the results [12,13].
The effects of random events are taken into account by systems based on modeling the behaviour of the PS during the execution of the production program. The simulation system is a tool that allows us to simulate the behaviour of the system when performing specified processes. Simulation systems (SIM) are based on the use of situational logic of decision-making in the management of material flow. Such systems include PlantTwin, Siemens Plant Simulation, DELMIA, AnyLogic, etc. [3].
For mass and in-line production, it is sufficient to specify the basic input data (information about products, processes and resources), as well as basic control algorithms ( Fig. 1a) as the initial data for conducting process simulation with an acceptable level of adequacy.

Fig. 1. Different approaches to simulation modeling
Speaking of discrete multi-nomenclature production, to simulate the operation of its production system, the source data must additionally contain the production schedule generated in MES/APS systems. It is important to note that the algorithms used to form the production schedule largely depend on the result of modeling and the implementation of the production program on time. At the same time, in contrast to MES/APS operational scheduling systems, simulation systems allow us to take into account additional factors that affect the behaviour of the production system over time and its functioning. These factors include: non-constant time of operations, failures, equipment breakdowns, non-constant time of transportation of parts, delivery delays, etc. Thus, the implementation of the interaction of MES/APS systems with simulation systems and the transfer of the production schedule to it can give a synergistic effect and significantly increase the adequacy of modeling [3,14]. Figure 1b shows the interaction scheme of the simulation system with the MES/APS system. In this case, the behaviour of the PS is modeled when executing a production schedule obtained from systems of the MES/APS class. At the same time, the above-described probabilistic and situational factors can affect the implementation of the production plan, reduce the stability of the system and lead to a deviation from the specified deadlines for the implementation of the production program. Figure 2 shows a general graph of changes in the state of the production system over time when planning the execution of the production program, and then modeling its operation using a simulation system [15]. The figure shows that during the modeling process, discrepancies with the plan will invariably accumulate, which is caused by the above-mentioned additional factors, which, unlike planning systems, the simulation system takes into account. Ultimately, this is expressed in the form of a shift in the simulated timing of the production program. It is important to note that the tasks of the simulation system do not include the management and formation of corrective control actions for the return and "catch-up" of the planned dates calculated in the operational-calendar planning systems. The tasks of the simulation system include exclusively modeling the execution of the generated schedule, taking into account a large number of factors [16][17][18][19].
Factors affecting the stability of the production system, taken into account in simulation systems, can significantly affect the timing of the production program, as well as lead to the impossibility of its implementation. When a real production system is functioning, in such cases, work is usually rescheduled, i.e. operational scheduling systems form a new up-to-date production schedule based on the current actual state of the PS.
Taking into account the above, the paper proposes a statement of the problem of implementing iterative interaction of operational-calendar planning systems and simulation modeling systems for the possibility of performing rescheduling cycles in the modeling process. Thus, the simulation of the functioning of the PS becomes more adequate and close to the work of the real PS. Such a statement of the problem requires the implementation of feedback from the simulation system to the MES/APS system, to transfer the current simulated state of the PS to them and send a request for rescheduling (Fig. 1C) [3,12,[20][21][22]. Figure 3 shows the change in the state of the PS over time in accordance with the calculations of the planning system, as well as the results of simulation modeling. As can be seen from figure 3, the graph contains one rescheduling cycle at the point t1, at which the critical deviation (value Δ) of the simulated PS state from the planned one, expressed in the form of standard hours worked, was determined. The idea of implementing iterative interaction between the simulation system and operational scheduling systems is that during the simulation process, the planned and simulated work volumes are compared, expressed in standard hours. When the specified level of deviation of the simulated PS state from the planned one is reached (the value Δ), the experiment control module initiates a command to reschedule and form a new schedule in the MES/APS system [23].
The increase in standard hours is mainly caused by the excess of the number of defective products obtained during modeling from the specified norm during the development of the production schedule.
When implementing this approach, the simulation system allows us to determine the deviation of the simulated state of the PS from the planned one in time and acts as a kind of virtual dispatcher, which simulates the state of the PS when executing a given schedule and reports deviations from the specified plan, which initiates a command to reschedule work (Fig. 1c). Thus, the iterative formation of the production schedule and its verification is implemented. In the actual operation of the PS, MDC/MDA systems are used as a tool for evaluating the actual implementation of the plan and the presence of critical deviation factors, which allow realtime monitoring of the PS state [3,24].
The results of simulation of a PS with a cycle of rescheduling can be seen that the time of completion of the production program after the start of the cycle of rescheduling decreased in comparison with if system simulation will continue to run for a given plan, given the backorder from him. We can also see that when rescheduling cycles are implemented, the amount of standard hours worked may increase compared to the original calculated data. This may occur due to the fact that during the modeling process there was an excess of the permissible level of incorrigible defects in a number of nomenclature items, which led to an increase in the labor intensity of the production program and the production cycle [22][23][24][25].
An important task for the implementation of this approach to the analysis of PS and the forecast of the timing of the production program is to determine the fact of the occurrence of a critical deviation, which should cause the start of the rescheduling cycle [26][27][28][29][30]. This deviation can be expressed in quantitative terms or represent an event, the occurrence of which can disrupt the stability of the PS and require the start of a rescheduling cycle. The main reasons for the need to restart the development of the production schedule: -deviation from the deadlines for the implementation of the specified production program. This factor can be expressed in quantitative terms, but it should be taken into account that this deviation may be different for different nomenclature items. In this case, it is necessary to determine the priority, i.e. deviations from the production time of which parts can lead to a significant violation of the stability of the PS, and for which parts this may be permissible; -equipment failure. If the PS has equipment of the same type as the failed one, or an alternative equipment is specified for performing the necessary operation, then the occurrence of this event may not lead to the need for rescheduling. However, if there is no possibility of using other equipment, or all the equipment units from the group are out of order, this will lead to a significant deviation from the set plan and will require rescheduling; -an incorrigible defect. If the modeling process reveals an excess of the norm of an incorrigible defect of the part/product, this should lead to the start of the rescheduling cycle, since the implementation of the production plan becomes impossible.

Conclusions
The article shows that the analysis of the PS of discrete machine-building enterprises is the basis for decisionmaking support during technical re-equipment, modernization or technological preparation of production. The proposed scheme of joint use of operational scheduling systems and simulation modeling systems will increase the efficiency and adequacy of the PS analysis. The problem of determining the deviation of the planned state of the PS from the simulated state and evaluating the level of stability and stability of the PS behaviour on its basis is considered. This approach will allow us to more adequately determine the timing of the production program, evaluate the stability of the PS behaviour when using various planning logics and algorithms, and choose the best one for subsequent use in a real PS.