Disclosure of Invention
The embodiment of the invention provides a dynamic scheduling method and a dynamic scheduling device for a flexible job shop, which can solve the problem that in the conventional dynamic scheduling method for the flexible job shop, due to the condition that quality inspection is unqualified, a single process is re-entered and the condition that quality inspection is scrapped, workpieces are put into production again, so that the operation plan is disconnected from the actual production.
In order to solve the above technical problem, the embodiment of the present invention is implemented as follows:
in a first aspect, an embodiment of the present invention provides a flexible job shop dynamic scheduling method, including:
in the scheduling process of the original scheme, if the quality inspection result of the first procedure is unqualified, generating at least one alternative scheme of the corresponding relation between each second procedure and the machinable equipment; wherein the second step is: a step which is not started in the original scheme when the quality inspection result of the first step is unqualified;
determining an optimal scheme corresponding to each second procedure based on a situation evaluation algorithm; wherein the optimal solution is one of at least one alternative solution corresponding to each of the second processes;
and determining the processing sequence of the second procedure through a simulated annealing genetic algorithm based on the optimal schemes respectively corresponding to the second procedures to obtain a target scheme.
Optionally, if the quality inspection result of the first process is unqualified, generating at least one alternative of the corresponding relationship between each second process and the machinable equipment, including:
under the condition that the quality inspection result of the first procedure is unqualified, determining the completion moment of the first procedure as a disturbance time node;
determining all processes started after the disturbance time node as the second process;
generating at least one alternative for each of said second procedures in correspondence with the processable equipment.
Optionally, the generating at least one alternative of the corresponding relationship between each second process and the machinable apparatus includes:
determining AM alternatives for arranging the first target process to the AM machinable devices according to the earliest starting time of the first target process and the idle time of the AM machinable devices; wherein the first target process is any one of the second processes; AM is the number of machinable apparatuses of the first target process.
Optionally, the determining, based on the situation evaluation algorithm, an optimal scheme corresponding to each of the second processes includes:
calculating a situation evaluation value corresponding to each alternative of the second target process;
determining a candidate scheme corresponding to the minimum value in the situation evaluation values as an optimal scheme corresponding to the second target process; wherein the second target process is any one of the second processes.
Optionally, the calculating the situation evaluation value corresponding to each alternative in the second target process includes:
by the formula Pijp=(NSij-OSij)2/(OYijp+1), calculating the situation evaluation value corresponding to each alternative of the second target process;
wherein, PijpTo form a second target process OijArranged in a machinable apparatus MpUpper situation evaluation value, NSijRepresents a second target process O in the alternativeijStart time of (1), OSijRepresents a second target process O in the original recipeijThe start time of (c); if the second target process O in the original schemeijArranged in a machinable apparatus MpUpper, then OYijpIs 1, otherwise is 0.
Optionally, the determining, based on the optimal solutions respectively corresponding to the second processes, the processing order of the second processes by using a simulated annealing genetic algorithm to obtain a target solution includes:
based on a genetic algorithm, the following steps are performed: taking m codes in the ith code group as individuals, taking the maximum completion time corresponding to the m codes respectively as the fitness of the individuals, and obtaining m updated codes through an annealing algorithm;
when a preset termination condition of the genetic algorithm is met, determining a global optimal code from i code groups respectively obtained after i times of the annealing algorithm;
obtaining the target scheme according to the global optimal coding;
wherein the code is used for indicating the processing sequence of the second procedure; i is the number of times of the annealing algorithm, and m is the number of codes in each code group;
when i is 1, m codes in the ith code group are: generating m codes based on the optimal schemes respectively corresponding to the second procedures;
when i is greater than 1, the m codes in the ith code group are: and the (i-1) th code group obtains m updated codes after an annealing algorithm and obtains m mutated codes after mutation processing.
Optionally, the determining a global optimal code from i code groups obtained after the i annealing algorithms includes:
and determining a code with the minimum maximum completion time from the i code groups as the global optimal code.
In a second aspect, an embodiment of the present invention further provides a flexible job shop dynamic scheduling apparatus, including:
the generating module is used for generating at least one alternative scheme of the corresponding relation between each second procedure and the machinable equipment if the quality inspection result of the first procedure is unqualified in the scheduling process of the original scheme; wherein the second step is: a step which is not started in the original scheme when the quality inspection result of the first step is unqualified;
the first determining module is used for determining the optimal scheme corresponding to each second procedure based on a situation evaluation algorithm; wherein the optimal solution is one of at least one alternative solution corresponding to each of the second processes;
and the second determining module is used for determining the processing sequence of the second procedure through a simulated annealing genetic algorithm based on the optimal schemes respectively corresponding to the second procedures to obtain a target scheme.
Optionally, the generating module includes:
the first determining submodule is used for determining the finishing moment of the first procedure as a disturbance time node under the condition that the quality inspection result of the first procedure is unqualified;
a second determining submodule configured to determine all processes started after the disturbance time node as the second process;
and the generation sub-module is used for generating at least one alternative of the corresponding relation between each second procedure and the machinable equipment.
Optionally, the generating sub-module includes:
a determining unit, configured to determine AM alternatives for arranging the first target process on the AM processable devices according to an earliest startable time of the first target process and idle times of the AM processable devices; wherein the first target process is any one of the second processes; AM is the number of machinable apparatuses of the first target process.
Optionally, the first determining module includes:
the calculation submodule is used for calculating the situation evaluation value corresponding to each alternative of the second target process;
a third determining submodule, configured to determine an alternative solution corresponding to a minimum value in the situation evaluation values, as an optimal solution corresponding to the second target process; wherein the second target process is any one of the second processes.
Optionally, the calculation sub-module includes:
a calculation unit for passing formula Pijp=(NSij-OSij)2/(OYijp+1), calculating the situation evaluation value corresponding to each alternative of the second target process;
wherein, PijpTo form a second target process OijArranged in a machinable apparatus MpUpper situation evaluation value, NSijRepresents a second target process O in the alternativeijStart time of (1), OSijRepresents a second target process O in the original recipeijThe start time of (c); if the second target process O in the original schemeijArranged in a machinable apparatus MpUpper, then OYijpIs 1, otherwise is 0.
Optionally, the second determining module includes:
a first processing submodule for performing the following steps, based on a genetic algorithm: taking m codes in the ith code group as individuals, taking the maximum completion time corresponding to the m codes respectively as the fitness of the individuals, and obtaining m updated codes through an annealing algorithm;
the second processing submodule is used for determining a global optimal code from i code groups respectively obtained after i times of annealing algorithm when a preset termination condition of the genetic algorithm is met;
the third processing submodule is used for obtaining the target scheme according to the global optimal code;
wherein the code is used for indicating the processing sequence of the second procedure; i is the number of times of the annealing algorithm, and m is the number of codes in each code group;
when i is 1, m codes in the ith code group are: generating m codes based on the optimal schemes respectively corresponding to the second procedures;
when i is greater than 1, the m codes in the ith code group are: and the (i-1) th code group obtains m updated codes after an annealing algorithm and obtains m mutated codes after mutation processing.
Optionally, the second processing sub-module includes:
and the processing unit is used for determining a code with the minimum maximum completion time from the i code groups as the global optimal code.
In a third aspect, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the steps of the flexible job shop dynamic scheduling method according to any one of claims 1 to 7.
In the scheme of the invention, in the scheduling process of the original scheme, if the quality inspection result of the first process is unqualified, at least one alternative scheme of the corresponding relation between each second process and the machinable equipment is generated; determining an optimal scheme corresponding to each second procedure based on a situation evaluation algorithm; based on the optimal schemes respectively corresponding to the second procedures, the processing sequence of the second procedures is determined through a simulated annealing genetic algorithm to obtain a target scheme, the problem that in the existing flexible job workshop dynamic scheduling method, due to the fact that quality inspection is unqualified, single procedure reentry is caused, and due to the fact that quality inspection is scrapped, workpieces are put into production again, and the operation plan is disconnected with the actual production is solved, and therefore guidance is provided for workshop scheduling personnel to conduct flexible job workshop dynamic scheduling with quality inspection procedures, the fact that the difference between the rescheduling scheme and the original scheme is small can be guaranteed, and the maximum completion time is guaranteed to be minimized.
Detailed Description
Exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the invention are shown in the drawings, it should be understood that the invention can be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the invention to those skilled in the art.
As shown in fig. 2, an embodiment of the present invention provides a flexible job shop dynamic scheduling method, including:
step 21: and in the scheduling process of the original scheme, if the quality inspection result of the first process is unqualified, generating at least one alternative scheme of the corresponding relation between each second process and the machinable equipment.
Wherein the second step is: and a step which is not started in the original scheme when the quality inspection result of the first step is unqualified.
As shown in fig. 3, a scheme of a process and a machinable apparatus in the scheduling process of an original scheme is given, wherein M1 to M5 represent machinable apparatuses; the processes O21 and O11 were performed in the machinable apparatus M1, the processes O41, O32 and O33 were performed in the machinable apparatus M2, the processes O31, O12 and O42 were performed in the machinable apparatus M3, the processes O22 and O13 were performed in the machinable apparatus M4, and the process O23 was performed in the machinable apparatus M5.
If the step O41 in fig. 3 is a first step of failing quality inspection (e.g., inspection or scrap, here, the inspection is taken as an example), the second step that is not started in the original recipe includes: procedures O41, O32, O33, O12, O42, O13 and O23; for example, to reassign the machinable equipment to the unprocessed process 41, the corresponding assignment scheme is shown in fig. 4-8.
Alternatively, if the quality inspection result of the process O41 in fig. 3 is reject, the second process not started in the original recipe does not include the processes after the processes O41 and O41, and new workpieces may be additionally added, and a machinable apparatus may be arranged for each process of the new workpieces.
It should be noted that the number of the machinable apparatuses, the number of the workpieces, and the number of the machining processes of each workpiece in the embodiment of the present invention are exemplary, and the scheduling scheme of the present invention should not be limited thereto.
Step 22: and determining the optimal scheme corresponding to each second procedure based on a situation evaluation algorithm.
Wherein the optimal solution is one of at least one alternative solution corresponding to each of the second processes.
In this embodiment, for each second process, based on the situation evaluation algorithm, a first alternative corresponding to each second process is found, that is, one alternative of the correspondence between the second process and the machinable apparatus is found for each second process, that is, the optimal solution is found.
Step 23: and determining the processing sequence of the second procedure through a simulated annealing genetic algorithm based on the optimal schemes respectively corresponding to the second procedures to obtain a target scheme.
In this embodiment, based on the optimal solution of the corresponding relationship between each second process and the machinable equipment determined in the step 22, the arrangement order of all the second processes is determined based on a simulated annealing algorithm, so as to obtain a target solution, that is, the target solution includes the machining order of the second processes and the machinable equipment corresponding to each second process.
In the scheme, in the scheduling process of the original scheme, if the quality inspection result of the first process is unqualified, at least one alternative scheme of the corresponding relation between each second process and the machinable equipment is generated; determining an optimal scheme corresponding to each second procedure based on a situation evaluation algorithm; based on the optimal schemes respectively corresponding to the second procedures, the processing sequence of the second procedures is determined through a simulated annealing genetic algorithm to obtain a target scheme, the problem that in the existing flexible job workshop dynamic scheduling method, due to the fact that quality inspection is unqualified, single procedure reentry is caused, and due to the fact that quality inspection is scrapped, workpieces are put into production again, and the operation plan is disconnected with the actual production is solved, and therefore guidance is provided for workshop scheduling personnel to conduct flexible job workshop dynamic scheduling with quality inspection procedures, the fact that the difference between the rescheduling scheme and the original scheme is small can be guaranteed, and the maximum completion time is guaranteed to be minimized.
Optionally, step 21 may specifically include:
under the condition that the quality inspection result of the first procedure is unqualified, determining the completion moment of the first procedure as a disturbance time node;
determining all processes started after the disturbance time node as the second process;
generating at least one alternative for each of said second procedures in correspondence with the processable equipment.
Specifically, under the condition that the obtained quality inspection result is the first process of repair or scrapping, calculating a disturbance time node (namely the processing end time of the unqualified first process in the original scheme); and keeping the processing time and the processing equipment of the process started before the disturbance time node in the original scheme unchanged, and rescheduling the process started after the disturbance node, namely respectively arranging the processing equipment for each process started after the disturbance node to obtain at least one alternative scheme corresponding to each process.
Optionally, the step of generating at least one alternative of the correspondence between each second process and the machinable apparatus may specifically include:
determining AM alternatives for arranging the first target process to the AM machinable devices according to the earliest starting time of the first target process and the idle time of the AM machinable devices; wherein the first target process is any one of the second processes; AM is the number of machinable apparatuses of the first target process.
Wherein, when the first target process is a first process in the processing processes of the target workpiece, the earliest starting time is a current time; in the case where the first target step is a step other than the first step in the machining step, the earliest possible start time is: and a finishing time of a last step before the first target step in the machining step.
For example: selecting a first procedure needing to be scheduled as a current procedure to be scheduled, and if the current procedure to be scheduled is not the first procedure of a certain workpiece, obtaining the earliest starting time of the current procedure to be scheduled according to the ending time of a previous procedure in a process route of the current procedure to be scheduled; if the current scheduled process is the first process of a certain workpiece, the current time is taken as the earliest starting time. Further, considering the earliest possible starting time of the current process to be scheduled and the idle time of all the machinable devices of the current process to be scheduled, the current process to be scheduled is respectively scheduled to each machinable device, and AM (AM is the number of machinable devices of the current process to be scheduled) alternatives of the current process to be scheduled are obtained, as shown in fig. 4 to 8.
In this embodiment, for each second process, the alternative corresponding to the second process may be determined by the same method as described above, and details are not described here.
Optionally, the step 22 may specifically include:
calculating a situation evaluation value corresponding to each alternative of the second target process;
determining a candidate scheme corresponding to the minimum value in the situation evaluation values as an optimal scheme corresponding to the second target process; wherein the second target process is any one of the second processes.
Specifically, the step of calculating the situation evaluation value corresponding to each alternative in the second target process may specifically include:
by the formula Pijp=(NSij-OSij)2/(OYijp+1), calculating the situation evaluation value corresponding to each alternative of the second target process;
wherein, PijpTo form a second target process OijArranged in a machinable apparatus MpUpper situation evaluation value, NSijRepresents a second target process O in the alternativeijStart time of (1), OSijRepresents a second target process O in the original recipeijThe start time of (c); if the second target process O in the original schemeijArranged in a machinable apparatus MpUpper, then OYijpIs 1, otherwise is 0.
The numerator in the above formula represents the original and alternative, process OijThe difference between the processing start times of (a). The denominator in the above formula represents the original scheme and the alternative scheme, the procedure OijArranged machinable deviceThe differences between the two. If the arranged machinable devices are different, the value of the denominator is 1; otherwise the value of the denominator is 2, procedure OijThe influence of the difference in the machining start time on the evaluation value is reduced.
In this embodiment, the situation evaluation values corresponding to each candidate in the second target process are calculated, and the candidate corresponding to the minimum value in the situation evaluation values is determined as the optimal solution corresponding to the second target process, so as to reduce the difference between the original solution and the candidate as much as possible.
Fig. 9 shows a flowchart for determining the optimal solution corresponding to the second process. The method specifically comprises the following steps:
step 91: a first procedure of obtaining an original scheme, a disturbance time node and unqualified data;
and step 92: judging whether a gene exists in the current code; wherein the genes represent the processes and the current codes indicate the processing order of the processes in the original scheme; if not, the process is ended; if yes, go to step 93;
step 93: obtaining a procedure corresponding to a first gene in the current code, namely the current procedure;
step 94: judging whether the current process is in front of a disturbance time node: if yes, go to step 95; if not, the following step 96 is executed;
step 95: deleting the first gene in the current code; after this step 95, the process returns to the step 92.
Step 96: obtaining an alternative scheme of the current process;
step 97: calculating the situation evaluation value of each alternative scheme;
step 98: generating an optimal scheme of the current process according to the situation evaluation, namely a candidate scheme with the smallest situation evaluation value; after this step 98, the procedure returns to the above step 95 until there are no unscheduled procedures, and the procedure ends, i.e. the optimal solution for each procedure after the disturbance node is found.
Optionally, step 23 may specifically include:
based on a genetic algorithm, the following steps are performed: taking m codes in the ith code group as individuals, taking the maximum completion time corresponding to the m codes respectively as the fitness of the individuals, and obtaining m updated codes through an annealing algorithm;
when a preset termination condition of the genetic algorithm is met, determining a global optimal code from i code groups respectively obtained after i times of the annealing algorithm;
obtaining the target scheme according to the global optimal coding;
wherein the code is used for indicating the processing sequence of the second procedure; i is the number of times of the annealing algorithm, and m is the number of codes in each code group;
when i is 1, m codes in the ith code group are: generating m codes based on the optimal schemes respectively corresponding to the second procedures;
when i is greater than 1, the m codes in the ith code group are: and the (i-1) th code group obtains m updated codes after an annealing algorithm and obtains m mutated codes after mutation processing.
Specifically, as shown in fig. 12, when the first annealing algorithm is performed, the population is initialized. I.e. the way the process codes are selected to generate population individuals (i.e. the codes in the first code group). In this coding scheme, each gene in the chromosome (i.e., population individual) represents the process corresponding to the number. FIG. 10 shows a master chromosome containing 8 genes, which represents the sequence of the process arrangement: the first step of the job 2 → the first step of the job 1 → the second step of the job 1 → the first step of the job 3 → the second step of the job 2 → the second step of the job 3 → the third step of the job 1 → the third step of the job 3.
Thus, when individuals in the population are generated, the fitness value of each individual can be calculated, that is, the maximum completion time (Cmax) of all the processes in the coding order of each individual can be calculated, and the Cmax is the fitness value. The maximum completion time is a time period from a start time of a first process to a completion time of a last process among all the processes.
Obtaining m codes through a first annealing algorithm, namely a local optimal solution of the first annealing algorithm, wherein the m codes obtained through the first annealing algorithm form a second code group; subjecting the second coding set to large-scale mutation, as shown in FIG. 11; taking the second coding group subjected to mutation processing as a new individual to carry out a second annealing algorithm, thereby obtaining m codes obtained by the second annealing algorithm, namely a local optimal solution of the second annealing algorithm, wherein the m codes obtained by the second annealing algorithm form a third coding group; and carrying out large-scale mutation treatment on the third coding group, and carrying out a third annealing algorithm by taking the mutated third coding group as a new individual so as to obtain m codes obtained after the third annealing algorithm, and so on until a preset termination condition of the genetic algorithm is reached.
Alternatively, the predetermined termination condition of the genetic algorithm may be an annealing algorithm performed a predetermined number of times, such as: 10 times. Thus, multiple groups of local optimal solutions can be obtained through the simulated genetic annealing algorithm.
Optionally, the step of determining a global optimal code from the i code groups obtained after the i annealing algorithms may specifically include: and determining a code with the minimum maximum completion time from the i code groups as the global optimal code.
In this way, from the obtained multiple sets of local optimal solutions, a code with the minimum maximum completion time is selected as a global optimal code, namely, all the second procedures are guaranteed to be arranged on the basis of machinable equipment with smaller difference from the original scheme, and the maximum completion time is guaranteed to be smaller as much as possible.
As shown in fig. 13, the step of obtaining m updated codes through an annealing algorithm by using m codes in the ith code group as individuals and using the maximum completion times corresponding to the m codes as fitness of the individuals in the above step may specifically include:
a. initializing a temperature value T;
b. respectively generating a neighborhood individual for each individual (for example, in fig. 13, the neighborhood individual of the individual 1 is 1 ', the neighborhood individual of the individual 2 is 2 ', the neighborhood individual of the individual m is m ', and specific ways for determining the neighborhood individual may be various, which are not specifically limited in the present invention), and calculating the fitness corresponding to the neighborhood individual;
c. calculating a fitness increment delta E between each individual and the corresponding neighborhood individual; if the increment delta E of the first individual corresponding to the first individual is less than 0, executing the following step f; if the increment delta E of the first individual corresponding to the first individual is not less than 0, executing the following step d;
d. calculating a reception rate between each of the individuals and the neighborhood individual corresponding thereto by a formula r ═ exp (Δ E/kT); wherein r is an acceptance rate, k is a preset constant, and exp is a natural constant;
e. comparing said acceptance rate r with a random number (rand); wherein the value range of the random number is 0-1; if r is greater than rand, executing the following step f; if r is less than or equal to rand, executing the following step g;
f. replacing the first individual with a neighboring individual corresponding thereto; wherein the first individual is any one of the individuals;
g. updating temperature values, such as: decrementing the temperature value T by a predetermined step size;
h. judging whether a termination condition is met, such as: whether the current temperature value T is decreased to a preset value or not; when the temperature value T is not decreased to a preset value, the steps b to g are repeatedly executed; and when the temperature value T is decreased to a preset value, ending the process to obtain m local optimal solutions, wherein the m local optimal solutions are m codes corresponding to the step g executed for the last time.
In the above scheme of the embodiment of the invention, a flexible job shop dynamic scheduling method considering a quality inspection process is provided; the method allocates one processing device for each process based on the device allocation algorithm of the situation evaluation, thereby realizing the device allocation of all processes with the aim of minimizing the maximum completion time and minimizing the difference of new and old production-removal schemes; the improved genetic annealing mixed algorithm is used for optimizing the arrangement sequence of all the working procedures, and the improved genetic annealing algorithm can be combined with the excellent local optimizing capability of the simulated annealing algorithm and the mutation operation of the genetic algorithm, so that the global optimizing capability is ensured, and the rapid global search is realized.
The scheme solves the problems that in the conventional flexible job workshop dynamic scheduling method, due to the fact that quality inspection is unqualified, a single process is reentered, and the quality inspection is scrapped, the work piece is put into production again, so that the job plan is disconnected from the actual production, the difference between the rescheduling scheme and the original scheme is small, and the maximum completion time is minimized.
As shown in fig. 14, an embodiment of the present invention further provides a flexible job shop dynamic scheduling apparatus, including:
a generating module 1410, configured to generate at least one alternative solution of the corresponding relationship between each second process and the processable equipment if the quality inspection result of the first process is unqualified in the scheduling process of the original solution; wherein the second step is: a step which is not started in the original scheme when the quality inspection result of the first step is unqualified;
a first determining module 1420, configured to determine, based on a situation evaluation algorithm, an optimal scheme corresponding to each of the second procedures; wherein the optimal solution is one of at least one alternative solution corresponding to each of the second processes;
and a second determining module 1430, configured to determine, based on the optimal solutions respectively corresponding to the second procedures, the processing order of the second procedures through a simulated annealing genetic algorithm, so as to obtain a target solution.
Optionally, the generating module 1410 includes:
the first determining submodule is used for determining the finishing moment of the first procedure as a disturbance time node under the condition that the quality inspection result of the first procedure is unqualified;
a second determining submodule configured to determine all processes started after the disturbance time node as the second process;
and the generation sub-module is used for generating at least one alternative of the corresponding relation between each second procedure and the machinable equipment.
Optionally, the generating sub-module includes:
a determining unit, configured to determine AM alternatives for arranging the first target process on the AM processable devices according to an earliest startable time of the first target process and idle times of the AM processable devices; wherein the first target process is any one of the second processes; AM is the number of machinable apparatuses of the first target process.
Optionally, the first determining module 1420 includes:
the calculation submodule is used for calculating the situation evaluation value corresponding to each alternative of the second target process;
a third determining submodule, configured to determine an alternative solution corresponding to a minimum value in the situation evaluation values, as an optimal solution corresponding to the second target process; wherein the second target process is any one of the second processes.
Optionally, the calculation sub-module includes:
a calculation unit for passing formula Pijp=(NSij-OSij)2/(OYijp+1), calculating the situation evaluation value corresponding to each alternative of the second target process;
wherein, PijpTo form a second target process OijArranged in a machinable apparatus MpUpper situation evaluation value, NSijRepresents a second target process O in the alternativeijStart time of (1), OSijRepresents a second target process O in the original recipeijThe start time of (c); if the second target process O in the original schemeijArranged in a machinable apparatus MpUpper, then OYijpIs 1, otherwise is 0.
Optionally, the second determining module 1430 includes:
a first processing submodule for performing the following steps, based on a genetic algorithm: taking m codes in the ith code group as individuals, taking the maximum completion time corresponding to the m codes respectively as the fitness of the individuals, and obtaining m updated codes through an annealing algorithm;
the second processing submodule is used for determining a global optimal code from i code groups respectively obtained after i times of annealing algorithm when a preset termination condition of the genetic algorithm is met;
the third processing submodule is used for obtaining the target scheme according to the global optimal code;
wherein the code is used for indicating the processing sequence of the second procedure; i is the number of times of the annealing algorithm, and m is the number of codes in each code group;
when i is 1, m codes in the ith code group are: generating m codes based on the optimal schemes respectively corresponding to the second procedures;
when i is greater than 1, the m codes in the ith code group are: and the (i-1) th code group obtains m updated codes after an annealing algorithm and obtains m mutated codes after mutation processing.
Optionally, the second processing sub-module includes:
and the processing unit is used for determining a code with the minimum maximum completion time from the i code groups as the global optimal code.
The apparatus provided in the embodiment of the present invention is capable of implementing each process implemented in at least one of the above method embodiments, and is not described here again to avoid repetition.
In the device 1400 in the embodiment of the present invention, in the scheduling process of the original scheme, through the generation module 1410, if the quality inspection result of the first process is unqualified, at least one alternative scheme of the corresponding relationship between each second process and the machinable equipment is generated; determining the optimal scheme corresponding to each second procedure based on a situation evaluation algorithm through a first determination module 1420; and determining the processing sequence of the second process by a simulated annealing genetic algorithm through a second determination module 1430 based on the optimal schemes respectively corresponding to the second process to obtain a target scheme, thereby solving the problem that the operation plan is disconnected from the actual production due to the condition that a single process is reentrant caused by unqualified quality inspection and the workpiece is re-put into production caused by scrapping quality inspection in the conventional flexible job shop dynamic scheduling method, providing guidance for shop scheduling personnel to perform flexible job shop dynamic scheduling with quality inspection processes, ensuring that the difference between the rescheduling scheme and the original scheme is small, and ensuring the minimization of the maximum completion time.
In addition, an embodiment of the present invention further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the computer program implements each process of the flexible job shop dynamic scheduling method embodiment, and can achieve the same technical effect, and is not described herein again to avoid repetition. The computer-readable storage medium may be a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk.
While the preferred embodiments of the present invention have been described, it will be understood by those skilled in the art that various changes and modifications may be made without departing from the spirit and scope of the invention as defined in the following claims.