A multimodal test function with penalty terms that create a complex
search landscape. Uses the Ufun helper function.
F12(x)Numeric scalar representing the function value.
Formula: $$f(x) = \frac{\pi}{n}\left\{10\sin^2(\pi y_1) + \sum_{i=1}^{n-1}(y_i-1)^2(1 + 10 \sin^2(\pi y_{i+1})) + (y_n-1)^2\right\} + \sum_{i=1}^{n}u(x_i,10,100,4)$$
where \(y_i = 1 + (x_i + 1)/4\) and \(u(x,a,k,m)\) is a penalty function.
Global minimum: \(f(-1, -1, ..., -1) = 0\)
Characteristics:
Type: Multimodal
Separable: No
Differentiable: Yes (in the interior)
Penalized: Yes (boundary penalty)
Default bounds: \([-50, 50]^n\)
Default dimensions: 50
The penalty term \(u(x,a,k,m)\) adds a cost when variables exceed the threshold \(a\), helping to constrain solutions to a feasible region.
test-functions for an overview of all test functions,
get_function_details to retrieve function parameters,
Ufun for the penalty function.