Inequality constraints in gamultiobj

Hello,
I have got a problem with inequality constraints in file 'constraintfunction': when I introduced A and b as constraints, optimization does not work anymore (file 'mainfunction_11') and my Pareto front plot is not showing anything. The principle is that decision variables x and y at each time step j and EV i should be less than trans_percent_w_ch and trans_percent_w_dch, respectively. I thought that with an introduction of inequality constraint I could satisfy this requirement, however, it fails to work completely. Could you help me to figure out how to fix it so that my decision variables are constrained?
Thanks in advance!

2 Comments

Alan Weiss
Alan Weiss on 13 Dec 2020
Edited: Alan Weiss on 13 Dec 2020
Your constraintfunction code is over 600 lines long. I wonder if there is a small subset of your code or something like it that shows what you are trying to do and exactly how it fails. I do not plan to read through that much code, and doubt that others are willing to, either.
Alan Weiss
MATLAB mathematical toolbox documentation
Alan, thank you for pointing this out. Indeed, I should have been more specific.
The problem occurs in file 'constraintfunction' lines 563 - 579, where inequality constraints A and b are introduced:
A_1 = [];
A_2 = [];
A=[A_1;A_2];
A=[];
%
for j=1:num_slot
for i=1:num_EV
b_1(i,j)=trans_percent_w_ch(i,j);
end
end
for j=1:num_slot
for i=1:num_EV
b_2(i,j)=trans_percent_w_dch(i,j);
end
end
b=[b_1;b_2];
b_1 should be a constraint for x and b_2 - for y. If I run gamultiobj without these contraints, it normally gives me Pareto front.
Thank you for having a look at my problem.

Sign in to comment.

Answers (0)

Asked:

on 12 Dec 2020

Commented:

on 14 Dec 2020

Community Treasure Hunt

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

Start Hunting!