In the crossover function, the split point is chosen in the range of the offspring size, instead of the solution size.
An out-of-range split point is silently ignored by the range selection: it selects all genes from parent1, and none from parent2. However, the error can be demonstrated by throwing an exception if the split point is out of range.
In the crossover function, the split point is chosen in the range of the offspring size, instead of the solution size.
An out-of-range split point is silently ignored by the range selection: it selects all genes from parent1, and none from parent2. However, the error can be demonstrated by throwing an exception if the split point is out of range.