N-D Test Functions O¶Odd Square objective function.
This class defines the Odd Square global optimization problem. This is a multimodal minimization problem defined as follows:

Where, in this exercise:
![\begin{cases}
d = n \cdot \smash{\displaystyle\max_{1 \leq i \leq n}} \left[ (x_i - b_i)^2 \right ] \\
\\
h = \sum_{i=1}^{n} (x_i - b_i)^2 \\
\end{cases}](_images/math/1877d08f165f97bffb2e58ea9152331a77b2cdd2.png)
And ![b = [1, 1.3, 0.8, -0.4, -1.3, 1.6, -0.2, -0.6, 0.5, 1.4, 1, 1.3, 0.8, -0.4, -1.3, 1.6, -0.2, -0.6, 0.5, 1.4]](_images/math/4282e5578975b3b42b4f533b6ad4c2488aef534b.png)
Here,
represents the number of dimensions and
for
and
.
Two-dimensional OddSquare function
Global optimum:
for 
Gavana, A. Global Optimization Benchmarks and AMPGO
Todo
The best solution changes on dimensionality
Osborne objective function.