1. Introduction
In the era of the rapid rise of the Internet, intelligent manufacturing, and artificial intelligence, information technology plays a more important role in the manufacturing industry [
1]. From the previous manual manufacturing to the current intelligent manufacturing, each country has issued different development goals. For instance, Germany released Industry 4.0 [
2], the United States proposed the Advanced Manufacturing Partnership plan [
3], and China put forward the “Made in China 2025” national action program [
4]. These plans have been put forward to meet the personalized, flexible and intelligent manufacturing development needs of the current era.
The flexible job shop (FJS) [
5] has become a widely adopted workshop mode in China due to its flexible and adjustable workpiece processing path [
6], which can well meet the production needs of multiple varieties and sizes of batches and adapt to personalized and customized market demands [
7]. Uncertain disturbance events often occur in a flexible job shop production system [
8]. Scheduling problems of the flexible job shop can be divided into static scheduling problems and dynamic problems according to whether disturbance events in the production system are considered [
9]. Among them, dynamic scheduling problems, which consider actual disturbances, are more practical and have more research significance.
Both static and dynamic scheduling problems of the flexible job shop have been studied extensively. For example, Rossi et al. [
10] proposed a swarm intelligence scheduling method based on a separate graph model for the static scheduling problem of the flexible shop floor. For the static scheduling problem of the flexible job shop, Ma Jia et al. [
11] combined a variety of solving strategies to generate the initial solution of an artificial immune algorithm and achieved better results. Abumizaret et al. [
12] artificially set the global disturbance capacity of the disturbance factors and established a dynamic scheduling strategy for the affected workpiece. Wu et al. [
13] studied the flexible job shop scheduling problem with machine faults, constructed relevant constraint models including aspects of the spare material condition and the machine state, and proposed different strategies for insertion rescheduling and full rescheduling.
In summary, the current research on the FJSP mainly focuses on a scheduling mode that consists in modeling first and solving later, and most of the research focuses on the improvement of FJSP modeling methods and optimization algorithms. However, with the development of flexible job shops into intelligent manufacturing systems, manufacturing enterprises have accumulated a large amount of historical scheduling big data, and have a more accurate real-time scheduling big data acquisition ability. In this context, the research on how to make full use of the scheduling knowledge contained in the scheduling big data and on how to combine big data technology, artificial intelligence technology, and Internet of Things technology to form an autonomous, intelligent and prescient scheduling mode still needs to be further deepened.
In this paper, a flexible job shop dynamic scheduling framework is constructed under an intelligent manufacturing environment. Combining intelligent manufacturing with dynamic shop scheduling, a dynamic scheduling model is established. To solve the problem of rush order insertion in production, a dynamic scheduling method is proposed. In the intelligent manufacturing scheduling mode, the scheduling process is realized through information fusion and interaction, and the validity of the proposed model is verified by a genetic algorithm. The innovation of this paper is that compared with the traditional workshop, in the intelligent manufacturing workshop, the production data of the actual workshop can be uploaded to the database. Through the cooperative operations of the processed data and the upper system, the dynamic scheduling of order insertion is realized, which improves production efficiency.
The paper is organized as follows. The dynamic scheduling framework of the flexible job shop based on digital twins is constructed in
Section 2. The flexible job shop dynamic scheduling problem is described in
Section 3.
Section 4 describes the genetic algorithm for model solving. The dynamic scheduling process of inserting orders is reported in
Section 5. Example verification is described in
Section 6. Finally, in
Section 7, the conclusions are reported.
2. Flexible Job Shop Dynamic Scheduling Framework Based on Digital Twins
Arranging the production of workshop material can improve production efficiency and reasonable allocation of resources. With the advent of the intelligent era, workshop scheduling has become complicated. Under the background of intelligent manufacturing, effective information data analysis can solve many problems. The key to solving dynamic disturbance is real-time interaction between physical space and information space, and data analysis in the information space. Finally, the intelligent system dynamically decides the next production scheduling plan.
Based on digital twins, this paper constructs a flexible job shop dynamic scheduling framework, as shown in
Figure 1. The model consists of four layers.
(1) Physical layer. The physical layer mainly refers to the set of objective entities such as the personnel, equipment, material and environment in the workshop, which is responsible for the production and processing activities in the workshop and functions to collect and transmit data in physical space, such as equipment data, material information, personnel information, and environmental data.
(2) Model layer. The model layer is a virtual digital twin workshop, which is the real mapping of the physical workshop. Based on real-time data, through the corresponding models, rules, and knowledge of the model layer, the physical space production operations are analyzed, and the corresponding optimization schemes and decision-making instructions are formed. The model layer has three attributes: computation, interaction, and control. Computational performance truly reflects the state of physical products with the help of simulation tools. The interaction includes two aspects. One is to improve the accuracy of the digital twin model through continuous interaction with physical products. The second is the interaction with other digital twin models to complete the product production process simulation. Controllability refers to the control of the behavior and state of products in the physical space through data analysis.
(3) Information layer. This layer is the data analysis and processing platform of the workshop. All kinds of data in the physical layer and model layer are transferred to the information layer and stored in the corresponding database, model base, rule base, and knowledge base. The rules and knowledge of the information layer can be directly used by the application system layer as a decision-making reference, and the encapsulated model can be directly called for production simulation and optimization. The information layer data is analyzed and collated by the workshop data analysis and processing platform, which serves as the decision-making basis for the application system layer to regulate production activities. The information layer realizes the data interaction and fusion between the physical layer and the model layer and ensures smooth communication between the information systems of the application system layer.
(4) Application system layer. The information systems of the digital twin workshop are no longer independent of each other, but interconnected and cooperative to realize the digital management of the product lifecycle. By analyzing the actual needs of the production workshop and relying on the support of the data, models, rules, and knowledge of the information layer, the system layer regulates the operations of the physical layer and the model layer. The application systems include ERP (Enterprise Resource Planning), PDM (Product Data Management), PLM (Product Lifecycle Management), MES (Manufacturing Execution System), and PCS (Process Control System). The functions include workshop production process optimization, process control, intelligent production scheduling, equipment efficiency analysis, and product processing progress monitoring.
3. Problem Description
3.1. Basic Parameters and Description
In the flexible job shop, there are processing stages, each processing stage has at least one piece of machinable equipment, and some processing stages have more than two pieces of processing equipment. At time , workpieces on the order start processing. At , rush urgent workpieces arrive and all processed workpieces are scheduled for rescheduling production.
is the maximum number of processing stages;
is the processing time;
is the maximum number of workpieces;
is the workpiece number, = 1, 2, 3…;
is the process number, = 1, 2, 3…;
is the total number of pieces of equipment in a certain stage, ;
is the number of pieces of processing equipment in a certain stage, = 1, 2, 3…;
is the completion time of a workpiece , = 1, 2, 3…;
is the maximum completion time of all workpieces;
is the processing time of the process of the workpiece ;
is the start processing time of the process of the workpiece ;
is the completion time of the process of the workpiece ;
is a 0–1 decision variable. If it is 1, it indicates that the operation of the workpiece is processed on machine ; otherwise, it is 0;
is the processing procedure of the workpiece on machine .
3.2. Model Building
The model is established with the minimum completion time as the goal. The mathematical model and other related constraints are as follows.
Formula (1) represents the objective function and represents the maximum value of the completion time of a workpiece selected from it; Formula (2) represents the completion time of each workpiece; Formula (3) is the constraint of the workpiece processing sequence, indicating that there can be no interruption between processes; Formula (4) represents the processing time constraint, and the workpiece cannot be interrupted during processing; Formula (5) indicates that a workpiece cannot be processed on two pieces of equipment at the same time.
4. Genetic Algorithm for Model Solving
4.1. Genetic Algorithm
A flexible job shop scheduling problem is a complex nonlinear problem. Metaheuristic algorithms, such as genetic algorithms, ant colony algorithms, and particle swarm optimization algorithms can solve this problem well. Because of its simple operation, strong universality, and good robustness, the genetic algorithm is one of the most popular algorithms for solving flexible job shop scheduling problems [
14].
The evolutionary algorithm is a kind of random search technology based on the idea of biological evolution, which simulates the evolutionary process of populations. It includes methods such as genetic algorithms (GAs), evolutionary strategies (ESs), and evolutionary programming (EP), among which GAs are the most widely used. They are particularly suitable for dealing with complex and nonlinear problems that are difficult to solve by traditional search methods and can be widely used in combination optimization, machine learning, planning and design, and other fields. FJS is a typical NP problem [
15] and one of the most difficult combinatorial optimization problems [
16]. In recent years, the development of probabilistic local search methods such as simulated annealing algorithms, tabu search algorithms, and GAs has aroused people’s interest in using local search methods to solve scheduling problems. In this paper, the GA is directly applied to the FJS problem [
17], eliminating the limitations of the current genetic algorithm which is mainly applied to the group technology FJS problem [
18]. A GA is a kind of bionic optimization method borrowed from biological evolution, especially inspired by the principles of genetics. As a robust global optimization method, the genetic algorithm shows good searchability in solving NP problems in the field of combinatorial optimization and has been well applied in job shop scheduling problems. Solving FJS based on a genetic algorithm has been proven to be an effective solution method. Many scholars at home and abroad have studied it, mainly focusing on population initialization, genetic operation, decoding, and integration with other algorithms. When using the genetic algorithm to solve the FJSP, the quality of the initial solution has a great influence on the speed and quality of the genetic algorithm. If the quality of the initial solution is higher, the starting point of the genetic algorithm is higher, which improves the efficiency and quality of the genetic algorithm. Compared with traditional job shop scheduling, flexible scheduling is a more complex NP-hard problem that includes machine selection and operation scheduling. The rationality of machine selection has an important impact on the final result of process scheduling. Excellent machine selection will greatly reduce the search space of the FJSP algorithm.
4.2. Chromosome Coding
The chromosome uses the workpiece process coding method. One chromosome has two substrings, which represent the selection of the machine and the processing process of the workpiece. The chromosome code is shown in
Figure 2. The number in the figure represents the machine number.
4.3. Crossover Operator
The chromosome crossover operator selects precedence-preserving order-based crossover (POX), randomly selects two chromosomes composed of machine selection strings, and makes A = (2), B = (1,3), where A and B represent two sets, and generates a blank chromosome between the two parents. The gene of parent 1 belonging to machine M1 is copied into the blank chromosome. Similarly, the gene of parent 2 belonging to machine M2 is copied into the corresponding blank, as shown in
Figure 3.
Similarly, the POX crossing mode is also selected for workpiece processing string selection, and the results are shown in
Figure 4. The number in the figure represents the operation number.
4.4. Mutation Operator
The mutation operator is not generally used for the workpiece string selection because the mutation may produce one or more non-existent workpiece operations, resulting in an infeasible scheduling scheme. Therefore, the mutation operation is generally used for the machine selection string. The mutation operator selects the optimization mutation method, and the process is as follows: suppose there are three processing machines at a certain stage, numbered No 1, No 2, and No 3, and their processing efficiency follows the order No 1 < No 2 = No 3. When selecting the mutation, machine No 1 is changed to machine No 2 and machine No 3. After the mutation, the fitness value (minimum completion time) is calculated and compared with the fitness value of the original chromosome. If the fitness value is larger, it will enter the next generation, otherwise, the original chromosome will remain unchanged. The variation operation is shown in
Figure 5.
5. Dynamic Scheduling Process of Rush Order Insertion
In the actual production of enterprises, the insertion of emergency orders will lead to the abnormal execution of the decided scheduling scheme due to sudden disturbances in the actual production process. The production scheduling system of an enterprise must be able to respond to sudden disturbances in real-time, be fault tolerant and make effective adjustments. Therefore, in the actual production process, job scheduling cannot be scheduled according to the set scheduling strategy or scheduling model, but must follow the real-time scheduling and continuous optimization according to the actual situation of the job shop. For some sudden or random disturbances under real-time conditions, the production system can dynamically adjust the original scheduling scheme in time and effectively. According to the status of the current system, the system will arrange the processing sequence of workpieces and assign tasks to the machine.
Based on the dynamic scheduling framework based on intelligent manufacturing in
Section 2, a dynamic scheduling process for rush order insertion has been designed. When a new rush order appears, a new scheduling scheme is dynamically generated. The detailed process is shown in
Figure 6. When the system receives the order, it generates the initial scheduling plan. In the process of executing the current plan, it determines whether the system receives the rush order on time. If there is no rush order insertion, it will continue to execute the current scheduling plan. If there is a rush order, the workshop’s real-time monitoring system will check the idle equipment in the workshop. In the workshop with more idle equipment, it will check the serial number of current unprocessed workpieces and upload the data to the system. The system will regenerate a new scheduling scheme according to the number of unprocessed workpieces, the number of workpieces in the rush order, and the workshop equipment status, and release it to the workshop manufacturing execution system, and the new scheduling scheme will be implemented by the workshop as the current scheduling scheme until the workpiece processing is completed.
The dynamic scheduling process effectively solves the impact of emergency order insertion on production. Moreover, in order to meet the constraints, the new scheduling scheme can be reasonably connected with the original scheduling scheme to optimize the scheduling objectives.
6. Example Verification
Taking the actual production of an enterprise as an example, the initial order is to process seven kinds of workpieces; the batch of each kind of workpiece is shown in
Table 1, the information related to part processing is shown in
Table 2, and the processing time unit of workpieces is an hour (h). It is realized on the 64-bit operating system of Windows 10 using MATLAB R2019b.
According to the above workpiece processing information, the Gantt chart of the initial scheduling scheme is generated, and the results are shown in
Figure 7. The Y-axis represents the equipment and the X-axis represents the processing time. The number in the figure has a specific meaning. For example, 5-1 indicates that the first process of the fifth workpiece is processed on Machine 1.
This paper studies the dynamic rescheduling of machined parts in the case of rush order insertion. Rush order 8 is received at time T = 2. The processing time for the workpieces is shown in
Table 3, and the processing quantity of the workpieces is shown in
Table 4. The status of the workpiece being processed during order insertion is shown in
Table 5.
When there is a rush order, the system reschedules the workpiece. The processing time of each process related to the received rush order is shown in
Table 3, and the processing status of the workpiece on each machine is checked through the monitoring system, as shown in
Table 5. The workpiece being processed continues to be processed on the current machine, and the remaining workpieces to be processed and the workpieces of the rush order are rescheduled for production; the processing time is imported into the genetic algorithm. After continuous iteration, mutation, and crossover of the population, the optimal solution is found. The final scheduling result is shown in
Figure 8, and the maximum completion time is 22 h.
In the traditional flexible job shop, if there is a rush order in the factory, the production is arranged manually, and the results of manual scheduling vary from person to person. According to the previous manual scheduling results, the shortest processing time is taken, and the results are shown in
Figure 9. The Y-axis represents the equipment and the X-axis represents the processing time. The maximum completion time is 35 h. It is concluded that the completion time is 13 h ahead of schedule. In small batch production, a genetic algorithm is used to schedule production, and the efficiency is improved by about 35%.
7. Conclusions
This paper combines the concept of intelligent manufacturing with a flexible job shop and makes full use of workshop information and data so that the upper application system can timely and reasonably schedule workshop resources, improve the utilization rate of machines, and ensure the efficient operation of the workshop. Finally, the Gantt chart of the rush order insertion dynamic scheduling is obtained through a genetic algorithm. Compared with the completion time of the manual scheduling scheme, the production efficiency is improved by 35% in the case of small-batch production. The results show that the combination of the flexible job shop and intelligent manufacturing has afforded a definite advantage in rush order insertion dynamic scheduling.