Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: correct objective function for fmincon
Date: Sat, 22 Nov 2008 23:00:21 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 26
Message-ID: <gga2u5$gfj$1@fred.mathworks.com>
References: <gg4mbo$rpr$1@fred.mathworks.com> <gg78nu$k0$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1227394821 16883 172.30.248.37 (22 Nov 2008 23:00:21 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Sat, 22 Nov 2008 23:00:21 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1179973
Xref: news.mathworks.com comp.soft-sys.matlab:502554


In my case the variables are the geometry parameters of the RF device. After the tests it turned out that by default  the gradient is calculated by varying the variables in the range 1e-6 or less. The device characteristics are not sensitive for such a small change in geometry.

I have changed the option "DiffMinChange" of the fmincon and I am able to work with my objective function now.
-
Dmytro

"loic paccard" <loic.paccard@ecam.fr> wrote in message <gg78nu$k0$1@fred.mathworks.com>...
> "Dmytro Vasylenko" <dmytre@mathworks.com> wrote in message <gg4mbo$rpr$1@fred.mathworks.com>...
> > After the first iteration in fmincon I receive a gradient=0 and the answer:
> >  "Optimization terminated: first-order optimality measure less
> >  than options.TolFun and maximum constraint violation is less
> >  than options.TolCon.
> > No active inequalities."
> > 
> > My objective function is not Matlab code , the Matlab code is simply calling an external executable and feeds the results to the optimizer. I knew already an optimum solution and try to set the starting guess near this value. But it doesn't help.
> > 
> 
> 
> Hi Dmytro,
> 
> I am pretty interesting in how you 'feeds" results to the optimizer.
> I do not know how to use fmincon with discrete values because I have no model and analytical expression inm ycase.
> Are you in the same situation?
> Could you explain ,me how you deal with fmincon without using an analytical expression?
> 
> Loic