How to set the variables as integers in a Genetic Algorithm Function?
15 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Zheng
am 7 Jul. 2012
Kommentiert: Walter Roberson
am 22 Mär. 2017
Hi,
Supposing the objective function is @(x)f(x(1),x(2)). I would like to set the variable 'x' as a integer in a Genetic Algorithm Function.
How should I do? Is there anyone knowing it?
Thanks, Zheng
0 Kommentare
Akzeptierte Antwort
Walter Roberson
am 7 Jul. 2012
Bearbeitet: Walter Roberson
am 27 Feb. 2015
Note that there are a number of restrictions on ga()'s operation when you constrain to integer.
9 Kommentare
Pratik Anandpara
am 22 Mär. 2017
how to set it in ga boundry value only in integer lb=[100 1] ub=[500 50]
i want upper and lower boundry value only in integer not in decimal point
Walter Roberson
am 22 Mär. 2017
Is the general form
x = ga(fitnessfcn,nvars,A,b,[],[],LB,UB,nonlcon,IntCon)
not what you need?
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Genetic Algorithm finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!