FindMinimum Also Maximizes

In[1]:= $Version

Out[1]= "10.0 for Microsoft Windows (64-bit) (September 9, 2014)"

In[2]:= FindMinimum[{x + y, x^2 + y^2 == 1}, {{x, 1}, {y, 1}}]

Out[2]= {1.41421, {x -> 0.707107, y -> 0.707107}}

I suppose this happens because the the starting point, maximum and minimum are on a straight line
with the maximum nearer to the starting point.

In[7]:= FindMinimum[{x + y, x^2 + y^2 == 1}, {{x, 1}, {y, 2}}]

Out[7]= {-1.41421, {x -> -0.707107, y -> -0.707107}}

I actually find this pretty bizarre. It’s not a minimum in any sense of the word… And FindMinimum should find a (possibly local) minimum. If things were flat then perhaps something non-mimimum-like might be found, but hopefully a warning message would be generated. Seems bugish…

By comparing different values, you can see that it is using Method → “InteriorPoint”.

I’m not sure I know enough to say whether or not an ideal implementation of this algorithm would exhiibit this kinda quirk. If you would like to, you can send an email to support@wolfram.com and they can file a report. An appropiate developer will take a look at it and decide if anything needs to be fixed.

Since there’s only one build in method for this kind of optimization problem, it is best to run run the optimization with several starting values and check where they converge.

I have report this problem in the past. However, an augmented lagrangian solver I wrote has the same problem, so it may be unavoidable.

1 Like

An inappropriate developer once looked at it and tinkered with that code. With the predictable outcome: one can break things much more easily than fix them. A big aspect of this problematic example is that one reaches a stationary point which is of the wrong type (max instead of min), and for which direction of improvement is orthogonal to the constraint set.

2 Likes

The same problem occurs if a starting point is not given:

In[2]:= FindMinimum[{x + y, x^2 + y^2 == 1}, {x, y}]

Out[2]= {1.41421, {x -> 0.707107, y -> 0.707107}}

The default starting value is 1.

Maybe FindMinimum could have an option that tests whether the point is actually a minimum