Poster of Linux kernelThe best gift for a Linux geek
PGAMutate

PGAMutate

Section: PGAPack (3) Updated: 05/01/95
Local index Up
 

NAME

PGAMutate - This routine performs mutation on a string.  

DESCRIPTION

The type of mutation depends on the data type. Refer to the user guide for data-specific examples.  

INPUT PARAMETERS

ctx
- context variable
p
- index of string to mutate
pop
- symbolic constant of the population containing p
 

OUTPUT PARAMETERS

none

 

SYNOPSIS

#include "pgapack.h"
int  PGAMutate(ctx, p, pop)
PGAContext *ctx
int p
int pop
 

LOCATION

mutation.c  

EXAMPLE

Example:
Mutate the best string in the population, until 10 or more mutations
have occured.

PGAContext *ctx;
int p, count = 0;
:
p = PGAGetBestIndex(ctx, PGA_NEWPOP);
while (count < 10) {
count += PGAMutate(ctx, p, PGA_NEWPOP);
}


 

Index

NAME
DESCRIPTION
INPUT PARAMETERS
OUTPUT PARAMETERS
SYNOPSIS
LOCATION
EXAMPLE

This document was created by man2html, using the manual pages.
Time: 21:52:25 GMT, April 16, 2011