MATLAB: Can GA always find a smaller objective than SQP

gaGlobal Optimization ToolboxMATLABoptimizationsqp

Hi everyone,
These days I am using GA and SQP for optimization.
It is very strange that the result from SQP is smaller than GA, i.e., better results are from SQP.
I think my codes are all right, but I am not sure about the results.
It is said SQP can only find a local optimal result while GA can search for the global one.
But why this happens ?
Any help is greatly appreciated!
Cheers

Best Answer

The SQP method starts from a specified point and moves (almost) along local gradient to smaller function values. If the start point is inside a valley, which does not contain the global minimum there is only a tiny chance that the surrounding mountains are exceeded by accident.
GA uses a set of start points and the crossing over exceeds the search area during the processing. Therefore there is a larger chance to find a global optimum.