Modified crossover and mutation to account for the new interface (bool ...)

Added the genop.tmpl, template for general op, 3 cases, growing pop,
shrinking pop through erase, thrinking pop through extra selector
This commit is contained in:
evomarc 2001-02-17 06:42:20 +00:00
commit 1662fd2a8b
3 changed files with 186 additions and 11 deletions

View file

@ -21,12 +21,13 @@ public:
* eoMon crossover - modifies the parent
* @param Indi The parent
*/
void operator()(Indi& Indi)
bool operator()(Indi& Indi)
{
// do whatever needs to be done
// DON'T FORGET if an individual is modified, to invalidate its fitness!!!
Indi.invalidate();
// if Indi has been modified
return true;
// otherwise
// return false;
}
protected: