Evolutionary search to minimize a function: For each point in the current
generation, n random points are introduced and the n best
results of each generation (and its parents) are used to form the next
generation.
The scale shrinks the generation of new points as the algorithm proceeds.
It is possible for some children to lie outside the given rectangle, and
therefore the final result may lie outside the unit rectangle well.
(TO DO: Make this an option.)
References
Stan Wagon. ``Think Globally, Act Locally". Chapter 4 In: F. Bornemann,
D. Laurie, S. Wagon, and J. Waldvogel (Eds.). The SIAM 100-Digit Challenge.
Society of Industrial and Applied Mathematics, 2004.
simpleEA(fnTrefethen, lower=c(-1,-1), upper=c(1,1), log=FALSE)
# $par# [1] -0.02440310 0.21061243 # this is the true global optimum!# $val# [1] -3.306869