# Contraction

## Basic contraction (c0)

We combine four individuals, $x_{best}$, $x_{worst2}$, $w_{worst}$, and the current $x_i$ that has to be moved.

The idea is that the gravity centre of the three first points may be interesting. However, this move is not applied on all dimensions, but only on some of them, according to the probability estimated at the end of the selection phase. So, finally, the formulae to define the new point $x_c$ are, for each dimension $d$:
if ($rand(0,1)<p)$
$x_{c,d}=(x_{best,d}+w_{worst2,d}+w_{worst,d})/3$
else
$x_{c,d}=x_{i,d}$

If $x_{c}$ is better than $x_i$, decrease the population cost $$C\leftarrow C-f(x_i)+f(x_c)$$

If $x_{c}$ is better than the best ever found (i.e. $Best$), set $Best=x_{c}$.