Hi, I am trying to use ALGLIB to replciate the QUADPROG functionality of MATLAB quadprog Quadratic programming. X = quadprog(H,f,A,b) attempts to solve the quadratic programming problem: min 0.5*x'*H*x + f'*x subject to: A*x <= b x I tried to use DENSE AUL from ALGLIB solver to solve the same, but my results are way different. Can someone please guide me as to where I might be going wrong? I have attached following with the thread. Matrix_A.txt The Quadratic Cost Function Data Matrix_Constraints.txt The Constraints Matrix main.cpp My code for The Same.
Matlab Output 0.63322,0.6999,0.76339,0.81933,0.86562,0.89764,0.91573,0.92111,0.91655,0.90413,0.88902,0.86974,0.85041,0.66259,0.73242,0.79896,0.85804,0.90604,0.9383,0.95464,0.95837,0.94988,0.93513,0.9144,0.89375,0.87154,0.68458,0.75677,0.82455,0.88545,0.9338,0.96761,0.98107,0.98419,0.97207,0.95564,0.93261,0.91005,0.88649,0.69814,0.76992,0.83835,0.89921,0.94662,0.97896,0.99621,1,0.9857,0.96377,0.94314,0.92005,0.89584,0.70335,0.773,0.83931,0.89679,0.94175,0.97553,0.98846,0.99143,0.98253,0.96533,0.94487,0.922,0.89855,0.701,0.76644,0.82871,0.88434,0.92761,0.95953,0.97384,0.97731,0.96962,0.95694,0.93693,0.91856,0.89525,0.69119,0.75288,0.81022,0.86168,0.90172,0.93079,0.94828,0.95335,0.95119,0.9394,0.92465,0.9069,0.88789,0.67827,0.73418,0.78699,0.83303,0.87095,0.90009,0.91722,0.92581,0.92378,0.91782,0.90519,0.89119,0.87501,0.6606,0.71298,0.76059,0.80342,0.83743,0.86469,0.88292,0.89307,0.89471,0.89205,0.88381,0.87271,0.86026,-5.0308e-05,-0.00011987,-0.0013769
ALGLIB Output
[-0.326426,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,-0.002436,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000505,0.003153,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000125,0.267527,1.000000,0.003153,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.018603,0.071664,0.000505,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,-0.058014,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,0.000098,-0.000009,-0.000006,0.000101]
|