/*
**  gp
**
**   genetic programming stuff
**
*/

/* 
**   Scott "Jerry" Lawrence
**   2000 January 23
**   j@absynth.com
*/

/*
** $Id: gp.h,v 1.4 2000/02/08 01:13:48 sdlpci Exp sdlpci $
**
** $Log: gp.h,v $
 * Revision 1.4  2000/02/08  01:13:48  sdlpci
 * population size is a variable now.
 *
 * Revision 1.3  2000/02/07  22:19:48  sdlpci
 * added more notes
 *
 * Revision 1.2  2000/01/25  17:37:01  sdlpci
 * added indent parameter to line_dump.
 * changed "infanticide" to "euthanasia"
 *
 * Revision 1.2  2000/01/25  17:37:01  sdlpci
 * added indent parameter to line_dump.
 * changed "infanticide" to "euthanasia"
 *
 * Revision 1.1  2000/01/24  16:38:21  sdlpci
 * Initial revision
 *
*/


#define GP_STATE_ADULT    (0)    /* fitness is computed */
#define GP_STATE_NEWBORN  (1)    /* needs new fitness computed */

extern int population_size;

typedef struct gp_individual
{
    GP_LINE * dna;
    int       fitness;
    int       generation;
    int       state;
} GP_INDIVIDUAL;

void gp_setup(void);
void gp_upset(void);

void gp_initial_population(void);
void gp_fitness(GP_INDIVIDUAL * i);

void gp_euthanasia(GP_INDIVIDUAL * i);
void gp_genocide(void);

void gp_run(INTMAP * map);
