Function PGAUpdateGeneration
Defined in File pga.c
Function Documentation
-
void PGAUpdateGeneration(PGAContext *ctx, MPI_Comm comm)
Update internal data structures for the next genetic algorithm iteration, and check if the termination conditions, both user and PGAPack, have been met.
Description
This routine must be called by both rank-0 and worker processes at the end of each GA generation.
Example
PGAContext *ctx; ... PGAUpdateGeneration (ctx, MPI_COMM_WORLD);
- Parameters:
ctx – context variable
comm – an MPI communicator
- Returns:
PGA_TRUE if the genetic algorithm has terminated, otherwise PGA_FALSE