I have two equation with 13 variables with some lower and upper bound.
t(1) = -118.676+0.167.*x(1)+0.097.*x(2)+0.120.*x(3)+0.659.*x(4)-0.044.*x(5)-0.066.*x(6)+0.042.*x(7)+0.065.*x(8)-8.821.*x(9);
t(2) = -0.804-0.001.*x(1)-0.001.*x(2)+0.0.*x(3)+0.0.*x(4)-0.031.*x(5)+0.005.*x(6)-0.002.*x(7)+0.001.*x(8)-0.735.*x(9)+0.097.*x(10)+0.012.*x(11)+0.078.*x(12)-0.220.*x(13);
If 1st equation's output acts as an inputs for 2nd equation, how to formulate it in PSO.
So that one can evaluate the behavior of both the equations simultaneously.
For example: 1st equation about the cost of the product which should be low/fixed and the 2nd equation about the profit which should be high.
If one can perform the optimization, both the equations should be satisfy simultaneously.
options = optimoptions('particleswarm','SwarmSize',100,'HybridFcn',@fmincon);
lb = [398 0 0 0 0 138 775 954 0.50 0.750 27 23.96 2];
ub = [402 0 0 0 0 142 779 959 0.50 0.750 27 23.96 2];
[x,fval,exitflag,output] = particleswarm(obj,nvars,lb,ub,options)
i have formulated this code. but its not quite Satisfactorily right. I am novice in matlab. Anybody mind helping in this regard?