Quantcast
Viewing all articles
Browse latest Browse all 130

Re: MaxFunEvals message question

So, is he recommended to trust the output?

"John D'Errico" <woodchips@rochester.rr.com> wrote in message <f72d6p$irr$1@fred.mathworks.com>...
> > Exiting: Maximum number of function evaluations has been exceeded
> > - increase MaxFunEvals option.
> > Current function value: 0.000000
> >
> > -- I know this is going to sound esoteric, but bear with me. I'd just
> > like someone to point me in the right direction.
> >
> > I'm running a script that loops through several directories and feeds
> > filenames as input to a function. This function calls another which does
> > some image processing to gather data from each image set, and one which
> > does some simple (fminsearch) curve fitting with this derived data.
> >
> > Can I trust the results returned by my code if I get this message?
>
> Before you "trust" anything that you don't understand,
> I'd suggest that you learn why this is happening.
>
> 1. Find an occurrence where fminsearch does this.
>
> 2. Look at the curve fit. Look at the final parameters.
> Consider the starting values chosen for this data set.
>
> Is fminsearch pushing the fit into some strange part
> of the parameter space that has no meaning?
>
> Are your requirements for the fit just too extreme?
> I.e., you have set a tolerance so tightly that it needs
> too many iterations to converge? Are your starting
> values just terrible?
>
> Do you have too many parameters for fminsearch
> to optimize reasonably? I'd never suggest use of
> fminsearch for large problems or ones with tight
> rolerances. If you are doing many optimizations,
> a better optimizer is well worth the investment.
> If I will only do a few optimizations, I might use
> fminsearch to solve problems with up to 5 or 6
> parameters, but fminsearch tends to be happier in
> only 2 or 3 dimensions.
>
> Finally, consider use of a partitioned fitting tool, such
> as fminspleas, for the curve fitting. This will do the
> curve fitting more robustly and often more accurately
> than fminsearch alone.
>
> http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=10093&objectType=FILE
>
> HTH,
> John

Viewing all articles
Browse latest Browse all 130

Trending Articles