genetic algorithm - not running - reg

조회 수: 3 (최근 30일)
Kallam Haranadha Reddy
Kallam Haranadha Reddy 2017년 11월 16일
댓글: Kallam Haranadha Reddy 2017년 11월 16일
I converted a GAMS model (mip) file into cplexmps format using PAVER web server. I read this file into MATLAB R2015b using mpsread command.
Then i got the following output.
problem = mpsread('cplex(1).mps')
problem =
f: [1925x1 double]
Aineq: [216x1925 double]
bineq: [216x1 double]
Aeq: [773x1925 double]
beq: [773x1 double]
lb: [1925x1 double]
ub: [1925x1 double]
intcon: [0x1 double]
solver: 'linprog'
options: [1x1 optim.options.Linprog]
Then i made slight modifications as follows to use the problem with genetic algorithm solver.
c =(problem.f)';
A=problem.Aineq;
b=problem.bineq;
Aeq=problem.Aeq;
beq=problem.beq;
lb=problem.lb;
ub=problem.ub;
A = full(A);
Aeq=full(Aeq);
fun = @(x) sum(c.*x);
A=[A;Aeq;-Aeq];
b=[b;beq;-beq];
options = gaoptimset('PlotFcn',@gaplotbestf)
when i wanted to run ga with the following commands, it is showing 'busy' symbol for an abnormal time. how can i get the output.
[x,fval]=ga(fun,1925,A,b,[],[],lb,ub,[],options)
  댓글 수: 2
KSSV
KSSV 2017년 11월 16일
May be the data is huge......for your computer spec. YOu first try with a down sampled/ less data.
Kallam Haranadha Reddy
Kallam Haranadha Reddy 2017년 11월 16일
sir,
if the data is huge can i reduce the data using principal component analysis. i.e., can i reduce the size of Aineq, Aeq of my above problem using principal component analysis.

댓글을 달려면 로그인하십시오.

답변 (1개)

Walter Roberson
Walter Roberson 2017년 11월 16일
ga() uses random searching that wanders around local minima hoping to find a good location, with no certainty at all that it will ever find the best conformation. The number of combinations to try rises exponentially.
linprog() uses linear programming techniques that know how to split the problem domain according to constraints and then run a minimizer on each subdomain that is certain to find the minima over that subdomain; it goes through all of the subdomains and picks the one that does the best. It can take a while to create all of the subdomains implied by the constraints, but because each sub-problem is linear, it is certain to be able to optimize it -- the optimum is always at one of the corners of each linear sub-domain.
  댓글 수: 1
Kallam Haranadha Reddy
Kallam Haranadha Reddy 2017년 11월 16일
sir,
if the data is huge can i reduce the size of the data using principal component analysis. i.e., can i reduce the size of Aineq, Aeq of my above problem using principal component analysis.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Genetic Algorithm에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by