Skip to content
Snippets Groups Projects
Commit 8f8aa286 authored by Martin Beseda's avatar Martin Beseda
Browse files

FIX: Fixed bad de-normalization formula.

parent 96f9bf4c
No related branches found
No related tags found
No related merge requests found
......@@ -40,6 +40,7 @@ double DoubleUnitStrategy::de_normalize(double n) {
THROW_RUNTIME_ERROR("Data were not normalized, so de-normalization cannot progress!");
}
return 0.5 * (1 + (this->get_max_value() - this->get_min_value()) * n) + this->get_min_value();
// return 0.5 * (1 + (this->get_max_value() - this->get_min_value()) * n) + this->get_min_value();
return 0.5 * ((1 + n) * (this->get_max_value() - this->get_min_value())) + this->get_min_value();
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment