Skip to content

Help in Optimization of a function

2 messages · John C Nash, Peter Dalgaard

#
This looks like a homework trap set up to catch those trying to use facilities like Rhelp.

f = exp(x^2-y+z^(-1))= exp(x^2) * exp(1/z)/exp(y)

To maximize clearly needs biggest x (37), smallest y (2) and a z that
makes exp(1/z) big -- 0. Except that you'll get Inf etc.

Actually, several of the optimization tools in R don't do too badly on this (about half of
the routines in optplus (the R-forge version of optimx) get reasobable answers, but there
are some oddities depending on starting values.

JN
On 07/08/2012 06:00 AM, r-help-request at r-project.org wrote:
#
On Jul 8, 2012, at 16:52 , John C Nash wrote:

            
As the function is unbounded in z, you can't really fault optimizers for not optimizing over x and y, can you? Or do you see other kinds of oddities?

-pd