Genetic Algorithm - limiting significant digits of Optimization Variable
古いコメントを表示
Hello All,
What is the correct options setting for limiting the sgnificant digits after the decimal point of the input variables to the fitness function.
Follwoing Example:
function [y] = fitnessfunction(XX)
%% ======================================================================== % Initialize for two objectives y = zeros(2,1);
% Compute first objective for i = 1:6 y(1) = y(1) - 10*exp(-0.2*sqrt(XX(i)^2 + XX(i+1)^2)); end
% Compute second objective for i = 1:6 y(2) = y(2) + abs(XX(i))^0.8 + 5*sin(XX(i)^3); end end
**************************************************** ****************************************************** options = gaoptimset( 'InitialPopulation', initpop, ... 'PopInitRange' ,[lower_bounds; upper_bounds], ... 'Vectorized', 'off', 'PlotFcns',@gaplotpareto,'StallGenLimit',150);
[X,FVAL,REASON,OUTPUT,POPULATION,SCORES] = gamultiobj(fitnessFunction,nvars,Aineq,Bineq,Aeq,Beq,LB,UB,options);
How can I change the setting such that 'gamultiobj' changes parameters XX to limit pricision to 2 digits.
Thanks, Yash
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Surrogate Optimization についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!