Chapter 5One-parameter minimization problems
Problems that involve minimizing a function of a single parameter are less common in themselves than as subproblems within other optimization problems. This is because many optimization methods generate a search direction and then need to find the “best” step to take along that direction. There are, however, problems that require a single parameter to be optimized, and it is important that we have suitable tools to solve these.
5.1 The optimize()
function
R has a built-in function to find the minimum of a function of a single parameter in a given interval . This is optimize()
. It requires a function or expression to be supplied, along with an interval specified as a two-element vector, as in the following example. The method is based on the work by Brent (1973).
A well-known function in molecular dynamics is the Lennard–Jones 6–12 potential (http://en.wikipedia.org/wiki/Lennard-Jones_potential). Here we have chosen a particular form as the function is extremely sensitive to its parameters ep
and sig
. Moreover, the limits for the curve()
have been chosen so that the graph is usable because the function has extreme scale changes (Figure ...
Get Nonlinear Parameter Optimization Using R Tools now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.