Discrete manufacturing job shop variable batch size flexible scheduling method and system
By optimizing the variable batch flexible scheduling of discrete manufacturing workshops through a double-layer chromosome genetic algorithm, the complex problem of equipment resource utilization in multi-variety and small-batch production is solved, the efficient utilization of equipment resources and the flexibility of production plans are achieved, and the equipment status changes in the actual production environment are adapted.
Patent Information
- Application Number
- CN202510947574.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-10
- Publication Date
- 2025-10-14
- Estimated Expiration
- 2045-07-10
AI Technical Summary
Existing technologies are unable to effectively solve the problem of equipment resource utilization under complex working conditions with multiple varieties, small batches, and short delivery cycles in flexible operation workshops in fields such as aerospace and precision equipment and instruments, especially the impact of equipment maintenance, failures, and unfinished tasks on scheduling, resulting in poor results of traditional scheduling methods in practical applications.
A genetic algorithm with a double-layer chromosome structure is used to construct a flexible scheduling model for variable batches in discrete manufacturing workshops. Combined with actual constraints such as equipment resource occupancy, workpiece incoming time, and processing equipment flexibility, crossover and mutation operations are designed to optimize equipment selection and process turnover batch arrangement to achieve scheduling with the shortest completion time.
It improves the scheduling efficiency of the flexible job shop, ensures the effective use of equipment resources, adapts to changes in equipment status in the actual production environment, and improves the flexibility and efficiency of production planning.
Smart Images

Figure CN120430599B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of digital workshop task management, and in particular to a variable batch flexible scheduling method and system for a discrete manufacturing workshop, and more particularly to a fast batch scheduling method and system for a machining workshop. Background Art
[0002] As a core component of advanced manufacturing technology, shop floor scheduling has attracted significant attention in both academia and industry in recent years. In academia, various methods for scheduling production tasks and resources have emerged. However, in industry, these methods have been less than satisfactory when applied to actual production tasks.
[0003] Flexible job shops, which process structural products for aerospace, precision equipment, and other fields, present a unique complexity. From the perspective of the products being processed, these shops typically exhibit numerous and complex processing steps. From the perspective of the workshop itself, complex working conditions such as multiple varieties, small batches, short lead times, and parallel development and production of batch products are the norm. In these circumstances, the traditional production method of equal turnover between processes is no longer able to effectively balance the differences in production rhythms between different processes. Particularly noteworthy is the lack of research addressing the scheduling issues of flexible job shops under the order-based, batch-turnover, rolling production model.
[0004] Furthermore, traditional solutions to shop scheduling problems often assume that all types of workpieces arrive simultaneously (complete sets) when the shop receives them, and that the equipment is ideally available at all times when scheduling begins. However, in the actual production scheduling of flexible machining shops, equipment resources face regular maintenance requirements, equipment failures, shop work shifts and holiday schedules, and previously scheduled but uncompleted tasks. Consequently, equipment resources often only have the capacity to be available in the form of multiple idle segments. This reality, significantly different from traditional assumptions, has significantly hindered the further promotion and application of related research results in industry.
[0005] Through the retrieval of patent documents, it is found that the patent with publication number CN110619437A discloses a low-energy-consumption flexible job shop scheduling method, which comprises the following steps: step 1, constructing a job shop scheduling model with energy consumption and completion time as optimization objectives, wherein the job shop includes workpieces to be machined by machine tools, the energy consumption and completion time of the job shop are obtained according to the number of workpieces and machine tools, and the optimization objectives are the minimum energy consumption and the shortest completion time of the job shop; step 2, for the job shop scheduling model, an improved genetic algorithm is proposed, a multi-layer coding strategy is adopted, the optimal conditions of energy consumption and completion time are obtained, and flexible job shop scheduling is completed. The patent does not involve the order process level batch turnover rolling production mode in the variable batch flexible scheduling of the discrete manufacturing workshop, and does not optimize the actual available state of the equipment, and does not involve the influence of equipment maintenance, failure and incomplete tasks on the scheduling.
[0006] In summary, in view of the problems of the prior art, a variable batch flexible scheduling method and system for a discrete manufacturing workshop become a key task to be solved at present. SUMMARY
[0007] In view of the defects in the prior art, the purpose of the present application is to provide a variable batch flexible scheduling method and system for a discrete manufacturing workshop.
[0008] According to the variable batch flexible scheduling method for a discrete manufacturing workshop provided by the present application, the following steps are included:
[0009] Step S1, establishing a constraint condition that the same kind of workpiece under the same order is split into process turnover batches at each process, taking the shortest completion time as the target of the scheduling scheme, and constructing a target function of the variable batch flexible scheduling of the discrete manufacturing workshop;
[0010] Step S2, based on the constraint condition and the target function, adopting a double-layer chromosome structure to describe the chromosome individuals of the genetic algorithm, and using a random generation method to generate an initial population comprising a plurality of chromosome individuals;
[0011] Step S3, based on the initial population, according to the coding characteristics of the double-layer chromosome structure, adopting a uniform crossover mode to obtain chromosome individuals subjected to crossover operation, and completing the exchange and transmission of process equipment selection information;
[0012] Step S4, performing mutation operation on the chromosome individuals subjected to crossover operation, wherein a random gene bit value mutation method is adopted for the second layer of the chromosome, that is, a new value is randomly generated in the set of selectable equipment corresponding to the selected gene bit, and the original gene bit gene value is replaced; two mutation modes are cooperatively operated for the first layer of the chromosome to realize gene mutation, and chromosome individuals subjected to mutation operation are obtained;
[0013] Step S5, decoding the chromosome individual of the mutation operation, generating the processing sequence and processing time of each workpiece process turnover batch on each device, and obtaining the total completion time.
[0014] Preferably, in step S1, the constraint condition comprises:
[0015] a. The total number B of the i-th workpiece i In the process of splitting each process turnover batch, the total number B of workpieces is kept unchanged, that is, for any process j belonging to workpiece i, the sum of the turnover workpiece numbers of the process turnover batch is equal to the total number B of workpieces i The constraint condition is expressed as follows:
[0016] (1)
[0017] Wherein:
[0018] , j, Denote the workpiece number, process number and turnover batch number respectively;
[0019] Denote the total number of the i-th workpiece;
[0020] j denotes the process of the workpiece
[0021] O ij Denotes the j-th process of workpiece i;
[0022] Denotes the total number of workpieces contained in the p-th production or transmission sub-batch of process O ij
[0023] Denotes the total number of production or transmission sub-batches of process O ij
[0024] b. Different turnover batches of the same process of any workpiece are arranged to be processed on the same device, Denotes the identification of the p-th production sub-batch of the j-th process of workpiece i processed on device k, and the constraint condition is expressed as follows:
[0025] (2)
[0026] Wherein, Denotes the total number of optional devices in the optional device set M ij ij
[0027] c. When the p-th turnover batch of the j-th process of the i-th workpiece is processed on device k, the processing start time ST ijp and the end time ET of the processing of the process cycle ijp There is a constraint, the constraint condition is expressed as follows, the processing time is equal to the equipment processing the process single piece time multiplied by the number of workpieces contained in the cycle batch;
[0028] (3)
[0029] Wherein:
[0030] ST ijp Indicates the start time of the processing of the jth process of the ith cycle batch of the workpiece .
[0031] ET ijp Indicates the end time of the processing of the jth process of the ith cycle batch of the workpiece .
[0032] Indicates the processing time of the jth process of the workpiece on the kth equipment in the optional equipment set Mij.
[0033] Indicates the start and end time window range of the pth production sub-batch of the process Oij arranged on the kth equipment, and the unavailable time of the kth equipment except for process processing.
[0034] d, any cycle batch processing, in accordance with the cycle batch sequence constraint, that is, after the completion of the previous cycle batch of the same process, the subsequent cycle batch production of the same process is carried out, the constraint condition is expressed as follows:
[0035] (4)
[0036] e, any cycle batch processing, in accordance with the process route constraint, that is, all workpieces in the cycle batch complete the processing of the immediately preceding process and complete the transfer of the immediately preceding process to the process, and then the subsequent cycle batch production of the same process is carried out, the constraint condition is expressed as follows:
[0037] (5)
[0038] Indicates the number of subsequent cycle batches.
[0039] Wherein, the previous batch L is the minimum value under the following constraint:
[0040] (6)
[0041] f, the latest completion time CT of all workpieces under the input task max The latest completion time of all workpieces, ET i For the total completion processing time of the ith kind of workpiece under the scheduling scheme, the constraint condition is expressed as follows:
[0042] (7)
[0043] wherein, represents the maximum latest completion time.
[0044] g, the jth process O of the ith workpiece ij processing time PT on the kth device in the optional device set M ij . ijk Non-negative constraint, the constraint condition is expressed as follows:
[0045] (8)
[0046] h, single process turn batch processing continuously, the constraint condition is expressed as follows:
[0047] (9)
[0048] wherein,
[0049] ;
[0050] : the start processing time of the pth production / transmission sub batch of the jth process of the ith workpiece on the device k;
[0051] : the end time of the pth production / transmission sub batch of the jth process of the ith workpiece on the device k;
[0052] : the start processing time of the zth production / transmission sub batch of the yth process of the xth workpiece on the device k;
[0053] : the end time of the zth production / transmission sub batch of the yth process of the xth workpiece on the device k;
[0054] x, y, z respectively represent workpiece number, process number, and turn batch number;
[0055] represents any.
[0056] Further, in step S1, the objective function of flexible workshop production scheduling under rolling production mode is expressed as follows:
[0057] (10)
[0058] wherein, denotes minimization, i.e. optimization of the objective.
[0059] Preferably, the double-layer chromosome structure in step S2 comprises:
[0060] The first layer of the chromosome adopts integer coding form to represent process turnover batch information;
[0061] The second layer of the chromosome adopts integer coding form to represent the selected processing equipment of each process.
[0062] Preferably, in step S3, for the first layer of the chromosome, the crossover mode adopts sequential crossover with starting position determined, i.e. the crossover starting position is determined as the first position of the first layer of the chromosome, and the crossover ending position is randomly generated within the range of the first layer of the chromosome.
[0063] Preferably, in step S3, for the second layer of the chromosome, the same position corresponds to the same represented process, and a uniform crossover mode is adopted to complete the exchange and transmission of the selection advantage information of the process equipment.
[0064] Preferably, in step S4, the first mutation mode of the first layer of the chromosome is to randomly select the parent chromosome gene position to be mutated, decode the process turnover batch, determine the turnover batch, and then calculate the immediately preceding turnover batch and the immediately following turnover batch of the current turnover batch according to the number of turnover workpieces corresponding to the turnover batch, and locate the immediately preceding turnover batch position and the immediately following turnover batch position in the chromosome, determine the adjustable position range of the mutation gene according to the positions of the preceding and following turnover batches, randomly select a new gene position n different from the current position o within the adjustable position range, and when the position is moved forward, the genes in the original [n, o-1] range are moved one position backward, and when the position is moved backward, the genes in the original [o, n+1] range are moved one position forward.
[0065] Preferably, in step S4, the second mutation mode of the first layer of the chromosome is to randomly select a workpiece and generate a new turnover batch to which the workpiece belongs, and then combine the new turnover batch with the original gene sequence of the non-selected workpiece in the first layer of the parent chromosome to complete the mutation of the chromosome.
[0066] Preferably, in step S5, the chromosome decoding comprises the following steps:
[0067] Step S5.1, for the gene position value Gene of the first layer of the chromosome, let i be the quotient obtained by dividing Gene by 100, and j be the remainder obtained by dividing Gene by 100, the gene position value Gene represents the turnover batch of workpiece i in process j, and the Gene is obtained in sequence and judged for the number of times it appears, and the pth appearance of Gene represents the pth turnover batch of workpiece i in process j.
[0068] Step S5.2, according to the gene position value Gene, the corresponding workpiece process Oij (O ij searching whether there exists O ij , if O ij , jumping to step S3, otherwise, based on the selection mechanism constructed by the stagnation generation number and the population average fitness value of the iteration optimization result, determining the process equipment by using the equipment code matching, random equipment generation or equipment bidding mode.
[0069] Step S5.3, based on the existing task scheduling time record and the processing time constraint of the process equipment, determining the process turn batch O ijp (O ijp the processing start time and the end time of the pth turn of the jth process of the ith workpiece, updating the record of the processing turn task on the selected process equipment, and adding the decoded workpiece process O ij to the decoded process set MS.
[0070] Step S5.4, repeatedly performing steps S5.1 to S5.3 until the decoding of all gene site values of the first layer of the chromosome is completed, and calculating the completion time of the scheduling scheme corresponding to the current chromosome individual according to formula (7).
[0071] The application also provides a variable batch flexible scheduling system for a discrete manufacturing workshop, comprising:
[0072] Module M1, establishing constraint conditions for splitting the same kind of workpieces under the same order into process turn batches at each process, taking the shortest completion time as the target of the scheduling scheme, and constructing a target function of the variable batch flexible scheduling of the discrete manufacturing workshop;
[0073] Module M2, based on the constraint conditions and the target function, adopting a double-layer chromosome structure to describe the chromosome individual of the genetic algorithm, and using a random generation method to generate an initial population comprising multiple chromosome individuals;
[0074] Module M3, based on the initial population, according to the coding characteristics of the double-layer chromosome structure, adopting a uniform crossover mode to obtain the chromosome individual of the crossover operation, and completing the exchange and transmission of the process equipment selection information;
[0075] Module M4, performing mutation operation on the chromosome individual of the crossover operation, wherein, for the second layer of the chromosome, a random gene site value mutation method is adopted, that is, a new value is randomly generated in the set of selectable equipment corresponding to the selected gene site, and the original gene site gene value is replaced; for the first layer of the chromosome, two mutation modes are cooperatively operated to realize gene mutation, and the chromosome individual of the mutation operation is obtained.
[0076] Module M5 decodes the chromosome individual of the mutation operation to generate the processing sequence and processing time of each workpiece process turnover batch on each device, and obtains the total completion time.
[0077] Preferably, the double-layer chromosome structure in module M2 comprises:
[0078] The first layer of the chromosome adopts integer coding form to represent the process turnover batch information;
[0079] The second layer of the chromosome adopts integer coding form to represent the selected processing device of each process.
[0080] Compared with the prior art, the present application has the following beneficial effects:
[0081] 1. The present application abstracts the process level batch turnover rolling production mode and related constraints of actual production in the workshop, and constructs a flexible job shop scheduling problem model. The model involves device resource occupation, workpiece arrival time, process turnover batch characteristics and processing device flexibility, and is more consistent with the actual production constraints.
[0082] 2. In the algorithm iteration, the present application adaptively designs the crossover and mutation modes to ensure the effectiveness of the solution when solving the flexible job shop scheduling problem under the process level batch turnover rolling production mode.
[0083] 3. The present application designs an adaptive adjustment mechanism for device selection in iteration, which improves the optimization effect of the algorithm through flexible combination of three modes of coding inheritance, device "bidding" and random allocation. BRIEF DESCRIPTION OF DRAWINGS
[0084] Other features, objects and advantages of the present application will become more apparent from the following detailed description of non-limiting embodiments, made with reference to the accompanying drawings:
[0085] Figure 1 A flow chart of a discrete manufacturing workshop variable batch flexible scheduling method in an embodiment of the present application;
[0086] Figure 2 A chromosome coding mode of population individuals in the improved genetic algorithm in an embodiment of the present application;
[0087] Figure 3 A chromosome first layer coding crossover mode in an embodiment of the present application;
[0088] Figure 4 A chromosome first layer coding mutation mode in an embodiment of the present application;
[0089] Figure 5 A decoding mode of process corresponding processing device in an embodiment of the present application. DETAILED DESCRIPTION
[0090] The present invention will be described in detail below with reference to specific embodiments. The following examples will help those skilled in the art to further understand the present invention, but are not intended to limit the present invention in any form. It should be noted that, for those skilled in the art, several changes and improvements can be made without departing from the scope of the present invention. These all fall within the scope of protection of the present invention.
[0091] The present invention provides a method and system for flexible scheduling of variable batch sizes in discrete manufacturing workshops. Based on the flexible job shop scheduling problem of variable batch sizes and batch turnover at the process level, a corresponding scheduling model is constructed, and a solution method based on an improved genetic algorithm is provided, thereby improving the technical capabilities of workshop scheduling.
[0092] Example 1:
[0093] Figure 1 The present invention is a flowchart of a method for flexible batch scheduling in a discrete manufacturing workshop according to an embodiment of the present invention.
[0094] like Figure 1 As shown, this embodiment provides a variable batch flexible scheduling method for a discrete manufacturing workshop, comprising the following steps:
[0095] Step S1: Establish the constraint conditions for splitting the same type of workpieces under the same order into process turnover batches in each process, take the shortest completion time as the goal of the scheduling plan, and construct the objective function of variable batch flexible scheduling of discrete manufacturing workshops.
[0096] Specifically, in step S1, the constraints include:
[0097] a. The total number of type i workpieces B i It remains unchanged during the splitting process of each process turnover batch, that is, for any process j belonging to workpiece i, the sum of the turnover workpieces of its process turnover batch is equal to the total number of workpieces B i , the constraints are expressed as follows:
[0098] (1)
[0099] in:
[0100] 、j、 Respectively represent the workpiece number, process number and turnover batch number;
[0101] Indicates the The total number of workpieces;
[0102] j represents the workpiece process;
[0103] O ijrepresents the jth operation of the workpiece i;
[0104] represents the total number of workpieces contained in the pth production or transport sub-batch of the operation O ij
[0105] represents the total number of production or transport sub-batches of the operation O ij
[0106] b, different turnover batches of the same operation of any workpiece are processed on the same equipment, represents the identification of the pth production sub-batch of the jth operation of the workpiece i processed on the equipment k, the constraint condition is represented as follows:
[0107] (2)
[0108] wherein, represents the total number of optional equipment in the set of optional equipment M ij ij
[0109] c, when the pth turnover batch of the jth operation of the ith workpiece is processed on the equipment k, the processing start time ST ijp and the processing end time ET ijp of the operation turnover batch exist constraints, the constraint condition is represented as follows, the processing time is equal to the single piece processing time of the equipment processing the operation of the workpiece multiplied by the number of workpieces contained in the turnover batch;
[0110] (3)
[0111] wherein:
[0112] ST ijp represents the processing start time of the jth operation of the workpiece
[0113] ET ijp represents the processing end time of the jth operation of the workpiece
[0114] represents the processing time of the jth operation of the workpiece on the equipment k in the set of optional equipment Mij;
[0115] represents the start and end time window range of the pth production sub-batch of the operation O ij arranged on the equipment k, the unavailable time (maintenance, maintenance, holiday, etc.) of the equipment k except for operation processing.
[0116] d. Any processing of a turnover batch, which complies with the turnover batch sequence constraint, i.e. the production of a subsequent turnover batch of the same process is not started until the previous turnover batch of the same process is completed, and the constraint condition is expressed as follows:
[0117] (4)
[0118] e. Any processing of a turnover batch, which complies with the process route constraint, i.e. all workpieces in a turnover batch complete the processing of the immediately previous process and are transferred to the current process before the production of a subsequent turnover batch of the same process is started, and the constraint condition is expressed as follows:
[0119] (5)
[0120] represents the number of subsequent turnover batches.
[0121] wherein the previous batch L is the minimum value under the following constraint:
[0122] (6)
[0123] f. The latest completion time CT of all workpieces under the input task max is the latest completion time among the completion times of all workpieces, ET i is the total processing time of the i-th workpiece under the scheduling scheme, and the constraint condition is expressed as follows:
[0124] (7)
[0125] wherein, represents the maximum latest completion time.
[0126] g. The j-th process O of the workpiece i ij on the k-th device in the optional device set M ij takes the processing time PT ijk is a non-negative constraint, and the constraint condition is expressed as follows:
[0127] (8)
[0128] h. The processing of a single-process turnover batch is continuous, and the constraint condition is expressed as follows:
[0129] (9)
[0130] wherein,
[0131] ;
[0132] : start processing time of the pth production / transmission sub-batch of the ith workpiece jth process on the device k;
[0133] : end processing time of the pth production / transmission sub-batch of the ith workpiece jth process on the device k;
[0134] : start processing time of the zth production / transmission sub-batch of the xth workpiece yth process on the device k;
[0135] : end processing time of the zth production / transmission sub-batch of the xth workpiece yth process on the device k;
[0136] x, y, z respectively represent workpiece number, process number, and turnover batch number;
[0137] represents arbitrary.
[0138] Further, in step S1, the objective function of the flexible workshop production scheduling in the rolling production mode is represented as follows:
[0139] (10)
[0140] wherein, represents minimization, i.e., optimization objective.
[0141] Step S2, based on the constraint condition and the objective function, a double-layer chromosome structure is adopted to describe the chromosome individual of the genetic algorithm, and a random generation method is adopted to generate an initial population containing multiple chromosome individuals.
[0142] Figure 2 It is the population individual chromosome coding mode in the improved genetic algorithm in the embodiment of the application.
[0143] As Figure 2 shown, the double-layer chromosome structure in step S2 includes:
[0144] The first layer of the chromosome adopts integer coding form to represent process turnover batch information.
[0145] Further, when the process processing device code is initialized, it is randomly generated within the corresponding process optional device range. Different workpiece codes have no precedence constraint, and there is a constraint between different process turnover batches of the same workpiece. Therefore, the independent generation and combination of different workpiece chromosome turnover batch order segments is adopted to complete the random generation of the final first layer of the chromosome.
[0146] In the embodiment, the first layer of the chromosome adopts integer coding form to represent the process turnover batch information. When the process equipment code is initialized, the gene value in the first layer of the chromosome is randomly generated in the range of the optional equipment of the corresponding process. For example, the gene value in the first layer of the chromosome is coded as The number of times that the gene value 203 at a certain position of the chromosome appears from left to right in the chromosome is recorded as pic, which represents the picth turnover batch of the third process of the second workpiece corresponding to the position. Since the same process and different turnover batches need to satisfy the constraint of processing on the same equipment.
[0147] The second layer of the chromosome adopts integer coding form to represent the selected processing equipment of each process.
[0148] Specifically, since the same process and different turnover batches need to satisfy the constraint of processing on the same equipment, the second layer of the chromosome encodes the selected equipment in the corresponding position in the order of the cumulative sequence of the workpiece processes.
[0149] In the embodiment, the second layer of the chromosome encodes the selected equipment in the corresponding position in the order of the cumulative sequence of the workpiece processes. For example, assuming that the first workpiece contains two processes and the second workpiece contains three processes in a certain scheduling task, the first to second positions in the second layer of the chromosome represent the selected processing equipment of the two processes of the first workpiece, respectively; the third to fifth positions represent the selected processing equipment of the three processes of the second workpiece, respectively, and the equipment selection of the processes of the remaining workpieces is sequentially similar.
[0150] In step S3, according to the chromosome coding characteristics of solving the flexible job shop scheduling problem under the process-level batch turnover rolling production mode, based on the initial population, according to the coding characteristics of the double-layer chromosome structure, the uniform crossover mode is adopted to obtain the chromosome individuals of the crossover operation, and the exchange and transmission of the process equipment selection information are completed.
[0151] Figure 3 The coding crossover mode for the first layer of the chromosome in the embodiment of the application.
[0152] As shown in Figure 3 For the first layer of the chromosome, in order to avoid illegal solutions that do not satisfy the turnover batch constraint in the crossover process, the uniform crossover mode is adopted, that is, the starting position is determined, the first position of the first layer of the chromosome is determined as the starting position of the crossover, and the termination position is randomly generated in the range of the first layer of the chromosome.
[0153] Specifically, for the same position of the second layer of the chromosome, the same process is represented, and the uniform crossover mode is adopted to complete the exchange and transmission of the process equipment selection advantage information.
[0154] For example, two chromosomes in the initial population: 521639, 135296, take the third gene of the chromosome as the uniform crossover position, and the new chromosome individuals obtained after the crossover transmission and exchange are: 525639, 131296.
[0155] Step S4, performing mutation operation on the chromosome individuals subjected to the crossover operation, wherein a random gene bit value mutation method is adopted for the second layer of the chromosome, that is, a new value is randomly generated in the process selectable equipment set corresponding to the selected gene bit, and the original gene bit gene value is replaced; the gene mutation is realized by the cooperative operation of the two mutation modes for the first layer of the chromosome, and the chromosome individuals subjected to the mutation operation are obtained.
[0156] Figure 4 The mutation mode for the first layer of the chromosome in the embodiment of the application is encoded.
[0157] Specifically, in step S4, the mutation mode for the first layer of the chromosome includes the following two kinds:
[0158] The first mutation mode is to randomly select the mutation gene position of the parent chromosome, decode the process turnover batch, determine the turnover batch, and then calculate the immediately preceding turnover batch and the immediately following turnover batch of the current turnover batch according to the number of turnover workpieces corresponding to the turnover batch, and locate the immediately preceding turnover batch position and the immediately following turnover batch position in the chromosome, determine the adjustable position range of the mutation gene according to the positions of the preceding and following turnover batches, randomly select a new gene bit n different from the current position o in the adjustable position range, and when the position is moved forward, the genes in the original [n, o-1] range are moved one bit backward, and when the position is moved backward, the genes in the original [o, n+1] range are moved one bit forward.
[0159] The second mutation mode is to randomly select a workpiece, generate a new turnover batch to which the workpiece belongs, and then combine the original gene order of the non-selected workpiece in the first layer of the parent chromosome to complete the mutation of the chromosome.
[0160] The selection rules of different mutation modes: the first mutation mode has a smaller mutation space range, and is more suitable for neighborhood exploration without destroying the main advantage of the individual gene after the population searches for a new optimal solution; the second mutation mode is not limited by the order of the selected workpiece parent chromosome, and is more suitable for large-span exploration to break through the defects of the population chromosome when the population iteration falls into local optimization.
[0161] Step S5: decoding the chromosome individuals subjected to the mutation operation based on the constraints of the preceding and following turnover batches and the device selection constraints, generating the processing order and processing time of each workpiece process turnover batch on each device under the current scheduling scheme, and obtaining the total completion time of the workpieces.
[0162] Figure 5 The decoding mode of the process corresponding processing device in the embodiment of the application.
[0163] As Figure 5 shown, in step S5, the chromosome decoding includes the following steps:
[0164] Step S5.1, for the gene position value Gene of the first layer of the chromosome, let i be the quotient obtained by dividing Gene by 100, and j be the remainder obtained by dividing Gene by 100, the gene position value Gene represents the turnover batch of the process j of the workpiece i, Gene is obtained in turn and the number of times Gene appears is determined, the pth appearance of Gene represents the pth turnover batch of the process j of the workpiece i.
[0165] Step S5.2, according to the gene position value Gene, the corresponding workpiece process O ij (O ij of the workpiece i is solved, and it is searched in the decoded process set MS whether O ij exists, if O ij exists in MS, it is jumped to step S3, otherwise, based on the selection mechanism constructed by the stagnation generation number and the population average fitness value of the iteration optimization result, the process equipment is determined in a device coding matching, random device generation or device bidding manner.
[0166] Step S5.3, based on the existing task arrangement time record and the processing time constraint of the process equipment, the processing start time and the end time of the process turnover batch O ijp (O ijp of the workpiece i are determined by using formula (3), formula (4) and formula (5), the processing turnover task is updated and recorded on the selected process equipment, and the decoded workpiece process O ij is added to the decoded process set MS.
[0167] Step S5.4, steps S5.1 to S5.3 are repeatedly executed until all gene position values of the first layer of the chromosome are decoded, and the completion time of the scheduling scheme corresponding to the current chromosome individual is calculated according to formula (7).
[0168] Embodiment 2:
[0169] The application also provides a discrete manufacturing workshop variable batch flexible scheduling system, which can be realized by executing the process steps of the discrete manufacturing workshop variable batch flexible scheduling method, that is, the discrete manufacturing workshop variable batch flexible scheduling method can be understood by those skilled in the art as the preferred embodiment of the discrete manufacturing workshop variable batch flexible scheduling system.
[0170] Specifically, the discrete manufacturing workshop variable batch flexible scheduling system comprises:
[0171] Module M1, establishes the constraint condition of splitting the same kind of workpiece in each process into process turnover batch with the same order, takes the shortest completion time as the target of scheduling scheme, and constructs the objective function of variable batch flexible scheduling of discrete manufacturing workshop;
[0172] Module M2, based on the constraint condition and the objective function, adopts a double-layer chromosome structure to describe the chromosome individual of genetic algorithm, and adopts a random generation method to generate an initial population containing multiple chromosome individuals;
[0173] Module M3, based on the initial population, adopts a uniform crossover method to obtain the chromosome individual of crossover operation according to the coding characteristics of the double-layer chromosome structure, and completes the exchange and transmission of process equipment selection information;
[0174] Module M4, performs mutation operation on the chromosome individual of crossover operation, wherein, a random gene bit value mutation method is adopted for the second layer of chromosome, that is, a new value is randomly generated in the set of selectable equipment of the corresponding selected gene bit, and the original gene bit gene value is replaced; two mutation methods are cooperatively operated for the first layer of chromosome to realize gene mutation, and the chromosome individual of mutation operation is obtained;
[0175] Module M5, decodes the chromosome individual of mutation operation to generate the processing sequence and processing time of each workpiece process turnover batch on each device, and calculates the total completion time.
[0176] Specifically, in module M1, the constraint condition includes:
[0177] a, the total number B of the i-th workpiece i is kept unchanged in the process of splitting each process turnover batch, that is, for any process j belonging to workpiece i, the sum of the turnover workpiece numbers of the process turnover batches is equal to the total number B of the workpiece i , and the constraint condition is as follows:
[0178] (1)
[0179] Wherein:
[0180] , j, represent workpiece number, process number and turnover batch number respectively;
[0181] represents the total number of the i-th workpiece ;
[0182] j represents the process of workpiece ;
[0183] O ij represents the j-th process of workpiece i;
[0184] Indicates process O ij The total number of workpieces contained in the pth production or transfer sub-batch;
[0185] Indicates process O ij The total number of production or transfer sub-batches.
[0186] b. Different turnover batches of the same process of any workpiece are arranged to be processed on the same equipment. The identifier of the p-th production batch of the j-th process of workpiece i processed on equipment k is represented by the following constraints:
[0187] (2)
[0188] in, Indicates process O ij Optional Equipment Set M ij The total number of optional devices.
[0189] c. When the pth turnover batch of the jth process of the i-th workpiece is processed on the equipment k, the processing start time ST of the process turnover batch ijp and the processing end time ET of the process turnover batch ijp There are constraints, which are expressed as follows: the processing time is equal to the time for the equipment to process a single piece of this type of workpiece multiplied by the number of workpieces included in the turnover batch;
[0190] (3)
[0191] in:
[0192] ST ijp Represents workpiece The first step of process j The processing start time of each turnover batch;
[0193] ET ijp Represents workpiece The first step of process j The processing end time of each turnover batch;
[0194] Represents workpiece The processing time of process j on equipment k in the optional equipment set Mij;
[0195] Indicates process O ij The pth production batch is scheduled within the start and end time window of equipment k, including the unavailable time of equipment k except for process processing (repair, maintenance, holidays, etc.).
[0196] d. Any turn batch processing, following the turn batch precedence constraint, i.e. the subsequent turn batch of the same process is processed after the previous turn batch of the same process is completed, the constraint condition is shown as follows:
[0197] (4)
[0198] e. Any turn batch processing, following the process route constraint, i.e. all workpieces in the turn batch complete the processing of the immediately previous process and complete the turn from the immediately previous process to the current process before the subsequent turn batch of the same process is processed, the constraint condition is shown as follows:
[0199] (5)
[0200] represents the number of subsequent turn batches.
[0201] Wherein, the previous batch L is the minimum value under the following constraint:
[0202] (6)
[0203] f. The latest completion time CT of all workpieces under the input task max is the latest completion time in the completion time of all workpieces, ET i is the total completion time of the i-th workpiece under the scheduling scheme, the constraint condition is shown as follows:
[0204] (7)
[0205] Wherein, represents the maximum latest completion time.
[0206] g. The j-th process O of the workpiece i ij is processed on the k-th device in the optional device set M ij The processing time PT ijk is non-negative, and the constraint condition is shown as follows:
[0207] (8)
[0208] h. Single-process turn batch processing is continuous, and the constraint condition is shown as follows:
[0209] (9)
[0210] Wherein,
[0211] ;
[0212] : the start processing time of the pth production / transmission sub-batch of the ith workpiece jth process on the device k;
[0213] : the end processing time of the pth production / transmission sub-batch of the ith workpiece jth process on the device k;
[0214] : the start processing time of the zth production / transmission sub-batch of the xth workpiece yth process on the device k;
[0215] : the end processing time of the zth production / transmission sub-batch of the xth workpiece yth process on the device k;
[0216] x, y, z respectively represent workpiece number, process number, and turnover batch number;
[0217] represents any.
[0218] Further, in the module M1, the objective function of the flexible workshop production scheduling in the rolling production mode is represented as follows:
[0219] (10)
[0220] wherein, represents minimization, i.e. optimization objective.
[0221] Specifically, in the module M5, the chromosome decoding comprises the following modules:
[0222] Module M5.1, for the gene position value Gene of the first layer of the chromosome, let i be the quotient obtained by dividing Gene by 100, and j be the remainder obtained by dividing Gene by 100, the gene position value Gene represents the turnover batch of the workpiece i in the process j, Gene is obtained in sequence and the number of times of occurrence of Gene is determined, the pth occurrence of Gene represents the pth turnover batch of the workpiece i in the process j.
[0223] Module M5.2, according to the gene position value Gene, the corresponding workpiece process O ij (O ij of the workpiece i in the jth process) is solved, and it is searched in the decoded process set MS whether O ij exists, if O ij exists in MS, it is jumped to execute the module M3, otherwise, based on the selection mechanism constructed by the stagnation generation number statistics value and the population average fitness value of the iterative optimization result, the process device is determined in the device coding matching, random device generation or device bidding mode.
[0224] Module M5.3, based on the existing task scheduling time record of the process equipment and the processing time constraint, determines the process turn-around batch O ijp (O ijp the processing start time and end time of the pth turn-around of the jth process of the ith workpiece, updates the record of the turn-around task on the selected process equipment, and adds the decoded workpiece process O ij to the decoded process set MS.
[0225] Module M5.4, repeatedly executes modules M5.1 to M5.3 until the decoding of all gene positions of the first layer of the chromosome is completed, and calculates the completion time of the scheduling scheme corresponding to the current chromosome individual according to formula (7).
[0226] Those skilled in the art know that, in addition to implementing the system provided by the present application and each device, module, unit thereof in the form of pure computer readable program code, the system provided by the present application and each device, module, unit thereof can also be implemented in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers and embedded microcontrollers, etc. to achieve the same function by logically programming the method steps. Therefore, the system provided by the present application and each device, module, unit thereof can be considered as a hardware component, and the devices, modules, units included therein for implementing various functions can also be considered as structures within the hardware component; the devices, modules, units for implementing various functions can also be considered as both software modules implementing methods and structures within hardware components.
[0227] The specific embodiments of the present application are described above. It should be understood that the present application is not limited to the specific embodiments described above, and various changes or modifications can be made by those skilled in the art within the scope of the claims, which do not affect the essential content of the present application. In the case of no conflict, the embodiments of the present application and the features in the embodiments can be combined with each other arbitrarily.
Claims
1. A flexible scheduling method for variable batch size in a discrete manufacturing workshop, characterized in that: The following steps are included: Step S1: Establish the constraints for splitting the same type of workpieces under the same order into process turnover batches in each process, take the shortest completion time as the scheduling goal, and construct the objective function of variable batch flexible scheduling for discrete manufacturing workshops; Step S2, based on the constraint conditions and the objective function, using a double-layer chromosome structure to describe the chromosome individuals of the genetic algorithm, and using a random generation method to generate an initial population including multiple chromosome individuals; Step S3, based on the initial population and according to the coding characteristics of the double-layer chromosome structure, a uniform crossover method is adopted to obtain chromosome individuals for crossover operation, thereby completing the exchange and transmission of process equipment selection information; Step S4: performing a mutation operation on the chromosome individuals subjected to the crossover operation. A random gene position value mutation method is used for the second layer of chromosomes, i.e., a new value is randomly generated in the process optional equipment set corresponding to the selected gene position and replaces the original gene position gene value. A collaborative operation of two mutation methods is used to achieve gene mutation on the first layer of chromosomes to obtain the chromosome individuals subjected to the mutation operation. The first mutation mode of the first layer of the chromosome is to randomly select the position of the mutant gene of the parent chromosome, decode the process turnover batch, determine the turnover batch, and then calculate the turnover batch immediately before and after the current turnover batch according to the number of turnover workpieces corresponding to the turnover batch, and locate the position of the immediately before and after turnover batches in the chromosome, and determine the adjustable position range of the mutant gene by combining the positions of the turnover batches before and after the same process. A new gene position n different from the current position o is randomly selected within the adjustable position range. When the position moves forward, the gene in the original [n, o-1] range is moved back by one position, and when the position moves back, the gene in the original [o, n+1] range is moved forward by one position. The second mutation method of the first layer of the chromosome is to randomly select workpieces and regenerate the turnover batch to which the workpieces belong, and then combine them with the original gene sequence of the non-selected workpieces in the first layer of genes of the parent chromosome to complete the chromosome mutation; Step S5: Decode the chromosome individuals of the variation operation, generate the processing sequence and processing time of each workpiece process turnover batch on each device, and calculate the total completion time.
2. The variable batch flexible scheduling method for discrete manufacturing workshops according to claim 1, characterized in that: In step S1, the constraints include: a. The total number of type i workpieces B i It remains unchanged during the splitting process of each process turnover batch, that is, for any process j belonging to workpiece i, the sum of the turnover workpieces of its process turnover batch is equal to the total number of workpieces B i , the constraints are expressed as follows: (1) in: 、j、 Respectively represent the workpiece number, process number and turnover batch number; Indicates the The total number of workpieces; j represents the workpiece process; O ij represents the j-th process of workpiece i; Indicates process O ij The total number of workpieces contained in the pth production or transfer sub-batch; Indicates process O ij Total number of sub-batches produced or transferred; b. Different turnover batches of the same process of any workpiece are arranged to be processed on the same equipment. The identifier of the p-th production batch of the j-th process of workpiece i processed on equipment k is represented by the following constraints: (2) in, Indicates process O ij Optional Equipment Set M ij Total number of optional equipment; c. When the pth turnover batch of the jth process of the i-th workpiece is processed on the equipment k, the processing start time ST of the process turnover batch ijp and the processing end time ET of the process turnover batch ijp There are constraints, which are expressed as follows: the processing time is equal to the time for the equipment to process a single piece of this type of workpiece multiplied by the number of workpieces included in the turnover batch; (3) in: ST ijp Represents workpiece The first step of process j The processing start time of each turnover batch; ET ijp Represents workpiece The first step of process j The processing end time of each turnover batch; Represents workpiece The processing time of process j on equipment k in the optional equipment set Mij; Indicates process O ij The p-th production batch is scheduled within the start and end time window of equipment k, and the unavailable time of equipment k except for process processing; d. For any turnover batch processing, the turnover batch sequence constraint must be observed. That is, the subsequent turnover batch production of the same process can be carried out after the previous turnover batch of the same process is completed. The constraint conditions are as follows: (4) e. For any turnover batch processing, the process route constraints must be followed. That is, all workpieces in the turnover batch must complete the processing of the immediate preceding process and complete the turnover of the immediate preceding process to the current process before the subsequent turnover batch production of the same process can be carried out. The constraints are as follows: (5) Indicates the number of subsequent turnover batches; Among them, the preceding batch L is the minimum value under the following constraints: (6) f. Enter the latest completion time CT of all workpieces under the task max The latest completion time among all workpiece completion times, ET i is the time to complete the processing of the i-th job under the scheduling scheme, and the constraints are expressed as follows: (7) in, Indicates the maximum latest completion time; g, the jth process O of workpiece i ij In the optional equipment set M ij The processing time PT on the kth device in ijk Non-negative constraints, the constraints are expressed as follows: (8) h. Single-process turnover batch processing is continuous, and the constraints are expressed as follows: (9) in, ; : The start processing time of the pth production / transfer batch of the jth process of the i-th workpiece on the equipment k; : The end time of the pth production / transfer sub-batch of the jth process of the i-th workpiece on the equipment k; : The start time of processing of the zth production / transfer batch of the xth workpiece in the yth process on the equipment k; : The end time of the zth production / transfer sub-batch of the xth workpiece in the yth process on the equipment k; x, y, and z represent the workpiece number, process number, and turnover batch number, respectively; It means any; The objective function of flexible workshop production scheduling under the rolling production mode is expressed as follows: (10) in, represents minimization, that is, optimization goal.
3. The variable batch flexible scheduling method for discrete manufacturing workshops according to claim 1, characterized in that: In step S2, the double-layer chromosome structure includes: The first level of chromosomes uses integer coding to represent process turnover batch information; The second level of chromosomes uses integer coding to characterize the processing equipment selected for each process.
4. The variable batch flexible scheduling method for discrete manufacturing workshops according to claim 1, characterized in that: In step S3, for the first layer of chromosomes, the crossover method adopts sequential crossover determined by the starting position, that is, the crossover starting position is determined to be the first position of the first layer of chromosomes, and the crossover ending position is randomly generated within the range of the first layer of chromosomes.
5. The variable batch flexible scheduling method for discrete manufacturing workshops according to claim 1, characterized in that: In step S3, for the same positions in the second layer of chromosomes corresponding to the same representative processes, a uniform crossover method is used to complete the exchange and transmission of process equipment selection advantage information.
6. The variable batch flexible scheduling method for discrete manufacturing workshops according to claim 1, characterized in that: In step S5, chromosome decoding includes the following steps: Step S5.1: For the gene bit value Gene at the first level of the chromosome, let i be the quotient of dividing Gene by 100, rounded to an integer, and j be the remainder of dividing Gene by 100. The gene bit value Gene represents the turnover batch of process j of workpiece i. Gene is obtained sequentially and the number of occurrences of Gene is determined. The pth occurrence of Gene represents the pth turnover batch of process j of workpiece i. Step S5.2, solve the corresponding workpiece process O according to the gene bit value Gene ij , search for O in the decoded process set MS ij , if there is O in MS ij , jump to step S3, otherwise, based on the selection mechanism constructed by the stagnant algebraic statistics value of the iterative optimization result and the average fitness value of the population, the process equipment is determined by using equipment code matching, random equipment generation or equipment bidding; Step S5.3, based on the existing task schedule time records and processing time constraints of the process equipment, use equations (3), (4) and (5) to determine the process turnover batch O ijp The processing start time and end time are recorded, and the processing turnover task is updated on the selected process equipment, and the decoded workpiece process O ij Add to the decoded process set MS; In step S5.4, steps S5.1 to S5.3 are repeated until the decoding of the numerical values of all gene bits in the first layer of the chromosome is completed. The completion time of the scheduling plan corresponding to the current chromosome individual is calculated according to formula (7).
7. A variable batch flexible scheduling system for discrete manufacturing workshops, characterized by: include; Module M1 establishes the constraints for splitting the same type of workpieces under the same order into process turnover batches in each process, takes the shortest completion time as the scheduling goal, and constructs the objective function for flexible scheduling of variable batches in discrete manufacturing workshops; Module M2, based on the constraints and objective function, uses a double-layer chromosome structure to describe the chromosome individuals of the genetic algorithm, and uses a random generation method to generate an initial population containing multiple chromosome individuals; Module M3, based on the initial population and the encoding characteristics of the double-layer chromosome structure, uses a uniform crossover method to obtain chromosome individuals for the crossover operation and complete the exchange and transmission of process equipment selection information; Module M4 performs mutation operations on the chromosome individuals that have undergone the crossover operation. A random gene position value mutation method is used for the second layer of chromosomes. This method randomly generates new values in the process optional equipment corresponding to the selected gene position and replaces the original gene position value. A collaborative operation of two mutation methods is used to achieve gene mutation on the first layer of chromosomes to obtain the chromosome individuals that have undergone the mutation operation. The first mutation mode of the first layer of the chromosome is to randomly select the position of the mutant gene of the parent chromosome, decode the process turnover batch, determine the turnover batch, and then calculate the turnover batch immediately before and after the current turnover batch according to the number of turnover workpieces corresponding to the turnover batch, and locate the position of the immediately before and after turnover batches in the chromosome, and determine the adjustable position range of the mutant gene by combining the positions of the turnover batches before and after the same process. A new gene position n different from the current position o is randomly selected within the adjustable position range. When the position moves forward, the gene in the original [n, o-1] range is moved back by one position, and when the position moves back, the gene in the original [o, n+1] range is moved forward by one position. The second mutation method for the first layer of chromosomes is to randomly select artifacts and regenerate the turnover batch to which the artifacts belong. This is then combined with the original gene sequence of the non-selected artifacts in the first layer of genes of the parent chromosome to complete the chromosome mutation. Module M5 decodes the chromosome individuals of the mutation operation, generates the processing sequence and processing time of each workpiece process turnover batch on each device, and obtains the total completion time.
8. The variable batch flexible scheduling system for discrete manufacturing workshops according to claim 7, characterized in that: In the module M2, the double-layer chromosome structure includes: The first level of chromosomes uses integer coding to represent process turnover batch information; The second level of chromosomes uses integer coding to characterize the processing equipment selected for each process.
Citation Information
Patent Citations
Low-energy-consumption flexible workshop scheduling method
CN110619437A
Hybrid optimization method for flexible workshop scheduling based on genetic algorithm
CN111027773A
Emergency material transportation and loading collaborative optimization method based on double-layer genetic coding
CN113222272A