[SciPy-user] Minimize a bounded convex function

Geoffrey Zhu zyzhu2000@gmail....
Fri Oct 19 11:09:34 CDT 2007


On 10/18/07, Anne Archibald <peridot.faceted@gmail.com> wrote:
> On 18/10/2007, Geoffrey Zhu <zyzhu2000@gmail.com> wrote:
>
> > I am trying to minimize a convex function f(x) that is not defined
> > when x<=0 or when x>=1.5. I am trying to use scipy.optimize.golden(),
> > but when the minimal point is very close to zero, golden() will call
> > my target function on the undefined region. Is there any way to ensure
> > that the optimizer will only look for answers within the domain?
>
> There's one open interval that many optimizers can handle, namely the
> real line. You can try transforming your x coordinate so that (for
> example) x = (tanh(w)+1)*0.75 and then minimizing as a function of w.
> This probably doesn't preserve convexity (though it should not
> introduce any local minima), but it means that you can use unbounded
> minimization and avoid the endpoints.
>
> Anne
> _______________________________________________
> SciPy-user mailing list
> SciPy-user@scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-user
>

Thanks a lot, Anne. This should work. Fortunately golden() does not
require convexity.


More information about the SciPy-user mailing list