[Date Index]
[Thread Index]
[Author Index]
FindMinimum and Gradient
*To*: mathgroup at smc.vnet.net
*Subject*: [mg24099] FindMinimum and Gradient
*From*: Grischa Stegemann <Stegemann at Physik.TU-Berlin.DE>
*Date*: Tue, 27 Jun 2000 00:51:54 -0400 (EDT)
*Sender*: owner-wri-mathgroup at wolfram.com
Dear group
I'm using Mathematica 3.0.2.0 with Solaris.
In trying to minimize relative entropy, i.e. a positive function like
S[a_, b_, n_] := -Sum[h[k]*Log[p[k, a, b, n]], {k, -n, n}]
/; a > 0 && b > 0
S[a_, b_, n_] := -1 /; a <= 0 || b <= 0
with FindMinimum I just encountered two general problems.
I'm only interested in a,b>0 with a fixed n. Since Mathematica is not able to
compute the gradient symbolically I specified it with the Gradient option. I
defined the gradient as 0 if not a,b>0. Thus if FindMinimum gives -1 for the
minimum i know, that the algorithm went out of the range of interest. But this
never happened.
Roughly I tried this with several starting points {as,bs}:
FindMinimum[S[a,b,n0],{a,as},{b,bs},
Gradient->{daS[a,b,n0],dbS[a,b,n0]},
MaxIterations->1000];
First of all, it works fine in many cases (depending on n0 and h). But in the
other cases I always get
FindMinimum::"fmlim": "The minimum could not be bracketed in 1000 iterations.
I tried to play around with Accuracy- and PrecisionGoal but even setting them to
1 doesn't make things better.
So, what exactly does this message mean? I cannot find any explanation of this
message in the documentation. Where got FindMinimum lost?
The second problem is that due to the first one I wanted to play with the Method
option.
But if I try Method->Newton or Method->QuasiNewton Mathematica complains
FindMinimum::"fmgs":
Could not symbolically find the gradient of S[a, b, n]. Try
giving two starting values for each variable.
This is inexplicable since I'm using Gradient->{daS[a,b,n0],dbS[a,b,n0]}, isn't
it?
Any suggestions about this? Thanks a lot in advance.
--
Grischa Stegemann
----------------------------------------------------------------------
Grischa Stegemann Technische Universitaet Berlin
email: Stegemann at physik.tu-berlin.de
*** We are here on Earth to do good for others.
*** What the others are here for, I do not know. (W.H. Auden)
Prev by Date:
**Fw: How to operate on strictly numerical functions ?**
Next by Date:
**Re: Re: RE:Working Precision**
Previous by thread:
**RE: How to operate on strictly numerical functions ?**
Next by thread:
**Re: FindMinimum and Gradient**
| |