call Mutate ( selected, seg, type<, parameter1, parameter2, …> );
The Mutate call executes a genetic mutation operator from within a user subroutine. The inputs to the subroutine are as follows:
selected |
is an array that specifies the solution to be mutated. |
seg |
is the desired segment of the solution to which the mutation should be applied. |
type |
is the type of mutation operator to apply, which also determines the number and type of parameters expected. |
parameter1-n |
are optional parameters applicable to some operators. |
The accepted values for type and the corresponding parameters are summarized in Table 4.2.
Table 4.2: Mutation Operator Types
The parameters are as follows:
delta |
is a vector of delta values for each component of the solution, used only for the Delta mutation operator. |
n |
specifies the number of solution elements that should be mutated for the Delta operator, and the number of swaps that should be made for the Swap operator. |
np |
specifies the number of solution elements that should be mutated, if np is integer; specifies the mutation probability for each solution element if . |
The Mutate call should be made only from within a user mutation subroutine. The precise action of these mutation operators is described in the section Mutation Operators.