Function PGASetDEVariant

Function Documentation

void PGASetDEVariant(PGAContext *ctx, int variant)

Set the variant used for Differential Evolution.

Description

Only used if the mutation type is Differential Evolution PGA_MUTATION_DE. The possible variants are PGA_DE_VARIANT_RAND, PGA_DE_VARIANT_BEST, and PGA_DE_VARIANT_EITHER_OR. See Constants for Differential Evolution Variants for the constants and section Mutation in the user guide for details.

Example

PGAContext *ctx;

...
PGASetDEVariant (ctx, PGA_DE_VARIANT_BEST);

Parameters
  • ctx – context variable

  • variant – symbolic constant for variant

Returns

None