network optimization when constraint calls a function
6 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen

I am trying to optimize a network using GA. The objective function is to minimize x(3). The formulation is as follows:
x(0) is known.
Constraint file:
% equality
c_eq(1) = x(0) + x(4) - x(1);
res_fun = f(x(1));
c_eq(2) = x(2) - res_fun;
c_eq(3) = x(2) - x(4) - x(3);
% inequality
c(1) = x(0) - x(3);
[x,fval] = ga(ObjectiveFunction,nvars,[],[],[],[],LB,UB, ConstraintFunction);
And my question is that the formulation is correct?
Thank you.
10 Kommentare
Antworten (0)
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

