public class INichedMutation extends java.lang.Object implements IntegerMutation
This class applies the niched mutation. So, the changes made in the classifier cannot result in another classifier that does not match with the environment (we can change a don't care for the value of the parent, or a value for a don't care value, but, for example, we would never change a '0' for a '1').
Constructor and Description |
---|
INichedMutation() |
Modifier and Type | Method and Description |
---|---|
int |
mutateLower(int lowerValue,
int upperValue,
int currentState,
int scale)
Mutates the lower real value.
|
int |
mutateUpper(int lowerValue,
int upperValue,
int currentState,
int scale)
Mutates the upper real value.
|
public int mutateLower(int lowerValue, int upperValue, int currentState, int scale)
Mutates the lower real value.
mutateLower
in interface IntegerMutation
lowerValue
- is the current lower value of this classifier positionupperValue
- is the current upper value of this classifier position.currentState
- is the current State of the environment for this
allele of the classifier.scale
- values scale.public int mutateUpper(int lowerValue, int upperValue, int currentState, int scale)
Mutates the upper real value.
mutateUpper
in interface IntegerMutation
lowerValue
- is the current lower value of this classifier positionupperValue
- is the current upper value of this classifier position.currentState
- is the current State of the environment for this
allele of the classifier.scale
- values scale.