This mutation operator is designed to introduce a partial grid structure
into to point of a given Euclidean problem instance. This is achieved by generating
a random box of width and height \(w, h \in [box.min, box.max]\) and placing it
at random within the boundaries \([0, 1]^2\). All points \(Q \subseteq P\) inside
the box are affected by the mutation. Point set \(Q\) is replaced by a quadratic
grid of points \(Q'\) with \(g = \lfloor \sqrt{|Q|} \rfloor\) rows and columns respectively.
Note that if \(g^2 < |Q|\) we ignore \(|Q| - g\) random points of \(Q\), i.e., these
points are not touched.
Subsequent, optional steps involve rotation and noise addition: with probability \(p.rot\)
\(Q'\) is rotated by a random angle \(alpha \in [0, \pi/2]\) and with probability
p.jitter
all points in \(Q\) are perturbed by additive Gaussian noise with
mean \((0,0)\) and standard deviation jitter.sd
in each dimension.
doGridMutation(coords, box.min = 0.1, box.max = 0.3, p.rot = 0, p.jitter = 0, jitter.sd = 0, ...)
coords | [ |
---|---|
box.min | [ |
box.max | [ |
p.rot | [ |
p.jitter | [ |
jitter.sd | [ |
... | [any] |
[matrix
] Mutated coordinates.