Method for scheduling a flow line

The workflow scheduling method based on population evolution and consistent coding solves the problem of repetitive coding in genetic algorithms, achieves more efficient process arrangement and resource allocation, reduces time and machine load, and generates a better job schedule.

CN114764669BActive Publication Date: 2026-06-05HITACHI LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HITACHI LTD
Filing Date
2021-01-13
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

In existing technologies, flow scheduling methods based on genetic algorithms suffer from repetitive coding problems, leading to increased time costs and machine load, and making it difficult to effectively avoid process conflicts and generate unique job schedules.

Method used

The algorithm employs population initialization, population evolution, decoding, and screening steps. Through consistent coding and crossover mutation algorithms, it constructs individual codes for workpiece and workbench combinations, eliminates redundant codes, optimizes scheduling indicators using a genetic algorithm, and adjusts parameters using an annealing algorithm to improve search efficiency.

Benefits of technology

It effectively eliminates redundant coding, reduces time costs and machine load, improves the efficiency of generating better job schedules within a certain time, and optimizes the scientific nature of process arrangement and resource allocation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114764669B_ABST
    Figure CN114764669B_ABST
Patent Text Reader

Abstract

The present application relates to a flow shop scheduling method, comprising: a population initialization step, based on the number of multiple workpieces processed in the flow shop, the number of workbenches processing each workpiece in each process, the processing time of each workpiece processed by each workbench, randomly generating a set of N individual codes as a population; and a population evolution step, comprising: a population diversification step, using a genetic algorithm to expand the number of individual codes in the population to be greater than N in a manner that meets the pre-set limit conditions; a consistent coding step, removing duplicate individual codes in the population that can be decoded into the same job schedule; a decoding step, decoding each individual code in the population into a corresponding job schedule and calculating the value of the scheduling index; and a population screening step, sorting all individual codes in the population according to the size of the scheduling index value, and replacing the population with the set of the top N individual codes with better scheduling indexes.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to a scheduling method for assembly line operations. Background Technology

[0002] In the manufacturing industry, multiple workpieces are often processed on multiple workbenches. For such assembly line operations, the arrangement of the processing order of each workpiece on each workbench, i.e., the scheduling, needs to take into account the allocation of time and resources. A scientific and reasonable scheduling scheme should be able to effectively improve production efficiency and reduce processing costs.

[0003] Regarding such scheduling arrangements, Patent Document 1 discloses a traditional job shop scheduling method based on an improved genetic algorithm, which aims to minimize the maximum completion time of the job schedule and calculates the optimal solution for the process order of the workpieces based on the optimized genetic algorithm.

[0004] Existing technical documents

[0005] Patent documents

[0006] Patent Document 1: CN111667071A Summary of the Invention

[0007] Technical problems to be solved

[0008] In the method of patent document 1, the following is employed: Figure 1 The workpiece process code in form C1 shown in (a) assumes there are 3 workpieces, numbered J1, J2, and J3 (referred to as 1, 2, and 3 for ease of coding), and 3 workbenches, numbered S1, S2, and S3. It is known that workpiece 3's first process uses workbench S2, the second process uses workbench S1, and the third process uses workbench S3; workpiece 1's first process uses workbench S1, the second process uses workbench S3, and the third process uses workbench S2; and workpiece 2's first process uses workbench S1, the second process uses workbench S2, and the third process uses workbench S3. The time spent on each process is also known. Therefore, a code like C1 represents a sequential arrangement of workpiece numbers. Based on the workbench and time used for each workpiece in each process, this code can be decoded to obtain a job schedule, which represents the time arrangement for processing each workpiece on each workbench.

[0009] During decoding, to avoid process conflicts, the start time of each process must be greater than or equal to the completion time of the previous process on that workstation, and the start time of each process must be greater than or equal to the completion time of the previous process on the same workpiece. Under conditions of no conflicts and following the greedy algorithm, an encoding can be decoded into a unique job schedule, for example... Figure 1The encoding C1 shown in (a) is decoded as Figure 1 The work schedule shown in (b) has time on the horizontal axis. The greedy rule mentioned above means that the start time of each operation is equal to the larger of the completion time of the operation preceding the workbench of that operation and the completion time of the operation preceding the workpiece of that operation. In other words, the idle time of the workbench is minimized.

[0010] According to the technical solution in Patent Document 1, process conflicts in the decoded job schedule can be avoided. A process conflict occurs when a workpiece is processed simultaneously on two or more workbenches at a given time, or when a workbench processes two or more workpieces simultaneously at a given time, or when the same workpiece passes through the same workbench more than twice, or when a workpiece is not processed in the correct order. If a process conflict occurs, the code becomes invalid, wasting time calculating the code during algorithm execution. However, this workpiece process coding has the following drawback: multiple codes may correspond to the same job schedule, for example... Figure 1 The codes C1, C2, C3, C4, and C5 shown in (c) all correspond to Figure 1 The job scheduling table shown in (b) is an example. In this case, the codes C2 to C5 become duplicate codes. The time spent by the genetic algorithm on the duplicate codes is unnecessary, leading to increased time costs and machine load. Furthermore, determining whether multiple codes correspond to the same job scheduling table can only be done after decoding the codes into the job scheduling table, making it difficult to eliminate this defect.

[0011] Technical methods for solving technical problems

[0012] This invention addresses the aforementioned technical problems by providing a scheduling method for assembly line operations. The method comprises: a population initialization step, which randomly generates a set of N individual codes as a population based on the numbers of multiple workpieces processed in the assembly line operation, the numbers of the workstations processing each workpiece in each process, and the processing time of each workstation for each workpiece; each individual code represents a permutation of all workpiece segments, where a workpiece segment refers to a combination of a workpiece and a processing workstation in a certain process, and N is a natural number greater than 1; and a population evolution step, which includes a population diversification step to satisfy pre-set limiting conditions. The formula involves: using a genetic algorithm to expand the number of individual codes in the population to greater than N; a consistency coding step to remove duplicate individual codes in the population that can be decoded into the same job schedule, where the job schedule represents the time arrangement for processing multiple workpieces on multiple workstations, obtained by decoding the individual codes in a way that minimizes process conflicts and idle time at the workstations; a decoding step to decode each individual code in the population into the corresponding job schedule and calculate the scheduling index value of each job schedule; and a population screening step to sort all individual codes in the population according to the value of the scheduling index and replace the population with the set of the top N individual codes with the best scheduling index.

[0013] Therefore, this invention adopts a new coding method. Compared with the one-dimensional coding of the prior art, this invention constructs individual codes based on the combination of workpiece and processing station, and performs consistent coding on this basis, thereby eliminating redundant codes corresponding to the same work schedule, eliminating the defects in the prior art, and reducing time costs and machine load.

[0014] In the above-described scheduling method for assembly line operations, preferably, in the consistency coding step, for each individual code in the population, the position exchange of work segments is performed according to the following rules until no further exchange is possible, thereby obtaining a unique code for the work schedule table corresponding to that individual code, and replacing that individual code with this unique code in the population. Finally, duplicate unique codes in the population are deleted:

[0015] Rule 1: For a given workpiece segment, the workpiece segment of the next process of the same workpiece can be exchanged with the workpiece segment of the next process of the same workbench.

[0016] Rule 2: For a given workpiece segment, the next process segment of the same workpiece can be exchanged with an adjacent workpiece segment that has different workpieces and different worktables.

[0017] Rule 3: If the two workpiece segments to be exchanged have the same workpiece or the same workbench, or if there is a workpiece segment between the two workpiece segments whose workbench is the same as the two workpiece segments to be exchanged, then the exchange is cancelled.

[0018] Rule 4: If the swap will result in the workpiece numbers being arranged in the prescribed monotonic order, then the swap is allowed; otherwise, the swap is cancelled.

[0019] Based on the above structure, the exchange of workpiece segments according to the set rules can convert all individual codes corresponding to the same work schedule into the same unique code, thereby accurately identifying and deleting redundant codes, reducing the time cost and machine load of various calculations.

[0020] In the above-mentioned scheduling method for assembly line operations, preferably, the genetic algorithm employs the following crossover algorithm: Two individual codes are randomly selected from the N individual codes of the population as parent codes, and a workpiece A is randomly selected, maintaining the order of workpiece A in these two individual codes. All workpiece segments other than workpiece A from one parent code are sequentially assigned to the other parent code to construct a child code. Similarly, all workpiece segments other than workpiece A from the other parent code are sequentially assigned to the first parent code to construct another child code. The two child codes are then decoded into corresponding job schedules, and child codes that do not meet the specified conditions are deleted. The remaining child codes are then added to the population.

[0021] Based on the above structure, and using the idea of ​​genetic algorithm, a crossover algorithm is used to generate new individual codes, thereby enabling population diversification while maintaining the non-conflict of workpiece segments.

[0022] In the above-mentioned scheduling method for assembly line operations, preferably, the genetic algorithm employs the following mutation algorithm: One individual code is randomly selected from the N individual codes in the population; for this individual code, a code segment of a predetermined length R is randomly selected, and its permutation is performed to construct R! new individual codes. These new individual codes are then decoded into corresponding job schedules. New individual codes that do not meet the aforementioned conditions are deleted. For the remaining new individual codes, the scheduling index is calculated, and the new individual code with the best scheduling index is added to the population. Here, R is a natural number greater than 0, and its value is above min(√(n×m),m) and below max(√(n×m),m), where n is the number of workpieces, m is the number of workstations, and both n and m are natural numbers greater than 0.

[0023] Based on the above structure, and using the idea of ​​genetic algorithm, a mutation algorithm is used to generate new individual codes, thereby enabling population diversification while maintaining the non-conflict of workpiece segments.

[0024] In the aforementioned scheduling method for assembly line operations, preferably, the genetic algorithm employs the following mutation algorithm: From the N individual codes in the population, one individual code is randomly selected. For this individual code, a code segment of a predetermined length R is randomly selected, and its permutation is performed to construct R! new individual codes. These new individual codes are then decoded into corresponding job schedules. New individual codes that do not meet the aforementioned constraints are deleted. For the remaining new individual codes, the scheduling index is calculated. For the new individual code with the best scheduling index, its acceptance probability ρ is calculated based on its scheduling index Fmax according to the following formula.

[0025]

[0026] If the acceptance probability ρ = 1, the new individual with the best scheduling index is directly added to the population; otherwise, it is added to the population with probability ρ, where T c Adjust according to the following formula:

[0027]

[0028] T0 = ​​tmax - tmin, where tmax represents the maximum effective processing time of the workbench, and tmin represents the minimum effective processing time of the workbench. The effective processing time of a certain workbench is the sum of the actual processing times of all workpieces on that workbench. R is a natural number greater than 0, and its value is above min(√(n×m),m) and below max(√(n×m),m). n is the number of workpieces, m is the number of workbench, and both n and m are natural numbers greater than 0. MaxF is the optimal scheduling index value calculated before the execution of this mutation algorithm in the scheduling method.

[0029] Based on the above structure, the mutation algorithm is improved by using the annealing algorithm. By dynamically adjusting parameters, the optimal solution generated by mutation is used to search for a better solution in the global range near the optimal solution. Thus, when the newly generated individual has a better code, the probability of accepting it is 100%, while the probability of accepting it gradually decreases when the newly generated individual has no better code. This feature combines the search speed of the genetic algorithm with the global search capability of the annealing algorithm, which can improve the efficiency of obtaining a better job scheduling table within a certain time.

[0030] In the above-described scheduling method for assembly line operations, preferably, the population evolution step further includes a transposition step between the decoding step and the population selection step. For each job arrangement table obtained in the decoding step, based on the transposition rule, the workpiece segments of the same workbench are transposed sequentially according to the workbench number. If a new job arrangement table is obtained after transposition, the scheduling index of the new job arrangement table is calculated, and the new job arrangement table is re-encoded into individual codes and added to the population.

[0031] The transposition rule is as follows:

[0032] Rule A: Interchange the positions of adjacent workpiece segments on the same workbench, or between the last and middle workpiece segments.

[0033] Rule B: If a workpiece segment conflict occurs during the transposition process, the transposition shall be cancelled.

[0034] Rule C: During the switching process, minimize the idle time of the workbench without causing conflicts;

[0035] Rule D: If a transposition makes the scheduling metrics of the job schedule better, then transpose the job; otherwise, cancel the transposition.

[0036] Based on the above structure, by transposing the decoded job schedule, individuals with better scheduling metrics can be reintroduced into the population, increasing population diversity, specifically the diversity of superior individual codes. This method can escape local optima in the algorithm, improving the efficiency of obtaining a better job schedule within a given time.

[0037] In the above-described scheduling method for assembly line operations, preferably, the scheduling index is determined based on at least one of the following parameters: job completion time, workbench idle time, effective workbench idle time, and workpiece waiting time. The job completion time refers to the time difference between the moment when the last workpiece finishes processing on the last workbench and the moment when the first workpiece begins processing on the first workbench. The workbench idle time refers to the sum of the idle times on a workbench before the moment when the last workpiece finishes processing on the last workbench. The effective workbench idle time refers to the sum of the idle times on a workbench before the moment when the last workpiece finishes processing on the last workbench. The workpiece waiting time refers to the sum of the waiting times on a workpiece before the end of its last process, before it is processed by any workbench.

[0038] Based on the above structure, scheduling indicators are determined using at least one of the following: job completion time, workbench idle time, effective workbench idle time, and workpiece waiting time. This allows for the generation of an optimal job schedule based on actual needs. For example, the optimal schedule can be generated with the goal of shortening job completion time, workbench idle time, effective workbench idle time, and workpiece waiting time. Alternatively, the optimal schedule can be generated with the goal of reducing job completion time, thereby improving job completion efficiency. Or, the optimal schedule can be generated with the goal of reducing the mean square error of workbench idle time, effective workbench idle time, and workpiece waiting time, thereby improving the idle balance and load balance of each workbench or workpiece in the overall operation.

[0039] In the above-mentioned scheduling method for assembly line operations, preferably, the scheduling index is a fitness value, which is determined based on the effective idle time of the workbench, and the fitness value = 1 / (mean square deviation of effective idle time of the workbench + 1).

[0040] Therefore, the fitness value can be used to characterize the idle balance and load balance of each workstation in the overall operation, and the optimal job scheduling table can be obtained by using the algorithm.

[0041] In the above-described scheduling method for assembly line operations, preferably, the scheduling index is a fitness value, which is determined based on the operation completion time and the effective idle time of the workbench.

[0042]

[0043] p1 and p2 are set according to the weights of the mean squared deviation of the job completion time and the effective idle time of the workbench.

[0044] Therefore, the fitness value can be used to simultaneously characterize the completion efficiency of the task and the idle balance and load balance of each workstation in the overall task. The weights of the two can be adjusted according to actual considerations, thereby obtaining the optimal task schedule using the algorithm.

[0045] In the above-described scheduling method for assembly line operations, it is preferred that the limiting condition is a limitation on at least one of the following parameters: the waiting time of one or more workpieces, and the effective idle time of one or more workstations.

[0046] Based on the above structure, it is possible to set limiting conditions according to actual needs, thereby avoiding the generation of work schedules that do not conform to the actual situation or are difficult to meet the real conditions.

[0047] Invention Effects

[0048] The scheduling method for assembly line operations according to the present invention can eliminate the defects in the prior art, avoid the increase in time costs and machine load, and improve the efficiency of obtaining a better work schedule within a certain period of time. Attached Figure Description

[0049] Figure 1 (a) shows encoding C1 based on the existing technology encoding method, (b) shows the job schedule obtained by decoding encoding C1, and (c) shows five encodings C1 to C5 that can all be decoded into the job schedule shown in (b).

[0050] Figure 2 This is a flowchart of the scheduling method for the flow operation in this embodiment.

[0051] Figure 3 This indicates that the encoding method generated according to this embodiment is similar to... Figure 1 The individual code D1 corresponds to the code C1.

[0052] Figure 4 This represents the unique code D2 obtained by consistent coding of individual code D1.

[0053] Figure 5 This is an example of a work schedule used to illustrate the transposition process. The upper part shows the work schedule before the transposition, and the lower part shows the work schedule after the transposition. Detailed Implementation

[0054] The scheduling method for the assembly line operation of this embodiment will be described below with reference to the accompanying drawings. In this assembly line operation, there are n workpieces that need to be processed and m workstations (machines, windows, personnel, etc.) for processing these workpieces. It is necessary to calculate the work schedule for processing workpieces at these workstations, and according to the work schedule, all workpieces are processed through each workstation in their respective process order.

[0055] This work schedule must meet the following conditions:

[0056] (1) Each of the n workpieces must be processed through these m workbenches according to a certain processing order. If a workpiece is not processed in the order of the process, it is considered a conflict.

[0057] (2) For each workpiece, each workbench processes a certain process of the workpiece;

[0058] (3) Each workbench can only process one workpiece at a time; otherwise, it is considered a conflict.

[0059] (4) The same workpiece can only be processed on one workbench at the same time; otherwise, it will be considered a conflict.

[0060] (5) The same workpiece should not pass through the same workbench more than twice, otherwise it is considered a conflict.

[0061] Figure 2 A flowchart illustrating the scheduling method for the flow operation of this embodiment is shown.

[0062] First, data is acquired in step S201. Specifically, this involves acquiring the numbers of multiple workpieces being processed in the assembly line operation, the number of the workbench that processes each workpiece in each process, and the processing time for each workbench to process each workpiece. For example, as shown in the table below, taking the case of m=n=3 as an example, the following data is acquired: workpiece set (J1, J2, ..., Jn), workbench set (S1, S2, ..., Sm), the workbench sequence list corresponding to each process of each workpiece, and the time required for each workbench to process each workpiece.

[0063] Table 1

[0064]

[0065] Table 2

[0066]

[0067] Next, in step S202, parameters are set. Specifically, parameters such as the maximum number of evolutions C, scheduling indicators, and limiting conditions can be set.

[0068] Wherein, the maximum number of evolutions C represents the number of times the population evolution steps described later are executed, and can be set based on experience. The scheduling index is used to characterize the quality of the job schedule, and this scheduling index can be determined based on at least one of the following: job completion time, workbench idle time, effective workbench idle time, and workpiece waiting time.

[0069] Job completion time reflects the overall efficiency of the operation; a shorter completion time indicates higher efficiency for that batch of workpieces. In production management, it is desirable to minimize batch completion time, which is beneficial for meeting delivery deadlines and reducing labor and equipment costs.

[0070] Reference Figure 1 In the example of the work schedule shown in (b), the above parameters are specifically defined as follows:

[0071] Job completion time = the moment when the last workpiece is finished being processed on the last workbench - the moment when the first workpiece is started being processed on the first workbench.

[0072] Workbench idle time = the sum of all idle time (idle time without processing any workpieces) of a certain workbench before the last workpiece is finished being processed on the last workbench.

[0073] Effective idle time of a workbench = the sum of all idle times (idle time when no workpieces are processed) of a workbench before the last workpiece on the workbench is finished. It is also equal to the time when the last workpiece on the workbench is finished – the time when the first workpiece in the entire operation begins to be processed – the effective processing time of the workbench. Wherein, effective processing time of a workbench = the actual processing time of all workpieces on the workbench.

[0074] The root mean square deviation of the effective idle time of a workstation can characterize the idle balance of each workstation in the overall operation. The smaller the root mean square deviation, the more balanced the idle time of each workstation. In production management, it is desirable for workstations to have as balanced an idle time and workload as possible.

[0075] Workpiece waiting time = the sum of the waiting time of a workpiece before the last process of a workpiece is completed and it has not been processed by any workstation.

[0076]

[0077] The average effective idle time of the workbench is equal to the sum of the effective idle times of the workbench divided by the number of workbench.

[0078] In this implementation, the fitness value is used as the scheduling index.

[0079] When the goal is to minimize the job completion time, the fitness value can be defined as:

[0080] Fitness value = 1 / (job completion time + 1).

[0081] When the goal is to minimize the mean squared error of the effective idle time of the workbench, the fitness value can be defined as:

[0082] Fitness value = 1 / (mean square deviation of effective idle time of the workbench + 1).

[0083] When the goal is to minimize the root mean square error of both job completion time and workstation effective time, the fitness value can be defined as:

[0084]

[0085] Among them, p1 and p2 are set according to the weights of the mean squared deviations of the task completion time and the effective idle time of the workbench, that is, the importance attached to the two. For example, it can be set as p1 / p2 = 2.

[0086] The fitness values ​​described above are merely examples and can be defined in other forms as needed, such as based on the sum of the effective idle time of each workbench, the sum of the idle time of each workbench, the root mean square deviation of the idle time of each workbench, the sum of the waiting time of each workpiece, and the root mean square deviation of the waiting time of each workpiece (e.g., when the workpiece needs to be kept at a certain temperature).

[0087] The aforementioned limiting conditions refer to restrictions on certain parameters of the work schedule, such as setting maximum or minimum values ​​for the waiting time of one or more workpieces or the effective idle time of one or more workstations. In addition, one limiting condition can be set as the priority, with the other limiting conditions having the next highest priority.

[0088] Next, proceed to step S203 to perform the population initialization step, setting c to the number of population evolutions, at which point c = 0. Based on the multiple workpiece numbers obtained in step S201, the workbench number that processes the workpiece in each process, and the processing time of each workbench for each workpiece, a set of N (N is a natural number greater than 1) individual codes is randomly generated as the population.

[0089] Regarding the individual encoding, this invention proposes a novel encoding method that differs from existing technologies, such as... Figure 3 As shown, D1 represents the encoding method generated according to this embodiment, and... Figure 1 The individual code corresponding to code C1 is defined as follows. In D1, the first line represents the workpiece number (again, the letter J is omitted for ease of encoding). The number of times a workpiece number appears in the code indicates the corresponding process step for that workpiece. The second line represents the workstation number for each workpiece in its corresponding process. As mentioned earlier, provided the processes do not conflict and the greedy algorithm rule is satisfied, each individual code can be decoded into a unique job schedule.

[0090] In D1, the length of the individual code is the total number of operations for all workpieces across all workstations (9 in this example). For each workpiece, the order in which they appear in the individual code corresponds to the order of the workpiece processing operations in the job schedule. For example, ① represents the first operation of workpiece 3, ② represents the first operation of workpiece 1, ③ represents the second operation of workpiece 1, ④ represents the first operation of workpiece 2, ⑤ represents the third operation of workpiece 1, ⑥ represents the second operation of workpiece 3, ⑦ represents the second operation of workpiece 2, ⑧ represents the third operation of workpiece 3, and ⑨ represents the third operation of workpiece 2. Therefore, combining the processing time of each operation shown in Table 2, and according to the order in which the workpieces appear in the code, the workpiece segments of each workpiece are placed sequentially in the job schedule, thus decoding the process. Figure 1 The work schedule shown in (b) is as follows. In the work schedule, the workpiece segment refers to the processing time of a workpiece on the corresponding workbench in a certain process, while in the individual code, it refers to the combination of a workpiece and the workbench that performs the processing in a certain process.

[0091] Based on the job schedule table decoded from the individual codes, the values ​​of the above scheduling indicators can be calculated.

[0092] Next, the population evolution steps S204 to S211 are executed.

[0093] First, in step S204, the number of population evolutions c is incremented, i.e., c = c + 1. When the population evolves for the first time, c = 1.

[0094] Next, in step S205, the following crossover operation is performed s1 times to diversify the population.

[0095] Specifically, two individual codes are randomly selected from the N individual codes of the population as parent individuals, as shown in the table below.

[0096] Table 3

[0097]

[0098] Randomly select a workpiece A (workpiece 2 in this example), keep the order of workpiece A in these two individual codes (the position of the gray grid does not change), assign all workpiece segments except workpiece A in parent individual 1 to parent individual 2 in sequence to construct child individual 1, and assign all workpiece segments except workpiece A in parent individual 2 to parent individual 1 in sequence to construct child individual 2, as shown in the table below.

[0099] Table 4

[0100]

[0101] The two obtained sub-individuals are decoded into corresponding job schedules, the values ​​of each scheduling indicator are calculated, and sub-individuals that do not meet the above constraints are deleted. If there are any remaining sub-individuals, they are encoded and added to the population.

[0102] Suppose that after s1 crossover operations, a total of s1' sub-individuals that do not meet the constraints are deleted. Then the number of individual codes in the population becomes N+2s1-s1'>N, and the population size is increased.

[0103] Next, in step S206, the following mutation operation is performed s2 times to diversify the population.

[0104] Specifically, one individual code is randomly selected from the N individual codes of the population as the parent individual, as shown in the table below.

[0105] Table 5

[0106]

[0107] For the parent individual, randomly select a code segment of length R (R is a natural number greater than 0, R = 3 in this example), perform full permutations on it, and construct R! new individual codes (that is, in each new individual code, all work segments except the R segment are the same as the parent individual, and the three work segments of the R segment are the full permutations of the three work segments in the parent individual). Decode the new individual codes into the corresponding job scheduling table, delete the new individual codes that do not meet the constraints, and if there are any remaining, calculate the scheduling index value for the remaining new individual codes, and add the new individual code with the largest scheduling index to the population.

[0108] The value of R can be set to be greater than or equal to min(√(n×m),m) and less than or equal to max(√(n×m),m), where n is the number of workpieces and m is the number of workbenches, and both n and m are natural numbers greater than 0.

[0109] After s2 mutation operations as described above, the population size was increased.

[0110] The crossover and mutation operations described above are used to diversify the population, increasing the number of individual codes within the population without conflict. The order of the crossover and mutation operations is not limited; either crossover or mutation can be performed alone.

[0111] Next, in step S207, consistency coding is performed.

[0112] As mentioned earlier, considering that existing encoding methods may result in multiple codes corresponding to the same job schedule, this invention adopts an encoding method similar to D1 and performs consistent encoding, transforming all individual codes corresponding to the same job schedule into identical, unique individual codes. Thus, during algorithm execution, for any job schedule, only one decoding and scheduling index calculation is required, thereby avoiding increased time costs and machine load.

[0113] Regarding consistent coding, specifically, for each individual code in the population, the positions of work segments are swapped according to the following rules until no further swapping is possible. This yields a unique code for the job schedule corresponding to that individual code. This unique code then replaces the individual code in the population. Finally, duplicate unique codes in the population are deleted. Figure 3 Take individual code D1 as an example:

[0114] Rule 1: For a certain workpiece segment, the workpiece segment of the next process of the same workpiece and the workpiece segment of the next process of the same workbench can be exchanged (for example, for workpiece segment ①, workpiece segment ⑥ and workpiece segment ⑤ can be exchanged).

[0115] Rule 2: For a certain workpiece segment, the workpiece segment of the next process of the same workpiece can be exchanged with the adjacent workpiece segment that has different workpieces and different worktables (for example, for workpiece segment ①, workpiece segment ⑥ and workpiece segment ⑦ can be exchanged).

[0116] Rule 3: If the two workpiece segments to be exchanged have the same workpiece or the same workbench, or if there is a workpiece segment between the two workpiece segments whose workbench is the same as these two workpiece segments, then the exchange is cancelled (for example, workpiece segments ② and ③, workpiece segments ⑧ and ⑨, and workpiece segments ⑤ and ⑧ cannot be exchanged).

[0117] Rule 4: If the swap will result in the workpiece numbers being arranged in the prescribed monotonic order, then the swap is allowed; otherwise, the swap is cancelled (for example, if the "prescribed monotonic order" is used as ascending order, workpiece segments ⑥ and ⑤ cannot be swapped).

[0118] According to this rule, individual code D1 undergoes a series of position swaps until no further swaps can be performed, ultimately resulting in a unique code D2 (e.g., ...). Figure 4 (As shown). In the population, the individual code D1 is replaced with the unique code D2. Similarly, the other individual codes corresponding to D1 in the same job schedule are eventually swapped to obtain D2 and replace the original individual codes. Finally, the duplicate D2 in the population is deleted.

[0119] Therefore, consistent coding can greatly reduce the time cost and machine load of computation.

[0120] Next, considering that a large number of duplicate individual codes in the job scheduling table may be deleted during the consistency coding in step S207, the number of individual codes in the population after step S207 may be less than N. To ensure the stability of population evolution, in step S208, it is determined whether the number of individual codes in the population is less than N. If it is less than N, the process returns to step S205 and crossover and / or mutation operations are performed again to achieve population diversification until the number of individual codes in the population after step S207 is greater than or equal to N.

[0121] Next, proceed to step S209 to perform decoding, which encodes and decodes each individual in the population into a corresponding job schedule table, and calculates the value of the scheduling index for each job schedule table.

[0122] Next, proceed to step S210 to perform population screening. Sort all individual codes in the population according to the calculated scheduling index values. Select the set of the top N individual codes with the largest scheduling index values ​​as the new population to replace the original population, and record the maximum value of the scheduling index, MaxF. In any population evolution, if a scheduling index value larger than MaxF is obtained, assign that value to MaxF.

[0123] Next, proceed to step S211 to determine whether the current number of population evolutions c has reached the maximum number of evolutions C set in step S202. If it has, proceed to step S212; otherwise, return to step S204 to execute the next population evolution.

[0124] In step S212, the individual encoding corresponding to MaxF is decoded into a job scheduling table, which is then output as the optimal solution. The output format is not limited and can be as follows: Figure 1 For a task schedule in the form of a chart like (b), the corresponding individual code can also be output along with the task schedule.

[0125] Furthermore, the above explanation uses the case where a larger scheduling index is better as an example, but it is not limited to this. Depending on the definition of the scheduling index, it can also be set that a smaller scheduling index is better.

[0126] Furthermore, the present invention is not limited to the embodiments described above. For example, the mutation operation described above can also be improved by using an annealing algorithm as follows.

[0127] Specifically, one individual code is randomly selected from the N individual codes in the population as the parent individual. For this individual code, a code segment of length R is randomly selected and permuted to construct R! new individual codes. The new individual codes are then decoded into corresponding job scheduling tables. New individual codes that do not meet the constraints are deleted. If there are any remaining new individual codes, the scheduling index is calculated for the remaining new individual codes. For the new individual code with the largest scheduling index, its acceptance probability ρ is calculated according to the following formula based on the scheduling index Fmax(c,k) of the individual code, where c is the number of population evolutions at this time, and k indicates that the mutation operation is executed for the kth time in this population evolution step.

[0128]

[0129] If the acceptance probability ρ = 1, the new individual with the highest scheduling index is directly added to the population; otherwise, it is added to the population with probability ρ, where T c Dynamic adjustments should be made according to the following temperature decrease formula:

[0130]

[0131] The above-mentioned "adding it to the population with probability ρ" means that a number greater than 0 and less than 1 is randomly generated. If the number is not greater than ρ, the new individual is added to the population. If the number is greater than ρ, the new individual is not added to the population.

[0132] Where T0 = tmax - tmin, tmax represents the maximum effective processing time of the workbench, tmin represents the minimum effective processing time of the workbench, the effective processing time of a certain workbench is the sum of the actual processing time of all workpieces on that workbench, R is a natural number greater than 0, and its value is above min(√(n×m),m) and below max(√(n×m),m), n is the number of workpieces, m is the number of workbench, and n and m are both natural numbers greater than 0, MaxF is the maximum scheduling index value calculated before the current mutation algorithm is executed in the scheduling method, that is, the maximum scheduling index value among all the population evolution steps executed before.

[0133] Therefore, an improvement is made using the annealing algorithm. By dynamically adjusting parameters and utilizing the optimal solution mutated from the previous one, a better solution is searched globally in the vicinity of the optimal solution. Thus, when a newly generated individual has a better code, the probability of accepting it is 100%, while the probability of accepting it gradually decreases when no better code is found. This feature combines the search speed of the genetic algorithm with the global search capability of the annealing algorithm, improving the efficiency of obtaining a better job scheduling table within a certain time.

[0134] In addition, a transposition step can be added between step S209 (decoding step) and step S210 (population selection step) in the above-mentioned population evolution steps.

[0135] Specifically, for each job schedule obtained in step S209, based on the transposition rule, the workpiece segments of the same workbench are transposed sequentially according to the workbench number. If a new job schedule is obtained after transposition, the scheduling index of the new job schedule is calculated, and the new job schedule is re-encoded into an individual code and added to the population. In this way, the newly added individual code will also be screened in step S210 to determine whether to participate in the next population evolution.

[0136] by Figure 5 Taking the work schedule at the top as an example, the above transposition rule is as follows:

[0137] Rule A: Interchange the positions of adjacent workpiece segments on the same workbench, or the last and middle workpiece segments (e.g., J1 and J2 of S2, or J3 and J2 of S3).

[0138] Rule B: If a workpiece segment conflict occurs during the transposition process, the transposition shall be cancelled.

[0139] Rule C: During the switching process, minimize the idle time of the workbench without causing conflicts;

[0140] Rule D: If a transposition makes the scheduling metrics of the job schedule better, then transpose the job; otherwise, cancel the transposition.

[0141] exist Figure 5 In the upper work schedule, starting from any workbench, the workpieces J2 and J1 in workbench S2 are transposed first, and then the workpieces J2 and J3 in workbench S3 are transposed. The resulting... (The text abruptly ends here, likely due to an incomplete sentence or missing information.) Figure 5 The new job schedule shown at the bottom has reduced job completion times by ▽C. Since the scheduling targets are determined based on job completion times, the scheduling targets have increased, hence this reshuffling is implemented.

[0142] Therefore, by using the decoded job schedule and making adjustments, individuals with better scheduling metrics can be reintroduced into the population, increasing population diversity, specifically the diversity of superior individual codes. This method can escape local optima in the algorithm, improving the efficiency of obtaining a better job schedule within a given time.

[0143] While the present invention has been illustrated and described above with reference to certain preferred embodiments, those skilled in the art should understand that the present invention is not necessarily limited to embodiments having all the described configurations. Within the scope of the technical concept of the present invention, the embodiments can be combined with each other or a part of the configuration of a certain embodiment can be replaced with the configuration of another embodiment. It is also possible to add the configuration of another embodiment to the configuration of a certain embodiment. In addition, it is possible to add, delete, or replace other configurations to a part of the configuration of each embodiment.

Claims

1. A scheduling method for assembly line operations, characterized in that, include: The population initialization step involves randomly generating a set of N individual codes as the population, based on the numbers of the multiple workpieces processed in the assembly line operation, the number of the workbench that processes the workpiece in each process, and the processing time of each workbench for each workpiece. Each individual code represents a permutation of all workpiece segments, where a workpiece segment refers to the combination of a workpiece and the workbench that processes it in a certain process, and N is a natural number greater than 1. as well as Steps of population evolution, The population evolution steps include: The population diversification step involves using a genetic algorithm to expand the number of individuals in the population to greater than N in a way that satisfies pre-defined constraints. The consistency coding step removes duplicate individual codes in the population that can be decoded into the same job schedule. The job schedule represents the time arrangement for the multiple workpieces to be processed on multiple workbenches, obtained by decoding the individual codes in a way that minimizes process conflicts and idle time of the workbenches. The decoding step involves encoding and decoding each individual in the population into a corresponding job schedule, and calculating the scheduling index value for each job schedule; and The population selection step involves sorting the codes of all individuals in the population according to the values ​​of the scheduling index, and replacing the entire population with the set of the top N individual codes with the best scheduling index. In the consistency coding step, for each individual code in the population, the positions of the work segments are swapped according to the following rules until no swapping is possible, thereby obtaining a unique code for the job schedule corresponding to that individual code. This unique code is then used to replace the individual code in the population. Finally, duplicate unique codes in the population are deleted. Rule 1: For a given workpiece segment, the workpiece segment of the next process of the same workpiece can be exchanged with the workpiece segment of the next process of the same workbench. Rule 2: For a given workpiece segment, the next process segment of the same workpiece can be exchanged with an adjacent workpiece segment that has different workpieces and different worktables. Rule 3: If the two workpiece segments to be exchanged have the same workpiece or the same workbench, or if there is a workpiece segment between the two workpiece segments whose workbench is the same as the two workpiece segments to be exchanged, then the exchange is cancelled. Rule 4: If the swap will result in the workpiece numbers being arranged in the prescribed monotonic order, then the swap is allowed; otherwise, the swap is cancelled.

2. The scheduling method for continuous flow operations according to claim 1, characterized in that, In the genetic algorithm, the following crossover algorithm is used. From the N individual codes in the population, two individual codes are randomly selected as parent individual codes. A workpiece A is randomly selected, and the order of workpiece A in the two individual codes is maintained. All workpiece segments except workpiece A in one parent individual code are sequentially assigned to the other parent individual code to construct a child individual code. All workpiece segments except workpiece A in the other parent individual code are sequentially assigned to the first parent individual code to construct another child individual code. The two child individual codes are decoded into the corresponding job scheduling table. Child individual codes that do not meet the given conditions are deleted. The remaining child individual codes are added to the population.

3. The scheduling method for continuous flow operations according to claim 1, characterized in that, In the genetic algorithm, the following mutation algorithm is used. From the N individual codes in the population, one individual code is randomly selected. For this individual code, a code segment of length R is randomly selected and permuted to construct R! new individual codes. The new individual codes are then decoded into corresponding job scheduling tables. New individual codes that do not meet the aforementioned conditions are deleted. For the remaining new individual codes, the scheduling index is calculated. The new individual code with the best scheduling index is added to the population. Here, R is a natural number greater than 0, and its value is above min(√(n×m), m) and below max(√(n×m), m). n is the number of workpieces, m is the number of workstations, and both n and m are natural numbers greater than 0.

4. The scheduling method for continuous flow operations according to claim 1, characterized in that, In the genetic algorithm, the following mutation algorithm is used. From the N individual codes in the population, one individual code is randomly selected. For this individual code, a code segment of length R is randomly selected and permuted to construct R! new individual codes. The new individual codes are then decoded into corresponding job scheduling tables. New individual codes that do not meet the aforementioned constraints are deleted. For the remaining new individual codes, the scheduling index is calculated. For the new individual code with the best scheduling index, its acceptance probability ρ is calculated according to the following formula based on its scheduling index Fmax. If the acceptance probability ρ=1, the new individual with the best scheduling index is directly added to the population; otherwise, it is added to the population with probability ρ, where T c Adjust according to the following formula: T0 = ​​tmax - tmin, where tmax represents the maximum effective processing time of the workbench, and tmin represents the minimum effective processing time of the workbench. The effective processing time of a certain workbench is the sum of the actual processing times of all workpieces on that workbench. R is a natural number greater than 0, and its value is above min (√(n×m), m) and below max (√(n×m), m). n is the number of workpieces, m is the number of workbench, and both n and m are natural numbers greater than 0. MaxF is the optimal scheduling index value calculated before the execution of the mutation algorithm in the scheduling method.

5. The scheduling method for continuous flow operations according to claim 1, characterized in that, The population evolution step further includes a transposition step between the decoding step and the population selection step. For each job schedule obtained in the decoding step, based on the transposition rule, the workpiece segments of the same workbench are transposed sequentially according to the workbench number. If a new job schedule is obtained after transposition, the scheduling index of the new job schedule is calculated, and the new job schedule is re-encoded into an individual code and added to the population. The transposition rule is as follows: Rule A: Interchange the positions of adjacent workpiece segments on the same workbench, or between the last and middle workpiece segments. Rule B: If a workpiece segment conflict occurs during the transposition process, the transposition shall be cancelled. Rule C: During the switching process, minimize the idle time of the workbench without causing conflicts; Rule D: If a transposition makes the scheduling metrics of the job schedule better, then transpose the job; otherwise, cancel the transposition.

6. The scheduling method for continuous flow operations according to claim 1, characterized in that, The scheduling metric is determined based on at least one of the following parameters: Job completion time, workbench idle time, effective workbench idle time, and workpiece waiting time. The job completion time refers to the time difference between the moment when the last workpiece finishes processing on the last workbench and the moment when the first workpiece begins processing on the first workbench. Workbench idle time refers to the sum of the idle time on a workbench when no workpieces are being processed, before the last workpiece is finished being processed on the last workbench. Effective idle time of a workbench refers to the sum of the idle time on a workbench before the last workpiece is processed, during which no workpieces are processed. Workpiece waiting time refers to the sum of the waiting time before a workpiece is processed by any workbench before the last process of a workpiece is completed.

7. The scheduling method for continuous flow operations according to claim 6, characterized in that, The scheduling index is a fitness value, which is determined based on the effective idle time of the workstation. Fitness value = 1 / (mean squared deviation of effective idle time of the workbench + 1).

8. The scheduling method for continuous flow operations according to claim 6, characterized in that, The scheduling metric is a fitness value, which is determined based on the job completion time and the effective idle time of the workbench. p1 and p2 are set according to the weights of the mean squared deviation of the task completion time and the effective idle time of the workbench.

9. The scheduling method for continuous flow operations according to claim 6, characterized in that, The limiting condition is a limitation on at least one of the following parameters: the waiting time of one or more workpieces, and the effective idle time of one or more worktables.