|
OPTK
0.1.2
Toolkit for global optimisation algorithms
|
#include <synthetic.hpp>
Public Member Functions | |
| levy3 (int dims) | |
| 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 |
The Levy 03 function has the following formula:
\[ f(\mathbf{x}) = \sin^2(\pi w_1) + \sum^{d-1}_{i=1}(w_i-1)^2\left( 1 + 10\sin^2(\pi w_i+1)\right) + (w_d - 1)^2 \left(1 + \sin^2(2\pi w_d)\right), \]
where
\[ w_i = 1 + \frac{x_i - 1}{4}, \forall i \in \{1, \ldots, d\}. \]
subject to \(-10 \le x_i \le 10\). The global minimum is located at \(\mathbf{x}^* = (1, \ldots, 1)\) with a value of \(f(\mathbf{x}^* = 0\).
|
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