TideMan <firstname.lastname@example.org> wrote in message <email@example.com>... > On Monday, January 7, 2013 9:25:09 AM UTC+13, Emrah wrote: > > isn't there anyone to answer this? > > Answer what? > I don't see a question, just a statement of the problem, which looks awfully like homework. > What have you tried? > In what way did it not work? > Show us the code you've developed so far.
ok mate, dont get angry :) here is the code i have developed so far
function objFuncPlot [x2, x3] = meshgrid(0.1:.1:10, 0.1:.1:10); %x1 and x4 is constant x1=0.1996; x4=0.2107; %calculating constraints [g1,g2,g3,g4,g5,g6,g7]=constraints(x1,x2,x3,x4); %objective function f=1.10471.*x1^2.*x2+0.04811.*x3.*x4.*(14.0+x2); %constraints are applied to f(x) (the problem point) f=f*mod_neg_step(g1)*mod_neg_step(g2)*mod_neg_step(g3)*mod_neg_step(g4)... *mod_neg_step(g5)*mod_neg_step(g6)*mod_neg_step(g7); %plotting surf surf(x2,x3,f,'LineStyle','none'); view(68,20) hold on plot3(4.7550, 9.3584, 1.988,'x','MarkerEdgeColor','b', ... 'MarkerSize',8); % best point xlabel('x');ylabel('y');zlabel('z'); hold off
My aim is to determine which type of optimization algorithm i have to use to solve this problem by checking the plot of the f(x) function. (local search or swarm or etc..) the answer is swarm and PSO is the best for this problem. but i have to show to my teacher the way how i discovered.
In my code, the problem is when I apply the penalty function to f(x), the plot returns none. also honestly i dont know if this is the true way. so i need something like a pseucode for the true way and have to know how to read the results.