global search problems.

8 ビュー (過去 30 日間)
Valerio Matteucci
Valerio Matteucci 2011 年 9 月 29 日
hi all, sorry for my bad english.
i have some problems with a global minimization:
A = [-1 0 0 0 ; 0 -1 0 0 ; 0 0 -1 0 ; 0 0 0 -1];
b = [0 0 0 0];
sf = @(x)sum(arrayfun(@(K)parameterfun(x,T(K),R(K)),1:length(T)));
opts = optimset('Algorithm','interior-point');
problem=createOptimProblem('fmincon','x0',[1 1 1 1] ,'Aineq',A,'bineq',b,'objective',sf,'options',opts);
gs = GlobalSearch;
x = run(gs,problem) %global search
Where parameterfun is a 4 positive variables function that i want minimize and T and R are input vectors.
When i run it i recive some errors i cant manage to resolve:
??? Error using ==> minus
Matrix dimensions must agree.
Error in ==> D:\Matlab
R2011a\toolbox\globaloptim\globaloptim\private\globalsearchnlp.p>i_calcConstrViolation
at 593
Error in ==> D:\Matlab
R2011a\toolbox\globaloptim\globaloptim\private\globalsearchnlp.p>i_calcPenalty at
627
Error in ==> D:\Matlab
R2011a\toolbox\globaloptim\globaloptim\private\globalsearchnlp.p>globalsearchnlp at
343
Error in ==> GlobalSearch>GlobalSearch.run at 330
[x,fval,exitflag,output] = ...
Error in ==> main at 32
x = run(gs,problem) %global search
any ideas ? maybe there is another algorithm to use instead of global search for my problem ? i had already tried with genetic algorithms without success : (
ty all.

回答 (0 件)

カテゴリ

Help Center および File ExchangeDirect Search についてさらに検索

タグ

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by