On Jan 21, 2017, at 10:03 PM, Enzo Fabbiani <[log in to unmask]> wrote:
> The specification of this method is
> public void defaultCrossover(EvolutionState state, int thread, VectorIndividual ind)
>
> But, woudln't be better if it was:
> public void defaultCrossover(EvolutionState state, int thread, VectorIndividual ind1, VectorIndividual ind2)
>
> Because, the crossover is among two individuals of the population.
Yes, but one of those individuals is having its method called. That is:
ind1.defaultCrossover(state, thread, ind2)
This crosses ind1 over with another individual ind2 to produce up to two children.
Sean
|