Function PGACharacterHash

Function Documentation

PGAHash PGACharacterHash(PGAContext *ctx, int p, int pop)

Return hash value of given gene.

Description

Note that this function is set in PGASetUp() as the hash user function for the char datatype by default.

Parameters
  • ctx – context variable

  • p – string index of the string to hash

  • pop – symbolic constant of the population string p is in

Returns

Hash value for string