mlpack / ensmallen

A header-only C++ library for numerical optimization --
http://ensmallen.org
Other
742 stars 120 forks source link

Multi-objective functions both MOEA/D-DE and NSGA2 - Examples using SchafferFunctionN1 #353

Closed scudelari closed 1 year ago

scudelari commented 1 year ago

Problem location

https://ensmallen.org/docs.html#moead-de https://ensmallen.org/docs.html#nsga2

Description of problem

In the examples of both algorithms, the function SchafferFunctionN1 is used, but the lower and upper bounds have 2 variables instead of only one. arma::vec lowerBound("-1000 -1000"); arma::vec upperBound("1000 1000");

The SchafferFunctionN1 only has one variable. /**

This causes an error when trying to run the test code.

rcurtin commented 1 year ago

Thanks for the report! I opened #354 to handle the problem. :+1: