Mixed integer optimisation with genetic algorithm problem
이전 댓글 표시
Hi,
I'm trying to run setup an optimisation problem using a genetic algorithm with the following specification.
options = gaoptimset(@ga)
[x,fval,exitflag,output,population,scores] = ga(@alpha3_0,6,[0,0,0,1,-1,0],[0],[],[],[25,15,80,45,45,15],[80,15,150,200,200,100],[],[1, 2],options)
The aim is to have integer constraints on parameters 1 and 2 as well as the specified linear inequality.
According to the documentation this should be possible as it states that while equality constraints are not enforced but that the solver shouldn't have a problem with mixed integer problems and inequality constraints.
The results of this so far has been that the optimisation runs without any problems other than that the inequality constraint is completely ignored.
Any help would be greatly appreciated.
Cheers,
Calen
댓글 수: 3
Sean de Wolski
2012년 4월 3일
Is the constraint ignored in the result or in the intermediate generations?
Calen Walshe
2012년 4월 4일
Bob Hickish
2017년 1월 17일
I am having a very similar problem 5 years on. http://uk.mathworks.com/matlabcentral/answers/320749-using-genetic-algorithm-ga-function-for-integer-and-linear-inequality-constrained-optimization-ca
Will update the above question if I find an answer (for other people looking into this).
답변 (1개)
Seth DeLand
2012년 4월 4일
0 개 추천
Hi Calen, The GA solver uses a penalty function when optimizing mixed-integer problems. The penalty function takes into account both the fitness function and the constraint violation. There's some more info here.
So it is possible for infeasible points to get evaluated, and they return a high value for the penalty function. You could try adjusting the PenaltyFactor and InitialPenalty values to increase the penalty applied to points that violate the constraint. This won't stop all infeasible points from being evaluated, but it will make their penalty value worse which hopefully results in the solver moving away from those points faster.
댓글 수: 3
Paul Kerr-Delworth
2012년 4월 12일
Hi Calen,
As Seth says, the mixed integer GA solver uses a penalty function to handle the fitness function and inequality constraints.
However, the mixed integer GA solver does not use the PenaltyFactor and InitialPenalty function options as the penalty function used does not require a penalty parameter.
We do not try to enforce the inequality constraints at each generation, so it is possible for population members to not satisfy the inequality constraints during the intermediate generations for the mixed integer GA.
Saying that, we do honor the bound constraints at each generation. If you can tighten the lower and upper bounds, this can help the mixed integer GA solver converge more quickly.
Hope this helps
Best regards,
Paul
Calen Walshe
2012년 4월 24일
suvrat
2014년 1월 26일
i am facing the same problem could you please tell me how you work on this problem.
카테고리
도움말 센터 및 File Exchange에서 Genetic Algorithm에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!