|
OPTK
0.1.2
Toolkit for global optimisation algorithms
|
#include <synthetic.hpp>
Public Member Functions | |
| double | evaluate (inst::set x) override |
Public Member Functions inherited from syn::synthetic | |
| synthetic (const std::string &n, u_int dims, double lb, double ub, double opt) | |
| synthetic (const std::string &n, u_int dims, double opt) | |
| ~synthetic () | |
| sspace::sspace_t * | get_search_space () |
| void | set_properties (std::vector< properties > p) |
| std::vector< properties > | get_properties () |
| inst::set | get_opt_param () |
| double | get_opt () |
| void | update_opt (double opt) |
| u_int | get_dims () |
| void | validate_param_set (inst::set x) |
Public Member Functions inherited from optk::benchmark | |
| benchmark (const std::string &name) | |
| std::string | get_name () |
Additional Inherited Members | |
Protected Member Functions inherited from syn::synthetic | |
| void | set_opt_param (inst::set op) |
Protected Attributes inherited from syn::synthetic | |
| u_int | m_dims |
| double | m_lb |
| double | m_ub |
| double | m_opt |
| std::vector< properties > | m_properties |
| inst::set | opt_params |
| sspace::sspace_t | m_sspace |
Protected Attributes inherited from optk::benchmark | |
| std::string | m_name |
Michalewicz's function (12D) has the following formula
\[ f(\mathbf{x}) = - \sum^{12}_{i=1}\sin(x_i)\left( \sin\left(\frac{ix_i^2}{\pi}\right) \right)^{20m} \]
which is subject to \(0 \le x_1 \le \pi\). In this 12 dimensional version, the global minimum is located at \(\mathbf{x}^* = ( 2.202905513296628, 1.570796322320509, 1.284991564577549, 1.923058467505610, 1.720469766517768, 1.570796319218113, 1.454413962081172, 1.756086513575824, 1.655717409323190, 1.570796319387859, 1.497728796097675, 1.923739461688219,)\), with value \(f(\mathbf{x}^*) = -11.595826967415329\).
|
overridevirtual |
Evaluate the benchmark (i.e. calculate the value of the objective fuinction) on the provided values.
| x | A vector of double-precision values to evaluate the benchmark at. |
Implements optk::benchmark.
1.8.13