Optimization ended: relative change in the objective value
over the last OPTIONS.MaxStallIterations iterations is less than OPTIONS.FunctionTolerance.

x = 1×2
-31.9521 -16.0176

fval = 5.9288

exitflag = 1

Is the solution x the global optimum? It is unclear at this point. Looking at the function plot shows that the function has local minima for components in the range [-50,50]. So restricting the range of the variables to [-50,50] helps the solver locate a global minimum.

Optimization ended: relative change in the objective value
over the last OPTIONS.MaxStallIterations iterations is less than OPTIONS.FunctionTolerance.

x = 1×2
-31.9781 -31.9784

fval = 0.9980

exitflag = 1

This looks even more promising. But is this answer a global solution, and how accurate is it? Rerun the solver with a hybrid function. particleswarm calls the hybrid function after particleswarm finishes its iterations.