A multi-objective distributed welding workshop scheduling method based on improved Seagull algorithm
By improving the Seagull algorithm to optimize workpiece distribution and sorting in the distributed welding workshop, the dual challenges of welding machine load and completion time are solved, and efficient production and cost reduction in the welding workshop are achieved.
Patent Information
- Application Number
- CN202210878317.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-25
- Publication Date
- 2024-09-03
- Estimated Expiration
- 2042-07-25
AI Technical Summary
The processing efficiency of workpieces in distributed welding workshops is low, resulting in increased welding machine load and extended maximum completion time. It is difficult for existing scheduling methods to simultaneously optimize machine load and completion time.
A multi-objective distributed welding shop scheduling method based on the improved seagull algorithm is adopted to achieve efficient allocation and sorting of workpieces in different factories by initializing the seagull population, calculating the seagull position and attack position, sorting and stratifying, updating the priority matrix and adjusting the welding machine allocation. , optimizing welding machine load and completion time.
Without increasing the maximum completion time, it can significantly reduce the welding machine load, reduce processing waiting time and production costs, and improve workpiece processing efficiency and corporate competitiveness.
Smart Images

Figure CN115237075B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of intelligent manufacturing of welding processing, and more specifically to an intelligent production scheduling optimization method for distributed welding workshops. Background Art
[0002] Welding technology has always been one of the most important technologies in the country's industrial manufacturing industry. It is widely used in the fields of machinery manufacturing, shipbuilding and aerospace, transportation and processing. If improvements can be made in welding or its related technologies, it will promote the modernization of my country's industry, improve international competitiveness, and accelerate my country's transformation from an industrial power to an industrial power. Therefore, welding technology is of great significance to my country's industrial manufacturing industry. However, the increase of welding machines in welding technology can speed up product production and promote the progress of construction period, but it will also greatly increase the load of welding machines. Therefore, if there is a scheduling method that can reduce the welding machine and the maximum completion time at the same time, it can not only solve the load problem mentioned above, but also reduce costs and improve factory efficiency according to the allocation plan.
[0003] Scheduling problems in distributed welding workshop manufacturing involve the allocation of limited resources, sorting sequence, time scheduling, optimization objectives, etc. for processing workpieces. In welding scheduling models, there is often a situation where multiple machines process a workpiece at the same time in order to shorten the processing time. This scheduling problem violates the assumption that a workpiece can only be processed by one machine at a time in traditional scheduling problems. This scheduling problem adds a new problem compared to other scheduling problems, namely the machine load of the welding machine. The multi-objective in the multi-objective distributed welding workshop problem is mainly to minimize the maximum completion time and machine load. In order to achieve the two mutually constrained goals, the scheduling method needs to be able to coordinately consider the number of machines and the sequence of processed workpieces to obtain a win-win non-dominated solution. This excellent scheduling model can reduce the machine load without increasing the maximum completion time.
[0004] Based on the above description, the distribution process of workpieces in the distributed welding workshop is briefly described as follows: Figure 2 As shown:
[0005] Before welding, the workpiece needs to be placed on the fixture and the welding machine needs to be started. This period of time is defined as the preparation time. After welding, the workpiece needs to be transported to other process machines, and this period of time is defined as the transfer time. The workpiece processing speed is not only determined by the workpiece properties and the number of assigned welding machines, but also the machine preparation time and workpiece transfer time. Figure 3 and 4In the figure, the length of the block is consistent with the processing time, and the number represents the workpiece number. It is assumed here that only one welding machine is assigned to process the workpiece. It can be seen here that the processing time of the same workpiece on different machines is different. The maximum completion time is the time after the last workpiece is processed and transmitted. Summary of the invention
[0006] The present invention solves the scheduling problem of distributed welding workshops. Specifically, this problem studies the allocation of n workpieces to m stages and l factories for welding processing that meet the processing constraints, and sorts the workpieces allocated to each factory. In the entire welding process, this method mainly considers two goals: minimizing the machine load of the welding machine and minimizing the maximum completion time, among which the machine load mainly considers the number of welding machines.
[0007] The entire welding process of a workpiece is divided into three time periods: preparation, processing and transfer. The preparation time is the time required to put the workpiece to be processed on the welding equipment and start the equipment. It is related to the type of workpiece and the processing stage of the workpiece, while the processing time is related to the type of workpiece and the number of welders assigned to this workpiece. The transfer time is the time required to transport the processed workpiece to the next stage.
[0008] Based on this, in response to the needs of the prior art, the present invention provides a multi-objective distributed welding workshop scheduling method based on the improved Seagull algorithm, which solves the problem of low welding machine utilization and long processing time in different factories, which makes it impossible to maximize efficiency, by optimizing the scheduling plan.
[0009] In order to achieve the above technical features, the purpose of the present invention is achieved as follows: a multi-objective distributed welding workshop scheduling method based on an improved Seagull algorithm, the method comprising the following steps:
[0010] Step 1: Set input parameters and initialize the seagull population using the NEH2 algorithm;
[0011] Step 2: Calculate the current position of each individual in the seagull population;
[0012] Step 3: Calculate the new positions of other individuals in the seagull population based on the best seagull;
[0013] Step 4: Calculate the attack position of each seagull;
[0014] Step 5: Sort and stratify based on the Pareto principle, calculate the crowding distance of seagull individuals in each layer, and then remove some individuals with high crowding degree according to the crowding degree of seagull individuals;
[0015] Step 6: Find the critical path of the welding machine matrix in the seagull individual and update the priority machine matrix;
[0016] Step 7: Determine whether the algorithm has reached the termination condition. If so, output the non-dominated solution to the problem. Otherwise, go to step 3.
[0017] The specific process of Step 1 is as follows:
[0018] Inputting initialization parameters, the initialization parameters include processing time matrix, preparation time matrix, transmission time matrix, load vectors of welding machines at different stages of welding workpieces, upper and lower bounds of welding machine processing quantity and factory number vector data;
[0019] The NEH2 algorithm is used to initialize the seagull population according to the input initialization parameters.
[0020] The specific process of Step 2 is as follows:
[0021] The proposed multi-objective seagull optimization algorithm has the characteristics of few parameters and easy coding. The algorithm divides the seagulls in the seagull group into optimal seagulls and ordinary seagulls according to different responsibilities. Then, based on the biological behavior of seagulls, the two intelligent behaviors of seagulls hunting and migration and the birth rules of optimal seagulls are abstracted.
[0022] After initialization, the population is solved, and then the population is stratified according to the Pareto sorting idea, the best seagull is selected, and the rest are regarded as ordinary seagulls. These seagulls will start to wander and search for "prey". The method for selecting the best seagull is as follows:
[0023] 1) If there is only one level in the solution set, the optimal seagull is randomly selected from this level;
[0024] 2) If the solution set is divided into two or more levels, an individual is selected in the first level as the best seagull, and the other individuals in the entire set are ordinary seagulls.
[0025] The specific process of Step 3 is as follows:
[0026] Simulate the migration action of seagulls, abstractly seeking non-dominated solutions in the solution space, and the action must satisfy the following constraints:
[0027] 1) Avoid collisions between seagulls:
[0028] In order to avoid overlapping positions between seagulls, an additional variable A is added to update the new position of the seagull. The calculation formula is as follows:
[0029] Cs(t)=A×Ps(t)
[0030] A=f c -(t×(f c / Max t )) (1)
[0031] Where: t represents the current iteration number; A represents the movement of the seagull in the search space; f c Used to control the frequency range of A; Max t Indicates the maximum number of iterations;
[0032] 2) Calculate the direction to the best seagull:
[0033] The seagull will calculate its direction towards the best seagull based on the current iteration number, as shown in formulas (2) and (3):
[0034]
[0035] B = 2 × A 2 ×R d (3)
[0036] Where: t is the current number of iterations; P BS (t) represents the optimal position of the seagull under this number of iterations; M S (t) represents the best seagull direction, and the function value will be rounded down at this time; R d is a random number between [0,1]; Ps(t) represents the position at the current iteration number; B represents a random number;
[0037] 3) Move to the best position:
[0038] When the position of the selected seagull does not collide with other seagulls, in order to reach the latest position, the seagull will move closer to the best seagull:
[0039] Cs(t)=A×Ps(t);
[0040] Ds(t)=|Ms(t)+Cs(t)| (4)
[0041] Where: Ds(t) represents the new position at the current iteration number; Cs(t) represents the updated position.
[0042] The specific process of Step 4 is as follows:
[0043] The simulation of seagulls hunting prey in spiral motion is abstracted as a local search near the non-dominated solution. Their motion trajectories on the three-dimensional plane are expressed by the following formulas (5), (6), (7) and (8):
[0044] X=r×sink (5)
[0045] Y=r×cosk (6)
[0046] Z=r×k (7)
[0047] r=u×e k×v (8)
[0048] Where: X, Y, Z represent the workpiece vector, factory vector, and machine matrix respectively; r represents the attack radius of the seagull; u and v are used to control the radius size; k is a random value in [0, 2π]; and formulas (5)-(8) are used to calculate the attack position of the seagull, and then the continuous problem is discretized using the probability formula.
[0049] The specific process of Step 5 is as follows:
[0050] First, initialize the population P0, calculate and record the multi-objective values of each individual in the population in turn, and use the Pareto idea to save all non-dominated individuals in the population P0 in a set S0, then ignore the individuals in this set, and continue the above operation with the remaining individuals in P0 until the entire population is stratified;
[0051] Next, compare the crowding distances of individuals at the same level, and then remove individuals with high crowding distances. The calculation steps are as follows:
[0052] 1) The crowding degree of the two end points of the Pareto frontier is recorded as positive infinity ∞. For points not at the two ends, their crowding distance is related to the adjacent points;
[0053] 2) For points on the same layer, draw a perpendicular line along the X and Y axes to obtain an area, and the symmetric difference between this area and the area of the adjacent points on the left and right is obtained;
[0054] 3) Traverse all groups in turn with three points as a group, retain the points with large symmetric difference sets, and also retain the points that are not enough to form a group.
[0055] The specific process of Step 6 is as follows:
[0056] From the actual welding problem, we know that a workpiece can be processed by multiple welding machines, which can reduce the processing time of the workpiece and thus affect the maximum completion time, but this will conflict with the goal of reducing machine load; therefore, a method that can simultaneously reduce the maximum completion time and the number of welding machines is needed; and then the allocation matrix strategy is proposed to solve the above problem. The allocation matrix strategy steps are divided into two steps:
[0057] 1) Convert the workpiece sequence and stage sequence into an Activity On Edge Network graph structure, where the edge represents the processing time, the graph node records the stage number of the workpiece, and the subsequent nodes of the graph node record the next stage of this workpiece and the next workpiece of this stage; the source point is the first workpiece of the first stage, and the end point is the last workpiece of the last stage.
[0058] 2) After obtaining the Activity On Edge Network graph, use topological sorting to obtain the critical path weight matrix of this sequence. The critical path weight matrix corresponds one-to-one to the position of the Activity On Edge Network graph elements obtained in the first step. Set the points on the non-critical path to 0, and the points on the critical path are determined by the number of overlapping points. Specifically, in some cases, the Activity On Edge Network graph structure has multiple critical paths, and the weight values of the overlapping points of multiple critical paths are increased. For example, if there are 3 overlaps, the matrix element at this position is 3, and if there is no overlap, it is 1.
[0059] The specific process of discretization is as follows:
[0060] Use the following conversion formula to convert the variables Control to the interval [0,1];
[0061] in: Represent the three vectors X, Y, and Z of the seagull individual, and t represents the current iteration number;
[0062]
[0063] Then, according to the probability formula, the (0, 1) encoding value of each X′, Y′, Z′ vector is obtained;
[0064]
[0065]
[0066]
[0067] Finally, the attack position of the seagull is calculated based on the obtained variables and the following formula:
[0068]
[0069]
[0070]
[0071] Where: T (w) A function used to control the X, Y, and Z variables to be in the (0,1) interval; e represents a natural constant; and rd represents a generated random number in the (0,1) interval.
[0072] The present invention has the following beneficial effects:
[0073] On the basis of minimizing the maximum completion time, the number of machines is considered to be small enough, that is, the machine load is small enough. In actual welding, a variety of processing plans will be provided for a group of workpieces. When scheduling the processing, various factors are comprehensively considered to select a reasonable scheduling plan from these scheduling plans. This scheduling plan can not only minimize the completion time of the processed workpiece, but also reduce the machine load to a certain extent, reduce the processing waiting time and production costs, and thus improve the competitiveness of the enterprise. BRIEF DESCRIPTION OF THE DRAWINGS
[0074] The present invention will be further described below in conjunction with the accompanying drawings and embodiments.
[0075] Figure 1 Flowchart of a multi-objective distributed welding workshop scheduling method based on the improved Seagull algorithm.
[0076] Figure 2 Workpiece allocation in a distributed welding shop.
[0077] Figure 3 The first Gantt chart under different processing sequences.
[0078] Figure 4 Gantt chart for the second different processing sequence.
[0079] Figure 5 Calculate the congestion degree between C and B on the left.
[0080] Figure 6 Calculate the congestion degree between C and D on the right.
[0081] Figure 7 Critical path example diagram.
[0082] Figure 8 The impact of shortened processing time on the critical path on Makespan.
[0083] Fig. 9 Diagram of a case with multiple critical paths. DETAILED DESCRIPTION
[0084] The embodiments of the present invention are further described below in conjunction with the accompanying drawings.
[0085] See also Figure 1-9 First, for the convenience of explanation, the following symbols introduced in this example are uniformly explained as shown in the following table:
[0086] Model Assumptions:
[0087] Considering the characteristics of the actual problem and the tractability of the problem, the following reasonable assumptions are made:
[0088] 1) Any workpiece can be processed in any factory;
[0089] 2) Once a workpiece is assigned to a factory, the processing factory cannot be changed;
[0090] 3) After the machine starts processing, it cannot be interrupted;
[0091] 4) A workpiece can only be processed on one machine in a factory at the same time, and a machine can only process one workpiece at the same time;
[0092] 5) The capacity of the buffers between all machines in the factory is infinite;
[0093] 6) The number of welders assigned to a workpiece has an upper and lower bound;
[0094] 7) There is no priority difference between different artifacts, and they remain independent of each other;
[0095] 8) The equipment starts processing from time zero and ensures that the equipment is in an idle state;
[0096] 9) All workpieces flow through each process in the same order;
[0097] 10) The preparation time and transmission time of different processes need to be considered, and the time cannot be adjusted;
[0098] 11) The rated working efficiency of the welding machines used in each process is the same and remains unchanged, and the welding processing time of each workpiece is a discrete value in a certain closed interval;
[0099] Symbol definition:
[0100]
[0101]
[0102] Scheduling model:
[0103] The multi-objective distributed welding scheduling problem studied in the present invention refers to: assigning a welding machine and a processing plant to each workpiece, arranging the processing order of the workpiece sequence in each plant, determining the start time, completion time and number of welds allocated during processing of the workpiece, so that the maximum completion time of the entire process and the machine load are as small as possible.
[0104] f1=minC max (9)
[0105]
[0106] N i,j,k ≥1 i∈{1, 2, ..., m}, j∈{1, 2, ..., n}, k∈{1, 2, ..., l} (11)
[0107] N i,j,k ≤NL i,j,k (12)
[0108] S i,j,k ≥ST i,j,k i∈{1, 2, ..., m}, j∈{1, 2, ..., n}, k∈{1, 2, ..., l} (13)
[0109] S i,j,k ≥T i,j,k i∈{1, 2, ..., m}, j∈{1, 2, ..., n}, k∈{1, 2, ..., l} (14) S i,j,k ≥S i′,j,k +P′ i,j,k +T i,j,k i,i′∈{1,2,...,m}i′=i-1 (15)
[0110] S i,j,k ≥S i,j′,k +P′ i,j,k +ST i,j,k j, j′∈{1, 2,...,n}j′=j-1 (16)
[0111] C max ≥S i,j,k +P′ i,j,k +T i,j,k (17)
[0112] Among them: Formula (9) is the maximum completion time optimization objective of scheduling; Formula (10) is the machine load optimization objective; Formulas (11) and (12) are welding machine allocation constraints, indicating that the welding machine assigned to each workpiece at each stage in the workshop can only be within one interval; Formulas (13) and (14) are time constraints, indicating that the workpiece cannot be processed until it is transferred to the machine and the welding machine cannot be processed until it is ready; Formula (15) is used to ensure that each workpiece can only be processed after the previous process is completed; Formula (16) ensures that each workpiece can only be processed after the previous workpiece is processed; Formula (17) The maximum completion time is the time when the last workpiece is processed and transferred.
[0113] ①Encoding and decoding
[0114] According to the scheduling problem of the multi-objective distributed welding workshop studied, it is known that it is difficult to solve the discrete combinatorial optimization problem using the Seagull algorithm with continuous problem coding. Therefore, according to the actual problem, the decimal coding method is adopted, that is, the serial number of the processed workpiece is represented by a decimal integer to form a decimal sequence (x i1 1,x i2 2...x ij k...xim n) represents, that is, the position of each seagull in the multi-objective seagull optimization algorithm (MOSOA); wherein i, j = 1, 2, ..., M; n represents the number of workpieces, and M represents the number of factory serial numbers; when this encoding method is adopted, the difficulty of solving the problem lies in how to deal with the workpieces, welding machine allocation and workpiece order problems in the model; in the algorithm, each coding position, that is, the workpiece, is set with three variables, one to store the currently allocated workpiece number, another to store the factory to which the workpiece is allocated, and the last one to store the welding machine allocation matrix, and the order in which the workpieces are processed on the machine is represented by the decimal sequence from left to right.
[0115] The decoding strategy is divided into the following three steps:
[0116] Step 1, arrange the workpieces in order to obtain the processing order of the workpieces;
[0117] Step 2, obtain the factory at the corresponding position of the workpiece sequence by allocating the factory sequence;
[0118] Step 3, obtain the machine matrix corresponding to the workpiece sequence from the machine matrix;
[0119] Taking 2 factories, 5 workpieces and 5 stages as an example, the encoding and decoding of the solution are shown in Table 1:
[0120] π = [5, 2, 1, 4, 3] represents the processing sequence of the workpieces, a = [2, 1, 2, 2, 1] represents the factory allocation, workpiece 5 and workpiece 1, workpiece 4 are allocated to factory 2, and workpiece 2 and workpiece 3 are allocated to factory 1; the matrix N represents the welding machine that needs to be allocated to each workpiece at each stage; for example, N 11 =2 means that workpiece 1 is assigned 2 welding machines in stage 1.
[0121] π1=[5,2,1,4,3]
[0122] a=[2,1,2,1,1]
[0123]
[0124] Table 1 Encoding and decoding methods of individual π1
[0125]
[0126] Processing distribution welding machine
[0127]
[0128] ② Initialize the population
[0129] In order to improve the quality of the solution, the population is not initialized randomly here, but the NEH2 method is used to initialize part of the population, and the rest of the population is initialized randomly. The steps of the NEH2 algorithm are as follows: first, the workpieces are sorted in reverse order of processing time to generate a decimal sequence, and then a factory is randomly selected from the available factory set at the first workpiece code position, and then the second one is inserted into any position of other factories to minimize the maximum completion time of its factory, and so on, all workpieces are inserted into the corresponding factories; after the initialization is completed, the population is stratified by Pareto sorting according to the solved dual objectives, and the optimal seagull is selected. The remaining seagulls are regarded as ordinary seagulls and wander to search for "prey"; the method for selecting the optimal seagull is as follows:
[0130] 1) If there is only one level in the solution set, randomly select the best seagull from this level;
[0131] 2) If the solution set is divided into two or more levels, an individual in the first level is selected as the best seagull, and the rest of the individuals in the entire set are ordinary seagulls;
[0132] ③Individual fitness
[0133] Calculate the objective function and perform Pareto non-dominated sorting, calculate the crowding distance of each seagull, and remove individuals with high crowding. First initialize the population P0, calculate the multi-objective values of each individual in the population in turn and record them. Using the Pareto idea, save all non-dominated individuals in the population P0 in a set S0, then ignore the individuals in this set, and continue the above operation with the remaining individuals in P0 until the entire population is stratified. Next, compare the crowding distances of individuals at the same level, and then remove individuals with high crowding distances. The calculation steps are as follows:
[0134] 1) Here, the crowding degree of the points at the two ends of the Pareto frontier is recorded as ∞. For points not at the two ends, their crowding distance is related to the adjacent points;
[0135] 2) For points on the same layer, draw a perpendicular line along the X and Y axes to obtain an area, and the symmetric difference between this area and the area of the adjacent points on the left and right is obtained;
[0136] 3) Traverse all groups in turn with three points as a group, retain the points with large symmetric difference sets, and also retain the points that are not enough to form a group.
[0137] as follows Figure 5 Figure 6 As shown, f1 and f2 are the two objective functions of the problem, and the point set {A, B, C, D, E} represents five solutions at the same level. Take point C as an example:
[0138] According to calculation step 3), point C first calculates the crowding distance with point B on the left, and the distance is Figure 5The size of the shaded area is denoted as S1.
[0139] Similarly, we can perform crowding distance calculation on point C and point D on the right to obtain the new shadow area S2.
[0140] Comparing the sizes of S1 and S2, we can see that S2>S1, which means that the crowding distance of S2 is larger, so it is retained.
[0141] ④Other seagulls migrate to the best seagull strategy
[0142] Because the location of the prey cannot be predicted in advance, it is generally believed that the optimal seagull is the closest to the non-dominated solution; therefore, other seagulls will move closer to the optimal seagull; this method proposes a wandering motion operator suitable for solving the scheduling problem under study, which includes two operations: migration and attack.
[0143] For the encoded part of the artifact, randomly select an element from the permutation and apply the following migration search strategy:
[0144] Cs(t)=A×Ps(t);
[0145] A=f c -(t×(f c / Max t )) (18)
[0146]
[0147] B = 2 × A 2 ×R d (20)
[0148] Ds(t)=|Ms(t)+Cs(t)| (21)
[0149] Where: t is the current number of iterations; P BS (t) represents the optimal position under this number of iterations; M S (t) represents the best seagull direction, at this time, the function value will be rounded down, at this time, the right function value will be rounded down; R d is a random number between [0,1]; Ds(t) represents the new position at the current iteration number; P S (t) represents the current operating seagull.
[0150] shift(x,d) means that the x element is moved right (+) or left (-) by |d| units; if the boundary of the individual is exceeded during the movement, the boundary element is connected to the element in the opposite direction; where "rand" is a randomly generated [0, 1] value, and fc is a control element. In this problem, fc is set to 1.0. Table 2 details the search process. Representing the best seagull, Representing other seagulls.
[0151] Table 2 Seagull migration strategy
[0152]
[0153]
[0154] ⑤Seagull’s attack strategy
[0155] Compared with the migratory behavior of seagulls, the attack action of seagulls belongs to local search. Although global search can obtain a near-optimal solution, the search converges too slowly and the quality of the solution is not high. Local search can improve the quality of the solution but will make the solution more likely to fall into the local optimum. The attack strategy of seagulls can be based on the following formula:
[0156] X=r×sink (22)
[0157] Y=r×cosk (23)
[0158] Z=r×k (24)
[0159] r=u×e k×v (25)
[0160] Among them: X, Y, Z represent the workpiece vector, factory vector, and machine matrix respectively, r represents the attack radius of the seagull; u and v are used to control the radius size, and k is a random value in [0, 2π].
[0161] Since the attack mode formula is suitable for continuous problems, it needs to be discretized. Using the following conversion formula, the variable Control to the interval [0,1];
[0162] in: They represent the three vectors X, Y, and Z of the seagull individual, and t represents the current iteration number.
[0163]
[0164] Then, according to probability formulas (27)-(29), the (0, 1) encoding value of each X′, Y′, Z′ vector is obtained, such as X′=[0, 1, 1, 0, 1].
[0165]
[0166]
[0167]
[0168] Finally, the attack position of the seagull is calculated based on the obtained variables and the following formula:
[0169]
[0170]
[0171]
[0172] The movement method of the attack position is the same as the shift(x,d) mentioned earlier.
[0173] ⑥Adjust the assigned welding machine matrix
[0174] When the population iterates a certain number of times, the solution is close to convergence. At this time, the previously obtained critical path weight matrix can be used to start adjusting the machine allocation matrix. Since machines are allocated on the critical path, the maximum completion time will be reduced. The usual practice is to initialize the workpiece processing process as a graph structure relationship, and then find the critical path of task processing in this graph structure. The maximum completion time is controlled by reducing the length of the work block on the critical path, that is, increasing the welders on the critical path and reducing the welders on the non-critical path.
[0175] by Figure 7 For example: three workpieces, job1, job2, and job3, are processed in stages 1, 2, and 3. The same pattern represents the same workpiece, the number in the square represents the number of welding machines used to process the workpiece in this stage, and the length of the square represents the processing time. The workpieces included in the dotted box constitute the critical path. When the workpiece of job3 in stage 3 on the critical path is processed by two welding machines instead of one, it is found that the maximum completion time is shortened. However, the workpiece of job2 in stage 3 on the non-critical path cannot shorten the maximum completion time even if the welding machine is changed. Figure 8 shown.
[0176] However, this design also has a flaw. For example, in real life, there may be multiple critical paths in the processing process, which will result in the maximum completion time not being reduced even if a machine is added to a critical path. Fig. 9 It can be seen that there are two critical paths in this processing process, that is, the two key blocks wrapped by dotted lines each constitute a critical path. At this time, even if the number of welders on the job2 workpiece in stage 2 is increased, the final maximum completion time cannot be changed.
[0177] Therefore, this method proposes a priority matrix strategy based on overlapping critical paths to solve the above problems. The steps are as follows:
[0178] 1) Initialize an N-row, M-column all-zero matrix X. N represents the number of stages, and M represents the number of workpieces.
[0179] 2) Find all the critical path sequences in the entire processing process. If it does not exceed the upper limit of the machine limit, add 1 to the value of the corresponding position in the matrix.
[0180] 3) The larger the value of the corresponding position in the matrix, the more important the corresponding critical path is, and the higher the priority of adding a welding machine is.
[0181] 4) After each iteration, in the welding machine allocation matrix, first add one welding machine at the highest priority position, and reduce one welding machine at position 0.
[0182] 5) After the iteration is completed, the graph structure is regenerated and the priority matrix is updated.
[0183] To make the above steps easier to understand, let’s take a specific example below to explain.
[0184] by Fig. 9 For example, two matrices can be analyzed according to the priority matrix strategy, namely, welding machine allocation matrix A and priority matrix B.
[0185]
[0186] The rows of A and B represent stages, and the columns represent artifacts. 23 =2, we can see that the corresponding A 23 The element needs to be increased by 1. And for A 21 or A 31 You need to reduce one machine.
[0187] ⑦Stop criteria
[0188] When the stopping criteria are met, the Pareto solution set is output, namely the factory scheduling plan, workpiece processing sequence and welding machine allocation plan.
[0189] It is easy for those skilled in the art to understand that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
[0190] ⑧ Algorithm Example Comparison
[0191] Take 5 workpieces, 2 factories and 3 stages as an example and enter the initial parameters:
[0192] π1=[1,2,3,4,5]
[0193] f = [1, 2]
[0194] cost = [0.8, 0.37, 0.4]
[0195] transFirst=[4, 5, 4, 3, 7]
[0196]
[0197]
[0198] Where π1 represents the workpiece to be processed, f represents the factory, processing represents the processing time matrix, setupFirst represents the first preparation time matrix of the workpiece in the stage, setupTime represents the preparation time matrix between workpieces, transFirst represents the transfer time vector of the workpiece in stage 1, and transportationTime represents the transfer time matrix of the workpiece after processing. cost is the load vector of the welding machine welding the workpiece at different stages. Here, the maximum number of welders in each stage is set to [3,4,2], and the lower bound of the welding machine processing is 1.
[0199] After initializing the random value, the final solution is calculated using the unoptimized Seagull algorithm and the optimized Seagull algorithm, and the comparison tables 3 and 4 of some non-dominated solutions are obtained, as shown below:
[0200] Table 3 Comparison of the improved Seagull algorithm
[0201]
[0202] Table 4 Comparison of the results after improving the Seagull algorithm
[0203]
[0204] It can be seen from the above table that the completion time and machine load values after algorithm optimization are effectively reduced. The maximum completion time in Table 3 is reduced by 7.2% and the machine load is reduced by 5.4%, while the maximum completion time in Table 4 is reduced by 10% and the machine load is reduced by 3.5%, which proves the effectiveness of this algorithm.
Claims
1. A multi-objective distributed welding workshop scheduling method based on improved Seagull algorithm, characterized in that: The method comprises the following steps: Step 1: Set input parameters and initialize the seagull population using the NEH2 algorithm; Step 2: Calculate the current position of each individual in the seagull population; Step 3: Calculate the new positions of other individuals in the seagull population based on the best seagull; Step 4: Calculate the attack position of each seagull; The simulation of seagulls hunting prey in spiral motion is abstracted as a local search near the non-dominated solution. Their motion trajectories on the three-dimensional plane are expressed by the following formulas (5), (6), (7) and (8): X=r×sink (5) Y=r×cosk (6) Z=r×k (7) r=u×e k×v (8) Where: X, Y, Z represent the workpiece vector, factory vector, and machine matrix respectively; r represents the attack radius of the seagull; u and v are used to control the radius size; k is a random value in [0, 2π]. Formulas (5)-(8) are used to calculate the attack position of the seagull, and then the continuous problem is discretized using the probability formula; The specific process of discretization is as follows: Use the following conversion formula to convert the variables Control to the interval [0,1]; in: Represent the three vectors X, Y, and Z of the seagull individual, and t represents the current iteration number; Then, according to the probability formula, the (0, 1) encoding value of each X′, Y′, Z′ vector is obtained; Finally, the attack position of the seagull is calculated based on the obtained variables and the following formula: Where: T (w) A function used to control the X, Y, and Z variables to the interval (0, 1); e represents a natural constant; rd represents a generated random number in the interval (0, 1); Step 5: Sort and stratify based on the Pareto principle, calculate the crowding distance of seagull individuals in each layer, and then remove some individuals with high crowding degree according to the crowding degree of seagull individuals; First, initialize the population P0, calculate and record the multi-objective values of each individual in the population in turn, and use the Pareto idea to save all non-dominated individuals in the population P0 in a set S0, then ignore the individuals in this set, and continue the above operation with the remaining individuals in P0 until the entire population is stratified; Next, compare the crowding distances of individuals at the same level, and then remove individuals with high crowding distances. The calculation steps are as follows: 1) The crowding degree of the two end points of the Pareto frontier is recorded as positive infinity ∞. For points not at the two ends, their crowding distance is related to the adjacent points; 2) For points on the same layer, draw a perpendicular line along the X and Y axes to obtain an area, and the symmetric difference between this area and the area of the adjacent points on the left and right is obtained; 3) Traverse all groups in turn with three points as a group, retain the points with large symmetric difference sets, and also retain the points that are not enough to form a group; Step 6: Find the critical path of the welding machine matrix in the seagull individual and update the priority machine matrix; The allocation matrix strategy step is divided into two steps: 1) Convert the workpiece sequence and stage sequence into an Activity On Edge Network graph structure, where the edge represents the processing time, the graph node records the stage number of the workpiece, and the subsequent nodes of the graph node record the next stage of this workpiece and the next workpiece of this stage; the source point is the first workpiece of the first stage, and the end point is the last workpiece of the last stage; 2) After obtaining the Activity On Edge Network graph, use topological sorting to obtain the critical path weight matrix of this sequence. The critical path weight matrix corresponds one-to-one with the position of the element of the Activity On Edge Network graph obtained in the first step. Set the points on the non-critical path to 0, and the points on the critical path are determined by the number of coincidence points. Step 7: Determine whether the algorithm has reached the termination condition. If so, output the non-dominated solution to the problem. Otherwise, go to step 3.
2. According to claim 1, a multi-objective distributed welding workshop scheduling method based on the improved Seagull algorithm is characterized in that: The specific process of Step 1 is as follows: Inputting initialization parameters, the initialization parameters include processing time matrix, preparation time matrix, transmission time matrix, load vectors of welding machines at different stages of welding workpieces, upper and lower bounds of welding machine processing quantity and factory number vector data; The NEH2 algorithm is used to initialize the seagull population according to the input initialization parameters.
3. According to the multi-objective distributed welding workshop scheduling method based on the improved Seagull algorithm of claim 1, it is characterized in that: The specific process of Step 2 is as follows: The proposed multi-objective seagull optimization algorithm has the characteristics of few parameters and easy coding. The algorithm divides the seagulls in the seagull group into optimal seagulls and ordinary seagulls according to different responsibilities. Then, based on the biological behavior of seagulls, the two intelligent behaviors of seagulls hunting and migration and the birth rules of optimal seagulls are abstracted. After initialization, the population is solved, and then the population is stratified according to the Pareto sorting idea, the best seagull is selected, and the rest are regarded as ordinary seagulls. These seagulls will start to wander and search for "prey". The method for selecting the best seagull is as follows: 1) If there is only one level in the solution set, the optimal seagull is randomly selected from this level; 2) If the solution set is divided into two or more levels, an individual is selected in the first level as the best seagull, and the other individuals in the entire set are ordinary seagulls.
4. A multi-objective distributed welding workshop scheduling method based on improved Seagull algorithm according to claim 1 or 2, characterized in that: The specific process of Step 3 is as follows: Simulate the migration action of seagulls, abstractly seeking non-dominated solutions in the solution space, and the action must satisfy the following constraints: 1) Avoid collisions between seagulls: In order to avoid overlapping positions between seagulls, an additional variable A is added to update the new position of the seagull. The calculation formula is as follows: A=f c -(t×(f c / Max t )) (1) Where: t represents the current iteration number; A represents the movement of the seagull in the search space; f c Used to control the frequency range of A; Max t Indicates the maximum number of iterations; 2) Calculate the direction to the best seagull: The seagull will calculate its direction towards the best seagull based on the current iteration number, as shown in formulas (2) and (3): B=2×A 2 ×R d (3) Where: t is the current number of iterations; P BS (t) represents the optimal position of the seagull under this number of iterations; M S (t) represents the best seagull direction, and the function value will be rounded down at this time; R d is a random number between [0,1]; Ps(t) represents the position at the current iteration number; B represents a random number; 3) Move to the best position: When the position of the selected seagull does not collide with other seagulls, in order to reach the latest position, the seagull will move closer to the best seagull: Cs(t)=A×Ps(t); Ds(t)=|Ms(t)+Cs(t)| (4) Where: Ds(t) represents the new position at the current iteration number; Cs(t) represents the updated position.
