MATLAB Answers

How to separate the Hybrid iteration from the MOGA iteration?

1 ビュー (過去 30 日間)
Mohamed Abubakr
Mohamed Abubakr 2019 年 12 月 1 日
Answered: Alan Weiss 2019 年 12 月 2 日
Hi
I am using gamultiobj and I am activating the hybrid option.
I am woundering if there is any way to store the Pareto front before the hybrid function start, so I can assess its effect on the solution. Till now I can up with performing gamultiobj without hybrid for say 20 generation then I perform only one more generation of gamultiobj with hybrid. But by this why I can't yet seperate the hybrid function effect since it is still couple with 1 more itteration using GA. I tried to set the GA generation to zero but the matlab refused this settings.
You can find below the part of the code I am intrested in modifying
Thanks
%Without hybrid
for i=2:20
InitialPopulationMatrix_Data=population;
InitialScoresMatrix_Data=score;
[x,fval,exitflag,output,population,score] = MOGA_2_With_Intial(nvars,lb,ub,PopulationSize_Data,CrossoverFraction_Data,ParetoFraction_Data,MaxGenerations_Data,MaxStallGenerations_Data,FunctionTolerance_Data,ConstraintTolerance_Data,InitialPopulationMatrix_Data,InitialScoresMatrix_Data);
end
%%Hybrid
InitialScoresMatrix_Data=score;
InitialPopulationMatrix_Data=population;
MaxGenerations_Data=1;
[x,fval,exitflag,output,population,score] = MOGA_2_With_Hybrid(nvars,lb,ub,PopulationSize_Data,CrossoverFraction_Data,ParetoFraction_Data,MaxGenerations_Data,MaxStallGenerations_Data,FunctionTolerance_Data,ConstraintTolerance_Data,InitialPopulationMatrix_Data,InitialScoresMatrix_Data);

  0 件のコメント

サインイン to comment.

件の回答 (1)

Alan Weiss
Alan Weiss 2019 年 12 月 2 日
You can use a custom output function to store the population and Pareto front at each generation. See Custom Output Function for Genetic Algorithm.
Alan Weiss
MATLAB mathematical toolbox documentation

  0 件のコメント

サインイン to comment.

サインイン してこの質問に回答します。


Translated by