'quadprog' getting empty output , how to rectify?
    4 views (last 30 days)
  
       Show older comments
    
aaa=[0.0014 0 0 0;0 0.0006 0 0;0 0 0.0040 0;0 0 0 0.0016];
>> bbb=[16.1900 17.2600 16.6000 27.7400];
>> ccc=[1 1 1 1];
>> ddd=1000.6;
>> eee=[150.000 238.0534 20.000 25.000];
>> fff=[455.000 283.0534 130.000 85.000];
>> ggg=[302.500 260.5534  75.000 55.000];
>> options=optimset('LargeScale','off','MaxPCGIter',50,'PrecondBandWidth',inf);
>> [sss,ooo]=quadprog(aaa,bbb,[],[],ccc,ddd,eee,fff,ggg,options);
i getting sss=[] and ooo=[] why?
0 Comments
Answers (1)
  Sivsankar
      
 on 26 Nov 2024
        When I ran your script, got a warning that the problem was infeasible. It suggests that while executing the ‘quadprog’ function, during the ‘presolve’, the solver found that the problem has an inconsistent formulation. Inconsistent means not all constraints can be satisfied at a single point x.
In other terms, ‘quadprog’ found the constraints to be inconsistent within the constraint tolerance. So, make sure that your variables abide by the constraint tolerances. You can view the constraint tolerances from here for presolve and make modifications to your variables accordingly:
Thank you!
0 Comments
See Also
Categories
				Find more on Particle Swarm in Help Center and File Exchange
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
