[Paradiseo-help] [paradiseo-Bugs][3703] Problem with the moeoParetoObjectiveComparator

paradiseo-bugs at gforge.inria.fr paradiseo-bugs at gforge.inria.fr
Ven 10 Aou 15:12:40 CEST 2007


Bugs item #3703, was opened at 30/07/2007 14:49
You can respond by visiting: 
http://gforge.inria.fr/tracker/?func=detail&atid=663&aid=3703&group_id=145

>Status: Closed
Priority: 3
Submitted By: Nobody (None)
>Assigned to: Arnaud Liefooghe (liefooga)
Summary: Problem with the moeoParetoObjectiveComparator 
>Resolution: Fixed
Group: None
>Category: ParadisEO-ix86-1.0-beta


Initial Comment:
In function :

const bool operator()(const ObjectiveVector & _objectiveVector1, const ObjectiveVector & _objectiveVector2)



of moeoParetoObjectiveVectorComparator.h



the comparaison is wrong in maximizing cases. Should be :



                else if (ObjectiveVector::maximizing(i))

                {

                    if (_objectiveVector1[i] < _objectiveVector2[i])

                    {

                        dom = true;             //_objectiveVector1[i] is not better than _objectiveVector2[i]

                    }

                    else

                    {

                        return false;   //_objectiveVector2 cannot dominate _objectiveVector1

                    }

                }



instead of (note the change in the comparison) :



                else if (ObjectiveVector::maximizing(i))

                {

                    if (_objectiveVector1[i] < _objectiveVector2[i])

                    {

                        dom = true;             //_objectiveVector1[i] is not better than _objectiveVector2[i]

                    }

                    else

                    {

                        return false;   //_objectiveVector2 cannot dominate _objectiveVector1

                    }

                }



----------------------------------------------------------------------

>Comment By: Arnaud Liefooghe (liefooga)
Date: 10/08/2007 15:12

Message:
The correct code is :

// ...

else if (ObjectiveVector::maximizing(i))

{

     if (_objectiveVector1[i] < _objectiveVector2[i])

     {

// ...



Thank you, this will be fixed in the next version.



ParadisEO Support



----------------------------------------------------------------------

You can respond by visiting: 
http://gforge.inria.fr/tracker/?func=detail&atid=663&aid=3703&group_id=145





Plus d'informations sur la liste de diffusion Paradiseo-help