# CPLEX claims to have solved QP minimisation but solution is not optimal

I am trying to solve a small QP problem in CPLEX. The problem has several linear constraints. The optimiser runs and finds a solution which satisfies these constraints and CPLEX returns a success code.

However the value of the objective function given by this solution is greater than that for the solution if I just supply a vector of 1's (this is my initial state which I trying to improve upon).

So CPLEX is failing to revert to the initial solution even if that is better than the given solution. How can this be possible ? I have tested this in Excel using Excel solver and it does something similar so CPLEX is not the problem.

I had always assumed that QP problems possessed a unique solution. I believe that the QP problem has a positive semi-definite matrix. In fact I know that.

What am I doing incorrectly ? Here is the mps file:

If the solvers are using interior-point methods, then they might completely ignore your initial solution.

You may try also MOSEK, which is free for academics or in trial.

If you could provide the mps file, I can try it out.

UPDATE:

running MOSEK I got these results

https://gist.github.com/andreacassioli/11425618

but there was some error in the mps file, so I post it in the github.

• I have posted the mps file. Please let me have your thoughts.
– Dom
Apr 30 '14 at 7:51
• Thanks. I actually obtained the same solution as you in CPLEX. The issue here is that the value of the objective function is HIGHER with this solution than the initial state {1,1,1,1}. In this case I would like the solution to be the initial state.
– Dom
Apr 30 '14 at 15:48
• I have just realised there is no objective function in the model..is it the right mps? If it is so, then no surprise the solver will give a random feasible solution... May 1 '14 at 6:12
• Yes. Your are correct. I found that very late yesterday. My problem was that my code for setting the objective function in CPLEX was for some reason not being used nor was it being complained about by CPLEX. In the end I had to use a special coefficient setting function. I now have a different problem in that my matrix is not strictly PSD according to CPLEX.
– Dom
May 1 '14 at 15:36