Normalized real_value

This commit is contained in:
evomarc 2001-05-21 04:10:55 +00:00
commit d9ddfeeaea
2 changed files with 2 additions and 2 deletions

View file

@ -12,7 +12,7 @@ double real_value(const std::vector<double>& _ind)
double sum = 0;
for (unsigned i = 0; i < _ind.size(); i++)
sum += _ind[i] * _ind[i];
return sqrt(sum);
return sum/_ind.size();
}

View file

@ -2,7 +2,7 @@
#ifdef _MSC_VER
#pragma warning(disable:4786)
#endif
#endif
#include <algorithm>
#include <string>