From luca@peperone.idsia.ch Fri Oct 7 14:59:38 EDT 1994 Article: 3933 of comp.ai.genetic Newsgroups: comp.ai.genetic Path: cantaloupe.srv.cs.cmu.edu!das-news.harvard.edu!news2.near.net!MathWorks.Com!europa.eng.gtefsd.com!howland.reston.ans.net!EU.net!chsun!peperone!luca From: luca@peperone.idsia.ch (Luca Gambardella) Subject: BUG in GENEsYs 1.0 Message-ID: Sender: luca@peperone (Luca Gambardella) Organization: IDSIA Date: Tue, 4 Oct 1994 09:04:39 GMT Lines: 35 I'm making some experiments using GENEsYS 1.0 that I have got from FTP.AIC.NRL.NAVY.MIL /pub/galist/src/ga. I have discover that the system does not execute correctly crossover operation becouse it does not sort crossover points correctly. The function sort((char *) Pts, NbrPts, sizeof(int), icmp) in cross.c; does not sort anything!!. The error is in icmp function (in cross.c) that must be redefined as: int icmp(i,j) /* compare two integer values for qsort */ register int *i, *j; { return (*i - *j); } /* end icmp */ Luca Gambardella ------------------------------------------------------------------- Luca Gambardella IDSIA - Istituto Dalle Molle di Studi sull'Intelligenza Artificiale C.so Elvezia 36 6900 Lugano - CH tel. +41 91 228881 fax. +41 91 228994 email luca@idsia.ch -------------------------------------------------------------------