Matrix input and matrix variables in minimization of an objective function
Mostrar comentarios más antiguos
I have three variables S,V,B .Each variable is a 16*1 Matrix. I'd like to minimize an objective function, which is a summation of variables in these matrices. There are also some linear constraints for this model. I get the error "Not enough input arguments" on this optimization model:
% [S,V,B,fval]=fmincon('objfun',x0,[],[],[],[],[-Inf(N,1),-Inf(N,1),zeros(N,1)],[Inf(N,1),Inf(N,1),ones(N,1)],'constraint');
I guess the way I define the input variables is not right.
I've attached the main code, the objective function and the constraints. I would be appreciated if you could take a look and help me.
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Choose a Solver en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!