Mutation of binary sequences for use in the genetic algorithm
Usage
mutate_binary_sequence(s, p = 0.1)
Value
A mutated binary sequence
Arguments
s
Sequence consisting of 0 and 1
p
Mutation probability. Defaults to 0.1
Author
Cesar Asensio
Details
This routine takes a binary sequence and it flips ("mutates") each
bit with a fixed probability. In the genetic algorithm
context, this operation randomly explores regions of
configuration space which are far away from the starting
point, thus trying to avoid local optima. The fitting
function values of mutated individuals are generically very
poor, and this behavior is to be expected. Thus, mutation is
not an optimization procedure per se.