Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
Genetic::OpCrossover(3User Contributed Perl DocumentatiGenetic::OpCrossover(3)

NAME
       AI::Genetic::OpCrossover	- A class that implements various crossover
       operators.

SYNOPSIS
       See AI::Genetic.

DESCRIPTION
       This package implements a few crossover mechanisms that can be used in
       user-defined strategies.	The methods in this class are to be called as
       static class methods, rather than instance methods, which means you
       must call them as such:

	 AI::Genetic::OpCrossover::MethodName(arguments)

CROSSOVER OPERATORS AND	THEIR METHODS
       The following crossover operators are defined:

       Single Point
	   In single point crossover, a	point is selected along	the
	   choromosomes	of both	parents.  The chromosomes are then split at
	   that	point, and the head of one parent chromosome is	joined with
	   the tail of the other and vice versa, creating two child
	   chromosomes.	 The following method is defined:

	   vectorSinglePoint(Xprob, parent1, parent2)
	       The first argument is the crossover rate. The second and	third
	       arguments are anonymous lists that define the genes of the
	       parents (not AI::Genetic::Individual objects, but the return
	       value of	the genes() method in scalar context).	If mating
	       occurs, two anonymous lists of genes are	returned corresponding
	       to the two new children.	If no mating occurs, 0 is returned.

       Two Point
	   In two point	crossover, two points are selected along the
	   choromosomes	of both	parents.  The chromosomes are then cut at
	   those points, and the middle	parts are swapped, creating two	child
	   chromosomes.	The following method is	defined:

	   vectorTwoPoint(Xprob, parent1, parent2)
	       The first argument is the crossover rate. The second and	third
	       arguments are anonymous lists that define the genes of the
	       parents (not AI::Genetic::Individual objects, but the return
	       value of	the genes() method in scalar context).	If mating
	       occurs, two anonymous lists of genes are	returned corresponding
	       to the two new children.	If no mating occurs, 0 is returned.

       Uniform
	   In uniform crossover, two child chromosomes are created by looking
	   at each gene	in both	parents, and randomly selecting	which one to
	   go with each	child.	The following method is	defined:

	   vectorUniform(Xprob,	parent1, parent2)
	       The first argument is the crossover rate. The second and	third
	       arguments are anonymous lists that define the genes of the
	       parents (not AI::Genetic::Individual objects, but the return
	       value of	the genes() method in scalar context).	If mating
	       occurs, two anonymous lists of genes are	returned corresponding
	       to the two new children.	If no mating occurs, 0 is returned.

AUTHOR
       Written by Ala Qumsieh aqumsieh@cpan.org.

COPYRIGHTS
       (c) 2003,2004 Ala Qumsieh. All rights reserved.	This module is
       distributed under the same terms	as Perl	itself.

perl v5.24.1			  2005-03-04	       Genetic::OpCrossover(3)

NAME | SYNOPSIS | DESCRIPTION | CROSSOVER OPERATORS AND THEIR METHODS | AUTHOR | COPYRIGHTS

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=AI::Genetic::OpCrossover&sektion=3&manpath=FreeBSD+12.1-RELEASE+and+Ports>

home | help