Function PGAGetCommunicator

Function Documentation

MPI_Comm PGAGetCommunicator(PGAContext *ctx)

Returns the default communicator used when PGARun is called.

Example

MPI_Comm comm;
PGAContext *ctx,
double f (PGAContext *ctx, int p, int pop, double *aux);

ctx = PGACreate (&argc, argv, PGA_DATATYPE_BINARY, 100, PGA_MAXIMIZE);
PGASetUp (ctx);
comm = PGAGetCommunicator (ctx);

Parameters
  • ctx – context variable

Returns

The default communicator