Struggling With Genetic Algorithms in Matlab
4 次查看(过去 30 天)
显示 更早的评论
Hi, This is my first post and I only have a relatively basic knowledge of Matlab so go easy on me! Basically I am undertaking a project at university looking at Job Shop Scheduling and I am trying to develop a code for a Genetic Algorithm.
I am trying to create a population of chromosomes for a situation with 3 jobs which each have 3 operations to complete. I think I can create the random chromosomes with the following:
NumJobs = 3; NumOps = 3; Chromosome = repmat(1:NumOps,NumJobs,1); Order = randperm(NumOps*NumJobs); Chromosome = Chromosome(order)
However the next step is to evaluate each chromosome by its respective fitness, in this case the shortest completion time. Obviously this is calculated from precedence constraints and operation times etc. Basically I was just hoping if there were any tips or if you could point me in the direction of any tutorials or help I could look at?
Any help would be greatly appreciated! Thanks in advance
0 个评论
采纳的回答
A Jenkins
2014-12-5
If you have the Global Optimization Toolbox, then there are quite a few tutorials and example projects on the Mathworks Genetic Algorithm page.
If not, you could search the File Exchange for examples. There should be several there to help get you started.
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Genetic Algorithm 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!