Distributed flexible heterogeneous job shop system modeling and scheduling method
Through the combination of Markov method and improved genetic algorithm, the problem of transient performance prediction and scheduling of heterogeneous production lines in distributed flexible job shop system is solved, and efficient scheduling and energy saving of small batch production tasks are achieved.
Patent Information
- Application Number
- CN202410714561.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-04
- Publication Date
- 2024-09-24
AI Technical Summary
Existing distributed flexible job shop system modeling is difficult to effectively handle heterogeneous production lines composed of unreliable machines and limited buffers, resulting in deviations in production task completion time predictions and affecting the effectiveness of scheduling strategies.
The Markov method is used to analyze the transient performance, combined with the improved genetic algorithm to design the chromosome integer encoding rules, and optimize the scheduling plan to minimize the maximum completion time and improve production efficiency and energy utilization efficiency.
It achieves accurate transient performance prediction of heterogeneous production lines and efficient scheduling of small batch production tasks, improving workshop production efficiency and energy saving effects.
Smart Images

Figure CN118691007A
Abstract
Description
Technical Field
[0001] The invention belongs to the field of production scheduling, and in particular relates to a distributed flexible heterogeneous job shop system modeling and a scheduling method thereof. Background Art
[0002] Since the 1950s, the job shop problem has attracted the attention of academia and industry due to its wide application background in the manufacturing industry. It is one of the most important problems in production planning of modern manufacturing systems. With the introduction of flexible manufacturing systems and the development trend of economic globalization, the distributed flexible job shop problem has become a research hotspot in the field of operations research and production scheduling. However, most of the current system modeling of distributed flexible job shops has the problem of simplifying the actual production scenario. On the one hand, the production unit that actually handles the task process may be composed of unreliable machines and limited buffers. Flexible production lines with different topological structures sometimes cannot be simplified to the machines in the traditional job shop problem for analysis; on the other hand, under the background of customized and small batch production, the production unit mostly runs in a transient state, and the completion time predicted based on steady-state analysis may have a large deviation from the actual production. The above problems have not been fully studied in the distributed flexible job shop scheduling problem, which may affect the effectiveness of the shop scheduling strategy under the actual production background. Summary of the invention
[0003] One of the main purposes of the present invention is to provide a distributed flexible heterogeneous job shop system modeling method. For heterogeneous production lines composed of Bernoulli machines that can produce random failures and finite buffers, the transient performance is analyzed by the Markov method to predict the completion time of batch processes under small batch production. Considering the production constraints of the distributed flexible heterogeneous job shop and the introduction of heterogeneous production lines, a distributed flexible heterogeneous job shop system model is established. The scheduling goal of the distributed flexible heterogeneous job shop system model is to minimize the maximum completion time of the system. The distributed flexible heterogeneous job shop system model is used to schedule small batch and multi-batch production tasks to improve the production efficiency of the workshop.
[0004] The second main purpose of the present invention is to provide a production scheduling method for a distributed flexible heterogeneous job shop system based on the modeling method of the distributed flexible heterogeneous job shop system. Based on the improved genetic algorithm, chromosome integer encoding and decoding rules for the distributed flexible heterogeneous job shop problem are designed to ensure that the randomly generated individuals become effective scheduling schemes that meet the production constraints after decoding; genetic operators including selection, crossover, and mutation are designed to optimize and iterate the population to ensure the effectiveness of individuals in the updating and iterative process and improve the population quality in the optimization algorithm; the best individuals in the populations of all generations are selected, decoded to form a scheduling scheme, and the distributed flexible heterogeneous job shop system scheduling is realized, the maximum completion time of the system is minimized, the workshop production efficiency is improved, and production energy is saved.
[0005] The object of the present invention is achieved through the following technical solutions.
[0006] The present invention discloses a distributed flexible heterogeneous job shop system modeling method, which predicts transient performance of production lines with different topological structures composed of Bernoulli machines and finite buffers, and calculates the batch completion time of the above production lines under transient working conditions. Based on the distributed flexible job shop system model and constraints, the influence of single machine, serial, and assembly production lines on system production scheduling is analyzed, and production constraints of heterogeneous production lines on system scheduling are added to establish a distributed flexible heterogeneous job shop system model. The scheduling goal of the distributed flexible heterogeneous job shop system model is to minimize the maximum completion time of the system. The distributed flexible heterogeneous job shop system model is used to schedule small batch and multi-batch production tasks.
[0007] The present invention discloses a production scheduling method for a distributed flexible heterogeneous job shop system. Based on a distributed flexible heterogeneous job shop system modeling method, the improved genetic algorithm is used to design four-chromosome integer encoding and decoding rules for the distributed flexible heterogeneous job shop, so as to ensure that the randomly generated individuals correspond to effective scheduling schemes; the improved genetic algorithm is used to design genetic operators including selection, crossover, and mutation operations, so as to schedule and arrange production for the processing procedures, ensure the effectiveness of each individual in the population during the updating and iterative process, and improve the population quality in the optimization algorithm. The optimal individuals in the populations of all generations are selected, and the scheduling scheme is formed by decoding. The optimal scheduling scheme formed by decoding is used to realize the scheduling of the distributed flexible heterogeneous job shop system, minimize the maximum completion time of the system, improve the production efficiency of the workshop, and save production energy.
[0008] A distributed flexible heterogeneous job shop system modeling method disclosed in the present invention comprises the following steps:
[0009] Step 1: System modeling of heterogeneous production lines; heterogeneous production lines are flexible production lines with different topological structures composed of Bernoulli machines and finite buffers; the system modeling of the heterogeneous production module mainly includes: system parameters, system status, and system topological structure; system parameters include production line processing cycle, Bernoulli machine processing efficiency, and finite buffer capacity; system status represents the operation status of the heterogeneous production line, the starvation status of the Bernoulli machine, and the blocking status of the Bernoulli machine;
[0010] Step 1.1: Determine the heterogeneous production line topology;
[0011] The heterogeneous production lines considered in the distributed flexible heterogeneous job shop system model have the following three topological structures: a single-machine production line consisting of 1 Bernoulli machine; a serial production line consisting of 2 Bernoulli machines and 1 finite buffer; an assembly production line consisting of 3 Bernoulli machines and 2 finite buffers; the above three heterogeneous production lines are referred to as single-machine line, serial line and assembly line respectively.
[0012] Step 1.2: Determine the processing cycle of the workpiece;
[0013] The workpiece refers to the raw materials required in small batch production or the workpiece to be processed in the finished product batch; according to the heterogeneous production line system model and actual working conditions, the workpiece processing cycle τ is defined h,i,j,k :Heterogeneous production line M h , Production Task J i , Raw material or work in progress batch B ij , Process The processing cycle of a unit workpiece is τ; the downtime of all Bernoulli machines in the production line due to processing failure is approximately equal to the workpiece processing cycle τ h,i,j,k Under the assumption that the workpiece processing cycle τ h,i,j,k Segment the time axis into units;
[0014] Step 1.3: Determine the efficiency of the Bernoulli machine.
[0015] The machines m that constitute the heterogeneous production line in the distributed flexible heterogeneous job shop system model h,i,j,k,l , Considering random failures, the Bernoulli distribution is satisfied when processing workpieces; according to the heterogeneous production line system model and actual working conditions, the Bernoulli machine efficiency p of the heterogeneous production line is defined h,i,j,k,l :M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process When the Bernoulli machine m h,i,j,k,l The probability of successfully machining a workpiece; in particular, m h,i,j,k,U represents the most downstream Bernoulli machine in a heterogeneous production line;
[0016] Step 1.4: Determine the finite buffer capacity;
[0017] Buffer b constituting heterogeneous production lines in the distributed flexible heterogeneous job shop system model h,i,j,k,m , Its WIP storage capacity is limited; according to the heterogeneous production line system model and actual working conditions, the limited buffer capacity N of the heterogeneous production line is defined h,i,j,k,m :M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process Time-limited buffer b h,i,j,k,m Maximum storage capacity of work in process;
[0018] Step 1.5: Determine the operating status of the heterogeneous production line;
[0019] The system state of the heterogeneous production line is composed of the working states s of all Bernoulli machines in the current production line h,i,j,k,l , Characterization; Based on the heterogeneous production line system model and actual working conditions, define the working state s of the Bernoulli machine of the heterogeneous production line h,i,j,k,l :M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process It is a binary variable indicating whether the Bernoulli machine is working or stopping in the current workpiece processing cycle;
[0020] Step 1.6: Determine the starvation state of the Bernoulli machine;
[0021] In heterogeneous production line M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process At the beginning of a workpiece processing cycle, if the Bernoulli machine m h,i,j,k,l , If there is no work-in-progress in its upstream buffer, the machine cannot process in the current processing cycle due to starvation; the upstream machine m of the heterogeneous production line h,i,j,k,1 Will not be in a state of hunger;
[0022] Step 1.7: Determine the blocking state of the Bernoulli machine;
[0023] In heterogeneous production line M h , Production Task J i , Required raw material work-in-progress batch B ij , Process At the beginning of a workpiece processing cycle, if the Bernoulli machine m h,i,j,k,l , If there is no WIP in its downstream buffer and its downstream machine is shut down, the machine will be unable to process at the beginning of the current processing cycle due to blockage; the downstream machine m of the heterogeneous production line h,i,j,k,U It will not be in a blocked state;
[0024] Step 2: According to the system model of the heterogeneous production line established in step 1, a distributed flexible heterogeneous workshop is system-modeled to obtain a distributed flexible heterogeneous workshop system model; the distributed flexible heterogeneous workshop system model is composed of a plurality of workshops with flexible heterogeneous production lines, and the distributed flexible heterogeneous workshop system model mainly includes: system parameters, production constraints, workshop production line structure; system parameters include the number of workshops and the number of heterogeneous production lines in the workshop; production constraints include workshop scheduling constraints and process scheduling constraints;
[0025] Step 2.1: Determine system parameters;
[0026] Determine the number of workshops F included in the distributed flexible heterogeneous job shop system model, and each workshop is numbered Each workshop contains f heterogeneous production lines. p ;
[0027] Step 2.2: Determine production constraints;
[0028] The production constraints of the distributed flexible heterogeneous job shop system model mainly include the scheduling constraints of production tasks between and within workshops: the scheduling constraints between workshops restrict that the workpiece processing of all processes of raw materials or work-in-progress required for the same task must be in the same workshop, and the workpiece processing of all processes of raw materials or work-in-progress required for the same task will be referred to as workpiece processing; the scheduling constraints within the workshop restrict that workpiece processing cannot be preempted before completion, and stipulate the order of processing of the same task process, and process processing can only be carried out on production lines with specific topological structures;
[0029] Step 2.3: Determine the topological structure of the heterogeneous production lines in each workshop in the distributed flexible heterogeneous job shop system model to obtain the distributed flexible heterogeneous job shop system model;
[0030] Step 3: Based on the heterogeneous production line system model constructed in step 1 and the actual distributed flexible heterogeneous job shop system model working conditions, define the heterogeneous production line system state, which is referred to as the state below; the state is characterized by the number of workpieces in the current batch processed by the Bernoulli machine in the heterogeneous production line and the number of work-in-progress in the finite buffer;
[0031] Step 3.1: Consider the single-machine line in the distributed flexible heterogeneous job shop system model. Its state is represented by the number of workpieces processed in the current workpiece processing cycle n, f(n). The total number of system states Q i,j =B i,j +1, System Status Where X i (n) represents the probability that the single machine line is in state i in the current workpiece processing cycle n;
[0032] Step 3.2: Consider the serial line of the distributed flexible heterogeneous job shop system model. Its state is represented by the number of work-in-progress in the buffer h(n) and the number of work-in-progress processed by the downstream machine f(b) at the current work-in-progress processing cycle n. The total number of system states Q i,j =(B i,j +1)(N h,i,j,k +1), system status Where X i (n) represents the probability that the serial line is in state i in the current workpiece processing cycle n, and the mapping relationship between state i and h(n) and f(n) for:
[0033] i=h(n)(B i,j +1)+f(n)+1;
[0034] Step 3.3: Consider the assembly line in the distributed flexible heterogeneous job shop system model. Its state is represented by the number of work-in-progress in the buffer h1(n), h2(n) and the number of work-in-progress processed by the downstream machine f(n) at the current work-in-progress cycle n. The total number of system states Q i,j =(B i,j +1)(N h,i,j,k,1 +1)(N h,i,j,k,2 +1), system status Where X i (n) represents the probability that the assembly line is in state i in the current workpiece processing cycle n. The mapping relationship λ between state i and h1(n), h2(n), and f(n) is:
[0035] i=(N h,i,j,k,2 +1)(B i,j +1)h1(n)+(B i,j +1)h2(n)+f(n)+1;
[0036] Step 4: Based on the state definition and system characteristics in step 2, define the state transfer matrix and use the Markov method to predict transient performance;
[0037] Step 4.1: Define the serial line state transition matrix A Ser , matrix A Ser Element A in ij represents the probability of the system transitioning from state j to state i; based on the serial line running state s h,i,j,k,l , when h(n)+f(n) ij When h(n+1)=h(n)-s h,i,j,k,2 *ω(n)+s h,i,j,k,1 *min(N h,i,j,k -h(n)+s h,i,j,k,2 *(ω(n)), 1), f(n+1)=f(n)+s h,i,j,k,2 *ω(n),
[0038] Where ω(n) = min(1, h(n));
[0039] When h(n)+f(n)=B ij When h(n)≠0,
[0040]
[0041] When h(n)+f(n)=B ij When h(n)=0,
[0042]
[0043] Step 4.2: Define the assembly line state transition matrix A Ass , matrix A Ass Element A in ij represents the probability of the system transitioning from state j to state i; based on the assembly line operation state s h,i,j,k,l , when h(n)+f(n) ij hour,
[0044] h1(n+1)=h1(n)-s h,i,j,k,3 *ω(n)+s h,i,j,k,1 *min(N h,i,j,k,1 -h1(n)+s h,i,j,k,3 *(ω(n)), 1),
[0045] h2(n+1)=h2(n)-s h,i,j,k,3 *ω(n)+s h,i,j,k,2 *min(N h,i,j,k,2 -h2(n)+sh,i,j,k,3 *(ω(n)), 1),
[0046] f(n+1)=f(n)+s h,i,j,k,3 *ω(n),
[0047] Where ω(n) = min(1, h1(n), h2(n));
[0048] When h1(n)+f(n)=B ij ,h2(n)+f(n) ij When h2(n)>0,
[0049] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,2 )(1-p h,i,j,k,3 ),
[0050] A Ass (λ(h1(n), h2(n)+1, f(n)), λ(h1(n), h2(n), f(n)))=p h,i,j,k,2 (1-p h,i,j,k,3 ),
[0051] A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,2 )*p h,i,j,k,3 ,
[0052] A Ass (λ(h1(n)-1, h2(n), f(n)+1), λ(h1(n), h2(n), f(n)))=p h,i,j,k,2 *p h,i,j,k,3 ;
[0053] When h1(n)+f(n)=B ij ,h2(n)+f(n) ij When h2(n)=0,
[0054] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=1-p h,i,j,k,2 ,
[0055] A Ass (λ(h1(n), h2(n)+1, f(n)), λ(h1(n), h2(n), f(n)))=p h,i,j,k,2 ;
[0056] When h1(n)+f(n) ij , h2(n)+f(n)=B ij and 0 h,i,j,k,1 hour,
[0057] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,1 )(1-p h,i,j,k,3 ),
[0058] A Ass (λ(h1(n)+1, h2(n), f(n)), λ(h1(n), h2(n), f(n)))=p h,i,j,k,1 (1-p h,i,j,k,3 ),
[0059] A Ass (λ(h1(n)+1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n)))=p h,i,j,k,1 *p h,i,j,k,3 ,
[0060] A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,1 )*p h,i,j,k,3 ;
[0061] When h1(n)+f(n) ij , h2(n)+f(n)=B ij And h1(n)=N h,i,j,k,1 hour,
[0062] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=1-p h,i,j,k,3 ,
[0063] A Ass (λ(h1(n), h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n)))=p h,i,j,k,1 *p h,i,j,k,3 ,
[0064] A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,1 )*p h,i,j,k,3 ;
[0065] When h1(n)+f(n) ij , h2(n)+f(n)=B ij And h1(n)=0,
[0066] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=1-p h,i,j,k,1 ,
[0067] A Ass (λ(h1(n)+1, h2(n), f(n)), λ(h1(n), h2(n), f(n)))=p h,i,j,k,1 ;
[0068] When h1(n)+f(n)=B ij , h2(n)+f(n)=B ij And h1(n)=0,
[0069] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=1;
[0070] When h1(n)+f(n)=B ij , h2(n)+f(n)=B ij And h1(n)≠0,
[0071] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=1-p h,i,j,k,0 ,
[0072] A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n)))=p h,i,j,k,0 ;
[0073] Step 5: Define transient performance indicators - batch completion time CT based on heterogeneous production line system model and actual working conditions h,i,j,k :Heterogeneous production line M h , Completed Mission J i , Raw material or work in progress batch B ij , Process Time expectation for raw material or work in progress batch B ij and process O ijk The index j is 0, which indicates the batch and process of the WIP after the assembly line completes the assembly process;
[0074] Step 5.1: Calculate M for the single machine line considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =B ij / p h,i,j,k *τ h,i,j,k ;
[0075] Step 5.2: According to the serial line state transfer matrix A obtained in step 4.2 Ser Update system status: X(n+1)=A Ser X(n);
[0076] Step 5.3: Calculate M for the serial lines considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =V Ser *X(n)*τ h,i,j,k , where the vector V Ser =1*Q i,j dimensional vector; The rest of the elements are 0;
[0077] Step 5.4: According to the assembly line state transfer matrix A obtained in step 4.5 Ass Update system status: X(n+1)=A Ass X(n);
[0078] Step 5.5: Calculate M for the assembly line considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =V Ass *X(n)*τ h,i,j,k , where the vector V Ass =1*Q i,j dimensional vector; V Ass (1,λ(1,1,B i,j -1))=1, and the rest of the elements are 0;
[0079] Step 6: Design and improve the chromosome encoding method of the genetic algorithm individuals. The genes in the chromosomes are encoded with integers. The gene encoding must meet the production constraints of the distributed flexible heterogeneous job shop system model in step 2, ensuring that the encoding generated by random initialization can generate an optimized scheduling solution that meets the production constraints of the distributed flexible heterogeneous job shop system model;
[0080] Step 6.1: Let Num_Operation be the sum of the number of operations of all tasks in the distributed flexible heterogeneous job shop system model; generate a non-divided chromosome OS with a chromosome length of Num_Operation; the genes in the chromosome OS are composed of elements 1, 2, ..., N, representing the order of the operations;
[0081] Step 6.2: Generate an undivided chromosome BS with a chromosome length of Num_Operation; at chromosome OS gene i, The corresponding position of the random integer gene j, Indicates the batch order; the premise for chromosome BS to randomly generate gene j is to meet the production task J i Required raw material batch B ij Processing sequence requirements; Indicates the batch index of the raw materials required for the task to be processed, j=0 indicates the batch index of the raw materials required for the task to be assembled or assembled;
[0082] Step 6.3: Generate a segmented chromosome FA with a chromosome length of Num_Operation; the gene p in chromosome FA is composed of randomly generated integers between 1 and F, representing the workshop assignment; according to task J i Segment chromosome FA, J i The corresponding chromosome length is to complete the task J i Required process O ijk The number of chromosomes FA randomly generates genes p on the premise that they correspond to workshop f p Able to meet production tasks i Required raw material batch B ij All processing steps O ijk ;
[0083] Step 6.4: Generate a chromosome MA with a chromosome length of Num_Operation; randomly generate an integer gene q at the corresponding position of the chromosome FA gene p, Indicates production line assignment; according to task J i Segment chromosome FA, J i The corresponding chromosome length is to complete the task J i Required process O ijkThe number of chromosomes MA randomly generates gene q on the premise that the corresponding production line M h Can meet the current processing steps O ijk ;
[0084] Step 6.5: Determine the processing sequence according to the integer encoding method specified in steps 6.1 and 6.2; gene i in chromosome OS and gene j in chromosome BS determine the current processing batch B ij ; The number of repetitions k of gene i in chromosome OS determines the current processing step O ijk ; The location of the gene in the chromosome determines the processing order of the Num_Operation process in the distributed flexible heterogeneous job shop system model;
[0085] Step 6.6: Determine the processing line assigned to the process according to the integer encoding method specified in Step 6.3 and Step 6.4; the position of the above chromosome gene pair represents the current processing process O ijk , in ascending order of k, j, i; gene p in chromosome FA and gene q in chromosome MA determine the current processing step O ijk Assigned workshops and production lines;
[0086] Step 7: Decode the chromosomes of the individuals randomly initialized in step 6, obtain the production tasks and processing sequence of each heterogeneous production line, analyze the production conditions of each workshop and production line under the corresponding scheduling scheme, and calculate the fitness value of the individuals; the fitness value is defined as the maximum completion time of the distributed flexible heterogeneous workshop system model; use the production tasks and processing sequence corresponding to the maximum completion time to schedule small batch and multi-batch production tasks;
[0087] Step 7.1: According to the decoding of the processing line assigned to the process in step 6.6, determine the processing process of the production line. The production scheduling of the processes in the production line must comply with the process processing sequence determined in step 6.5;
[0088] Step 7.2: Initialize the current maximum completion time Makespan_M of all heterogeneous production lines h ; Initialize the start time of all process operations OperationStartTime_O ijk and the processing end time OperationEndTime_O ijk ;
[0089] Step 7.3: For production line M h Production Task J i Required raw material batch B ij Process O without pre-processing requirements ijk, the processing start time of this process is updated to Makespan_M h , processing machine M h The current maximum completion time is updated to The processing start time of this process is updated to Makespan_M h ;
[0090] Step 7.4: For production line M h Production Task J i Required raw material batch B ij Process O with pre-process processing requirements ijk , let its preceding process be The processing start time of this process is updated to Processing Machine h The current maximum completion time is updated to The processing start time of this process is updated to Makespan_M h ;
[0091] Step 7.5: Calculate the decoded individual fitness value, which corresponds to the maximum completion time of the distributed flexible heterogeneous job shop system model Use the production tasks and processing sequences corresponding to the maximum completion time to schedule small batch and multi-batch production tasks.
[0092] The present invention also discloses a production scheduling method for a distributed flexible heterogeneous job shop system, which is implemented based on a distributed flexible heterogeneous job shop system modeling method, including steps 1 to 7 of a distributed flexible heterogeneous job shop system modeling method, and also includes the following steps:
[0093] Step 8: Initialize the improved genetic algorithm hyperparameters; assign values to the population size, crossover probability, mutation probability, and maximum number of iterations of the distributed flexible heterogeneous job shop system model scheduling scheme during the improved genetic algorithm optimization iteration process; initialize the improved genetic algorithm population;
[0094] Specifically, the population size of the distributed flexible heterogeneous job shop system model scheduling scheme is set to Pop_Size, the crossover probability is set to Pro_Crossover, the mutation probability is set to Pro_Mutation, and the maximum number of iterations is set to Max_Gen; the population of Pop_Size is initialized according to the encoding method in step 6;
[0095] Step 9: Design the selection operator in the improved genetic algorithm, perform selection operations on the current population in the improved genetic algorithm, and retain the excellent individuals in the current population; use elite selection and the method of randomly generating individuals described in step 6 to generate a parent population of Pop_Size; use tournament selection and the method of randomly generating individuals described in step 6 to generate a parent population of Pop_Size;
[0096] In the selection operation, the elite selection of the parent generation refers to a certain number of individuals with lower fitness values from the current population entering the parent population; the tournament selection of the mother generation refers to randomly selecting a certain number of individuals from the current population to compare fitness values, and the individuals with the lowest fitness values enter the mother population;
[0097] Step 9.1: Set the elite selection rate to Elitist_Rate, and select Elitist_Rate*Pop_Size individuals with the smallest fitness from the current population to enter the parent population;
[0098] Step 9.2: Generate Pop_Size*(1-Elitist_Rate) individuals using the random generation method described in step 6;
[0099] Step 9.3: Shuffle the individuals in step 9.1 and step 9.2 to form a parent population;
[0100] Step 9.4: Set the tournament size to Tournament_Size and the number of tournament rounds to Tournament_Round, randomly select Tournament_Size individuals from the current population to compare fitness values, and select the individual with the smallest fitness value; repeat Tournament_Round times, and finally Tournament_Round individuals enter the parent population;
[0101] Step 9.5: Generate Pop_Size-Tournament_Round=50 individuals using the method of randomly generating individuals described in step 6;
[0102] Step 9.6: Shuffle the individuals in step 9.4 and step 9.5 to form a parent population;
[0103] Step 10: Design a crossover operator in the improved genetic algorithm, perform a crossover operation on the parent and maternal populations in the improved genetic algorithm, and explore the solution space; select some chromosome genes of individuals in the maternal population to replace some chromosome genes of individuals in the parent chromosome; the improved genetic algorithm includes two crossover operations: a crossover operation based on OS and BS gene pairs and a crossover operation based on MA and FA gene pairs; form a progeny population;
[0104] Step 10.1: Generate a random number R between 0 and 1. If the random number R satisfies R < Pro_Crossover, proceed to Steps 10.2 to 10.6; otherwise, jump to Step 10.7;
[0105] Step 10.2: Randomly generate a random integer Num_JobChange between 0 and N, where i is the number of tasks completed by the distributed flexible heterogeneous job shop system model; randomly generate Num_JobChange non-repeating random integers between 0 and N to form the operation crossover set JobChange of chromosome OS, JobChange = {JobChange1, JobChange2,..., JobChange Num_JobChange};
[0106] Step 10.3: Delete the genes in chromosome OS of the parental individual that contain elements in the operation crossover set {JobChange1, JobChange2,..., JobChange Num_JobChange} and the corresponding genes at the same positions in chromosome BS;
[0107] Step 10.4: Sequentially extract the genes in chromosome OS of the corresponding maternal individual that contain elements in the operation crossover set {JobChange1, JobChange2,..., JobChange Num_JobChange} and the corresponding genes at the same positions in chromosome BS, and copy them to the missing parts of chromosome OS and BS of the parental individual in the original gene pair order of the maternal individual;
[0108] Step 10.5: Randomly select a crossover point Crossover_Point in the split chromosomes FA and MA of the parental individual, and delete the gene pairs of FA and MA on the right side of Crossover_Point in the parental individual; extract the gene pairs of FA and MA on the right side of Crossover_Point in the corresponding maternal individual, and copy them to the missing parts of chromosomes FA and MA of the parental individual;
[0109] Step 10.6: Use the parental individual after the above crossover operation as an individual in the offspring;
[0110] Step 10.7: Compare the fitness values of the corresponding individuals of the parental and maternal generations, and select the individual with the smaller fitness value as an individual in the offspring;
[0111] Step 11: Design a mutation operator in the improved genetic algorithm to perform mutation operations on the offspring population of the improved genetic algorithm to explore the solution space; change the assigned workshops and machines of some operations in the offspring individuals based on the mutation operations of the MA and FA gene pairs; randomly generate chromosomes FA and MA again according to the methods in Steps 6.5 and 6.6;
[0112] Step 11.1: Generate a random number R between 0 and 1. If the random number R satisfies R < Pro_Mutation, proceed to Step 11.2; otherwise, jump to Step 12;
[0113] Step 11.2: According to the methods in Step 6.3 and Step 6.4, randomly generate the chromosomes FA and MA of the offspring again to enable the offspring individuals that perform the mutation operation to generate new workshop and production line assignment plans;
[0114] Step 12: Repeat the operations in Step 9 to Step 11. Through the cooperation of the selection operator, crossover operator, and mutation operator, improve the balance between exploring the solution space and utilizing its own information during the population update and iteration of the genetic algorithm; obtain the individual with the lowest fitness value from历次iterations; decode the individual, draw a Gantt chart, and obtain the optimized scheduling plan obtained by the improved genetic algorithm. Improve the workshop production efficiency and save production energy according to the optimized scheduling plan;
[0115] Step 12.1: Take the offspring population after performing the mutation operation in the improved genetic algorithm as the current population, and calculate the fitness values of the individuals in the current population according to the method in Step 7 to select the optimal individual;
[0116] Step 12.2: Update the current iteration number Now_Gen; record the chromosome of the optimal individual in the current population as Best_Now, its fitness value as Fit_Now, the chromosome of the optimal individual in历次iterations as Best_His, and its fitness value as Fit_His; if Fit_Now < Fit_His, then let Fit_His = Fit_Now and Best_His = Best_Now;
[0117] Step 12.3: Repeat Step 9 to Step 12.2 until Now_Gen = Max_Gen;
[0118] Step 12.4: Decode Fit_His according to Step 7 and draw a Gantt chart; the horizontal axis of the Gantt chart is the processing time, and the vertical axis is the production line number; the scheduling plan corresponding to Fit_His after decoding is the optimal scheduling plan obtained by the improved genetic algorithm. Use the optimal scheduling plan formed by decoding to implement the scheduling of the distributed flexible heterogeneous job shop system, minimize the makespan of the system, improve the workshop production efficiency, and save production energy.
[0119] Beneficial effects:
[0120] 1. The present invention discloses a distributed flexible heterogeneous job shop system modeling and scheduling method, analyzes the impact of single-machine, serial, and assembly production lines on the production scheduling of the distributed flexible heterogeneous job shop system model, adds production constraints of heterogeneous production lines on system scheduling, establishes a distributed flexible heterogeneous job shop system model, schedules small batch and multi-batch production tasks, and improves the effectiveness of the job shop model in actual manufacturing production scheduling.
[0121] 2. The present invention discloses a distributed flexible heterogeneous job shop system modeling and scheduling method. Aiming at the distributed flexible heterogeneous job shop system model, four-chromosome integer encoding and decoding rules are designed to meet the production constraints of the distributed flexible heterogeneous job shop system model. The four-chromosome integer encoding and decoding rules are used to ensure the effectiveness of initialization of individuals and improve the quality of the initial population, thereby improving the optimization scheduling efficiency of the improved genetic algorithm for the distributed flexible heterogeneous job shop system model.
[0122] 3. The present invention discloses a distributed flexible heterogeneous job shop system modeling and scheduling method. In the improved genetic algorithm, a genetic algorithm operator including selection operation, crossover operation and mutation operation is designed. The excellent individuals of the current population are retained based on the selection operator, and the solution space is explored based on the crossover operator and mutation operator. Through the coordination of the selection operator, crossover operator and mutation operator, the improved genetic algorithm takes into account the balance between the exploration of the solution space and the use of its own information in the process of population update and iteration, and the formed optimization scheduling strategy minimizes the maximum completion time of the distributed flexible heterogeneous job shop system model under the current production constraints and production conditions, thereby improving the workshop production efficiency and saving production energy. BRIEF DESCRIPTION OF THE DRAWINGS
[0123] Figure 1 It is a modeling flow chart of the distributed flexible heterogeneous job shop system of the present invention.
[0124] Figure 2 It is the flow chart of the improved genetic algorithm of the present invention.
[0125] Figure 3 It is a schematic diagram of a single-machine production line of the present invention.
[0126] Figure 4 It is a schematic diagram of a serial production line of the present invention.
[0127] Figure 5 It is a schematic diagram of an assembly production line of the present invention.
[0128] Figure 6It is an example diagram of the distributed flexible heterogeneous job workshop system of the present invention, which reflects the production conditions, production tasks and production constraints of the distributed flexible heterogeneous job workshop system. The cells marked with "——" in the table indicate that the corresponding process cannot be processed on the corresponding production line, and the numbers indicate the time for the corresponding process to be processed on the corresponding production line.
[0129] Figure 7 It is a schematic diagram of chromosome integer encoding and decoding of the distributed flexible heterogeneous workshop of the present invention.
[0130] Figure 8 It is a schematic diagram of generating a parent population through an elite selection operation in the improved genetic algorithm of the present invention.
[0131] Fig. 9 It is a schematic diagram of generating a mother band population through a tournament selection operation in the improved genetic algorithm of the present invention.
[0132] Fig.10 It is a schematic diagram of the crossover operation on chromosomes OS and BS in the improved genetic algorithm of the present invention.
[0133] Fig.11 It is a schematic diagram of the crossover operation on chromosomes FA and MA in the improved genetic algorithm of the present invention.
[0134] Fig.12 It is a schematic diagram of the mutation operation on the chromosomes FA and MA in the improved genetic algorithm of the present invention.
[0135] Fig.13 It is a line graph of the optimal maximum completion time of a population under the improved genetic algorithm optimization iteration of the system example diagram of the present invention, the horizontal axis represents the number of iterations, and the vertical axis represents the maximum completion time of the optimal individual of the current population.
[0136] Fig.14 It is a Gantt chart of the optimal scheduling solution obtained by optimizing the system example diagram of the present invention through the improved genetic algorithm. The horizontal axis represents the processing time and the vertical axis represents the production line number. DETAILED DESCRIPTION
[0137] In order to better illustrate the purpose and advantages of the present invention, the invention is further described below with reference to the accompanying drawings and examples.
[0138] Embodiment 1:
[0139] and Figure 2 As shown, the distributed flexible heterogeneous job shop system modeling and scheduling method disclosed in this embodiment are specifically implemented in the following steps:
[0140] like Figure 1 As shown, the distributed flexible heterogeneous job shop system modeling method disclosed in this embodiment has the following specific implementation steps:
[0141] Step 1: System modeling of heterogeneous production lines; heterogeneous production lines are flexible production lines with different topological structures composed of Bernoulli machines and finite buffers; the system modeling of the heterogeneous production module mainly includes: system parameters, system status, and system topological structure; system parameters include production line processing cycle, Bernoulli machine processing efficiency, and finite buffer capacity; system status represents the operation status of the heterogeneous production line, the starvation status of the Bernoulli machine, and the blocking status of the Bernoulli machine;
[0142] Step 1.1: Determine the heterogeneous production line topology;
[0143] The heterogeneous production lines considered in the distributed flexible heterogeneous job shop system model have the following three topological structures: a single-machine production line consisting of 1 Bernoulli machine; a serial production line consisting of 2 Bernoulli machines and 1 finite buffer; an assembly production line consisting of 3 Bernoulli machines and 2 finite buffers; the above three heterogeneous production lines are referred to as single-machine line, serial line and assembly line respectively.
[0144] Step 1.2: Determine the processing cycle of the workpiece;
[0145] The workpiece refers to the raw materials required in small batch production or the workpiece to be processed in the finished product batch; according to the heterogeneous production line system model and actual working conditions, the workpiece processing cycle τ is defined h,i,j,k :Heterogeneous production line M h , Production Task J i , Raw material or work in progress batch B ij , Process The processing cycle of a unit workpiece is τ; the downtime of all Bernoulli machines in the production line due to processing failure is approximately equal to the workpiece processing cycle τ h,i,j,k Under the assumption that the workpiece processing cycle τ h,i,j,k Segment the time axis into units;
[0146] Figure 3 , 4 , 5 are three types of flexible production lines: stand-alone line, serial line and assembly line. h Production Task J i Required raw materials or work-in-progress batch B ij Process O ijk Schematic diagram;
[0147] In the subsequent calculation of completion time, for different heterogeneous production lines M h Production Task J i Required raw materials or work-in-progress batch B ij Process Oijk , τ h,i,j,k Randomly generated between 0.8-1.2, batch B ij is a random integer between 10 and 30; in particular, if B ij Production task J i In the case of processes that require assembly lines to complete, the number of workpieces from different raw material batches should be equal;
[0148] Step 1.3: Determine the efficiency of the Bernoulli machine.
[0149] The machines m that constitute the heterogeneous production line in the distributed flexible heterogeneous job shop system model h,i,j,k,l , Considering random failures, the Bernoulli distribution is satisfied when processing workpieces; according to the heterogeneous production line system model and actual working conditions, the Bernoulli machine efficiency p of the heterogeneous production line is defined h,i,j,k,l :M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process When the Bernoulli machine m h,i,j,k,l The probability of successfully machining a workpiece; in particular, m h,i,j,k,U represents the most downstream Bernoulli machine in a heterogeneous production line;
[0150] like Figure 3 As shown, the single machine line contains 1 Bernoulli machine m h,i,j,k , the capacity is denoted as p h,i,j,k ;
[0151] like Figure 4 As shown, the serial line contains two Bernoulli machines m h,i,j,k,1 , m h,i,j,k,2 , the machine efficiency is denoted as p h,i,j,k,1 , p h,i,j,k,2 ;
[0152] like Figure 5 As shown, the assembly line contains 3 Bernoulli machines m h,i,j,k,1 , m h,i,j,k,2 , m h,i,j,k,3 , the machine efficiency is denoted as p h,i,j,k,1 , p h,i,j,k,2 , p h,i,j,k,3 ;
[0153] For the Bernoulli machine mh in the above production line ,i,\,k,l Regardless of the topology of the production line, the machine efficiency p h,i,j,k,ι A random number between 0.7 and 0.9;
[0154] Step 1.4: Determine the finite buffer capacity;
[0155] Buffer b constituting heterogeneous production lines in the distributed flexible heterogeneous job shop system model h,i,j,k,m , Its WIP storage capacity is limited; according to the heterogeneous production line system model and actual working conditions, the limited buffer capacity N of the heterogeneous production line is defined h,i,j,k,m :M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process Time-limited buffer b h,i,j,k,m Maximum storage capacity of work in process;
[0156] like Figure 3 As shown, the single-machine line does not contain a finite buffer;
[0157] like Figure 4 As shown, the serial line contains a limited buffer b h,i,j,k , the capacity is recorded as N h,i,j,k ;
[0158] like Figure 5 As shown, the assembly line contains two limited buffers b h,i,j,k,1 , b h,i,j,k,2 , the capacity is recorded as N h,i,j,k,1 , N h,i,j,k,2 ;
[0159] For the finite buffer b in the above production line h,i,j,k,m Regardless of the topology of the production line, the machine efficiency N h,i,j,k,m A random integer between 2 and 5;
[0160] Step 1.5: Determine the operating status of the heterogeneous production line;
[0161] The system state of the heterogeneous production line is composed of the working states s of all Bernoulli machines in the current production line h,i,j,k,l , Characterization; Based on the heterogeneous production line system model and actual working conditions, define the working state s of the Bernoulli machine of the heterogeneous production line h,i,j,k,l :M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process It is a binary variable indicating whether the Bernoulli machine is working or stopping in the current workpiece processing cycle;
[0162] Step 1.6: Determine the starvation state of the Bernoulli machine;
[0163] In heterogeneous production line M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process At the beginning of a workpiece processing cycle, if the Bernoulli machine m h,i,j,k,l , If there is no work-in-progress in its upstream buffer, the machine cannot process in the current processing cycle due to starvation; in particular, the upstream machine m of the heterogeneous production line h,i,j,k,1 Will not be in a state of hunger;
[0164] Step 1.7: Determine the blocking state of the Bernoulli machine;
[0165] In heterogeneous production line M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process At the beginning of a workpiece processing cycle, if the Bernoulli machine m h,i,j,k,l , If there is no WIP in its downstream buffer and its downstream machine is shut down, the machine will be unable to process at the beginning of the current processing cycle due to blockage; in particular, the downstream machine m of the heterogeneous production line h,i,j,k,U It will not be in a blocked state;
[0166] like Figure 3 As shown, the single-machine line does not contain a finite buffer and does not consider the starvation and blocking states of the Bernoulli machine;
[0167] like Figure 4 As shown, the serial line contains a limited buffer b h,i,j,k , Bernoulli machine m h,i,j,k,1 Need blocking state, Bernoulli machine m h,i,j,k,2 Requires hunger state;
[0168] like Figure 5 As shown, the assembly line contains two limited buffers b h,i,j,k , Bernoulli machine m h,i,j,k,1 , m h,i,j,k,2 Need blocking state, Bernoulli machine m h,i,j,k,3 Requires hunger state;
[0169] Step 2: Based on the system model of the heterogeneous production line established in step 1, a distributed flexible heterogeneous workshop is system-modeled; to distinguish it from the heterogeneous production line system, the distributed flexible heterogeneous workshop system is referred to as the distributed flexible heterogeneous workshop system model below; the distributed flexible heterogeneous workshop system model consists of a plurality of workshops with flexible heterogeneous production lines, and its system modeling mainly includes: system parameters, production constraints, and workshop production line structure; system parameters include the number of workshops and the number of heterogeneous production lines in the workshop; production constraints include workshop scheduling constraints and process scheduling constraints;
[0170] Step 2.1: Determine system parameters;
[0171] Determine the number of workshops F included in the distributed flexible heterogeneous job shop system model, and each workshop is numbered Each workshop contains f heterogeneous production lines. p ;
[0172] Step 2.2: Determine production constraints;
[0173] The production constraints of the distributed flexible heterogeneous job shop system model mainly include the scheduling constraints of production tasks between and within workshops: the scheduling constraints between workshops restrict that the workpiece processing of all processes of raw materials or work-in-progress required for the same task must be in the same workshop, and the workpiece processing of all processes of raw materials or work-in-progress required for the same task will be referred to as workpiece processing; the scheduling constraints within the workshop restrict that workpiece processing cannot be preempted before completion, and stipulate the order of processing of the same task process, and process processing can only be carried out on production lines with specific topological structures;
[0174] Step 2.3: Determine the topological structure of the heterogeneous production lines in each workshop in the distributed flexible heterogeneous job shop system model;
[0175] According to step 1 and step 2, consider Figure 6 A production example of a distributed flexible heterogeneous workshop system model; where F = 2, M = 8, indicating that there are 2 workshops in the system and 8 heterogeneous production lines; workshop 1 contains stand-alone lines M1, M2, serial line M3, and assembly line M4, and workshop 2 contains stand-alone line M5, serial lines M6, M7, and assembly line M8; N = 5; taking production task J2 as an example, J2 requires two batches of raw material B 21 , B 22 , the process generates a batch of work-in-process B 20 ; J2 has 5 processes in total O 211 , O 221 , O 201 , O 202 , O203 ; Process O 211 and O 203 Can only be completed by a single machine line, process O 221 and O 202 Can only be completed by serial line processing, process O 201 It can only be processed by assembly line;
[0176] The production constraints of J2 mainly include: all five processes of J2 can only be processed in workshop 1 or workshop 2; before the current batch of raw materials or finished products are completed, the production line cannot be occupied by other processes; process O 201 The processing must be done in O 211 , O 221 After processing is completed, process O 202 The processing must be done in O 201 After processing is completed, process O 203 The processing must be done in O 202 After processing is completed;
[0177] The production requirements of the other four production tasks are the same as J2 and will not be repeated here;
[0178] like Figure 6 The distributed flexible heterogeneous job shop system model production instance includes system production conditions, production tasks and production constraints; if there is "——" in the table in the picture, it means the corresponding production task J i Raw materials or batch B in process ij Process O ijk Cannot be matched to production line M h Processing;
[0179] Step 3: Based on the heterogeneous production line system model constructed in step 1 and the actual distributed flexible heterogeneous job shop system model working conditions, define the heterogeneous production line system state, which is referred to as the state below; the state is characterized by the number of workpieces in the current batch processed by the Bernoulli machine in the heterogeneous production line and the number of work-in-progress in the finite buffer;
[0180] Step 3.1: Consider the single-machine line in the distributed flexible heterogeneous job shop system model. Its state is represented by the number of workpieces processed in the current workpiece processing cycle n, f(n). The total number of system states Q i,j =B i,j +1, System Status Where X i (n) represents the probability that the single machine line is in state i in the current workpiece processing cycle n;
[0181] Step 3.2: Consider the serial line of the distributed flexible heterogeneous job shop system model. Its state is represented by the number of work-in-progress in the buffer h(n) and the number of work-in-progress processed by the downstream machine f(n) at the current work-in-progress processing cycle n. The total number of system states Q i,j =(B i,j +1)(N h,i,j,k +1), system status Where X i (n) represents the probability that the serial line is in state i in the current workpiece processing cycle n, and the mapping relationship between state i and h(n) and f(n) for:
[0182] i=h(n)(B i,j +1)+f(n)+1;
[0183] Step 3.3: Consider the assembly line in the distributed flexible heterogeneous job shop system model. Its state is represented by the number of work-in-progress in the buffer h1(n), h2(n) and the number of work-in-progress processed by the downstream machine f(n) at the current work-in-progress cycle n. The total number of system states Q i,j =(B i,j +1)(N h,i,j,k,1 +1)(N h,i,j,k,2 +1), system status Where X i (n) represents the probability that the assembly line is in state i in the current workpiece processing cycle n. The mapping relationship λ between state i and h1(n), h2(n), and f(n) is:
[0184] i=(N h,i,j,k,2 +1)(B i,j +1)h1(n)+(B i,j +1)h2(n)+f(n)+1;
[0185] Step 4: Based on the state definition and system characteristics in step 2, define the state transfer matrix and use the Markov method to predict transient performance;
[0186] Step 4.1: Define the serial line state transition matrix A Ser , matrix A Ser Element A in ij represents the probability of the system transitioning from state j to state i; based on the serial line running state s h,i,j,k,l , when h(n)+f(n) ij hour,
[0187] h(n+1)=h(n)-s h,i,j,k,2 *ω(n)+s h,i,j,k,1 *min(N h,i,j,k -h(n)+sh,i,j,k,2 *(ω(n)), 1),
[0188] f(n+1)=f(n)+s h,i,j,k,2 *ω(n),
[0189] Where ω(n) = min(1, h(n));
[0190] When h(n)+f(n)=B ij When h(n)≠0,
[0191]
[0192] When h(n)+f(n)=B ij When h(n)=0,
[0193]
[0194] Step 4.2: Define the assembly line state transition matrix A Ass , matrix A Ass Element A in ij represents the probability of the system transitioning from state j to state i; based on the assembly line operation state s h,i,j,k,l , when h(n)+f(n) ij hour,
[0195] h1(n+1)=h1(n)-s h,i,j,k,3 *ω(n)+s h,i,j,k,1 *min(N h,i,j,k,1 -h1(n)+s h,i,j,k,3 *(ω(n)), 1),
[0196] h2(n+1)=h2(n)-s h,i,j,k,3 *ω(n)+s h,i,j,k,2 *min(N h,i,j,k,2 -h2(n)+s h,i,j,k,3 *(ω(n)), 1),
[0197] f(n+1)=f(n)+s h,i,j,k,3 *ω(n),
[0198] Where ω(n) = min(1, h1(n), h2(n));
[0199] When h1(n)+f(n)=B ij ,h2(n)+f(n) ij When h2(n)>0,
[0200] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,2 )(1-p h,i,j,k,3 ),
[0201] A Ass (λ(h1(n), h2(n)+1, f(n)), λ(h1(n), h2(n), f(n)))=p h,i,j,k,2 (1-p h,i,j,k,3 ),
[0202] A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,2 )*p h,i,j,k,3 ,
[0203] A Ass (λ(h1(n)-1, h2(n), f(n)+1), λ(h1(n), h2(n), f(n)))=p h,i,j,k,2 *p h,i,j,k,3 ;
[0204] When h1(n)+f(n)=B ij ,h2(n)+f(n) ij When h2(n)=0,
[0205] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=1-p h,i,j,k,2 ,
[0206] A Ass (λ(h1(n), h2(n)+1, f(n)), λ(h1(n), h2(n), f(n)))=p h,i,j,k,2 ;
[0207] When h1(n)+f(n) ij , h2(n)+f(n)=B ij and 0 h,i,j,k,1 hour,
[0208] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,1 )(1-p h,i,j,k,3 ),
[0209] A Ass (λ(h1(n)+1, h2(n), f(n)), λ(h1(n), h2(n), f(n))) = p h,i,j,k,1 (1 - p h,i,j,k,3 )
[0210] A Ass (λ(h1(n)+1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n))) = p h,i,j,k,1 *p h,i,j,k,3 ,
[0211] A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n))) = (1 - p h,i,j,k,1 )*p h,i,j,k,3 ;
[0212] When h1(n) + f(n) < B ij , h2(n) + f(n) = B ij and h1(n) = N h,i,j,k,1 then
[0213] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n))) = 1 - p h,i,j,k,3 ,
[0214] A Ass (λ(h1(n), h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n))) = p h,i,j,k,1 *p h,i,j,k,3 ,
[0215] A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n))) = (1 - p h,i,j,k,1 )*p h,i,j,k,3 ;
[0216] When h1(n) + f(n) < B ij , h2(n) + f(n) = B ij and h1(n) = 0,
[0217] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n))) = 1 - p h,i,j,k,1 ,
[0218] A Ass(λ(h1(n)+1, h2(n), f(n)), λ(h1(n), h2(n), f(n)))=p h,i,j,k,1 ;
[0219] When h1(n)+f(n)=B ij , h2(n)+f(n)=B ij And h1(n)=0,
[0220] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=1;
[0221] When h1(n)+f(n)=B ij , h2(n)+f(n)=B ij And h1(n)≠0,
[0222] A Ass (λ(h1(n), h2(n), f(n)), λ(h1(n), h2(n), f(n)))=1-p h,i,j,k,0 ,
[0223] A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1), λ(h1(n), h2(n), f(n)))=p h,i,j,k,0 ;
[0224] Step 5: Define transient performance indicators - batch completion time CT based on heterogeneous production line system model and actual working conditions h,i,j,k :Heterogeneous production line M h , Completed Mission J i , Raw material or work in progress batch B ij , Process time expectations; in particular, raw material or work-in-progress batch B ij and process O ijk The index j is 0, which indicates the batch and process of the work-in-progress after the assembly line completes the assembly process, which will not be described in detail below;
[0225] Step 5.1: Calculate M for the single machine line considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =B ij / p h,i,j,k *τ h,i,j,k ;
[0226] According to batch B in step 1 ij , Bernoulli machine efficiency p h,i,j,k,l and production line processing cycle τ h,i,j,k Random generation method, calculation Figure 6 The batch completion time of the single-machine line processing is involved. The completion time of a certain process of the single-machine line processing in the figure is the result of calculation and retaining one decimal place;
[0227] Step 5.2: According to the serial line state transfer matrix A obtained in step 4.2 Ser Update system status: X(n+1)=A Ser X(n);
[0228] Step 5.3: Calculate M for the serial lines considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =V Ser *X(n)*τ h,i,j,k , where the vector V Ser =1*Q i,j dimensional vector; The rest of the elements are 0;
[0229] According to batch B in step 1 ij , Bernoulli machine efficiency p h,i,j,k,l , finite buffer capacity N h,i,j,k,m and production line processing cycle τ h,i,j,k Random generation method, calculation Figure 6 The batch completion time of serial line processing is involved in the figure. The completion time of a certain process of serial line processing is the result of calculation and retaining one decimal place;
[0230] Step 5.4: According to the assembly line state transfer matrix A obtained in step 4.5 Ass Update system status: X(n+1)=A Ass X(n);
[0231] Step 5.5: Calculate M for the assembly line considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =V Ass *X(n)*τ h,i,j,k , where the vector V Ass =1*Qi,j dimensional vector; V Ass (1,λ(1,1,B i,j -1))=1, the rest of the elements are 0;
[0232] According to batch B in step 1 ij , Bernoulli machine efficiency p h,i,j,k,l , finite buffer capacity N h,i,j,k,m and production line processing cycle τ h,i,j,k Random generation method, calculation Figure 6 The batch completion time of the assembly line processing is involved. The completion time of a certain process of the assembly line processing in the figure is the result of calculation and retaining one decimal place;
[0233] Step 6: Design and improve the chromosome encoding method of the genetic algorithm individuals. The genes in the chromosomes are encoded with integers. The gene encoding must meet the production constraints of the distributed flexible heterogeneous job shop system model in step 2 to ensure that the encoding generated by random initialization can produce an effective optimization scheduling solution;
[0234] Step 6.1: Let Num_Operation be the sum of the number of operations of all tasks in the distributed flexible heterogeneous job shop system model; generate a non-divided chromosome OS with a chromosome length of Num_Operation; the genes in the chromosome OS are composed of elements 1, 2, ..., N, representing the order of the operations;
[0235] like Figure 7 As shown, taking production task J2 as an example, other production tasks are not described in detail; production task J2 includes a total of 5 processes: 211 , O 221 , O 201 , O 202 , O 203 , so gene 2 appears 5 times in chromosome OS, at positions 3, 4, 9, 10, and 12, and its position represents the processing order of these 5 steps in all 19 steps;
[0236] Step 6.2: Generate an undivided chromosome BS with a chromosome length of Num_Operation; at chromosome OS gene i, The corresponding position of the random integer gene j, Indicates the batch order; the premise for chromosome BS to randomly generate gene j is to meet the production task J i Required raw material batch B ij Processing sequence requirements; in particular, Indicates the batch index of the raw materials required for the task to be processed, j=0 indicates the batch index of the raw materials required for the task to be assembled or assembled;
[0237] like Figure 7 As shown, taking production task J2 as an example, other production tasks are not described in detail; considering that J2 contains assembly process O 201 , so the gene corresponding to the position 2 of the first 2 elements of chromosome OS in the chromosome BS sequence is randomly generated from 1 and 2, for example O 211 , O 221 There is no restriction on the order of processing; however, the gene corresponding to the position of the last 3 elements 2 of the chromosome OS in the chromosome BS sequence must be 0, for example, 201 Must be in O 211 , O 221 After completion, and in-process batch B 20 The process must be in accordance with O 201 , O 202 , O 203 in the order of;
[0238] Step 6.3: Generate a segmented chromosome FA with a chromosome length of Num_Operation; the gene p in chromosome FA is composed of randomly generated integers between 1 and F, representing the workshop assignment; according to task J i Segment chromosome FA, J i The corresponding chromosome length is to complete the task J i Required process O ijk The number of chromosomes FA randomly generates genes p on the premise that they correspond to workshop f p Able to meet production tasks i Required raw material batch B ij All processing steps O ijk ;
[0239] Step 6.4: Generate a chromosome MA with a chromosome length of Num_Operation; randomly generate an integer gene q at the corresponding position of the chromosome FA gene p, Indicates production line assignment; according to task J i Segment chromosome FA, J i The corresponding chromosome length is to complete the task J i Required process O ijk The number of chromosomes MA randomly generates gene q on the premise that the corresponding production line M h Can meet the current processing steps O ijk ;
[0240] like Figure 7As shown, taking production task J2 as an example, other production tasks will not be described in detail; the meaning of the chromosome MA position is the same as described in step 6.3; the gene pair formed by chromosome MA and chromosome FA determines the machine assignment of the process corresponding to the gene position; considering the production constraint that a certain process can only be processed in a certain topological structure production line, since step 6.3 assigns process 2 to workshop 2, and workshop 2 contains stand-alone line M5, serial lines M6, M7, and assembly line M8, genes No. 6 and No. 10 can only be fixed to 1, genes No. 7 and No. 9 are randomly generated to 2 or 3, and gene No. 8 can only be fixed to 4;
[0241] Step 6.5: Determine the processing sequence according to the integer encoding method specified in steps 6.1 and 6.2; gene i in chromosome OS and gene j in chromosome BS determine the current processing batch B ij ; The number of repetitions k of gene i in chromosome OS determines the current processing step O ijk ; The location of the gene in the chromosome determines the processing order of the Num_Operation process in the distributed flexible heterogeneous job shop system model;
[0242] Step 6.6: Determine the processing line assigned to the process according to the integer encoding method specified in Step 6.3 and Step 6.4; the position of the above chromosome gene pair represents the current processing process O ijk , in ascending order of k, j, i; gene p in chromosome FA and gene q in chromosome MA determine the current processing step O ijk Assigned workshops and production lines;
[0243] Step 7: Decode the chromosomes of the individuals randomly initialized in step 6, analyze the production conditions of each workshop and production line under the corresponding scheduling scheme, and calculate the fitness value of the individuals; the fitness value is defined as the maximum completion time of the distributed flexible heterogeneous job shop system model;
[0244] Step 7.1: According to the decoding of the processing line assigned to the process in step 6.6, determine the processing process of the production line. The production scheduling of the processes in the production line must comply with the process processing sequence determined in step 6.5;
[0245] According to the assignment of chromosomes FA and MA to the workshop and production line of the processing process in step 6, Figure 7 Under the scheduling scheme shown, the production scheduling results of all production line processes are as follows: M1: O 121 , O 512 , O 412 , M2:O 111 , O 122 , O 411 , M3:O 511 , O 112 , O513 , M4:O 101 , M5:O 211 , O 321 , O 203 , M6:O 221 , M7:O 311 , O 202 , O 122 , M8:O 201 , O 301 ;
[0246] Step 7.2: Initialize the current maximum completion time Makespan_M of all heterogeneous production lines h ; Initialize the start time of all process operations OperationStartTime_O ijk and the processing end time OperationEndTime_O ijk ;
[0247] Step 7.3: For production line M h Production Task J i Required raw material batch B ij Process O without pre-processing requirements ijk , the processing start time of this process is updated to Makespan_M h , processing machine M h The current maximum completion time is updated to The processing start time of this process is updated to Makespan_M h ;
[0248] Step 7.4: For production line M h Production Task J i Required raw material batch B ij Process O with pre-process processing requirements ijk , let its preceding process be The processing start time of this process is updated to Processing Machine h The current maximum completion time is updated to The processing start time of this process is updated to Makespan_M h ;
[0249] Step 7.5: Calculate the maximum completion time of the distributed flexible heterogeneous job shop system model after the four-chromosome integer encoding That is, individual fitness value;
[0250] According to the decoding process from step 7.1 to step 7.5, Figure 7Under the scheduling scheme shown, Makespan=max(71.5, 49.1, 71.9, 75.9, 74.5, 19.2, 73.6, 57.1)=75.9 is calculated;
[0251] The present embodiment discloses a distributed flexible heterogeneous job shop system modeling and scheduling method thereof, including the distributed flexible heterogeneous job shop system modeling method, as shown in steps 1 to 7, according to the distributed flexible heterogeneous job shop system modeling method, the completion time of the heterogeneous production line is analyzed and predicted, and an integer encoding and decoding method is designed to initialize a job scheduling method.
[0252] like Figure 2 As shown, the distributed flexible heterogeneous job shop system modeling and scheduling method disclosed in this embodiment also includes the following steps:
[0253] Step 8: Initialize the improved genetic algorithm hyperparameters; assign values to the population size, crossover probability, mutation probability, and maximum number of iterations of the distributed flexible heterogeneous job shop system model scheduling scheme during the improved genetic algorithm optimization iteration process; initialize the improved genetic algorithm population;
[0254] Specifically, the population size of the distributed flexible heterogeneous job shop system model scheduling scheme is set to Pop_Size = 100, the crossover probability is set to Pro_Crossover = 0.95, the mutation probability is set to Pro_Mutation = 0.2, and the maximum number of iterations is set to Max_Gen = 60; the population of Pop_Size is initialized according to the encoding method in step 6;
[0255] Step 9: Perform selection operation on the current population in the improved genetic algorithm; use elite selection and the method of randomly generating individuals described in step 6 to generate a parent population of Pop_Size; use tournament selection and the method of randomly generating individuals described in step 6 to generate a parent population of Pop_Size;
[0256] Specifically, the elite selection of the parent generation in the selection operation refers to a certain number of individuals with lower fitness values from the current population entering the parent population; the tournament selection of the mother generation refers to randomly selecting a certain number of individuals from the current population to compare fitness values, and the individuals with the lowest fitness values enter the mother population;
[0257] Step 9.1: Set the elite selection rate to Elitist_Rate, and select Elitist_Rate*Pop_Size individuals with the smallest fitness from the current population to enter the parent population;
[0258] like Figure 8As shown in the figure, after calculating the fitness values of all individuals in the current population and sorting them in ascending order, the fitness value of individual i ranks in the top 50 and enters the parent population after the elite selection; the fitness value of individual j ranks in the bottom 50 and does not enter the parent population after the elite selection;
[0259] Step 9.2: Generate Pop_Size*(1-Elitist_Rate) individuals using the random generation method described in step 6;
[0260] Step 9.3: Shuffle the individuals in step 9.1 and step 9.2 to form a parent population;
[0261] like Figure 8 As shown, after individual i enters the parent population, its position in the parent population may be different from its position in the original population;
[0262] Step 9.4: Set the tournament size to Tournament_Size and the number of tournament rounds to Tournament_Round, randomly select Tournament_Size individuals from the current population to compare fitness values, and select the individual with the smallest fitness value; repeat Tournament_Round times, and finally Tournament_Round individuals enter the parent population;
[0263] like Fig. 9 As shown in the figure, the fitness values of all individuals in the current population are calculated, and individuals i and j in the current population are randomly selected to compare their fitness values. Since the fitness value of individual i is small, it enters the mother population after the tournament selection; in particular, the tournament selection may repeatedly select individuals in the current population, and individuals in the current population may also enter the mother population multiple times;
[0264] Step 9.5: Generate Pop_Size-Tournament_Round=50 individuals using the method of randomly generating individuals described in step 6;
[0265] Step 9.6: Shuffle the individuals in step 9.4 and step 9.5 to form a parent population;
[0266] like Fig. 9 As shown, after individual i enters the parent population, its position in the parent population may be different from its position in the original population;
[0267] Step 10: Perform a crossover operation on the parent and parent populations in the improved genetic algorithm; select some chromosome genes of individuals in the parent population to replace some chromosome genes of individuals in the parent chromosome; the improved genetic algorithm includes two crossover operations: a crossover operation based on the OS and BS gene pairs and a crossover operation based on the MA and FA gene pairs; form a progeny population;
[0268] Step 10.1: Generate a random number R between 0 and 1. If the random number R satisfies R < Pro_Crossover, then continue with Steps 10.2 to 10.6; otherwise, jump to Step 10.7;
[0269] Step 10.2: Randomly generate a random integer Num_JobChange between 0 and N, where i is the number of tasks completed by the distributed flexible heterogeneous job shop system model; randomly generate Num_JobChange non-repeating random integers between 0 and N to form the process crossover set JobChange of chromosome OS, JobChange = {JobChange1, JobChange2,..., JobChange Num_JobChange};
[0270] Step 10.3: Delete the genes in chromosome OS of the parent individual that contain elements in the process crossover set {JobChange1, JobChange2,..., JobChange Num_JobChange} and the corresponding genes in chromosome BS at the corresponding positions;
[0271] Step 10.4: Sequentially extract the genes in chromosome OS of the corresponding parent individual that contain elements in the process crossover set {JobChange1, JobChange2,..., JobChange Num_JobChange} and the corresponding genes in chromosome BS at the corresponding positions, and copy them in the original gene pair order of the parent to the missing parts of chromosome OS and BS of the parent individual;
[0272] As Fig.10 shown, at this time, the randomly generated random integer Num_JobChange = 2. Therefore, 2 production tasks are selected, and the randomly generated production task set is JobChange = {J4, J5}; 5 pairs of {OS, BS} gene pairs containing genes 4 and 5 in chromosome OS are selected, and they are located at the 2nd, 7th, 11th, 15th, and 18th positions of chromosome i of the parent population individual respectively, and they are deleted; extract the corresponding gene pairs of the corresponding processes from the parent population individual i and fill them into the blank gene pairs of the parent in order to form the offspring individual;
[0273] Step 10.5: Randomly select a certain crossover point Crossover_Point in the split chromosomes FA and MA of the parent individual, and delete the gene pairs of FA and MA on the right side of Crossover_Point of the parent; extract the gene pairs of FA and MA on the right side of Crossover_Point of the corresponding parent individual and copy them to the missing parts of chromosome FA and MA of the parent individual;
[0274] As Fig.11As shown, the randomly generated random integer Crossover_Point = 10 at this time. Therefore, the first 10 {FA, MA} of the parent individual i are copied into the offspring individual, and the 9 missing gene pairs at the back of the offspring individual i are filled by the corresponding positions of the master individual i;
[0275] Step 10.6: Use the above parent individuals after the crossover operation as individuals in the offspring;
[0276] Step 10.7: Compare the fitness values of the corresponding individuals of the parent and the master, and select the individual with the smaller fitness value as the individual in the offspring;
[0277] Step 11: Perform a mutation operation on the offspring population in the improved genetic algorithm; The mutation operation based on the MA and FA gene pairs changes the assigned workshops and machines of some processes in the offspring individuals; Randomly generate chromosomes FA and MA again according to the methods in Step 6.5 and Step 6.6;
[0278] Step 11.1: Generate a random number R between 0 and 1. If the random number R satisfies R < Pro_Mutation, continue to Step 11.2, otherwise jump to Step 12;
[0279] As Fig.12 shown, change the chromosome FA of the parent; Since the considered distributed flexible heterogeneous job shop system model instance has only 2 workshops, change the elements in the parent chromosome FA from 2 to 1 and from 1 to 2;
[0280] Step 11.2: According to the methods in Step 6.3 and Step 6.4, randomly generate chromosomes FA and MA of the offspring again, so that the offspring individuals that perform the mutation operation generate new workshop and production line assignment plans;
[0281] As Fig.12 shown, consider production constraints to generate a new MA chromosome to ensure that the individual corresponds to an effective scheduling plan;
[0282] Step 12: Repeat the operations in Step 9 to Step 11; Obtain the individual with the lowest fitness value from历次 iterations; Decode the individual and draw a Gantt chart to obtain the optimized scheduling plan obtained by the improved genetic algorithm, achieving the effect of improving the workshop production efficiency and saving production energy;
[0283] Step 12.1: Use the offspring population after the mutation operation in the improved genetic algorithm as the current population, and calculate the fitness values of the individuals in the current population according to the method in Step 7 to select the optimal individual;
[0284] Step 12.2: Update the current iteration number Now_Gen; Denote the chromosome of the best individual in the current population as Best_Now, its fitness value as Fit_Now, the chromosome of the best individual in历次 iteration process as Best_His, and its fitness value as Fit_His; If Fit_Now < Fit_His, then let Fit_His = Fit_Now and Best_His = Best_Now;
[0285] Step 12.3: Repeat Step 9 to Step 12.2 until Now_Gen = Max_Gen;
[0286] Step 12.4: Decode Fit_His according to Step 7 and draw a Gantt chart; The horizontal axis of the Gantt chart is the processing time, and the vertical axis is the production line number; The scheduling scheme corresponding to the decoded Fit_His is the optimal scheduling obtained by the improved genetic algorithm.
[0287] Specifically, according to the above improved genetic algorithm scheduling strategy, Figure 7 In the system example of the distributed flexible heterogeneous job shop with operation completion time shown below, the iteration of the maximum completion time of the best individual in each generation of the population under the improved genetic algorithm scheduling is as Fig.13 shown; The specific scheduling scheme of Best_His is the individual shown as Figure 7 below, and its fitness value Fit_His = 75.9, and the result is accurate to one decimal place;
[0288] The Gantt chart drawn according to the specific scheduling scheme of Best_His is as Fig.14 shown below, where the horizontal axis represents the processing time and the vertical axis represents the production line number.
[0289] The above specific description further details the purpose, technical solution and beneficial effects of the invention. It should be understood that the above is only a specific embodiment of the present invention and is not used to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A distributed flexible heterogeneous job shop system modeling method, characterized by: The following steps are included: Step 1: System modeling of heterogeneous production lines; heterogeneous production lines are flexible production lines with different topological structures composed of Bernoulli machines and finite buffers; the system modeling of the heterogeneous production module mainly includes: system parameters, system status, and system topological structure; system parameters include production line processing cycle, Bernoulli machine processing efficiency, and finite buffer capacity; system status represents the operation status of the heterogeneous production line, the starvation status of the Bernoulli machine, and the blocking status of the Bernoulli machine; Step 2: According to the system model of the heterogeneous production line established in step 1, a distributed flexible heterogeneous workshop is system-modeled to obtain a distributed flexible heterogeneous workshop system model; the distributed flexible heterogeneous workshop system model is composed of a plurality of workshops with flexible heterogeneous production lines, and the distributed flexible heterogeneous workshop system model mainly includes: system parameters, production constraints, workshop production line structure; system parameters include the number of workshops and the number of heterogeneous production lines in the workshop; production constraints include workshop scheduling constraints and process scheduling constraints; Step 3: Based on the heterogeneous production line system model constructed in step 1 and the actual distributed flexible heterogeneous job shop system model working conditions, define the heterogeneous production line system state, which is referred to as the state below; the state is characterized by the number of workpieces in the current batch processed by the Bernoulli machine in the heterogeneous production line and the number of work-in-progress in the finite buffer; Step 4: Based on the state definition and system characteristics in step 2, define the state transfer matrix and use the Markov method to predict transient performance; Step 5: Define transient performance indicators - batch completion time CT based on heterogeneous production line system model and actual working conditions h,i,j,k :Heterogeneous production line M h , Completed Mission J i , Raw material or work in progress batch B ij , Process Time expectation for raw material or work in progress batch B ij and process O ijk The index j is 0, which indicates the batch and process of the WIP after the assembly line completes the assembly process; Step 6: Design and improve the chromosome encoding method of the genetic algorithm individuals. The genes in the chromosomes are encoded with integers. The gene encoding must meet the production constraints of the distributed flexible heterogeneous job shop system model in step 2, ensuring that the encoding generated by random initialization can generate an optimized scheduling solution that meets the production constraints of the distributed flexible heterogeneous job shop system model; Step 7: Decode the chromosomes of the individuals randomly initialized in step 6, obtain the production tasks and processing sequence of each heterogeneous production line, analyze the production status of each workshop and production line under the corresponding scheduling scheme, and calculate the fitness value of the individual; the fitness value is defined as the maximum completion time of the distributed flexible heterogeneous job workshop system model; use the production tasks and processing sequence corresponding to the maximum completion time to schedule small batch and multi-batch production tasks.
2. A distributed flexible heterogeneous job shop system modeling method as claimed in claim 1, characterized in that: Step 1 is implemented as follows: Step 1.1: Determine the heterogeneous production line topology; The heterogeneous production lines considered in the distributed flexible heterogeneous job shop system model have the following three topological structures: a single-machine production line consisting of 1 Bernoulli machine; a serial production line consisting of 2 Bernoulli machines and 1 finite buffer; an assembly production line consisting of 3 Bernoulli machines and 2 finite buffers; the above three heterogeneous production lines are referred to as single-machine line, serial line and assembly line respectively. Step 1.2: Determine the processing cycle of the workpiece; The workpiece refers to the raw materials required in small batch production or the workpiece to be processed in the finished product batch; according to the heterogeneous production line system model and actual working conditions, the workpiece processing cycle τ is defined h,i,j,k :Heterogeneous production line M h , Production Task J i , Raw material or work in progress batch B ij , Process The processing cycle of a unit workpiece is τ; the downtime of all Bernoulli machines in the production line due to processing failure is approximately equal to the workpiece processing cycle τ h,i,j,k In the case of workpiece processing cycle τ h,i,j,k Segment the time axis into units; Step 1.3: Determine the efficiency of the Bernoulli machine. The machines m that constitute the heterogeneous production line in the distributed flexible heterogeneous job shop system model h,i,j,k,l , Considering random failures, the Bernoulli distribution is satisfied when processing workpieces; according to the heterogeneous production line system model and actual working conditions, the Bernoulli machine efficiency p of the heterogeneous production line is defined h,i,j,k,l :M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process When the Bernoulli machine m h,i,j,k,l The probability of successfully machining a workpiece; in particular, m h,i,j,k,U represents the most downstream Bernoulli machine in a heterogeneous production line; Step 1.4: Determine the finite buffer capacity; Buffer b constituting heterogeneous production lines in the distributed flexible heterogeneous job shop system model h,i,j,k,m , Its WIP storage capacity is limited; according to the heterogeneous production line system model and actual working conditions, the limited buffer capacity N of the heterogeneous production line is defined h,i,j,k,m :M h , Production tasks Required raw materials or work-in-progress batch B ij , Process Time-limited buffer b h,i,j,k,m Maximum storage capacity of work in process; Step 1.5: Determine the operating status of the heterogeneous production line; The system state of the heterogeneous production line is composed of the working states s of all Bernoulli machines in the current production line h,i,j,k,l , Characterization; Based on the heterogeneous production line system model and actual working conditions, define the working state s of the Bernoulli machine of the heterogeneous production line h,i,j,k,l :M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process It is a binary variable indicating whether the Bernoulli machine is working or stopping in the current workpiece processing cycle; Step 1.6: Determine the starvation state of the Bernoulli machine; In heterogeneous production line M h , Production Task J i , Required raw materials or work-in-progress batch B ij , Process At the beginning of a workpiece processing cycle, if the Bernoulli machine m h,i,j,k,l , If there is no work-in-progress in its upstream buffer, the machine cannot process in the current processing cycle due to starvation; the upstream machine m of the heterogeneous production line h,i,j,k,1 Will not be in a state of hunger; Step 1.7: Determine the blocking state of the Bernoulli machine; In heterogeneous production line M h , Production Task J i , Required raw material work-in-progress batch B ij , Process At the beginning of a workpiece processing cycle, if the Bernoulli machine m h,i,j,k,l , If there is no WIP in its downstream buffer and its downstream machine is shut down, the machine will be unable to process at the beginning of the current processing cycle due to blockage; the downstream machine m of the heterogeneous production line h,i,j,k,U It will not be in a blocked state.
3. A distributed flexible heterogeneous job shop system modeling method as claimed in claim 2, characterized in that: Step 2 is implemented as follows: Step 2.1: Determine system parameters; Determine the number of workshops F included in the distributed flexible heterogeneous job shop system model, and each workshop number Each workshop contains f heterogeneous production lines. p ; Step 2.2: Determine production constraints; The production constraints of the distributed flexible heterogeneous job shop system model mainly include the scheduling constraints of production tasks between and within workshops: the scheduling constraints between workshops restrict that the workpiece processing of all processes of raw materials or work-in-progress required for the same task must be in the same workshop, and the workpiece processing of all processes of raw materials or work-in-progress required for the same task will be referred to as workpiece processing; the scheduling constraints within the workshop restrict that workpiece processing cannot be preempted before completion, and stipulate the order of processing of the same task process, and process processing can only be carried out on production lines with specific topological structures; Step 2.3: Determine the topological structure of the heterogeneous production lines in each workshop in the distributed flexible heterogeneous job shop system model to obtain the distributed flexible heterogeneous job shop system model.
4. A distributed flexible heterogeneous job shop system modeling method as claimed in claim 3, characterized in that: Step 3 is implemented as follows: Step 3.1: Consider the single-machine line in the distributed flexible heterogeneous job shop system model. Its state is represented by the number of workpieces processed in the current workpiece processing cycle n, f(n). The total number of system states Q i,j =B i,j +1,System Status Where X i (n) represents the probability that the single machine line is in state i in the current workpiece processing cycle n; Step 3.2: Consider the serial line of the distributed flexible heterogeneous job shop system model. Its state is represented by the number of work-in-progress in the buffer h(n) and the number of work-in-progress processed by the downstream machine f(n) at the current work-in-progress processing cycle n. The total number of system states Q i,j =(B i,j +1)(N h,i,j,k +1), System Status Where X i (n) represents the probability that the serial line is in state i in the current workpiece processing cycle n, and the mapping relationship between state i and h(n) and f(n) for: i=h(n)(B i,j +1)+f(n)+1; Step 3.3: Consider the assembly line in the distributed flexible heterogeneous job shop system model. Its state is represented by the number of work-in-progress in the buffer h1(n), h2(n) and the number of work-in-progress processed by the downstream machine f(n) at the current work-in-progress cycle n. The total number of system states Q i,j =(B i,j +1)(N h,i,j,k,1 +1)(N h,i,j,k,2 +1), System Status Where X i (n) represents the probability that the assembly line is in state i in the current workpiece processing cycle n. The mapping relationship λ between state i and h1(n), h2(n), and f(n) is: i=(N h,i,j,k,2 +1)(B i,j +1)h1(n)+(B i,j +1)h2(n)+f(n)+1。 5. A distributed flexible heterogeneous job shop system modeling method as claimed in claim 4, characterized in that: Step 4 is implemented as follows: Step 4.1: Define the serial line state transition matrix A Ser , matrix A Ser Element A in ij represents the probability of the system transitioning from state j to state i; Based on the serial line operation status h,i,j,k,l , when h(n)+f(n) ij hour, h(n+1)=h(n)-s h,i,j,k,2 *ω(n)+s h,i,j,k,1 *min(N h,i,j,k -h(n)+s h,i,j,k,2 *(ω(n)), 1), f(n+1)=f(n)+s h,i,j,k,2 *ω(n), Where ω(n) = min(1, h(n)); When h(n)+f(n)=B ij When h(n)≠0, When h(n)+f(n)=B ij When h(n)=0, Step 4.2: Define the assembly line state transition matrix A Ass , matrix A Ass Element A in ij represents the probability of the system transitioning from state j to state i; Based on the assembly line running status h,i,j,k,l , when h(n)+f(n) ij hour, h1(n+1)=h1(n)-s h,i,j,k,3 *ω(n)+s h,i,j,k,1 *min(N h,i,j,k,1 -h1(n)+s h,i,j,k,3 *(ω(n)), 1), h2(n+1)=h2(n)-s h,i,j,k,3 *ω(n)+s h,i,j,k,2 *min(N h,i,j,k,2 -h2(n)+s h,i,j,k,3 *(ω(n)),1), f(n+1)=f(n)+s h,i,j,k,3 *ω(n), Where ω(n) = min(1, h1(n), h2(n)); When h1(n)+f(n)=B ij ,h2(n)+f(n) ij When h2(n)>0, A Ass (λ(h1(n),h2(n),f(n)),λ(h1(n),h2(n),f(n)))=(1-p h,i,j,k,2 )(1-p h,i,j,k,3 ), A Ass (λ(h1(n),h2(n)+1,f(n)),λ(h1(n),h2(n),f(n)))=p h,i,j,k,2 (1-p h,i,j,k,3 ), A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1),λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,2 )*p h,i,j,k,3 , A Ass (λ(h1(n)-1, h2(n), f(n)+1),λ(h1(n), h2(n), f(n)))=p h,i,j,k,2 *p h,i,j,k,3 ; When h1(n)+f(n)=B ij ,h2(n)+f(n) ij When h2(n)=0, A Ass (λ(h1(n),h2(n),f(n)),λ(h1(n),h2(n),f(n)))=1-p h,i,j,k,2 , A Ass (λ(h1(n),h2(n)+1,f(n)),λ(h1(n),h2(n),f(n)))=p h,i,j,k,2 ; When h1(n)+f(n) ij , h2(n)+f(n)=B ij and 0 h,i,j,k,1 hour, A Ass (λ(h1(n),h2(n),f(n)),λ(h1(n),h2(n),f(n)))=(1-p h,i,j,k,1 )(1-p h,i,j,k,3 ), A Ass (λ(h1(n)+1, h2(n), f(n)),λ(h1(n), h2(n), f(n)))=p h,i,j,k,1 (1-p h,i,j,k,3 ), A Ass (λ(h1(n)+1, h2(n)-1, f(n)+1),λ(h1(n), h2(n), f(n)))=p h,i,j,k,1 *p h,i,j,k,3 , A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1),λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,1 )*p h,i,j,k,3 ; When h1(n)+f(n) ij , h2(n)+f(n)=B ij And h1(n)=N h,i,j,k,1 hour, A Ass (λ(h1(n),h2(n),f(n)),λ(h1(n),h2(n),f(n)))=1-p h,i,j,k,3 , A Ass (λ(h1(n),h2(n)-1,f(n)+1),λ(h1(n),h2(n),f(n)))=p h,i,j,k,1 *p h,i,j,k,3 , A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1),λ(h1(n), h2(n), f(n)))=(1-p h,i,j,k,1 )*p h,i,j,k,3 ; When h1(n)+f(n) ij , h2(n)+f(n)=B ij And h1(n)=0, A Ass (λ(h1(n),h2(n),f(n)),λ(h1(n),h2(n),f(n)))=1-p h,i,j,k,1 , A Ass (λ(h1(n)+1, h2(n), f(n)),λ(h1(n), h2(n), f(n)))=p h,i,j,k,1 ; When h1(n)+f(n)=B ij , h2(n)+f(n)=B ij And h1(n)=0, A Ass (λ(h1(n),h2(n),f(n)),λ(h1(n),h2(n),f(n)))=1; When h1(n)+f(n)=B ij , h2(n)+f(n)=B ij And h1(n)≠0, A Ass (λ(h1(n),h2(n),f(n)),λ(h1(n),h2(n),f(n)))=1-p h,i,j,k,0 , A Ass (λ(h1(n)-1, h2(n)-1, f(n)+1),λ(h1(n), h2(n), f(n)))=p h,i,j,k,0 。 6. A distributed flexible heterogeneous job shop system modeling method as claimed in claim 5, characterized in that: Step 5 is implemented as follows: Step 5.1: Calculate M for the single machine line considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =B ij / p h,i,j,k *τ h,i,j,k ; Step 5.2: According to the serial line state transfer matrix A obtained in step 4.2 Ser Update system status: X(n+1)=A Ser X(n); Step 5.3: Calculate M for the serial lines considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =V Ser *X(n)*τ h,i,j,k , where the vector V Ser =1*Q i,j dimensional vector; The rest of the elements are 0; Step 5.4: According to the assembly line state transfer matrix A obtained in step 4.5 Ass Update system status: X(n+1)=A Ass X(n); Step 5.5: Calculate M for the assembly line considered in the distributed flexible heterogeneous job shop system model h Completed Mission J i Required raw materials or work-in-progress batch B ij Process O ijk Batch completion time CT h,i,j,k =V Ass *X(n)*τ h,i,j,k , where the vector V Ass =1*Q i,j dimensional vector; V Ass (1,λ(1,1,B i,j -1))=1, and the rest of the elements are 0.
7. A distributed flexible heterogeneous job shop system modeling method as claimed in claim 6, characterized in that: Step 6 is implemented as follows: Step 6.1: Let Num_Operation be the sum of the number of operations of all tasks in the distributed flexible heterogeneous job shop system model; generate a non-divided chromosome OS with a chromosome length of Num_Operation; the genes in the chromosome OS are composed of elements 1, 2, ..., N, representing the order of the operations; Step 6.2: Generate an undivided chromosome BS with a chromosome length of Num_Operation; at chromosome OS gene i, The corresponding position of the random integer gene j, Indicates the batch order; the premise for chromosome BS to randomly generate gene j is to meet the production task J i Required raw material batch B ij Processing sequence requirements; Indicates the batch index of the raw materials required for the task to be processed, j=0 indicates the batch index of the raw materials required for the task to be assembled or assembled; Step 6.3: Generate a segmented chromosome FA with a chromosome length of Num_Operation; the gene p in chromosome FA is composed of randomly generated integers between 1 and F, representing the workshop assignment; according to task J i Segment chromosome FA, J i The corresponding chromosome length is to complete the task J i Required process O ijk The number of chromosomes FA randomly generates genes p on the premise that they correspond to workshop f p Able to meet production tasks i Required raw material batch B ij All processing steps O ijk ; Step 6.4: Generate a chromosome MA with a chromosome length of Num_Operation; randomly generate an integer gene q at the corresponding position of the chromosome FA gene p, Indicates production line assignment; according to task J i Segment chromosome FA, J i The corresponding chromosome length is to complete the task J i Required process O ijk The number of chromosomes MA randomly generates gene q on the premise that the corresponding production line M h Can meet the current processing steps O ijk ; Step 6.5: Determine the processing sequence according to the integer encoding method specified in steps 6.1 and 6.2; gene i in chromosome OS and gene j in chromosome BS determine the current processing batch B ij ; The number of repetitions k of gene i in chromosome OS determines the current processing step O ijk ; The location of the gene in the chromosome determines the processing order of the Num_Operation process in the distributed flexible heterogeneous job shop system model; Step 6.6: Determine the processing line assigned to the process according to the integer encoding method specified in Step 6.3 and Step 6.4; the position of the above chromosome gene pair represents the current processing process O ijk , in ascending order of k, j, i; gene p in chromosome FA and gene q in chromosome MA determine the current processing step O ijk Assigned workshops and production lines.
8. A distributed flexible heterogeneous job shop system modeling method as claimed in claim 7, characterized in that: Step 7 is implemented as follows: Step 7.1: According to the decoding of the processing line assigned to the process in step 6.6, determine the processing process of the production line. The production scheduling of the processes in the production line must comply with the process processing sequence determined in step 6.5; Step 7.2: Initialize the current maximum completion time Makespan_M of all heterogeneous production lines h ; Initialize the start time of all process operations OperationStartTime_O ijk and the processing end time OperationEndTime_O ijk ; Step 7.3: For production line M h Production Task J i Required raw material batch B ij Process O without pre-processing requirements ijk , the processing start time of this process is updated to Makespan_M h , processing machine M h The current maximum completion time is updated to The processing start time of this process is updated to Makespan_M h ; Step 7.4: For production line M h Production Task J i Required raw material batch B ij Process O with pre-process processing requirements ijk , let its preceding process be The processing start time of this process is updated to Processing Machine h The current maximum completion time is updated to The processing start time of this process is updated to Makespan_M h ; Step 7.5: Calculate the decoded individual fitness value, which corresponds to the maximum completion time of the distributed flexible heterogeneous job shop system model Use the production tasks and processing sequences corresponding to the maximum completion time to schedule small batch and multi-batch production tasks.
9. A production scheduling method for a distributed flexible heterogeneous job shop system, based on a distributed flexible heterogeneous job shop system modeling method as claimed in claim 1, 2, 3, 4, 5, 6 or 7, characterized in that: The method comprises steps 1 to 7 of a distributed flexible heterogeneous job shop system modeling method, and further comprises the following steps: Step 8: Initialize the improved genetic algorithm hyperparameters; assign values to the population size, crossover probability, mutation probability, and maximum number of iterations of the distributed flexible heterogeneous job shop system model scheduling scheme during the improved genetic algorithm optimization iteration process; initialize the improved genetic algorithm population; Step 9: Design the selection operator in the improved genetic algorithm, perform selection operations on the current population in the improved genetic algorithm, and retain the excellent individuals in the current population; use elite selection and the method of randomly generating individuals described in step 6 to generate a parent population of Pop_Size; use tournament selection and the method of randomly generating individuals described in step 6 to generate a parent population of Pop_Size; Step 10: Design a crossover operator in the improved genetic algorithm, perform a crossover operation on the parent and maternal populations in the improved genetic algorithm, and explore the solution space; select some chromosome genes of individuals in the maternal population to replace some chromosome genes of individuals in the parent chromosome; the improved genetic algorithm includes two crossover operations: a crossover operation based on OS and BS gene pairs and a crossover operation based on MA and FA gene pairs; form a progeny population; Step 11: Design a mutation operator in the improved genetic algorithm to perform mutation operations on the offspring population in the improved genetic algorithm, exploring the solution space; based on the mutation operations of the MA and FA gene pairs, change the assigned workshops and machines of some processes in the offspring individuals; randomly generate chromosomes FA and MA again according to the method in Step 6; Step 12: Repeat the operations in Step 9 to Step 11. Through the cooperation of the selection operator, crossover operator, and mutation operator, the improved genetic algorithm balances the exploration of the solution space and the utilization of its own information during the population update and iteration process; obtain the individual with the lowest fitness value from历次iterations; decode the individual and draw a Gantt chart to obtain the optimized scheduling scheme obtained by the improved genetic algorithm, and improve the workshop production efficiency and save production energy according to the optimized scheduling scheme.
10. A production scheduling method for a distributed flexible heterogeneous job shop system as claimed in claim 9, characterized in that: In Step 8, The population size of the scheduling scheme of the distributed flexible heterogeneous job shop system model is set to Pop_Size, the crossover probability is set to Pro_Crossover, the mutation probability is set to Pro_Mutation, and the maximum number of iterations is set to Max_Gen; initialize a population of Pop_Size individuals according to the encoding method in Step 6; The implementation method of Step 9 is, Step 9.1: Set the elitist selection rate to Elitist_Rate, and select Elitist_Rate * Pop_Size individuals with the lowest fitness values from the current population to enter the parent population; Step 9.2: Generate Pop_Size * (1 - Elitist_Rate) individuals using the method of randomly generating individuals described in Step 6; Step 9.3: Shuffle the individuals in Step 9.1 and Step 9.2 to form the parent population; Step 9.4: Set the tournament size to Tournament_Size and the number of tournament rounds to Tournament_Round. Randomly select Tournament_Size individuals from the current population to compare their fitness values, and select the individual with the lowest fitness value; repeat this process Tournament_Round times, and finally Tournament_Round individuals enter the mother population; Step 9.5: Generate Pop_Size - Tournament_Round = 50 individuals using the method of randomly generating individuals described in Step 6; Step 9.6: Shuffle the individuals in Step 9.4 and Step 9.5 to form the mother population; The implementation method of Step 10 is, Step 10.1: Generate a random number R between 0 and 1. If the random number R satisfies R < Pro_Crossover, then continue with Steps 10.2 to 10.6; otherwise, jump to Step 10.7; Step 10.2: Randomly generate a random integer Num_JobChange between 0 and N, where i is the number of completed tasks in the distributed flexible heterogeneous job shop system model; randomly generate Num_JobChange non-repeating random integers between 0 and N to form the process intersection set JobChange = {JobChange1, JobChange2, ..., JobChange Num_JobChange }; Step 10.3: Delete the process intersection set {JobChange1, JobChange2, ..., JobChange Num_JobChange }The genes in the elements and the genes at the corresponding positions in the chromosome BS; Step 10.4: Extract the process intersection set {JobChange1, JobChange2, ..., JobChange Num_JobChange } The genes of the elements in the chromosome and the genes at the corresponding positions in the chromosome BS, and the original gene pairs of the mother are sequentially copied to the missing parts of the chromosome OS and BS of the father individual; Step 10.5: Randomly select a crossover point Crossover_Point in the parental individuals for the split chromosomes FA and MA, and delete the gene pairs of FA and MA on the right side of Crossover_Point in the parental individuals; extract the gene pairs of FA and MA on the right side of Crossover_Point in the corresponding maternal individuals and copy them to the missing parts of chromosomes FA and MA in the parental individuals. Step 10.6: Use the parental individuals after the above crossover operation as individuals in the offspring. Step 10.7: Compare the fitness values of the corresponding individuals in the parental and maternal generations, and select the individual with the smaller fitness value as an individual in the offspring. The implementation method of Step 11 is as follows. Step 11.1: Generate a random number R between 0 and 1. If the random number R satisfies R < Pro_Mutation, continue to Step 11.2; otherwise, jump to Step 12. Step 11.2: According to the methods in Step 6.3 and Step 6.4, randomly generate the chromosomes FA and MA of the offspring again, so that the offspring individuals that perform the mutation operation generate new workshop and production line assignment plans. The implementation method of Step 12 is as follows. Step 12.1: Use the offspring population after the mutation operation in the improved genetic algorithm as the current population, and calculate the fitness values of the individuals in the current population according to the method in Step 7 to select the optimal individual. Step 12.2: Update the current iteration number Now_Gen; record the chromosome Best_Now of the optimal individual in the current population, its fitness value is Fit_Now, the chromosome Best_His of the optimal individual in previous iteration processes, and its fitness value is Fit_His; if Fit_Now < Fit_His, then let Fit_His = Fit_Now and Best_His = Best_Now. Step 12.3: Repeat Step 9 to Step 12.2 until Now_Gen = Max_Gen. Step 12.4: Decode Fit_His according to Step 7 and draw a Gantt chart; the horizontal axis of the Gantt chart is the processing time, and the vertical axis is the production line number; the scheduling plan corresponding to Fit_His after decoding is the optimal scheduling plan obtained by the improved genetic algorithm. Use the optimal scheduling plan formed by decoding to implement the scheduling of the distributed flexible heterogeneous job shop system, minimize the makespan of the system, improve the production efficiency of the workshop, and save production energy.
