Buddha anger lotus 2021-08-31 15:38:00 阅读数:330

workshop
scheduling
solve
workshop
scheduling

**1 Job shop scheduling problem description **

Job shop scheduling problem （Job Shop Scheduling, JSP） Are some of the most classic NP-hard One of the problems . Its application fields are extremely wide , Involving aircraft carrier scheduling , Airport aircraft dispatch , Port terminal cargo ship dispatching , Automobile processing line, etc .

JSP Problem description ： A processing system has M Taiwan machine , Required processing N Homework , among , Homework i The number of operations included is Li. Make , be L Is the total work ordinal number of the task set . among , The processing time of each process has been determined , And each operation must be processed according to the sequence of processes . The task of scheduling is to arrange the processing scheduling and sorting of all jobs , While the constraints are met , Optimize the performance index .

Job shop scheduling needs to consider the following constraints :

Cons1： Each process is processed on the designated machine , And the processing can only be started after the previous process is completed ;

Cons2： At some point 1 This machine can only process 1 Homework ;

Cons3： Each job can only be in 1 On this machine 1 Time ;

Cons4： The process sequence and processing time of each operation are known , It does not change with the change of machining order .**2 Problem instance **

An example of job shop scheduling problem is given below , Each process is marked with a pair of values （m,p）, among ,m Indicates that the current operation must be performed on the m Processing on a machine ,p It means the first one m The processing time required for this machine to process the current operation .（ notes ： The machine and job numbers are from 0 Start ）

jop0=[(0,3),(1,2),(2,2)]

jop1=[(0,2),(2,1),(1,4)]

jop2=[(1,4),(2,3)]

In this case , Homework jop0 Yes 3 Process ： It's the first 1 The process is marked with (0,3), It means the second 1 The next process must be in the 0 Processing on a machine , And we need 3 Unit processing time ; It's the first 2 The process is marked with (1,2), It means the second 2 The next process must be in the 1 Processing on a machine , And we need 2 Unit processing time ; The rest is the same . in general , In this case, there are 8 Process .

A feasible solution to this problem is L=8 An arrangement of the start time of a process , And satisfy the constraints of the problem . The following figure shows a feasible solution （ notes ： The solution is not the optimal solution ） An example of ：

**1 Overview of genetic algorithm **

Genetic algorithm (ga) （Genetic Algorithm,GA） It's part of evolutionary computing , It is a computational model that simulates the biological evolution process of Darwin's genetic selection and natural elimination , It is a method to search the optimal solution by simulating the natural evolution process . The algorithm is simple 、 Universal , Strong robustness , Suitable for parallel processing .

**2 Characteristics and application of genetic algorithm **

Genetic algorithm is a kind of robust search algorithm which can be used for complex system optimization , Compared with the traditional optimization algorithm , It has the following characteristics ：

（1） Take the code of decision variable as the operation object . Traditional optimization algorithms often directly use the actual value of decision variables to optimize calculation , But genetic algorithm uses some form of coding of decision variables as the operation object . This coding method for decision variables , So we can learn from the concepts of chromosome and gene in Biology , It can imitate the genetic and evolutionary incentives of organisms in nature , Genetic operators can also be easily applied .

（2） Directly use fitness as search information . The traditional optimization algorithm not only needs to use the value of the objective function , Moreover, the search process is often constrained by the continuity of the objective function , There may be a need to meet “ The derivative of the objective function must exist ” To determine the search direction . The genetic algorithm only uses the fitness function value transformed by the objective function value to determine the further search range , No other auxiliary information such as derivative value of objective function is required . Directly using the objective function value or individual fitness value can also focus the search range into the search space with higher fitness , To improve search efficiency .

（3） Search information using multiple points , With implicit parallelism . The traditional optimization algorithm is often an iterative search process starting from an initial point in the solution space . A single point provides little search information , So the search efficiency is not high , It is also possible to fall into the local optimal solution and stop ; Genetic algorithm starts the search process of the optimal solution from the initial population composed of many individuals , Instead of searching from a single individual . Of the initial population 、 choice 、 cross 、 Mutation and other operations , Produce a new generation of groups , It includes a lot of group information . This information can avoid searching some unnecessary points , So as to avoid falling into local optimization , Gradually approach the global optimal solution .

（4） Use probabilistic search instead of deterministic rules . Traditional optimization algorithms often use deterministic search methods , The transfer from one search point to another has a definite transfer direction and transfer relationship , This certainty may make the search less than optimal , It limits the application scope of the algorithm . Genetic algorithm is an adaptive search technology , Its choice 、 cross 、 Operations such as mutation are carried out in a probabilistic way , Increases the flexibility of the search process , And it can converge to the optimal solution with a large probability , It has good global optimization ability . but , Crossover probability 、 Mutation probability and other parameters will also affect the search results and search efficiency of the algorithm , Therefore, how to select the parameters of genetic algorithm is an important problem in its application .

Sum up , Because the overall search strategy and optimization search method of genetic algorithm do not depend on gradient information or other auxiliary knowledge , Only the objective function affecting the search direction and the corresponding fitness function need to be solved , Therefore, genetic algorithm provides a general framework for solving complex system problems . It does not depend on the specific area of the problem , Strong robustness to the types of problems , So it is widely used in various fields , Include ： Function optimization 、 Combinatorial optimal production scheduling problem 、 Auto-Control

、 Robotics 、 The image processing （ Image restoration 、 Image edge feature extraction …)、 Artificial life 、 Genetic programming 、 machine learning .

**3 The basic flow and implementation technology of genetic algorithm **

Basic genetic algorithm （Simple Genetic Algorithms,SGA） Use only the selection operator 、 Crossover operator and mutation operator are three genetic operators , Evolution is simple , It is the basis of other genetic algorithms .

3.1 The basic flow of genetic algorithm

Generate a number of randomly determined lengths （ The length is related to the accuracy of the problem to be solved ） The initial population of coding ;

Each individual is evaluated by fitness function , Individuals with high fitness value were selected to participate in genetic operation , Individuals with low fitness are eliminated ;

Genetically manipulated （ Copy 、 cross 、 variation ） A new generation of population is formed by the collection of individuals , Until the stop criteria are met （ Evolution algebra GEN>=?）;

The best realized individual in the offspring is taken as the execution result of the genetic algorithm .

among ,GEN Is the current algebra ;M It's population size ,i Represents the number of populations .

3.2 Implementation technology of genetic algorithm

Basic genetic algorithm （SGA） Coded by 、 Fitness function 、 Genetic operators （ choice 、 cross 、 variation ） And operation parameters .

3.2.1 code

（1） Binary code

The length of binary coded string is related to the accuracy of the problem . We need to ensure that every individual in the solution space can be encoded .

advantage ： Ed 、 The decoding operation is simple , inheritance 、 Crossover is easy to achieve

shortcoming ： The length is large

（2） Other coding methods

Gray code 、 Floating point code 、 Symbolic encoding 、 Multi parameter coding, etc

3.2.2 Fitness function

The fitness function should effectively reflect the gap between each chromosome and the chromosome of the optimal solution of the problem .

3.2.3 Selection operator

3.2.4 Crossover operator

Cross operation refers to the exchange of some genes between two paired chromosomes in some way , And two new individuals ; Crossover operation is an important feature that distinguishes genetic algorithm from other evolutionary algorithms , Is the main way to produce new individuals . Before crossing, individuals in the group need to be paired , Generally, the principle of random pairing is adopted .

Commonly used crossover ：

A single point of intersection

Two point intersection （ Multi-point crossover , The more cross points , The more likely the individual's structure is to be destroyed , Generally, multi-point intersection is not adopted ）

Uniform cross

Arithmetic crossover

3.2.5 Mutation operator

The mutation operation in genetic algorithm refers to replacing the gene values at some loci in the individual chromosome coding string with other alleles at this locus , So as to form a new individual .

In terms of the ability to generate new individuals in the operation of genetic algorithm , Cross operation is the main method to generate new individuals , It determines the global search ability of genetic algorithm ; Mutation is only an auxiliary method to generate new individuals , But it is also an essential operation step , It determines the local search ability of genetic algorithm . The combination of crossover operator and mutation operator completes the global search and local search of the search space , Thus, the genetic algorithm can complete the optimization process of the optimization problem with good search performance .

3.2.6 Operation parameters **4 The basic principle of genetic algorithm 4.1 Pattern theorem **

With low order 、 The definition length is short , The pattern whose fitness value is higher than the average fitness value of the population is called gene block or building block .

Building block hypothesis ： Individual gene blocks are selected 、 cross 、 The role of genetic operators such as mutation , Can be spliced together , Form individual coding strings with higher fitness .

The building block hypothesis illustrates the basic idea of using genetic algorithm to solve various problems , That is, better solutions can be produced by directly splicing building blocks together .

**1 matlab edition **

2014a

**2 reference **

[1] Baoziyang , Yu Jizhou , Poplar . Intelligent optimization algorithm and its application MATLAB example （ The first 2 edition ）[M]. Electronic industry press ,2016.

[2] Zhang Yan , Wu Shuigen .MATLAB Optimization algorithm source code [M]. tsinghua university press ,2017.

版权声明：本文为[Buddha anger lotus]所创，转载请带上原文链接，感谢。 https://car.inotgo.com/2021/08/20210825162444506n.html

- 解决你的“选择困难症”！全新日产Frontier实车，硬朗时尚的皮卡
- 2021成都车展丨纯电续航53公里 路虎卫士110 P400e售79.8万
- 十万预算之选 分析轩逸、哈弗H6、欧拉好猫优缺点 看完还入手吗？
- 2021成都车展：针对细节调整 新款奥迪Q2L正式上市
- 新车速递 | 配置升级 哈弗H6 Supreme+最新消息
- 呃｜五菱征程预售价公布了
- 新款宝马5系正式亮相，时尚气息十足，简直不要太喜欢
- 这还是你曾经认识的它吗？斯巴鲁新一代傲虎实力亮相，真香
- 可爱呆萌 奇瑞QQ冰淇淋将于11月上市
- 什么都好就是太霸气了！全新凯迪拉克凯雷德实车，6.2L+V8动力
- 30.98万元起，成都车展：林肯冒险家PHEV正式上市，1.5T+双电机
- 这四种人最好别学开车，尤其是最后一种，路上谁遇到谁倒霉
- 长安马自达收购案尘埃落定，一汽马自达“真情告白”说了啥？
- 黑武士版本你能“顶得住”？全新梅赛德斯-迈巴赫S级街拍，真不错
- 新车 | 竞争林肯飞行家，新款捷尼赛思GV80正式发布，增加6座车型
- 国产中大型MPV赛那SIENNA，够大够豪华，家用新选择
- The owner said ｜ what about the Lexus es purchased for 31 months?
- Waiting for you to control! Another luxury car bow! A pragmatic choice with an annual salary of 200000! Ruiji vs maiteng
- The appearance is domineering and side leakage. The 2021 wey vv6 makes a profit of 15000, and the naked car price is as low as 133000
- Experience BMW 7 Series: the interior is super luxurious, and even the floor has color, which is rare! The price has dropped again
- Drive it! A winner with a monthly salary of 8000! Langyi vs Xiangyu
- The sense of refinement is improved. The new Audi q2l will be officially launched at Chengdu auto show, equipped with 1.4T engine
- Why don't you buy it because it's so cost-effective? What are you thinking about with a monthly salary of 8000! Wing tiger vs creation
- 可愛呆萌 奇瑞QQ冰淇淋將於11月上市
- 這還是你曾經認識的它嗎？斯巴魯新一代傲虎實力亮相，真香
- It is possible to release a popular new MPV within this year. The pressure is really great!
- rise! Don't go away! Who says you can't buy it with a monthly salary of 8000? Santana vs Baron HS
- Hyundai's first MPV Cousteau is about to appear in Chengdu auto show. Is the MPV market going to rise?
- 30.98萬元起，成都車展：林肯冒險家PHEV正式上市，1.5T+雙電機
- 什麼都好就是太霸氣了！全新凱迪拉克凱雷德實車，6.2L+V8動力
- 國產中大型MPV賽那SIENNA，够大够豪華，家用新選擇
- 新車 | 競爭林肯飛行家，新款捷尼賽思GV80正式發布，增加6座車型
- It is estimated that 276800 domestic Saina real cars will be sold, and the second row seats will be upgraded. Will the price be increased
- A total of 8 models are promoted. Which configuration of the new generation Qijun is the most worth buying?
- 黑武士版本你能“頂得住”？全新梅賽德斯-邁巴赫S級街拍，真不錯
- 長安馬自達收購案塵埃落定，一汽馬自達“真情告白”說了啥？
- Test drive Salis sF5: how does this car, which can be bought in Huawei stores, drive?
- Trillion "big infrastructure" bill passed, focusing on charging piles and vehicle safety in the United States
- The interior of tank 500 was exposed, and the interior watch and wood grain trim panel were released in 4 days
- Promoting the low-carbon development of the automobile industry is an important starting point to achieve the goal of "double carbon"
- "Auto V news" Lingke 03 + cyan customized version is released; 2022 Subaru WRX preview exposure-20210825
- Preview of Geely Dihao L / boyue x at Chengdu auto show
- 這四種人最好別學開車，尤其是最後一種，路上誰遇到誰倒黴
- 頂配車型才八萬多，到店體驗第四代吉利帝豪
- A precursor to the return of the rotor engine! Mazda registered trademark of "triangle rice ball"
- “帶刀”護衛，2021成都車展：長城炮機車版亮相，空間更大更實用
- 新款寶馬5系正式亮相，時尚氣息十足，簡直不要太喜歡
- This car is full of fashion? There is no discount for mingtu in the near future, starting from 133800 yuan
- Finally the trump card! Second kill! Really fragrant series! Ruiji vs Asian Dragon
- BJ212 salute version of the new model is on the market at a price of 94800
- Be decisive! Netizen: starting with a monthly salary of 8000, don't panic! Santana vs se DX7
- Elegant and atmospheric design, driving a row of Bentley cars
- Equipped with armored body and triple screen instrument panel, the first batch of "tank 700" was photographed in the store
- Go out and pull the wind! The name of tank 600 is changed to tank 500. Netizen: the intelligent configuration of this car understands me!
- Jeep launched the Wrangler "Weiss" special edition, limited to 300, which will be officially put on sale on September 4
- 115900 new Changan uni-t were sold and officially launched
- Walking "noble spirit", a new generation of "AMG g63" was officially listed, and the terminal price rose again
- 呃｜五菱征程預售價公布了
- 越賣越火的國產車-吉利帝豪GL，部分地區優惠2.1萬
- 終於等到它，第4代帝豪驚喜上市，還不進來看一看