jakobbossek / smoof

Single- and Multi-Objective Optimization Test Functions
http://jakobbossek.github.io/smoof/
Other
36 stars 16 forks source link

Conversion doesn´t flip Optima #105

Closed surmann closed 7 years ago

surmann commented 7 years ago

When I change the optimisation direction via convertToMinimization the value of the optima should change, too. It is difficult to get the information from the output of getGlobalOptimum that I have to multiply $value by -1.

packageVersion("smoof")

[1] ‘1.5’

obj.fun = makeAlpine02Function(2) getGlobalOptimum(obj.fun)

$value

[1] 7.884864

$is.minimum

[1] FALSE

obj.fun = convertToMinimization(obj.fun) getGlobalOptimum(obj.fun)

$value

[1] 7.884864

$is.minimum

[1] TRUE

What do you think?

jakobbossek commented 7 years ago

I think you found an embarrassing bug sir! Thanks for reporting!

jakobbossek commented 7 years ago

Fixed.