Failure in initial user-supplied objective function evaluation. FMINCON cannot continue

1 view (last 30 days)
I am trying to use FMINCON to minimize an objective function with 10 unknowns. The code works fine on my own laptop (mac) and workstation (windows 7) (MATLAB 2013 both) but when I try to run the same code on the server with Linux with Matlab R2012a, the code fails. The error I see is "Failure in initial user-supplied objective function evaluation. FMINCON cannot continue.
Do you know what can be the causes of such behaviour. It is a bit weird that the same code works on 2 machines but not on the 3rd one.
Thanks a lot in advance

Answers (1)

Sean de Wolski
Sean de Wolski on 16 Oct 2013
Run the following at the command line:
dbstop if error
And then run fmincon on the offending machine. This will stop on the offending line and you can inspect the values to see what is going on.
My guess is that the offending machine is either missing a required function or has a necessary function shadowed by another function that is not what you expect.

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!