Use the objective type instead of double in metrics

This commit is contained in:
Johann Dreo 2013-06-07 17:51:01 +02:00
commit ac61b782c3

View file

@ -52,6 +52,8 @@ class moeoNormalizedSolutionVsSolutionBinaryMetric : public moeoSolutionVsSoluti
{ {
public: public:
typedef typename ObjectiveVector::Type Type;
/** /**
* Default ctr for any moeoNormalizedSolutionVsSolutionBinaryMetric object * Default ctr for any moeoNormalizedSolutionVsSolutionBinaryMetric object
*/ */
@ -72,7 +74,7 @@ class moeoNormalizedSolutionVsSolutionBinaryMetric : public moeoSolutionVsSoluti
* @param _max upper bound * @param _max upper bound
* @param _obj the objective index * @param _obj the objective index
*/ */
void setup(double _min, double _max, unsigned int _obj) void setup( Type _min, Type _max, unsigned int _obj)
{ {
if (_min == _max) if (_min == _max)
{ {