Algorithm::Evolutionary::Op::QuadXOver - N-point crossover operator that changes operands
<op name='QuadXOver' type='binary' rate='1'>
<param name='numPoints' value='2' /> #Max is 2, anyways
my $ref3 = XMLin($xmlStr3);
my $op3 = Algorithm::Evolutionary::Op::Base->fromXML( $ref3 );
print $op3->asXML(), "\n";
my $indi = new Algorithm::Evolutionary::Individual::BitString 10;
my $indi2 = $indi->clone();
my $indi3 = $indi->clone(); #Operands are modified, so better to clone them
$op3->apply( $indi2, $indi3 );
my $op4 = new Algorithm::Evolutionary::Op::QuadXOver 1; #QuadXOver with 1 crossover points
Crossover operator for a GA, takes args by reference and issues two children from two parents
Same as Algorithm::Evolutionary::Op::Crossover, but changes parents, does not return anything; that is, $parent_1 and $parent_2 interchange genetic material.
This file is released under the GPL. See the LICENSE file included in this distribution,
or go to http://www.fsf.org/licenses/gpl.txt
CVS Info: $Date: 2010/12/08 17:34:22 $
$Header: /media/Backup/Repos/opeal/opeal/Algorithm-Evolutionary/lib/Algorithm/Evolutionary/Op/QuadXOver.pm,v 3.4 2010/12/08 17:34:22 jmerelo Exp $
$Author: jmerelo $
$Revision: 3.4 $
To install Algorithm::Evolutionary, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell
For more information on module installation, please visit the detailed CPAN module installation guide.