%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % MIDACO 7 benchmark - Levy function with 800 variables % ------------------------------------------------------ % % A multimodal test function with a large number of local minima in % every variable (sine terms) around a parabolic trend. The global % minimum F(X) = 0 lies at x = (1, 1, ..., 1). % % Reference: S. Surjanovic and D. Bingham, Virtual Library of Simulation % Experiments: https://www.sfu.ca/~ssurjano/levy.html % % Variables: 800 continuous variables in [-10, 10] % Constraints: none % Optimum: F(X) = 0 % % MIDACO setting: all parameters by default, start at % the lower bounds, the run stops when F(X) reaches 0.0001 (FSTOP). % % This benchmark needs a full MIDACO license: the limited version % solves problems with up to 8 variables and the default parameters. % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% function levy800 key = '************************************************************'; problem.func = @problem_function; problem.o = 1; % Number of objectives problem.n = 800; % Number of variables (in total) problem.ni = 0; % Number of integer variables (0 <= ni <= n) problem.m = 0; % Number of constraints (in total) problem.me = 0; % Number of equality constraints (0 <= me <= m) problem.xl = -10 * ones(1,800); problem.xu = 10 * ones(1,800); problem.x = problem.xl; % Starting point: lower bounds option.maxeval = 10000000; option.maxtime = 60*60*24; option.printeval = 1000; option.save2file = 1; option.resumable = 0; option.param( 1) = 0; % ACCURACY option.param( 2) = 0; % SEED option.param( 3) = 0.0001; % FSTOP option.param( 4) = 0; % ALGOSTOP option.param( 5) = 0; % EVALSTOP option.param( 6) = 0; % FOCUS option.param( 7) = 0; % ANTS option.param( 8) = 0; % KERNEL option.param( 9) = 0; % ORACLE option.param(10) = 0; % PARETOMAX option.param(11) = 0; % EPSILON option.param(12) = 0; % BALANCE option.param(13) = 0; % CHARACTER option.param(14) = 0; % SURROGATE option.param(15) = 0; % PMISQP option.parallel = 0; % Serial: 0 or 1, Parallel: 2,3,4,5,6,7,8... option.paradigm = 0; % Parallel mode: 0 = parfor, 1 = vectorized [F,G] = func(X) [ solution ] = midaco( problem, option, key ); end %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% function [ f, g ] = problem_function( x ) w = 1 + (x - 1) / 4; f(1) = sin(pi*w(1))^2 ... + sum( (w(1:end-1)-1).^2 .* (1 + 10*sin(pi*w(1:end-1)+1).^2) ) ... + (w(end)-1)^2 * (1 + sin(2*pi*w(end))^2); g = []; end